BouchardLab / nsds_lab_to_nwb

Python package to convert NSDS Lab data to NWB files.
https://nsds-lab-to-nwb.readthedocs.io/en/latest/
0 stars 4 forks source link

Fixed auto yaml dump behavior #106

Closed jthermiz closed 2 years ago

jthermiz commented 3 years ago

Description and related issues

Currently, the user needs to specify the block metadata yaml file path, which is annoying. I propose making this an optional argument in generate_nwb.py where the default value is None. In nwb_builder.py, if None is detected, it files in a good default path to look for metadata files. In the metadata_manager this will fail and trigger the except block to look for experiment notes and then dump those as a yaml (if found of course).

I tested this locally and it passes.

Closes #(issue number)

Checklist:

jihyunbak commented 3 years ago

just a quick FYI, the default block_metadata_path feature might overlap with the open PR #105 (can I merge this PR?)

jthermiz commented 3 years ago

@jihyunbak Ahh shot, I didn't realize that. I tried to run your PR, but ran into an error see #105. The block_metadata_path feature does overlap, but I don't think it will work bc ExpNoteReader will need a path to look for experiment notes rather than a .yaml path. Since #105 handles a lot more, I can try to integrate this PR into #105.

jihyunbak commented 3 years ago

Hi John, could you also pull the branch of the open PR in the metadata repo if you haven't already, and see if that fixes the error? If that doesn't work I will look into this next week!

On Sat, Jul 31, 2021 at 11:24 John Hermiz @.***> wrote:

@jihyunbak https://github.com/jihyunbak Ahh shot, I didn't realize that. I tried to run your PR, but ran into an error see #105 https://github.com/BouchardLab/nsds_lab_to_nwb/pull/105. The block_metadata_path feature does overlap, but I don't think it will work bc ExpNoteReader will need a path to look for experiment notes rather than a .yaml path. Since #105 https://github.com/BouchardLab/nsds_lab_to_nwb/pull/105 handles a lot more, I can try to integrate this PR into #105 https://github.com/BouchardLab/nsds_lab_to_nwb/pull/105.

— You are receiving this because you were mentioned.

Reply to this email directly, view it on GitHub https://github.com/BouchardLab/nsds_lab_to_nwb/pull/106#issuecomment-890386574, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJLF34ZORUJZG2EXIXUPI4DT2Q5WLANCNFSM5BJVBLSA .

jihyunbak commented 3 years ago

Should this be closed?