def test_pick_events():
 events = np.array([[1, 0, 1], [2, 1, 0], [3, 0, 4], [4, 4, 2], [5, 2, 0]])
 assert_array_equal(pick_events(events, include=[1, 4], exclude=4), [[1, 0, 1], [3, 0, 4]])
 assert_array_equal(pick_events(events, exclude=[0, 2]), [[1, 0, 1], [3, 0, 4]])
 assert_array_equal(pick_events(events, include=[1, 2], step=True), [[1, 0, 1], [2, 1, 0], [4, 4, 2], [5, 2, 0]])

def test_pick_events ( ) : events = np . array ( [ [ 1 , 0 , 1 ] , [ 2 , 1 , 0 ] , [ 3 , 0 , 4 ] , [ 4 , 4 , 2 ] , [ 5 , 2 , 0 ] ] ) assert_array_equal ( pick_events ( events , include = [ 1 , 4 ] , exclude = 4 ) , [ [ 1 , 0 , 1 ] , [ 3 , 0 , 4 ] ] ) assert_array_equal ( pick_events ( events , exclude = [ 0 , 2 ] ) , [ [ 1 , 0 , 1 ] , [ 3 , 0 , 4 ] ] ) assert_array_equal ( pick_events ( events , include = [ 1 , 2 ] , step = True ) , [ [ 1 , 0 , 1 ] , [ 2 , 1 , 0 ] , [ 4 , 4 , 2 ] , [ 5 , 2 , 0 ] ] )
test pick events in a events ndarray .