-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implement scope control over check submodule (#486)
* implement scope control over check submodule * remove hallucinated names and fix test imports * adjust imports for deprecated submodules --------- Co-authored-by: CodyCBakerPhD <[email protected]>
- Loading branch information
1 parent
d6a13ca
commit bf93524
Showing
28 changed files
with
313 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,149 @@ | ||
from .ecephys import * | ||
from .general import * | ||
from .image_series import * | ||
from .images import * | ||
from .nwb_containers import * | ||
from .nwbfile_metadata import * | ||
from .ogen import * | ||
from .ophys import * | ||
from .tables import * | ||
from .time_series import * | ||
from .icephys import * | ||
from .behavior import * | ||
from ._ecephys import ( | ||
check_negative_spike_times, | ||
check_electrical_series_dims, | ||
check_electrical_series_reference_electrodes_table, | ||
check_spike_times_not_in_unobserved_interval, | ||
) | ||
from ._general import ( | ||
check_description, | ||
check_name_slashes, | ||
) | ||
from ._image_series import ( | ||
check_image_series_data_size, | ||
check_image_series_external_file_relative, | ||
check_image_series_external_file_valid, | ||
) | ||
from ._images import ( | ||
check_order_of_images_unique, | ||
check_order_of_images_len, | ||
check_index_series_points_to_image, | ||
) | ||
from ._nwb_containers import ( | ||
check_empty_string_for_optional_attribute, | ||
check_small_dataset_compression, | ||
check_large_dataset_compression, | ||
) | ||
from ._nwbfile_metadata import ( | ||
check_keywords, | ||
check_institution, | ||
check_subject_age, | ||
check_subject_sex, | ||
check_subject_exists, | ||
check_doi_publications, | ||
check_experimenter_form, | ||
check_experimenter_exists, | ||
check_experiment_description, | ||
check_subject_id_exists, | ||
check_subject_species_exists, | ||
check_subject_species_form, | ||
check_subject_proper_age_range, | ||
check_session_start_time_future_date, | ||
check_processing_module_name, | ||
check_session_start_time_old_date, | ||
) | ||
from ._ogen import ( | ||
check_optogenetic_stimulus_site_has_optogenetic_series, | ||
) | ||
from ._ophys import ( | ||
check_excitation_lambda_in_nm, | ||
check_plane_segmentation_image_mask_shape_against_ref_images, | ||
check_roi_response_series_dims, | ||
check_emission_lambda_in_nm, | ||
check_roi_response_series_link_to_plane_segmentation, | ||
) | ||
from ._tables import ( | ||
check_single_row, | ||
check_ids_unique, | ||
check_empty_table, | ||
check_col_not_nan, | ||
check_column_binary_capability, | ||
check_dynamic_table_region_data_validity, | ||
check_time_interval_time_columns, | ||
check_time_intervals_stop_after_start, | ||
check_table_values_for_dict, | ||
check_table_time_columns_are_not_negative, | ||
) | ||
from ._time_series import ( | ||
check_resolution, | ||
check_missing_unit, | ||
check_regular_timestamps, | ||
check_timestamps_ascending, | ||
check_data_orientation, | ||
check_timestamps_without_nans, | ||
check_timestamps_match_first_dimension, | ||
check_timestamp_of_the_first_sample_is_not_negative, | ||
check_rate_is_not_zero, | ||
) | ||
from ._icephys import ( | ||
check_intracellular_electrode_cell_id_exists, | ||
) | ||
from ._behavior import ( | ||
check_compass_direction_unit, | ||
check_spatial_series_radians_magnitude, | ||
check_spatial_series_dims, | ||
check_spatial_series_degrees_magnitude, | ||
) | ||
|
||
__all__ = [ | ||
"check_negative_spike_times", | ||
"check_electrical_series_dims", | ||
"check_electrical_series_reference_electrodes_table", | ||
"check_spike_times_not_in_unobserved_interval", | ||
"check_description", | ||
"check_name_slashes", | ||
"check_image_series_data_size", | ||
"check_image_series_external_file_relative", | ||
"check_image_series_external_file_valid", | ||
"check_order_of_images_unique", | ||
"check_order_of_images_len", | ||
"check_index_series_points_to_image", | ||
"check_empty_string_for_optional_attribute", | ||
"check_small_dataset_compression", | ||
"check_large_dataset_compression", | ||
"check_keywords", | ||
"check_institution", | ||
"check_subject_age", | ||
"check_subject_sex", | ||
"check_subject_exists", | ||
"check_doi_publications", | ||
"check_experimenter_form", | ||
"check_experimenter_exists", | ||
"check_experiment_description", | ||
"check_subject_id_exists", | ||
"check_subject_species_exists", | ||
"check_subject_species_form", | ||
"check_subject_proper_age_range", | ||
"check_session_start_time_future_date", | ||
"check_processing_module_name", | ||
"check_session_start_time_old_date", | ||
"check_optogenetic_stimulus_site_has_optogenetic_series", | ||
"check_excitation_lambda_in_nm", | ||
"check_plane_segmentation_image_mask_shape_against_ref_images", | ||
"check_roi_response_series_dims", | ||
"check_emission_lambda_in_nm", | ||
"check_roi_response_series_link_to_plane_segmentation", | ||
"check_single_row", | ||
"check_ids_unique", | ||
"check_empty_table", | ||
"check_col_not_nan", | ||
"check_column_binary_capability", | ||
"check_dynamic_table_region_data_validity", | ||
"check_time_interval_time_columns", | ||
"check_time_intervals_stop_after_start", | ||
"check_table_values_for_dict", | ||
"check_table_time_columns_are_not_negative", | ||
"check_resolution", | ||
"check_missing_unit", | ||
"check_regular_timestamps", | ||
"check_timestamps_ascending", | ||
"check_data_orientation", | ||
"check_timestamps_without_nans", | ||
"check_timestamps_match_first_dimension", | ||
"check_timestamp_of_the_first_sample_is_not_negative", | ||
"check_rate_is_not_zero", | ||
"check_intracellular_electrode_cell_id_exists", | ||
"check_compass_direction_unit", | ||
"check_spatial_series_radians_magnitude", | ||
"check_spatial_series_dims", | ||
"check_spatial_series_degrees_magnitude", | ||
] |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import warnings | ||
|
||
message = ( | ||
"All submodules below the level 'nwbinspector.checks' have been deprecated. " | ||
"Please retrieve the specific check function(s) you wish to use from the `available_checks` registry " | ||
"at the top-level or import directly from 'nwbinspector.checks'." | ||
) | ||
|
||
warnings.warn(message=message, category=DeprecationWarning, stacklevel=2) | ||
|
||
# Still keep imports functional with warning for soft deprecation cycle | ||
# TODO: remove after 9/15/2024 | ||
from .._behavior import * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import warnings | ||
|
||
message = ( | ||
"All submodules below the level 'nwbinspector.checks' have been deprecated. " | ||
"Please retrieve the specific check function(s) you wish to use from the `available_checks` registry " | ||
"at the top-level or import directly from 'nwbinspector.checks'." | ||
) | ||
|
||
warnings.warn(message=message, category=DeprecationWarning, stacklevel=2) | ||
|
||
# Still keep imports functional with warning for soft deprecation cycle | ||
# TODO: remove after 9/15/2024 | ||
from .._ecephys import * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import warnings | ||
|
||
message = ( | ||
"All submodules below the level 'nwbinspector.checks' have been deprecated. " | ||
"Please retrieve the specific check function(s) you wish to use from the `available_checks` registry " | ||
"at the top-level or import directly from 'nwbinspector.checks'." | ||
) | ||
|
||
warnings.warn(message=message, category=DeprecationWarning, stacklevel=2) | ||
|
||
# Still keep imports functional with warning for soft deprecation cycle | ||
# TODO: remove after 9/15/2024 | ||
from .._general import * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import warnings | ||
|
||
message = ( | ||
"All submodules below the level 'nwbinspector.checks' have been deprecated. " | ||
"Please retrieve the specific check function(s) you wish to use from the `available_checks` registry " | ||
"at the top-level or import directly from 'nwbinspector.checks'." | ||
) | ||
|
||
warnings.warn(message=message, category=DeprecationWarning, stacklevel=2) | ||
|
||
# Still keep imports functional with warning for soft deprecation cycle | ||
# TODO: remove after 9/15/2024 | ||
from .._icephys import * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import warnings | ||
|
||
message = ( | ||
"All submodules below the level 'nwbinspector.checks' have been deprecated. " | ||
"Please retrieve the specific check function(s) you wish to use from the `available_checks` registry " | ||
"at the top-level or import directly from 'nwbinspector.checks'." | ||
) | ||
|
||
warnings.warn(message=message, category=DeprecationWarning, stacklevel=2) | ||
|
||
# Still keep imports functional with warning for soft deprecation cycle | ||
# TODO: remove after 9/15/2024 | ||
from .._image_series import * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import warnings | ||
|
||
message = ( | ||
"All submodules below the level 'nwbinspector.checks' have been deprecated. " | ||
"Please retrieve the specific check function(s) you wish to use from the `available_checks` registry " | ||
"at the top-level or import directly from 'nwbinspector.checks'." | ||
) | ||
|
||
warnings.warn(message=message, category=DeprecationWarning, stacklevel=2) | ||
|
||
# Still keep imports functional with warning for soft deprecation cycle | ||
# TODO: remove after 9/15/2024 | ||
from .._images import * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import warnings | ||
|
||
message = ( | ||
"All submodules below the level 'nwbinspector.checks' have been deprecated. " | ||
"Please retrieve the specific check function(s) you wish to use from the `available_checks` registry " | ||
"at the top-level or import directly from 'nwbinspector.checks'." | ||
) | ||
|
||
warnings.warn(message=message, category=DeprecationWarning, stacklevel=2) | ||
|
||
# Still keep imports functional with warning for soft deprecation cycle | ||
# TODO: remove after 9/15/2024 | ||
from .._nwb_containers import * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import warnings | ||
|
||
message = ( | ||
"All submodules below the level 'nwbinspector.checks' have been deprecated. " | ||
"Please retrieve the specific check function(s) you wish to use from the `available_checks` registry " | ||
"at the top-level or import directly from 'nwbinspector.checks'." | ||
) | ||
|
||
warnings.warn(message=message, category=DeprecationWarning, stacklevel=2) | ||
|
||
# Still keep imports functional with warning for soft deprecation cycle | ||
# TODO: remove after 9/15/2024 | ||
from .._nwbfile_metadata import * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import warnings | ||
|
||
message = ( | ||
"All submodules below the level 'nwbinspector.checks' have been deprecated. " | ||
"Please retrieve the specific check function(s) you wish to use from the `available_checks` registry " | ||
"at the top-level or import directly from 'nwbinspector.checks'." | ||
) | ||
|
||
warnings.warn(message=message, category=DeprecationWarning, stacklevel=2) | ||
|
||
# Still keep imports functional with warning for soft deprecation cycle | ||
# TODO: remove after 9/15/2024 | ||
from .._ogen import * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import warnings | ||
|
||
message = ( | ||
"All submodules below the level 'nwbinspector.checks' have been deprecated. " | ||
"Please retrieve the specific check function(s) you wish to use from the `available_checks` registry " | ||
"at the top-level or import directly from 'nwbinspector.checks'." | ||
) | ||
|
||
warnings.warn(message=message, category=DeprecationWarning, stacklevel=2) | ||
|
||
# Still keep imports functional with warning for soft deprecation cycle | ||
# TODO: remove after 9/15/2024 | ||
from .._ophys import * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import warnings | ||
|
||
message = ( | ||
"All submodules below the level 'nwbinspector.checks' have been deprecated. " | ||
"Please retrieve the specific check function(s) you wish to use from the `available_checks` registry " | ||
"at the top-level or import directly from 'nwbinspector.checks'." | ||
) | ||
|
||
warnings.warn(message=message, category=DeprecationWarning, stacklevel=2) | ||
|
||
# Still keep imports functional with warning for soft deprecation cycle | ||
# TODO: remove after 9/15/2024 | ||
from .._tables import * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import warnings | ||
|
||
message = ( | ||
"All submodules below the level 'nwbinspector.checks' have been deprecated. " | ||
"Please retrieve the specific check function(s) you wish to use from the `available_checks` registry " | ||
"at the top-level or import directly from 'nwbinspector.checks'." | ||
) | ||
|
||
warnings.warn(message=message, category=DeprecationWarning, stacklevel=2) | ||
|
||
# Still keep imports functional with warning for soft deprecation cycle | ||
# TODO: remove after 9/15/2024 | ||
from .._time_series import * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters