Issues with loading old data and scalar product computation (f * u) after updating Oceananigans #3978
-
Hello everyone. I recently updated both Julia (to version 1.10.7) and Oceananigans (to the latest version 0.94.3). Previously, I had installed Oceananigans about a year ago, but unfortunately, I don’t remember the exact version I was using. After the updates, I’ve encountered a couple of issues:
Now, when I try to load this data using FieldTimeSeries, it fails with the following error:
I attempted to compute the scalar product f * u using this line (here is an example for t = 5):
This code worked in the previous version, but now it fails with the following error:
I apologize for including such long error messages and detailed examples, but I hope they help clarify the issues I'm encountering. I would greatly appreciate any guidance on how to resolve these problems or adapt my workflow to the current version of the library. Thank you so much for your time and assistance! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
Unfortunately, loading data saved with previous versions of Oceananigans is not always possible automatically because of compatibility issues with new and old types saved in the JLD2 files. You can always open the old datafile manually with file = jldopen("/path") and inspect the saved data that should be under the file["timeseries"] With regards to the second issue, I think you are missing the field constructor, try with: u_forcing_field = Oceananigans.field((Face, Center, Center), u_forcing, u_timeseries. grid) |
Beta Was this translation helpful? Give feedback.
Unfortunately, loading data saved with previous versions of Oceananigans is not always possible automatically because of compatibility issues with new and old types saved in the JLD2 files.
You can always open the old datafile manually with
and inspect the saved data that should be under the
timeseries
keyfile["timeseries"]
With regards to the second issue, I think you are missing the field constructor, try with: