Skip to content

Commit

Permalink
Fixed reset timing offset
Browse files Browse the repository at this point in the history
Signed-off-by: bamsumit <[email protected]>
  • Loading branch information
bamsumit committed Mar 2, 2022
1 parent b746bb7 commit 27898a7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lava/proc/io/reset.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ class AbstractPyReset(PyLoihiProcessModel):
offset: np.ndarray = LavaPyType(np.ndarray, int)

def post_guard(self) -> None:
return self.time_step % self.interval == self.offset
return (self.time_step - 1) % self.interval == self.offset

def run_post_mgmt(self) -> None:
self.state.write(np.zeros(self.state._shape,
Expand Down

0 comments on commit 27898a7

Please sign in to comment.