from element_lab.lab import Source, Lab, Protocol, User, Location, Project from element_animal.subject import Subject from element_session.session import Session from .paths import (get_imaging_root_data_dir, get_scan_image_files, get_scan_box_files) if 'custom' not in dj.config: dj.config['custom'] = {} db_prefix = dj.config['custom'].get('database.prefix', '') # ------------- Activate "lab", "subject", "session" schema ------------- lab.activate(db_prefix + 'lab') subject.activate(db_prefix + 'subject', linking_module=__name__) session.activate(db_prefix + 'session', linking_module=__name__) # ------------- Declare table Equipment for use in element_calcium_imaging ------------- @lab.schema class Equipment(dj.Manual): definition = """ scanner: varchar(32) """
"Lab", "Protocol", "User", "Project", "ProjectKeywords", "ProjectPublication", "ProjectSourceCode", "ProjectUser", "Session", "SessionDirectory", "SessionExperimenter", "SessionNote", "ProjectSession", ] # Activate "lab", "subject", "session", "genotyping" schemas ------------- lab.activate(db_prefix + "lab") subject.activate(db_prefix + "subject", linking_module=__name__) from element_animal.export.nwb import subject_to_nwb from element_lab.export.nwb import element_lab_to_nwb_dict Experimenter = lab.User session.activate(db_prefix + "session", linking_module=__name__) genotyping.activate( db_prefix + "genotyping", db_prefix + "subject", linking_module=__name__ )