This was the error raised
np.object was a deprecated alias for the builtin object. To avoid this error in existing code, use object by itself. Doing this will not modify any behavior and is safe.
The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations
My tensorflow is version 2.6.0 and Numpy version 1.25.0
Nothing has worked so far, it seems like I was just juggling between pip install of different versions and it seems to open a can of worms and asking me to change different versions of packages I have.
What I have done
- I have tried
!pip installto upgrade downgrade to solve compatibility issue but no dice - I have tried upgrading the tensorflow packages through Anaconda Navigator but it seems to have bug and just stuck at version 2.6.0
I'm also using Tensorflow 2.6.0 and numpy 1.25.0 and ran into the same problem. Since I already fixed it, I can't get screenshots of the errors anymore. I also referred to that linked documentation, so we're on exactly the same page. I'm confident this will help you.
Note: my Anaconda environment is named "tf_gpu"
The first error that
np.intwas deprecated appeared inUsing the release notes, I went into that file and replaced all instances with
np.int_. I don't understand the difference nor why tensorflow hasn't incorporated that yet.The second error that
np.boolwas deprecated appeared in the same file. I once again replaced allnp.boolwithnp.bool_per the numpy 1.25.0 release notes.The third error popped up in the following folder:
Since I already fixed it, I don't remember which file within this folder the error happened, but the solution was the same as before: replace
np.boolwithnp.bool_.After those changes, I didn't have any other issues.