deeppavlov / intent_classifier

Apache License 2.0
84 stars 31 forks source link

PosixPath Error #7

Closed dylanail closed 6 years ago

dylanail commented 6 years ago

Every time I try to run this, I get the following error: dylxnxil@imposing-medium-187303:~/intent_classifier$ ./intent_classifier.py ./snips_pretrained/snips_config.json /usr/local/lib/python3.5/dist-packages/h5py/__init__.py:36: FutureWarning: Conversion of the second argument of issubdtype fromfloattonp.floatingis deprecated. In future, it will be treated asnp.float64 == np.dtype(float).type. from ._conv import register_converters as _register_converters Using TensorFlow backend. 2018-05-19 12:07:39.242585: I tensorflow/core/platform/cpu_feature_guard.cc:140] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX2 FMA Traceback (most recent call last): File "./intent_classifier.py", line 35, in <module> model = KerasMulticlassModel(opt) File "/home/dylxnxil/intent_classifier/intent_model/multiclass.py", line 90, in __init__ add_metrics_file=metrics_file) File "/home/dylxnxil/intent_classifier/intent_model/multiclass.py", line 432, in load with open(opt_path, 'r') as opt_file: TypeError: invalid file: PosixPath('snips_pretrained/cnn_model/cnn_model_opt.json')

I am using Tensorflow 1.8.0 and Keras 2.1.6. I tried this both on my machine and in a google cloud shell with the same issue both times. What is going wrong? Thanks.

dilyararimovna commented 6 years ago

Hello! This issue is caused by incompatibility of pathlib and python3.5. This repo requires python3.6. Sorry for not indicating it in README. This repo is not currently supported.

If you would like to use our libraries for intent classification, please, pay attention to deepmipt.DeepPavlov repo.

dylanail commented 6 years ago

Thanks! I figured that out eventually and got it working. I've been messing with DeepPavlov since. Thanks for the tip!