Skip to content

Commit

Permalink
Merge pull request #1161 from StochSS/notebook-hotfix
Browse files Browse the repository at this point in the history
HOTFIX: Notebooks to main
  • Loading branch information
BryanRumsey authored Jun 24, 2021
2 parents 312a24d + 47ba65c commit 2330d66
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions stochss/handlers/util/stochss_notebook.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ def __create_event_strings(self, model, pad):
pad=pad)
a_names = self.__create_event_assignment_strings(assignments=assignments,
event=event, pad=pad)
delay = f"{event['delay']}" if event['delay'] else None
delay = f'"{event["delay"]}"' if event['delay'] else None
ev_str = f'{pad}self.add_event(Event(name="{event["name"]}", '
ev_str += f'trigger={t_name}, assignments=[{a_names}], '
ev_str += f'delay={delay}, priority="{event["priority"]}", '
Expand Down Expand Up @@ -770,9 +770,9 @@ def __create_stoich_spec_string(self, stoich_species):
def __create_tspan_string(self, model, pad):
end = self.s_model['modelSettings']['endSim']
output_freq = self.s_model['modelSettings']['timeStep']
step_size = self.s_model['modelSettings']['timestepSize']
tspan = ["", f"{pad}# Timespan"]
if self.s_model['is_spatial']:
step_size = self.s_model['modelSettings']['timestepSize']
ts_str = f'{pad}self.timespan(np.arange(0, {end + step_size}, {output_freq})'
ts_str += f", timestep_size={step_size})"
else:
Expand Down

0 comments on commit 2330d66

Please sign in to comment.