Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement adding data from config file #934

Draft
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

calderast
Copy link

@calderast calderast commented Apr 17, 2024

Implement adding data from config file

Allows users to specify Institution, Lab, LabMember, Subject, and CameraDevice information for an nwb file in the associated config file.

Checklist:

  • This PR should be accompanied by a release: (yes/no/unsure)
  • (If release) I have updated the CITATION.cff
  • I have updated the CHANGELOG.md
  • I have added/edited docs/notebooks to reflect the changes

Copy link
Member

@CBroz1 CBroz1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for working on this!

I started on common_subject and worked up, so the 'why' might be in the later comments. All my comments are along the lines of "This old part of spyglass doesn't do this python thing that I think we'd be better off if we did". What you've got so far looks like it would work perfectly well, but I'm cutting down lines of code in my suggestions

src/spyglass/common/common_subject.py Outdated Show resolved Hide resolved
src/spyglass/common/common_session.py Outdated Show resolved Hide resolved
src/spyglass/common/common_lab.py Outdated Show resolved Hide resolved
src/spyglass/common/common_device.py Outdated Show resolved Hide resolved
src/spyglass/common/common_device.py Outdated Show resolved Hide resolved
src/spyglass/common/common_device.py Outdated Show resolved Hide resolved
calderast and others added 2 commits April 17, 2024 13:51
Co-authored-by: Chris Brozdowski <CBrozdowski@yahoo.com>
@edeno edeno added the infrastructure Unix, MySQL, etc. settings/issues impacting users label Apr 19, 2024
@@ -252,13 +252,16 @@ class CameraDevice(SpyglassMixin, dj.Manual):
"""

@classmethod
def insert_from_nwbfile(cls, nwbf):
def insert_from_nwbfile(cls, nwbf, config):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

config should probably be optional here since not everyone will have one.

@edeno
Copy link
Collaborator

edeno commented May 6, 2024

@calderast what is the status of this PR? is it mostly good to go (aside from the change requested above) or are you still working on things?

@samuelbray32 samuelbray32 self-assigned this May 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
infrastructure Unix, MySQL, etc. settings/issues impacting users
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implementation of import config
4 participants