Repeating particles starting from second time step #1154
Replies: 2 comments
-
I've also checked the pset.repeatlon and pset.repeatlat variables. At the first time step, they are in the correct location, but after that they shift to the second time step particle locations and that becomes the repeat particle locations for the remainder of the execution. |
Beta Was this translation helpful? Give feedback.
-
Hi @JonathanC33. If you want more control of particle start times and locations, I'd suggest to use the 'delayed release' functionality (i.e. also provide a |
Beta Was this translation helpful? Give feedback.
-
Hi, I'm trying to create a repeating particle output every hour, with position and time recorded every hour. The particles are initially defined in a gridded formation but the repeats of the particles are initially placed at the second time step of the first particles released. Is there a way to define at which time step the repeating particle positions are take from?
#Fieldset using FieldSet.from_netcdf using the filenames, variables, and dimensions
fieldset_ocean = FieldSet.from_netcdf(
filenames,
variables,
dimensions,
indices=indices,
deferred_load=True,
allow_time_extrapolation=True)
#Run through each of the ToEs, setting up particle grids and repeating every 3 hours
#Run for 2 days total to cover the entire time of interest
#Mask out land for the lons and lats used later for particle locations
#Every 5th space, approx. 600m spacing
lons = (lonland_mask)[::5,::5]
lats = (latland_mask)[::5,::5]
#Release new particles every x hour(s)
repeatdt = timedelta(hours=1)
for i in ToI.keys():
for ii in ToI[i].keys():
Beta Was this translation helpful? Give feedback.
All reactions