Skip to content

Conversation

@DuncDennis
Copy link

Fixed a bug in the simulation classes, where the default parameter is wrongly used if the parameter is set to 0.


The previous parameter assignment in the __init__ of the simulation classes is done by:

self.<param> = <param> or self.default_parameters["<param>"]

This leads to wrong behavior if you want to set the <param> to 0, as in these cases, the default parameter is used.

In this pull-request the parameter is changed to the following to get the correct behavior:

self.<param> = <param> if <param> is not None else self.default_parameters["<param>"]

Fixed a bug in the simulation classes, where the default parameter is used if the given parameter is 0.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant