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
'EnumTypeWrapper' object has no attribute 'DT_FLOAT' while importing in Python 3 #2014
Comments
seems to be a bug , @pyu10055 can you please take a look ? |
AttributeError: 'EnumTypeWrapper' object has no attribute 'DT_FLOAT' Same problem |
+1 |
I tried it with version 1.2.6 and it does not have this error. 1.2.9 has |
|
I believe this is fixed by this PR dd5d9ed you should see the changes in next release. |
on version 1.2.6 I get this error:
|
"pip install tensorflowjs==1.2.6" worked for me, thanks |
TensorFlow.js version
1.2.9
Browser version
Does not matter
Describe the problem or feature request
While importing tensorflowjs module in python3 (using Google Colab environment), I get the following error:
`---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
in ()
1 from google.colab import drive
2 from google.colab import files
----> 3 import tensorflowjs as tfjs
4
5 drive.mount('/content/gdrive')
4 frames
/usr/local/lib/python3.6/dist-packages/tensorflowjs/init.py in ()
19
20 # pylint: disable=unused-imports
---> 21 from tensorflowjs import converters
22 from tensorflowjs import quantization
23 from tensorflowjs import version
/usr/local/lib/python3.6/dist-packages/tensorflowjs/converters/init.py in ()
22 from tensorflowjs.converters.keras_tfjs_loader import deserialize_keras_model
23 from tensorflowjs.converters.keras_tfjs_loader import load_keras_model
---> 24 from tensorflowjs.converters.tf_saved_model_conversion_v2 import convert_tf_saved_model
/usr/local/lib/python3.6/dist-packages/tensorflowjs/converters/tf_saved_model_conversion_v2.py in ()
39 from tensorflowjs.converters import common
40 from tensorflowjs.converters import fold_batch_norms
---> 41 from tensorflowjs.converters import fuse_prelu
42
43 # enable eager execution for v2 APIs
/usr/local/lib/python3.6/dist-packages/tensorflowjs/converters/fuse_prelu.py in ()
198 prelu_fn(tf.constant(1.0), tf.constant(1.0))
199
--> 200 register_prelu_op()
/usr/local/lib/python3.6/dist-packages/tensorflowjs/converters/fuse_prelu.py in register_prelu_op()
40
41 value = attr_value_pb2.AttrValue()
---> 42 value.list.type.extend([types_pb2.DataType.DT_FLOAT])
43 attr = op_def_pb2.OpDef.AttrDef()
44 attr.name = 'T'
AttributeError: 'EnumTypeWrapper' object has no attribute 'DT_FLOAT'
`
Code to reproduce the bug / link to feature request
You can try it on Google Colab.
https://colab.research.google.com/drive/1gftM84djEwrxNfgqbriIzxatI5S_p9aX
The text was updated successfully, but these errors were encountered: