Skip to content

Commit

Permalink
channel loader returns the electrode sites indexing, closes #893
Browse files Browse the repository at this point in the history
  • Loading branch information
oliche committed Dec 4, 2024
1 parent 1382460 commit 0c8944d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion brainbox/io/one.py
Original file line number Diff line number Diff line change
Expand Up @@ -1017,7 +1017,10 @@ def load_channels(self, **kwargs):
self.download_spike_sorting_object(obj='channels', missing='ignore', **kwargs)
channels = self._load_object(self.files['channels'], wildcards=self.one.wildcards)
if 'electrodeSites' in self.files: # if common dict keys, electrodeSites prevails
channels = channels | self._load_object(self.files['electrodeSites'], wildcards=self.one.wildcards)
esites = channels | self._load_object(self.files['electrodeSites'], wildcards=self.one.wildcards)
if alfio.check_dimensions(esites) != 0:
esites = self._load_object(self.files['electrodeSites'], wildcards=self.one.wildcards)
esites['rawInd'] = np.arange(esites[list(esites.keys())[0]].shape[0])
if 'brainLocationIds_ccf_2017' not in channels:
_logger.debug(f"loading channels from alyx for {self.files['channels']}")
_channels, self.histology = _load_channel_locations_traj(
Expand Down

0 comments on commit 0c8944d

Please sign in to comment.