You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Got the following error while training an agent when it came to saving the agents training.
WARNING:absl:SaveArgs.aggregateisdeprecated, pleaseusecustomTypeHandler (https://orbax.readthedocs.io/en/latest/custom_handlers.html#typehandler) or contact Orbax team to migrate before August 1st, 2024.Traceback (mostrecentcalllast):
File"/Users/adrien.bolling/Applications/PyCharm Professional Edition.app/Contents/plugins/python/helpers-pro/pydevd_asyncio/pydevd_nest_asyncio.py", line138, inrunreturnloop.run_until_complete(task)
File"/Users/adrien.bolling/Applications/PyCharm Professional Edition.app/Contents/plugins/python/helpers-pro/pydevd_asyncio/pydevd_nest_asyncio.py", line243, inrun_until_completereturnf.result()
File"/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.9/lib/python3.9/asyncio/futures.py", line201, inresultraiseself._exceptionFile"/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.9/lib/python3.9/asyncio/tasks.py", line256, in__stepresult=coro.send(None)
File"/Users/adrien.bolling/PycharmProjects/technician-assignment/.venv/lib/python3.9/site-packages/orbax/checkpoint/base_pytree_checkpoint_handler.py", line620, inasync_savecommit_futures=awaitself.async_save(*args, **kwargs) # pytype: disable=bad-return-typeFile"/Users/adrien.bolling/PycharmProjects/technician-assignment/.venv/lib/python3.9/site-packages/orbax/checkpoint/base_pytree_checkpoint_handler.py", line528, inasync_savesave_args=jax.tree.map(
File"/Users/adrien.bolling/PycharmProjects/technician-assignment/.venv/lib/python3.9/site-packages/jax/_src/deprecations.py", line53, ingetattrraiseAttributeError(f"module {module!r} has no attribute {name!r}")
AttributeError: module'jax'hasnoattribute'tree'python-BaseException
This is very likely due to a mismatch between jax and orbax versions, especially considering the recent changes to orbax-checkpoints.
I temporarily fixed it by upgrading jax to 0.4.30 and keeping orbax to 0.5.16, then forcibly downgrading numpy to 1.21.0 and scipy to 1.10.1
It seems to me like this will need a refactor to either use legacy functionnalities that will soon be deprecated, or a global version bump for jax, orbax, numpy, and scipy (the former 2 which in turn break other functions due to behaviour changes, I think it stems from PettingZoo requirements)
Also be advised that such problems will only increase in the future due to the following :
WARNING:absl:SaveArgs.aggregateisdeprecated, pleaseusecustomTypeHandler (https://orbax.readthedocs.io/en/latest/custom_handlers.html#typehandler) or contact Orbax team to migrate before August 1st, 2024.
The text was updated successfully, but these errors were encountered:
@ffelten As mentionned I fixed it by forcibly downgrading certain packages after install, I didn't adapt the code to the new API, I can look into it if needed however
@ffelten As mentionned I fixed it by forcibly downgrading certain packages after install, I didn't adapt the code to the new API, I can look into it if needed however
Got the following error while training an agent when it came to saving the agents training.
This is very likely due to a mismatch between jax and orbax versions, especially considering the recent changes to orbax-checkpoints.
I temporarily fixed it by upgrading jax to 0.4.30 and keeping orbax to 0.5.16, then forcibly downgrading numpy to 1.21.0 and scipy to 1.10.1
It seems to me like this will need a refactor to either use legacy functionnalities that will soon be deprecated, or a global version bump for jax, orbax, numpy, and scipy (the former 2 which in turn break other functions due to behaviour changes, I think it stems from PettingZoo requirements)
Also be advised that such problems will only increase in the future due to the following :
The text was updated successfully, but these errors were encountered: