add condition that time constants (taus) are larger than 0
This commit is contained in:
parent
45abc0ae14
commit
42ee462016
@ -78,8 +78,8 @@ class AbstractModel:
|
||||
if key not in self.DEFAULT_VALUES.keys():
|
||||
raise ValueError("Given key is unknown!\n"
|
||||
"Please check spelling and refer to list LIFAC.KEYS.")
|
||||
if "tau" in key and value < 0:
|
||||
warn("Time constants cannot be negative! Setting it to 0.5ms")
|
||||
if "tau" in key and value <= 0:
|
||||
warn("Time constants cannot be zero or negative! Setting " + str(key) + " to 0.5ms")
|
||||
self.parameters[key] = 0.00005
|
||||
return
|
||||
self.parameters[key] = value
|
||||
|
Loading…
Reference in New Issue
Block a user