Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python 3.9 error #2

Closed
ajikmr opened this issue Aug 12, 2023 · 2 comments
Closed

Python 3.9 error #2

ajikmr opened this issue Aug 12, 2023 · 2 comments

Comments

@ajikmr
Copy link

ajikmr commented Aug 12, 2023

Though code works fine with python 3.10, python 3.9 throws error.

Traceback (most recent call last):
File "/xxxxxxxgraphcast/graphcast_example.py", line 44, in
ckpt=checkpoint.load(f, graphcast.CheckPoint)
File "/xxxxxxxgraphcast/graphcast/checkpoint.py", line 54, in load
return _convert_types(typ, _unflatten(np.load(source)))
File "/xxxxxxxgraphcast/graphcast/checkpoint.py", line 117, in _convert_types
if isinstance(f.type, (types.UnionType, type(Optional[int]))):
AttributeError: module 'types' has no attribute 'UnionType'

OS: Ubuntu 20.04.6
Python: 3.9.17
jax: 0.4.14

@alvarosg
Copy link
Collaborator

Thank you for flagging this. In principle we support python 3.10 and above. We have updated setup.py to indicate this.

Thanks again!

@ajikmr
Copy link
Author

ajikmr commented Sep 20, 2023

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants