From f00b134c2cf798e36ec9be959e994f89cb176531 Mon Sep 17 00:00:00 2001 From: mavaylon1 Date: Thu, 1 Aug 2024 08:34:13 -0700 Subject: [PATCH] not sure clean up --- src/pynwb/__init__.py | 27 +-------------------------- src/pynwb/nwb-schema | 2 +- 2 files changed, 2 insertions(+), 27 deletions(-) diff --git a/src/pynwb/__init__.py b/src/pynwb/__init__.py index 31556509e..d3564b5bb 100644 --- a/src/pynwb/__init__.py +++ b/src/pynwb/__init__.py @@ -77,33 +77,8 @@ def _get_resources(): global __TYPE_MAP __NS_CATALOG = NamespaceCatalog(NWBGroupSpec, NWBDatasetSpec, NWBNamespace) - -class NWBTypeMap(TypeMap): - def __init__(self, **kwargs): - super().__init__(**kwargs) - - def __copy__(self): - ret = NWBTypeMap(namespaces=copy(self._TypeMap__ns_catalog), - mapper_cls=self._TypeMap__default_mapper_cls, - type_config=self.type_config) - ret.merge(self) - return ret - - def modify_builder(self, builder): - try: - ndtype = builder['neurodata_type'] - except KeyError: - ndtype = 'Not Group' - # remap ElectrodesTable from a DynamicTable named electrodes - if ndtype == 'DynamicTable' and builder.name == 'electrodes': - builder.set_attribute(name='namespace', value='core') - builder.set_attribute(name='neurodata_type', value='ElectrodesTable') - return builder - else: - return None - hdmf_typemap = hdmf.common.get_type_map() -__TYPE_MAP = NWBTypeMap(namespaces=__NS_CATALOG) +__TYPE_MAP = TypeMap(namespaces=__NS_CATALOG) __TYPE_MAP.merge(hdmf_typemap, ns_catalog=True) @docval({'name': 'extensions', 'type': (str, TypeMap, list), diff --git a/src/pynwb/nwb-schema b/src/pynwb/nwb-schema index 7393211bb..65230a20d 160000 --- a/src/pynwb/nwb-schema +++ b/src/pynwb/nwb-schema @@ -1 +1 @@ -Subproject commit 7393211bb04a61c153239dc49691598b4a41fa39 +Subproject commit 65230a20d9f6f895968c61f1cc52b2c15fcec10b