Skip to content

Commit 833b14f

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 8d49927 commit 833b14f

1 file changed

Lines changed: 7 additions & 6 deletions

File tree

src/probeinterface/neuropixels_tools.py

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -91,15 +91,16 @@
9191
"tip_length_um": "tip_length_um",
9292
}
9393

94+
9495
def get_probe_length(probe_part_number: str) -> int:
9596
"""
96-
Returns the length of a given probe. We assume a length of
97+
Returns the length of a given probe. We assume a length of
9798
1cm (10_000 microns) by default.
9899
99100
Parameters
100101
----------
101102
probe_part_number : str
102-
The part number of the probe e.g. 'NP2013'.
103+
The part number of the probe e.g. 'NP2013'.
103104
104105
Returns
105106
-------
@@ -173,7 +174,7 @@ def make_npx_description(probe_part_number):
173174
# Read the imro table formats to find out which fields the imro tables contain
174175
imro_table_format_type = pt_metadata["imro_table_format_type"]
175176
imro_table_fields = probe_features["z_imro_formats"][imro_table_format_type + "_elm_flds"]
176-
177+
177178
# parse the imro_table_fields, which look like (value value value ...)
178179
list_of_imro_fields = imro_table_fields.replace("(", "").replace(")", "").split(" ")
179180

@@ -190,7 +191,7 @@ def make_npx_description(probe_part_number):
190191
pi_metadata["contour_description"] = get_probe_contour_vertices(shank_width, tip_length, probe_length)
191192

192193
# Get the mux table. This describes which electrodes are multiplexed together, meaning
193-
# which electrodes are sampled at the same time.
194+
# which electrodes are sampled at the same time.
194195
mux_table_format_type = pt_metadata["mux_table_format_type"]
195196
mux_information = probe_features["z_mux_tables"].get(mux_table_format_type)
196197
pi_metadata["mux_table_array"] = make_mux_table_array(mux_information)
@@ -403,7 +404,7 @@ def _read_imro_string(imro_str: str, imDatPrb_pn: Optional[str] = None) -> Probe
403404
probe_type_num_chans, *imro_table_values_list, _ = imro_str.strip().split(")")
404405

405406
# probe_type_num_chans looks like f"({probe_type},{num_chans}"
406-
probe_type = probe_type_num_chans.split(',')[0][1:]
407+
probe_type = probe_type_num_chans.split(",")[0][1:]
407408

408409
probe_description = make_npx_description(imDatPrb_pn)
409410

@@ -440,7 +441,7 @@ def _read_imro_string(imro_str: str, imDatPrb_pn: Optional[str] = None) -> Probe
440441

441442
# this is vector annotations
442443
vector_properties = ("channel_ids", "banks", "references", "ap_gains", "lf_gains", "ap_hp_filters")
443-
vector_properties_available = {k: v for k, v in contact_info.items() if (k in vector_properties) and (len(v)>0) }
444+
vector_properties_available = {k: v for k, v in contact_info.items() if (k in vector_properties) and (len(v) > 0)}
444445
probe.annotate_contacts(**vector_properties_available)
445446

446447
return probe

0 commit comments

Comments
 (0)