def test_UnivariateStat(self): # create a Port and a Node port = Port() port.set_parameters(data_type='epoch', channels=COLUMN, sampling_frequency=250, meta={}) node = UnivariateStat(port, 'mean') # simulate NeuXus loops simulate_loop_and_verify(port, node, self)
def test_TimeBasedEpoching(self): # create a Port and a Node port = Port() port.set_parameters(data_type='signal', channels=COLUMN, sampling_frequency=250, meta={}) node = TimeBasedEpoching(port, 1, 0.5) # simulate NeuXus loops simulate_loop_and_verify(port, node, self)
def test_ReferenceChannel(self): # create a Port and a Node port = Port() port.set_parameters(data_type='signal', channels=COLUMN, sampling_frequency=250, meta={}) node = ReferenceChannel(port, 'index', 1) # simulate NeuXus loops simulate_loop_and_verify(port, node, self)
def test_HilbertTransform(self): # create a Port and a Node port = Port() port.set_parameters(data_type='signal', channels=COLUMN, sampling_frequency=250, meta={}) node = HilbertTransform(port) # simulate NeuXus loops simulate_loop_and_verify(port, node, self)
def test_LslSend(self): # create a Port and a Node port = Port() port.set_parameters(data_type='signal', channels=COLUMN, sampling_frequency=250, meta={}) node = LslSend(port, 'my_test_signal') # simulate NeuXus loops simulate_loop_and_verify(port, node, self)
def test_NotchFilter(self): # create a Port and a Node port = Port() port.set_parameters(data_type='signal', channels=COLUMN, sampling_frequency=250, meta={}) node = NotchFilter(port, 10, 0.4) # simulate NeuXus loops simulate_loop_and_verify(port, node, self)
def test_ChannelSelector(self): # create a Port and a Node port = Port() port.set_parameters( data_type='signal', channels=COLUMN, sampling_frequency=250, meta={}) node = FeatureAggregator(port) # simulate NeuXus loops simulate_loop_and_verify(port, node, self)
def test_Hdf5(self): # create a Port and a Node port = Port() port.set_parameters( data_type='signal', channels=COLUMN, sampling_frequency=250, meta={}) node = Hdf5(port, 'my_test', 'df') # simulate NeuXus loops simulate_loop_and_verify(port, node, self) os.remove('my_test.h5')
def test_SpatialFilter(self): matrix = {'OC2': [4, 0, -1e-2, 0], 'OC3': [0, -1, 2, 4]} # create a Port and a Node port = Port() port.set_parameters(data_type='signal', channels=COLUMN, sampling_frequency=250, meta={}) node = SpatialFilter(port, matrix) # simulate NeuXus loops simulate_loop_and_verify(port, node, self)
def test_Classify(self): col = ['a', 'b'] # create a Port and a Node port = Port() port.set_parameters( data_type='signal', channels=col, sampling_frequency=250, meta={}) node = Classify(port, 'tests/nodes/data/classifier.sav', 'class') # simulate NeuXus loops simulate_loop_and_verify(port, node, self, column=col)
def test_Windowing(self): # create a Port and a Node port = Port() port.set_parameters(data_type='epoch', channels=COLUMN, sampling_frequency=250, meta={}) node = Windowing(port, 'blackman') # simulate NeuXus loops simulate_loop_and_verify(port, node, self, index=[0.2 * i for i in range(250)])
def test_StimulationBasedEpoching(self): # create a Port and a Node port = Port() port.set_parameters(data_type='signal', channels=COLUMN, sampling_frequency=250, meta={}) marker_port = Port() marker_port.set_parameters(data_type='marker', channels=['marker'], sampling_frequency=0, meta={}) node = StimulationBasedEpoching(port, marker_port, 400, 0.125, 2) marker_port.set([[400]], [0.4]) # simulate NeuXus loops simulate_loop_and_verify(port, node, self)