Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
… into spikeglx
  • Loading branch information
kabilar committed Sep 16, 2023
2 parents 2b75f9f + 3b8efe5 commit 9374a11
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 13 deletions.
11 changes: 3 additions & 8 deletions element_array_ephys/probe.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
"""
Neuropixels Probes
"""
from __future__ import annotations

import datajoint as dj

from .readers import probe_geometry
Expand Down Expand Up @@ -109,13 +107,10 @@ def create_neuropixels_probe(probe_type: str = "neuropixels 1.0 - 3A"):
npx_probes_config["neuropixels 2.0 - MS"] = npx_probes_config["NP2010"]

probe_type = {"probe_type": probe_type}
probe_params = {
n: v
for n, v in zip(
probe_params = dict(zip(
probe_geometry.geom_param_names,
npx_probes_config[probe_type["probe_type"]],
)
}
npx_probes_config[probe_type["probe_type"]]
))
electrode_layouts = probe_geometry.build_npx_probe(
**{**probe_params, **probe_type}
)
Expand Down
2 changes: 2 additions & 0 deletions element_array_ephys/readers/probe_geometry.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
from __future__ import annotations

import numpy as np
import pandas as pd
from typing import List
Expand Down
10 changes: 5 additions & 5 deletions element_array_ephys/readers/spikeglx.py
Original file line number Diff line number Diff line change
Expand Up @@ -450,12 +450,12 @@ def _transform_geom_to_shank(self):

from . import probe_geometry

probe_params = {
n: v
for n, v in zip(
probe_geometry.geom_param_names, probe_geometry.M[self.probe_PN]
probe_params = dict(
zip(
probe_geometry.geom_param_names,
probe_geometry.M[self.probe_PN]
)
}
)
probe_params["probe_type"] = self.probe_PN
elec_pos_df = probe_geometry.build_npx_probe(**probe_params)

Expand Down

0 comments on commit 9374a11

Please sign in to comment.