BouchardLab / process_nwb

Functions for preprocessing timeseries data stored in the NWB format
https://process-nwb.readthedocs.io/en/latest/
4 stars 6 forks source link

Wavelet inspect #50

Closed jthermiz closed 3 years ago

jthermiz commented 3 years ago

Minor necessary fix:

Minor optional edits:

jthermiz commented 3 years ago

Hi @JesseLivezey can I go ahead and merge this?

jthermiz commented 3 years ago

Re removing .py, sounds good. I didn't realize that not including a .py is common practice for scripts like this.

jthermiz commented 3 years ago

@JesseLivezey Are you ok with me merging this PR?

JesseLivezey commented 3 years ago

@jthermiz this PR causes 1 test to fail and there were also some formatting problems. Can you make another PR to fix?

The post_resample_rate changes introduced a problem in the code when the phase is saved.

pytest -sv tests/test_pipeline.py::test_pipeline
# tests/test_pipeline.py::test_pipeline FAILED

            series = [elec_series_wvlt_amp]
            if not abs_only:
                if post_resample_rate is not None:
>                   raise ValueError('Wavelet phase should not be resampled.')
E                   ValueError: Wavelet phase should not be resampled.

process_nwb/wavelet_transform.py:391: ValueError

You can probably set your editor to automatically remove these sorts of whitepsace

flake8 process_nwb tests
# process_nwb/wavelet_transform.py:86:35: W291 trailing whitespace
# process_nwb/wavelet_transform.py:351:1: W293 blank line contains whitespace
# process_nwb/wavelet_transform.py:354:1: W293 blank line contains whitespace