Open bsivavenu opened 5 years ago
I just replaced tf.logging by tf.compat.v1.logging in my code, which required the trick for tf.app
For me also required: tf.cast(tf.gather(class_ids, keep)) -> tf.cast(tf.gather(class_ids, keep), tf.float32) so totally 5 replaces in model.py
If you can find the exact line where
tf.log
is used, trytf.math.log
instead.
Would you please tell me in which line it is in the model.py file? because I search but I didn't find it.
Hey, I've tested the official upgrade command. First I was in the project folder, then I
cd ..
Since I don't need another backup, I use the following command, according to the help instruction.tf_upgrade_v2 --intree Mask_RCNN --inplace --reportfile report.txt
Mask_RCNN is where I clone the whole repo. And it works.Hi, I tried this but still getting the AttributeError: module 'tensorflow' has no attribute 'log'
I am using Kaggle with tensorflow version 2.2.0
I tried to upgrade my code from tf.v1 to tf.v2 but still it is showing me same error. Please help.
Thanks Ahmad! It worked for me by running a completely independent virtual environment with a fresh install and specific tensor flow=1.13.1 and keras=2.1.0 versions Rami … On Nov 26, 2019, at 11:02 AM, ahmadasghar1992 @.***> wrote: I got it solved by downloading the shapely (.whl) file manually. Download the file from the following link. Be sure to check the Python version. Mine is Python 3.6 with Win 10 64 so I downloaded Shapely-1.6.4.post2-cp36-cp36m-win_amd64. Yours can be different, be sure to check. Link to download the file https://www.lfd.uci.edu/~gohlke/pythonlibs/#shapely https://www.lfd.uci.edu/~gohlke/pythonlibs/#shapely — You are receiving this because you commented. Reply to this email directly, view it on GitHub <#1797?email_source=notifications&email_token=AMLN7INB4MZIPCMLEGAIAVLQVVCBLA5CNFSM4JA7FMB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEFGQX6A#issuecomment-558697464>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AMLN7IMASHWZIMVJU257Y73QVVCBLANCNFSM4JA7FMBQ.
I currently have 2.3.1 version of TensorFlow installed. How do I get the lower version?
Dear All,
After adjusting the Tensorflow version according to the advices above.
I got an error message "TypeError: expected string or bytes-like object"
Any advice what to do?
change the following portion of code in 'requirements.txt'
tensorflow>=1.3.0 keras>=2.0.8
to
tensorflow==1.3.0 keras==2.0.8
change the following portion of code in 'requirements.txt'
tensorflow>=1.3.0 keras>=2.0.8
to
tensorflow==1.3.0 keras==2.0.8
If you can find the exact line where
tf.log
is used, trytf.math.log
instead.Would you please tell me in which line it is in the model.py file? because I search but I didn't find it.
It is found in Mask_RCNN--> mrcnn
https://www.immersivelimit.com/tutorials/mask-rcnn-for-windows-10-tensorflow-2-cuda-101
I tried this and works fine.
If you can find the exact line where
tf.log
is used, trytf.math.log
instead.
I tried it, It's working, Thanks.
It still use old version of tf library. So what I did is find the replacement functions and replace it on
model.py
file.I'll copy+paste changed code here and you use and compare yourself.
Summary:
tf.log()
->tf.math.log()
tf.sets.set_intersection()
->tf.sets.intersection()
tf.sparse_tensor_to_dense()
->tf.sparse.to_dense()
tf.to_float()
->tf.cast([value], tf.float32)
click to view the code block
Hi @xenogew
I tried replacing all functions as mentioned here but I am still getting this error.
Earlier, I was getting this error: TypeError: Could not build a TypeSpec for <KerasTensor: shape=(None, None, 4)
So I tried what's mentioned here and I got this log error and was redirected here. But I am still getting the log error.
I struggled for a bit with both the outdated Keras and Tensorflow versions on this repo. If you want to use the current versions, instead of replacing lines I recommend you cloning the following repo: https://github.com/akTwelve/Mask_RCNN It has been updated to run on tensorflow v2+ and keras v2.
i downloaded mask_rcnn_coco.h5 weights and installed pycocotools also and when i try to run demo.ipynb. i am getting this error as AttributeError: module 'tensorflow' has no attribute 'log' , please help i am still learning. I installed all the requoremnts.txt file also. please help.
**AttributeError Traceback (most recent call last)