From 055e9f5f1e3bc9135a4413fea8b6b41e8cb606c7 Mon Sep 17 00:00:00 2001 From: rly Date: Sat, 29 Jun 2024 15:52:29 -0700 Subject: [PATCH] Rename actual_x to confirmed_x --- ...ndx-extracellular-channels.extensions.yaml | 4 ++-- src/pynwb/tests/test_classes.py | 20 +++++++++---------- src/pynwb/tests/test_example_usage_all.py | 10 +++++----- src/spec/create_extension_spec.py | 4 ++-- 4 files changed, 19 insertions(+), 19 deletions(-) diff --git a/spec/ndx-extracellular-channels.extensions.yaml b/spec/ndx-extracellular-channels.extensions.yaml index 42b74e7..4af2e46 100644 --- a/spec/ndx-extracellular-channels.extensions.yaml +++ b/spec/ndx-extracellular-channels.extensions.yaml @@ -206,7 +206,7 @@ groups: dtype: text doc: The brain area of the estimated contact position, e.g., 'CA1'. quantity: '?' - - name: actual_position_in_mm + - name: confirmed_position_in_mm neurodata_type_inc: VectorData dtype: - name: ap @@ -229,7 +229,7 @@ groups: doc: Reference point for the position coordinates. e.g., "bregma at the cortical surface". required: false - - name: actual_brain_area + - name: confirmed_brain_area neurodata_type_inc: VectorData dtype: text doc: The brain area of the actual contact position, e.g., 'CA1'. diff --git a/src/pynwb/tests/test_classes.py b/src/pynwb/tests/test_classes.py index 99040da..18474e4 100644 --- a/src/pynwb/tests/test_classes.py +++ b/src/pynwb/tests/test_classes.py @@ -426,8 +426,8 @@ def test_constructor_add_row(self): filter="High-pass at 300 Hz", estimated_position_in_mm=[-1.5, 2.5, -2.5], estimated_brain_area="CA3", - actual_position_in_mm=[-1.5, 2.4, -2.4], - actual_brain_area="CA3", + confirmed_position_in_mm=[-1.5, 2.4, -2.4], + confirmed_brain_area="CA3", ) ct.add_row( @@ -436,14 +436,14 @@ def test_constructor_add_row(self): filter="High-pass at 300 Hz", estimated_position_in_mm=[-1.5, 2.5, -2.4], estimated_brain_area="CA3", - actual_position_in_mm=[-1.5, 2.4, -2.3], - actual_brain_area="CA3", + confirmed_position_in_mm=[-1.5, 2.4, -2.3], + confirmed_brain_area="CA3", ) # TODO might be nice to put this on the constructor of ContactsTable as position__reference # without using a custom mapper ct["estimated_position_in_mm"].reference = "Bregma at the cortical surface" - ct["actual_position_in_mm"].reference = "Bregma at the cortical surface" + ct["confirmed_position_in_mm"].reference = "Bregma at the cortical surface" # TODO assert ct.name == "Neuropixels1ChannelsTable" @@ -484,8 +484,8 @@ def addContainer(self): filter="High-pass at 300 Hz", estimated_position_in_mm=[-1.5, 2.5, -2.5], estimated_brain_area="CA3", - actual_position_in_mm=[-1.5, 2.4, -2.4], - actual_brain_area="CA3", + confirmed_position_in_mm=[-1.5, 2.4, -2.4], + confirmed_brain_area="CA3", ) ct.add_row( @@ -494,15 +494,15 @@ def addContainer(self): filter="High-pass at 300 Hz", estimated_position_in_mm=[-1.5, 2.5, -2.4], estimated_brain_area="CA3", - actual_position_in_mm=[-1.5, 2.4, -2.3], - actual_brain_area="CA3", + confirmed_position_in_mm=[-1.5, 2.4, -2.3], + confirmed_brain_area="CA3", ) # TODO might be nice to put this on the constructor of ContactsTable as position__reference # without using a custom mapper # TODO does matching this happen in the container equals roundtrip test? ct["estimated_position_in_mm"].reference = "Bregma at the cortical surface" - ct["actual_position_in_mm"].reference = "Bregma at the cortical surface" + ct["confirmed_position_in_mm"].reference = "Bregma at the cortical surface" # put this in nwbfile.acquisition for testing self.nwbfile.add_acquisition(ct) diff --git a/src/pynwb/tests/test_example_usage_all.py b/src/pynwb/tests/test_example_usage_all.py index 39bc738..45d04e9 100644 --- a/src/pynwb/tests/test_example_usage_all.py +++ b/src/pynwb/tests/test_example_usage_all.py @@ -98,8 +98,8 @@ filter="High-pass at 300 Hz", estimated_position_in_mm=[-1.5, 2.5, -2.5], estimated_brain_area="CA3", - actual_position_in_mm=[-1.5, 2.4, -2.4], - actual_brain_area="CA3", + confirmed_position_in_mm=[-1.5, 2.4, -2.4], + confirmed_brain_area="CA3", ) channels_table.add_row( contact=1, @@ -107,11 +107,11 @@ filter="High-pass at 300 Hz", estimated_position_in_mm=[-1.5, 2.5, -2.4], estimated_brain_area="CA3", - actual_position_in_mm=[-1.5, 2.4, -2.3], - actual_brain_area="CA3", + confirmed_position_in_mm=[-1.5, 2.4, -2.3], + confirmed_brain_area="CA3", ) channels_table["estimated_position_in_mm"].reference = "Bregma at the cortical surface" -channels_table["actual_position_in_mm"].reference = "Bregma at the cortical surface" +channels_table["confirmed_position_in_mm"].reference = "Bregma at the cortical surface" # put this in nwbfile.acquisition for testing nwbfile.add_acquisition(channels_table) diff --git a/src/spec/create_extension_spec.py b/src/spec/create_extension_spec.py index 31c7edf..36b4124 100644 --- a/src/spec/create_extension_spec.py +++ b/src/spec/create_extension_spec.py @@ -377,7 +377,7 @@ def main(): quantity="?", ), NWBDatasetSpec( - name="actual_position_in_mm", + name="confirmed_position_in_mm", neurodata_type_inc="VectorData", doc=( "Stereotactic coordinates (AP, ML, DV) of the the verified actual contact position, such as from " @@ -415,7 +415,7 @@ def main(): ], ), NWBDatasetSpec( - name="actual_brain_area", + name="confirmed_brain_area", neurodata_type_inc="VectorData", dtype="text", doc=("The brain area of the actual contact position, e.g., 'CA1'."),