Skip to content

Commit

Permalink
fixing SimpleRNN shape issue
Browse files Browse the repository at this point in the history
  • Loading branch information
dsrankin authored and vloncar committed Jun 24, 2022
1 parent 0ce874f commit 59ed824
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions hls4ml/model/layers.py
Original file line number Diff line number Diff line change
Expand Up @@ -872,9 +872,10 @@ class SimpleRNN(Layer):
def initialize(self):
if self.attributes['return_sequences']:
shape = [self.attributes['n_timesteps'], self.attributes['n_out']]
dims = ['N_TIME_STEPS_{}'.format(self.index), 'N_OUT_{}'.format(self.index)]
else:
shape = [1, self.attributes['n_out']]
dims = ['N_TIME_STEPS_{}'.format(self.index), 'N_OUT_{}'.format(self.index)]
shape = [self.attributes['n_out']]
dims = ['N_OUT_{}'.format(self.index)]

self.add_output_variable(shape, dims)

Expand Down

0 comments on commit 59ed824

Please sign in to comment.