Replies: 1 comment 1 reply
-
|
Hi,
It is not clear from your sample code which order is violated, so this is probably in the part you left out. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi, i wish to use o.run() for a bunch of different end_times for diferent readers, thats why I decided to use a nester for loop. But I receive the following error 'opendrift.errors.WrongMode: Cannot call this function in this mode: Mode.Result, only in: [<Mode.Run: 3>]: None'
The loop has more less this syntax:
`for i ...:
for t in range(len(times_to_plot)):
plot_filename = f"{names[i]}_{timestamp[t]}.png"
o.run(end_time=times_to_plot[t],time_step=dt.timedelta(days=1))
o.plot(linecolor='origin_marker',
fast=False,
show_elements=False,
filename=plot_filename )´
Has anyone faced this same issue or knows a way to fix this?
Thanks in advance.
Beta Was this translation helpful? Give feedback.
All reactions