From 227c0a2677ef457daeb9e70ce680bb8e56258f54 Mon Sep 17 00:00:00 2001 From: Erik van Sebille Date: Wed, 31 Jul 2024 14:03:37 +0200 Subject: [PATCH] Improvin advice on how to call pfile.write_latest_locations() --- docs/examples/tutorial_kernelloop.ipynb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/examples/tutorial_kernelloop.ipynb b/docs/examples/tutorial_kernelloop.ipynb index b8c72950d..0824d28dc 100644 --- a/docs/examples/tutorial_kernelloop.ipynb +++ b/docs/examples/tutorial_kernelloop.ipynb @@ -307,7 +307,7 @@ "### 3. The last time is not written to file\n", "Because the location at the start of the loop is written at the end of the Kernel loop, the last `particle.time` of the particle is not written to file. This is similar behaviour to e.g. `np.arange(start, stop)`, which also doesn't include the `stop` value itself. \n", "\n", - "If you do want to write the last time to file, you can increase the `runtime` or `endtime` by `dt` (although this may cause a TimeExtrapolationError if your run was to the end of the available hydrodynamic data), or you can call `pfile.write_latest_locations(pset, time=endtime)`. Note that in the latter case, the particle locations (longitude, latitude and depth) will be updated, but other variables will _not_ be updated as the Kernels are not run again." + "If you do want to write the last time to file, you can increase the `runtime` or `endtime` by `dt` (although this may cause a TimeExtrapolationError if your run was to the end of the available hydrodynamic data), or you can call `pfile.write_latest_locations(pset, time=pset[0].time_nextloop)`. Note that in the latter case, the particle locations (longitude, latitude and depth) will be updated, but other variables will _not_ be updated as the Kernels are not run again." ] }, {