Skip to content

Commit b09be80

Browse files
committed
Refactor VQT_Analyzer parameters and update batch_run to use wandb_script_wrapper path
1 parent 3bc633d commit b09be80

File tree

4 files changed

+31
-24
lines changed

4 files changed

+31
-24
lines changed

batch_run/dispatcher.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
from face_rhythm import util
1010

1111
path_self, \
12+
path_wandb_script_wrapper, \
1213
path_script, \
1314
dir_save, \
1415
dir_videos, \
@@ -257,7 +258,7 @@
257258
[os.system(f"chmod -R 777 {p}") for p in [dir_save, dir_videos, path_ROIs]]
258259

259260
## run batch_run function
260-
paths_scripts = [path_script]
261+
paths_scripts = [path_wandb_script_wrapper]
261262
params_list = params
262263
max_n_jobs=1
263264
name_save=name_job

face_rhythm/pipelines.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ def pipeline_basic(params):
220220
## - `F_min`: Lowest frequency band to use.
221221
## - `F_max`: Highest frequency band to use.
222222
## - `downsample_factor`: How much to downsample the spectrogram by in time.
223-
## - `return_complex`: Whether or not to return the complex spectrogram. Generally set to False unless you want to try something fancy.
223+
## - `take_abs`: Whether or not to return the complex spectrogram. Generally set to True unless you want to try something fancy.
224224

225225
params['VQT_Analyzer']['device'] = fr.helpers.set_device(use_GPU=use_GPU)
226226

face_rhythm/util.py

Lines changed: 17 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -148,21 +148,24 @@ def get_default_parameters(
148148
},
149149
"VQT_Analyzer": {
150150
"params_VQT": {
151-
"Q_lowF": 4,
152-
"Q_highF": 10,
153-
"F_min": 1.0,
154-
"F_max": 60,
155-
"n_freq_bins": 36,
156-
"win_size": 501,
157-
"symmetry": 'center',
158-
"taper_asymmetric": True,
159-
"plot_pref": False,
160-
"downsample_factor": 20,
161-
"padding": "valid",
162-
"batch_size": 10,
163-
"return_complex": False,
164-
"progressBar": True,
151+
'Fs_sample': 120,
152+
'Q_lowF': 4.0,
153+
'Q_highF': 10.0,
154+
'F_min': 1.0,
155+
'F_max': 60,
156+
'n_freq_bins': 36,
157+
'window_type': 'hann',
158+
'symmetry': 'center',
159+
'taper_asymmetric': True,
160+
'downsample_factor': 20,
161+
'padding': 'valid',
162+
'fft_conv': True,
163+
'fast_length': True,
164+
'take_abs': True,
165+
'filters': None,
166+
'plot_pref': False,
165167
},
168+
"batch_size": 10,
166169
"normalization_factor": 0.95,
167170
"spectrogram_exponent": 1.0,
168171
"one_over_f_exponent": 0.5,

scripts/params_pipeline_basic.json

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -91,21 +91,24 @@
9191
},
9292
"VQT_Analyzer": {
9393
"params_VQT": {
94-
"Q_lowF": 4,
95-
"Q_highF": 10,
94+
"Fs_sample": 120,
95+
"Q_lowF": 4.0,
96+
"Q_highF": 10.0,
9697
"F_min": 1.0,
9798
"F_max": 60,
9899
"n_freq_bins": 36,
99-
"win_size": 501,
100-
"symmetry": "left",
100+
"window_type": "hann",
101+
"symmetry": "center",
101102
"taper_asymmetric": true,
102-
"plot_pref": false,
103103
"downsample_factor": 20,
104104
"padding": "valid",
105-
"batch_size": 10,
106-
"return_complex": false,
107-
"progressBar": true
105+
"fft_conv": true,
106+
"fast_length": true,
107+
"take_abs": true,
108+
"filters": null,
109+
"plot_pref": false,
108110
},
111+
"batch_size": 10,
109112
"normalization_factor": 0.95,
110113
"spectrogram_exponent": 1.0,
111114
"one_over_f_exponent": 0.5,

0 commit comments

Comments
 (0)