Skip to content

Commit d57a397

Browse files
committed
Misc fixes
1 parent 8725078 commit d57a397

File tree

6 files changed

+17
-43
lines changed

6 files changed

+17
-43
lines changed

blech_dat_file_join.py

Lines changed: 0 additions & 31 deletions
This file was deleted.

blech_make_arrays.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ def create_emg_trials_for_digin(
211211
match_ind = np.where(
212212
np.abs(taste_info_frame['start'] - this_start) < match_tol
213213
)[0]
214-
assert len(match_ind) == 1, 'Exact match not found'
214+
assert len(match_ind) == 1, f'Exact match not found between taste and laser signals given tolerance of {(match_tol)/sampling_rate} sec'
215215
match_trials_ind.append(match_ind[0])
216216
match_trials = taste_info_frame.iloc[match_trials_ind]['abs_trial_num'].values
217217
laser_info_frame['abs_trial_num'] = match_trials
@@ -479,4 +479,4 @@ def create_emg_trials_for_digin(
479479
hf5.close()
480480

481481
# Write successful execution to log
482-
this_pipeline_check.write_to_log(script_path, 'completed')
482+
this_pipeline_check.write_to_log(script_path, 'completed')

params/_templates/sorting_params_template.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,10 @@
5353
2000,
5454
5000
5555
],
56+
"responsiveness_pre_post_durations": [
57+
1000,
58+
2000
59+
],
5660
"pal_iden_calc_params": {
5761
"window_size": 250,
5862
"step_size": 25

params/dependency_graph.json

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,8 @@
77
"blech_process.py": "blech_common_avg_reference.py",
88
"blech_post_process.py": "blech_process.py",
99
"blech_units_plot.py": "blech_post_process.py",
10-
"blech_make_psth.py": "blech_make_arrays.py",
1110
"emg/emg_filter.py": "blech_make_arrays.py",
12-
"blech_palatability_identity_setup.py": "blech_make_psth.py",
13-
"blech_overlay_psth.py": "blech_palatability_identity_setup.py",
11+
"blech_unit_characteristics.py": "blech_make_arrays.py",
1412
"utils/qa_utils/unit_similarity.py": "blech_post_process.py",
1513
"utils/qa_utils/drift_check.py": "blech_post_process.py"
1614
},

pipeline_testing/test_data_handling/download_test_data.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
# Google Drive link : https://drive.google.com/file/d/1EcpUIqp81h3J89-6dEEueeULqBlKW5a7/view?usp=sharing
2+
13
SCRIPT_PATH=$(realpath ${BASH_SOURCE[0]})
24
# Find path to neuRecommend as parent directory of test.sh
35
DIR_PATH=$(dirname ${SCRIPT_PATH})

utils/cluster_stability.py

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,18 +22,19 @@
2222
import seaborn as sns
2323
import matplotlib
2424

25-
def load_electrode_data(electrode_num):
25+
def load_electrode_data(data_dir, electrode_num):
2626
"""
2727
Load data from disk
2828
"""
2929

3030
loading_paths = [\
31-
f'./spike_waveforms/electrode{electrode_num:02}/spike_waveforms.npy',
32-
f'./spike_times/electrode{electrode_num:02}/spike_times.npy',
33-
f'./spike_waveforms/electrode{electrode_num:02}/pca_waveforms.npy',
34-
f'./spike_waveforms/electrode{electrode_num:02}/energy.npy',
35-
f'./spike_waveforms/electrode{electrode_num:02}/spike_amplitudes.npy',
31+
f'spike_waveforms/electrode{electrode_num:02}/spike_waveforms.npy',
32+
f'spike_times/electrode{electrode_num:02}/spike_times.npy',
33+
f'spike_waveforms/electrode{electrode_num:02}/pca_waveforms.npy',
34+
f'spike_waveforms/electrode{electrode_num:02}/energy.npy',
35+
f'spike_waveforms/electrode{electrode_num:02}/spike_amplitudes.npy',
3636
]
37+
loading_paths = [os.path.join(data_dir, x) for x in loading_paths]
3738

3839
loaded_dat = [np.load(x) for x in loading_paths]
3940

@@ -78,7 +79,7 @@ def return_clustering_solutions(electrode_num):
7879
pca_slices,
7980
energy,
8081
amplitudes,
81-
) = load_electrode_data(electrode_num)
82+
) = load_electrode_data(data_dir, electrode_num)
8283

8384
# Load predictions for all clustering solutions
8485
predictions = [load_cluster_predictions(electrode_num, x) \

0 commit comments

Comments
 (0)