tensorlab / tensorfx

TensorFlow framework for training and serving machine learning models
Apache License 2.0
196 stars 41 forks source link

Import fails with ImportError: no module named '_schema' #23

Closed sometechchick closed 7 years ago

sometechchick commented 7 years ago

Ran pip install tensorfx as per instructions. Tried import and failed with no module named '_schema'. Python env is Anaconda conda 4.2.9, Python 3.5.2. Running the build.sh script also yields the same error.

sometechchick commented 7 years ago

I fixed this error by changing all the import statements causing errors so they reference the tensorfx module directory structure, plus a few print statement updates (putting parenthesis in).

To import tensorfx as a module (particularly when using python setup bdist_wheel --universal and then pip installing the subsequent .whl file), any files with imports from folders in tensorfx needed to be prefaced with:

tensorfx.data._schema tensorfx.tools._train tensorfx.prediction._model

(for whatever the directory structure was.)