thunlp / JointNRE

Joint Neural Relation Extraction with Text and KGs
MIT License
187 stars 36 forks source link

what's the version of keras and tensorflow #17

Closed SeekPoint closed 4 years ago

SeekPoint commented 5 years ago

ub16hp@UB16HP:~/ub16_prj/JointNRE/jointE$ python train.py Traceback (most recent call last): File "train.py", line 1, in import tensorflow as tf File "/usr/local/lib/python2.7/dist-packages/tensorflow/init.py", line 24, in from tensorflow.python import pywrap_tensorflow # pylint: disable=unused-import File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/init.py", line 82, in from tensorflow.python import keras File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/keras/init.py", line 24, in from tensorflow.python.keras import activations File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/keras/activations/init.py", line 22, in from tensorflow.python.keras._impl.keras.activations import elu File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/keras/_impl/keras/init.py", line 21, in from tensorflow.python.keras._impl.keras import activations File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/keras/_impl/keras/activations.py", line 23, in from tensorflow.python.keras._impl.keras import backend as K File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/keras/_impl/keras/backend.py", line 36, in from tensorflow.python.layers import base as tf_base_layers File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/layers/base.py", line 25, in from tensorflow.python.keras.engine import base_layer File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/keras/engine/init.py", line 23, in from tensorflow.python.keras.engine.base_layer import Layer File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/keras/engine/base_layer.py", line 34, in from tensorflow.python.keras import backend File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/keras/backend/init.py", line 22, in from tensorflow.python.keras._impl.keras.backend import abs ImportError: cannot import name abs

THUCSTHanxu13 commented 4 years ago

The model is implemented using tensorflow 1.3. It may be difficult for the latest TF version to run the code = =!