Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG]: getPulseGenMethod for Brian 2 doesn't properly account for the simulation time line #77

Open
jonrkarr opened this issue Nov 25, 2021 · 0 comments

Comments

@jonrkarr
Copy link

getPulseGenMethod fails when a pulse occurs beyond the simulation time line (steps < int("+(del_si+dur_si)+"/defaultclock.dt)). The getPulseGenMethod should be adjusted to account for this.

" np.repeat(0, (steps - int("+(del_si+dur_si)+"/defaultclock.dt))) ) ) * "+unit+" , \n"

Replace steps - int("+(del_si+dur_si)+"/defaultclock.dt) with max(0, steps - int("+(del_si+dur_si)+"/defaultclock.dt)).

@jonrkarr jonrkarr changed the title [BUG]: getPulseGenMethod for Brian 2 [BUG]: getPulseGenMethod for Brian 2 doesn't properly account for the simulation time line Nov 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 📋 Backlog
Development

No branches or pull requests

1 participant