Skip to content

Commit

Permalink
Quartus tests for Softmax
Browse files Browse the repository at this point in the history
  • Loading branch information
bo3z committed May 6, 2022
1 parent acf51d2 commit 5acd593
Showing 1 changed file with 14 additions and 7 deletions.
21 changes: 14 additions & 7 deletions test/pytest/test_softmax.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,20 +24,27 @@ def generate_data(function, input_shape):
return function((1000, *input_shape))


# TODO: include latency strategy with flat_distribution when it can be made to pass
# TODO: Include latency strategy with flat_distribution when it can be made to pass
@pytest.mark.parametrize('backend,strategy,function,input_shape,io_type', [
#('latency', flat_distribution, (8,), 'io_parallel'),
#('latency', flat_distribution, (8, 8, 3), 'io_stream'),
('Vivado', 'stable', flat_distribution, (8,), 'io_parallel'),
('Vivado', 'stable', high_accuracy_distribution, (8,), 'io_parallel'),
('Quartus', 'resource', flat_distribution, (8,), 'io_parallel'),
('Quartus', 'resource', high_accuracy_distribution, (8,), 'io_parallel'),
('Quartus', 'stable', flat_distribution, (8,), 'io_parallel'),
('Quartus', 'stable', high_accuracy_distribution, (8,), 'io_parallel'),
# Streaming, single-dimensional implementation (not supported on Quartus yet)
('Vivado', 'stable', flat_distribution, (8,), 'io_stream'),
('Vivado', 'stable', high_accuracy_distribution, (8,), 'io_stream'),
# Multi-dimensional tests, only for io_stream for now
('Vivado', 'stable', flat_distribution, (8, 8, 3), 'io_stream'),
('Vivado', 'stable', high_accuracy_distribution, (8, 8, 3), 'io_stream')
('Vivado', 'stable', high_accuracy_distribution, (8, 8, 3), 'io_stream'),
# Latency, include when test pass
#('Vivado', 'latency', flat_distribution, (8,), 'io_parallel'),
#('Vivado', 'latency', flat_distribution, (8, 8, 3), 'io_stream'),
#('Quartus', 'latency', flat_distribution, (8,), 'io_parallel'),
])
def test_softmax(backend, strategy, generate_data, input_shape, io_type):
X = generate_data
Expand Down

0 comments on commit 5acd593

Please sign in to comment.