Comments (6)
Hi,
It is a absolute importing problem in Python2.7. Please update the pip package (name no changed) with:
pip install -U https://github.com/Microsoft/MMdnn/releases/download/0.1.0/mmdnn-0.1.0-py2.py3-none-any.whl
and try again. Thanks.
from mmdnn.
Thanks for prompt reply.
I tried to upgrade the package and the new error is:
Traceback (most recent call last):
File "/usr/lib/python2.7/runpy.py", line 174, in _run_module_as_main
"__main__", fname, loader, pkg_name)
File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
exec code in run_globals
File "/usr/local/lib/python2.7/dist-packages/mmdnn/conversion/examples/tensorflow/extract_model.py", line 12, in <module>
from mmdnn.conversion.examples.imagenet_test import TestKit
File "/usr/local/lib/python2.7/dist-packages/mmdnn/conversion/examples/imagenet_test.py", line 13, in <module>
from tensorflow.contrib.keras.python.keras.preprocessing import image
ImportError: No module named python.keras.preprocessing
from mmdnn.
What is your tensorflow version? 1.4? Checked the package of tensorflow in windows is different from in linux. Please update the pip package and try again. Thanks.
from mmdnn.
I used Linux so I'm pretty sure it is 1.4.0. I updated again and it remains...
from mmdnn.
Fixed problem
Hi, I fixed a api changed [tensorflow.contrib.keras.python.keras.preprocessing] --> tensorflow.contrib.keras.api.keras.preprocessing
And reinstalled tensorflow 1.4 and mmdnn (both with pip) but can't reproduce this problem.
Question
If you pip package updated successfully, the error should become
[ImportError: No module named api.keras.preprocessing].
- If error is is still [tensorflow.contrib.keras.python.keras.preprocessing]
Please check the file [~/.local/lib/python3.5/site-packages/mmdnn/conversion/examples/imagenet_test.py](my python library path, please change to your path) and see if there are lines like
# work for tf 1.4 in windows & linux
from tensorflow.contrib.keras.api.keras.preprocessing import image
if it is just
from tensorflow.contrib.keras.python.keras.preprocessing import image
which means the pip package is not updated. Please try this before re-install
pip uninstall mmdnn
- If the error is [No module named api.keras.preprocessing]
Please check if you can call
python -c "from tensorflow.contrib.keras.api.keras.preprocessing import image"
Thanks for diagnosing the problem.
from mmdnn.
The problem has been resolved. Thank you!
from mmdnn.
Related Issues (20)
- Handling multiple inputs in keras
- load higher version pytorch model error
- AttributeError: 'NoneType' object has no attribute 'name' in FusedBatchNorm HOT 3
- KeyError while converting PyTorch model to IR
- How to make modifications?
- Make upgrades?
- Fail to convert resnet101 from PyTorch to IR
- Convert Inception_v3 from Caffe to PyTorch
- SpaceToBatchND/BatchToSpaceND not supported while converting from tensorflow to caffe
- Fail to Convert resnet from Caffe to onnx and Pytorch
- mmtoir from PyTorch 2 IR missing .json, .npy and .pb file
- Getting ValueError: axes don't match array
- Pytorch model GFPGANv1.3.pth
- onnx2IR? HOT 1
- This repo is missing important files HOT 2
- How can I convert tf(.pb) to pytorch?
- Error to convert a model from IR to Pytorch
- Error converting caffe to torch model HOT 1
- pytorch to onnx
- pytorch to onnx
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mmdnn.