From d09aee6b287e5e9d86ee1b9064406cd4a651f234 Mon Sep 17 00:00:00 2001 From: CodyCBakerPhD Date: Thu, 21 Jul 2022 13:11:45 +0000 Subject: [PATCH] debug full --- .../yaml_conversion_specification.py | 2 +- tests/test_on_data/test_gin_icephys.py | 6 +++--- tests/test_on_data/test_yaml_conversion_specification.py | 2 +- .../test_on_data/test_yaml_conversion_specification_cli.py | 4 ++-- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/neuroconv/tools/yaml_conversion_specification/yaml_conversion_specification.py b/src/neuroconv/tools/yaml_conversion_specification/yaml_conversion_specification.py index f7fef36d8..3b1665aab 100644 --- a/src/neuroconv/tools/yaml_conversion_specification/yaml_conversion_specification.py +++ b/src/neuroconv/tools/yaml_conversion_specification/yaml_conversion_specification.py @@ -112,7 +112,7 @@ def run_conversion_from_yaml( global_data_interfaces = specification.get("data_interfaces") nwb_conversion_tools = import_module( name=".", - package="nwb_conversion_tools", # relative import, but named and referenced as if it were absolute + package="neuroconv", # relative import, but named and referenced as if it were absolute ) file_counter = 0 for experiment in specification["experiments"].values(): diff --git a/tests/test_on_data/test_gin_icephys.py b/tests/test_on_data/test_gin_icephys.py index 8d9ca8bfc..844424975 100644 --- a/tests/test_on_data/test_gin_icephys.py +++ b/tests/test_on_data/test_gin_icephys.py @@ -4,13 +4,13 @@ from pathlib import Path from datetime import datetime -import neo import pytest import numpy.testing as npt from pynwb import NWBHDF5IO from neuroconv import NWBConverter, AbfInterface from neuroconv.utils import load_dict_from_file +from neuroconv.tools.neo import get_number_of_segments, get_number_of_electrodes try: from parameterized import parameterized, param @@ -67,8 +67,8 @@ def test_convert_abf_to_nwb(self, data_interface, interface_kwargs): from neo import AxonIO neo_reader = AxonIO(filename=interface_kwargs["file_paths"][0]) - n_segments = neo.get_number_of_segments(neo_reader, block=0) - n_electrodes = neo.get_number_of_electrodes(neo_reader) + n_segments = get_number_of_segments(neo_reader, block=0) + n_electrodes = get_number_of_electrodes(neo_reader) nwbfile_path = str(self.savedir / f"{data_interface.__name__}.nwb") diff --git a/tests/test_on_data/test_yaml_conversion_specification.py b/tests/test_on_data/test_yaml_conversion_specification.py index 05d4f0e06..93a37470a 100644 --- a/tests/test_on_data/test_yaml_conversion_specification.py +++ b/tests/test_on_data/test_yaml_conversion_specification.py @@ -20,7 +20,7 @@ class TestYAMLConversionSpecification(TestCase): def test_validate_example_specification(self): path_to_test_yml_files = Path(__file__).parent / "conversion_specifications" yaml_file_path = path_to_test_yml_files / "GIN_conversion_specification.yml" - schema_folder = path_to_test_yml_files.parent.parent.parent / "src" / "nwb_conversion_tools" / "schemas" + schema_folder = path_to_test_yml_files.parent.parent.parent / "src" / "neuroconv" / "schemas" specification_schema = load_dict_from_file( file_path=schema_folder / "yaml_conversion_specification_schema.json" ) diff --git a/tests/test_on_data/test_yaml_conversion_specification_cli.py b/tests/test_on_data/test_yaml_conversion_specification_cli.py index fa07f7fef..3eefffbd5 100644 --- a/tests/test_on_data/test_yaml_conversion_specification_cli.py +++ b/tests/test_on_data/test_yaml_conversion_specification_cli.py @@ -19,7 +19,7 @@ def test_run_conversion_from_yaml_cli(self): yaml_file_path = path_to_test_yml_files / "GIN_conversion_specification.yml" deploy_process( command=( - f"nwbct-run-conversion {yaml_file_path} " + f"neuroconv {yaml_file_path} " f"--data-folder-path {DATA_PATH} --output-folder-path {self.test_folder} --overwrite" ) ) @@ -55,7 +55,7 @@ def test_run_conversion_from_yaml_default_nwbfile_name(self): yaml_file_path = path_to_test_yml_files / "GIN_conversion_specification_missing_nwbfile_names.yml" deploy_process( command=( - f"nwbct-run-conversion {yaml_file_path} " + f"neuroconv {yaml_file_path} " f"--data-folder-path {DATA_PATH} --output-folder-path {self.test_folder} --overwrite" ) )