From cff20a532dbc0daa4d6909b77633f9f83cb254e4 Mon Sep 17 00:00:00 2001 From: Georg Raiser Date: Wed, 18 Dec 2024 15:56:36 +0100 Subject: [PATCH] for heberto --- ...ert_brainwide_map_processed_only_local_testing.py | 2 +- .../convert_brainwide_map_raw_only_local_testing.py | 2 +- .../datainterfaces/_ibl_sorting_extractor.py | 12 ++++++++++++ 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/src/ibl_to_nwb/_scripts/convert_brainwide_map_processed_only_local_testing.py b/src/ibl_to_nwb/_scripts/convert_brainwide_map_processed_only_local_testing.py index d197a48..b3a4429 100644 --- a/src/ibl_to_nwb/_scripts/convert_brainwide_map_processed_only_local_testing.py +++ b/src/ibl_to_nwb/_scripts/convert_brainwide_map_processed_only_local_testing.py @@ -79,7 +79,7 @@ subject_folder_path = nwbfiles_folder_path / f"sub-{subject_id}" subject_folder_path.mkdir(exist_ok=True) -nwbfile_path = subject_folder_path / f"sub-{subject_id}_ses-{eid}_desc-processed.nwb" +nwbfile_path = subject_folder_path / f"sub-{subject_id}_ses-{eid}_desc-processed_.nwb" session_converter.run_conversion( nwbfile_path=nwbfile_path, diff --git a/src/ibl_to_nwb/_scripts/convert_brainwide_map_raw_only_local_testing.py b/src/ibl_to_nwb/_scripts/convert_brainwide_map_raw_only_local_testing.py index 04f1422..085b31b 100644 --- a/src/ibl_to_nwb/_scripts/convert_brainwide_map_raw_only_local_testing.py +++ b/src/ibl_to_nwb/_scripts/convert_brainwide_map_raw_only_local_testing.py @@ -61,7 +61,7 @@ subject_folder_path = nwbfiles_folder_path / f"sub-{subject_id}" subject_folder_path.mkdir(exist_ok=True) -nwbfile_path = subject_folder_path / f"sub-{subject_id}_ses-{eid}_desc-raw.nwb" +nwbfile_path = subject_folder_path / f"sub-{subject_id}_ses-{eid}_desc-raw_ecephys+raw_video_.nwb" session_converter.run_conversion(nwbfile_path=nwbfile_path, metadata=metadata, overwrite=True) diff --git a/src/ibl_to_nwb/datainterfaces/_ibl_sorting_extractor.py b/src/ibl_to_nwb/datainterfaces/_ibl_sorting_extractor.py index 9a0b480..3602a79 100644 --- a/src/ibl_to_nwb/datainterfaces/_ibl_sorting_extractor.py +++ b/src/ibl_to_nwb/datainterfaces/_ibl_sorting_extractor.py @@ -10,6 +10,7 @@ from iblatlas.regions import BrainRegions from one.api import ONE from spikeinterface import BaseSorting, BaseSortingSegment +from neuroconv.utils import get_json_schema_from_method_signature class IblSortingExtractor(BaseSorting): @@ -19,6 +20,17 @@ class IblSortingExtractor(BaseSorting): installation_mesg = "" name = "iblsorting" + def get_source_schema(cls) -> dict: + """ + Infer the JSON schema for the source_data from the method signature (annotation typing). + + Returns + ------- + dict + The JSON schema for the source_data. + """ + return get_json_schema_from_method_signature(cls, exclude=["source_data", "one"]) + # def __init__(self, session: str, cache_folder: Optional[DirectoryPath] = None, revision: Optional[str] = None): def __init__( self,