File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -679,7 +679,10 @@ def make(self, key):
679679 kilosort_dir = find_full_path (get_ephys_root_data_dir (), output_dir )
680680
681681 kilosort_dataset = kilosort .Kilosort (kilosort_dir )
682- acq_software = (EphysRecording & key ).fetch1 ('acq_software' )
682+ acq_software , sample_rate = (EphysRecording & key ).fetch1 (
683+ 'acq_software' , 'sampling_rate' )
684+
685+ sample_rate = kilosort_dataset .data ['params' ].get ('sample_rate' , sample_rate )
683686
684687 # ---------- Unit ----------
685688 # -- Remove 0-spike units
@@ -709,7 +712,7 @@ def make(self, key):
709712 if (kilosort_dataset .data ['spike_clusters' ] == unit ).any ():
710713 unit_channel , _ = kilosort_dataset .get_best_channel (unit )
711714 unit_spike_times = (spike_times [kilosort_dataset .data ['spike_clusters' ] == unit ]
712- / kilosort_dataset . data [ 'params' ][ ' sample_rate' ] )
715+ / sample_rate )
713716 spike_count = len (unit_spike_times )
714717
715718 units .append ({
You can’t perform that action at this time.
0 commit comments