@@ -143,11 +143,13 @@ def create_neuropixels_probe(probe_type: str = "neuropixels 1.0 - 3A"):
143
143
}
144
144
145
145
probe_type = {"probe_type" : probe_type }
146
- electrodes = build_electrode_layouts ({** neuropixels_probes_config [probe_type ["probe_type" ]], ** probe_type })
146
+ electrode_layouts : list [dict ] = build_electrode_layouts (
147
+ ** {** neuropixels_probes_config [probe_type ["probe_type" ]], ** probe_type }
148
+ )
147
149
with ProbeType .connection .transaction :
148
150
ProbeType .insert1 (probe_type , skip_duplicates = True )
149
151
ProbeType .Electrode .insert (
150
- [{** probe_type , ** e } for e in electrodes ], skip_duplicates = True
152
+ [{** e } for e in electrode_layouts ], skip_duplicates = True
151
153
)
152
154
153
155
@@ -203,7 +205,7 @@ class Electrode(dj.Part):
203
205
204
206
205
207
def build_electrode_layouts (
206
- probe_type : str ,
208
+ probe_type : str ,
207
209
site_count_per_shank : int ,
208
210
col_spacing : float = None ,
209
211
row_spacing : float = None ,
@@ -243,7 +245,7 @@ def build_electrode_layouts(
243
245
shank_rows = np .repeat (range (row_count ), col_count_per_shank )
244
246
245
247
electrode_layouts = [
246
- {
248
+ {
247
249
"probe_type" : probe_type ,
248
250
"electrode" : (site_count_per_shank * shank_no ) + e_id ,
249
251
"shank" : shank_no ,
0 commit comments