From dc1f7b8567cb227ecfa84e7b954e64ee574065ef Mon Sep 17 00:00:00 2001 From: mavaylon1 Date: Tue, 1 Oct 2024 16:57:40 -0700 Subject: [PATCH] cleanup 1 --- src/pynwb/file.py | 14 ++------------ src/pynwb/io/file.py | 1 - 2 files changed, 2 insertions(+), 13 deletions(-) diff --git a/src/pynwb/file.py b/src/pynwb/file.py index b48ba7cb0..39a55b128 100644 --- a/src/pynwb/file.py +++ b/src/pynwb/file.py @@ -698,8 +698,8 @@ def add_electrode(self, **kwargs): raise ValueError("The 'location' argument is required when creating an electrode.") if not kwargs['group']: raise ValueError("The 'group' argument is required when creating an electrode.") - # if d.get('group_name', None) is None: - # d['group_name'] = d['group'].name + if d.get('group_name', None) is None: + d['group_name'] = d['group'].name new_cols = [('x', 'the x coordinate of the position (+x is posterior)'), ('y', 'the y coordinate of the position (+y is inferior)'), @@ -1176,16 +1176,6 @@ def _tablefunc(table_name, description, columns): return t -# def ElectrodesTable(name='electrodes', -# description='metadata about extracellular electrodes'): -# return _tablefunc(name, description, -# [('location', 'the location of channel within the subject e.g. brain region'), -# ('group', 'a reference to the ElectrodeGroup this electrode is a part of'), -# ('group_name', 'the name of the ElectrodeGroup this electrode is a part of') -# ] -# ) - - def TrialTable(name='trials', description='metadata about experimental trials'): return _tablefunc(name, description, ['start_time', 'stop_time']) diff --git a/src/pynwb/io/file.py b/src/pynwb/io/file.py index 3189e697f..b4ae412fb 100644 --- a/src/pynwb/io/file.py +++ b/src/pynwb/io/file.py @@ -195,7 +195,6 @@ def electrodes(self, builder, manager): else: return None - @ObjectMapper.constructor_arg('session_start_time') def dateconversion(self, builder, manager): """Set the constructor arg for 'session_start_time' to a datetime object.