Replies: 2 comments 1 reply
-
|
Apologies, was supposed to post this in issues. Won't happen again |
Beta Was this translation helpful? Give feedback.
0 replies
-
|
Ag, what a coincidence. This is because we just released the new Parcels v3.0.2 a few hours ago, which has this new feature. This probably happened after you installed Parcels on your local system... You can do two things:
|
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 there,
I'm working through the getting started with parcels tutorials (https://docs.oceanparcels.org/en/latest/examples/parcels_tutorial.html) and am having trouble getting this code chunk to work:
extra_vars = [
Variable("distance", initial=0.0, dtype=np.float32),
Variable("prev_lon", dtype=np.float32, to_write=False, initial=attrgetter("lon")),
Variable("prev_lat", dtype=np.float32, to_write=False, initial=attrgetter("lat")),
]
DistParticle = JITParticle.add_variables(extra_vars)
Here is the error message:
__AttributeError Traceback (most recent call last)
Cell In[6], line 1
----> 1 DistParticle = JITParticle.add_variables(extra_vars)
AttributeError: type object 'JITParticle' has no attribute 'add_variables'__
I think the attribute it is calling for no longer exists, can you help? I would like to understand in case I encounter this in the future.
Thanks,
Tom
Beta Was this translation helpful? Give feedback.
All reactions