Im runnign a machine on Google cloud (16 vCPUs, 41 GB memory) CPU platform Intel Skylake
which im running keras
on it, im getting the following error:
yehoshaphat_schellekens@try-kaggle-toxic:~/toxic$ python
Python 3.5.4 |Anaconda custom (64-bit)| (default, Aug 14 2017, 13:26:58)
[GCC 4.4.7 20120313 (Red Hat 4.4.7-1)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import keras
Using TensorFlow backend.
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/keras/__init__.py", line 3, in <module>
from . import utils
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/keras/utils/__init__.py", line 6, in <module>
from . import conv_utils
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/keras/utils/conv_utils.py", line 3, in <module>
from .. import backend as K
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/keras/backend/__init__.py", line 83, in <module>
from .tensorflow_backend import *
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/keras/backend/tensorflow_backend.py", line 1, in <module>
import tensorflow as tf
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/tensorflow/__init__.py", line 23, in <module>
from tensorflow.python import *
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/tensorflow/python/__init__.py", line 62, in <module>
import tensorflow.contrib as contrib
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/tensorflow/contrib/__init__.py", line 26, in <module>
from tensorflow.contrib import learn
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/tensorflow/contrib/learn/__init__.py", line 20, in <module>
from tensorflow.contrib.learn.python.learn import *
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/tensorflow/contrib/learn/python/__init__.py", line 20, in <module>
from tensorflow.contrib.learn.python.learn import *
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/tensorflow/contrib/learn/python/learn/__init__.py", line 22, in <module>
from tensorflow.contrib.learn.python.learn.io import *
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/tensorflow/contrib/learn/python/learn/io/__init__.py", line 20, in <module>
from tensorflow.contrib.learn.python.learn.io.dask_io import *
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/tensorflow/contrib/learn/python/learn/io/dask_io.py", line 23, in <module>
import dask.dataframe as dd
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/dask/dataframe/__init__.py", line 1, in <module>
from .core import (DataFrame, Series, Index, _Frame, map_partitions,
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/dask/dataframe/core.py", line 23, in <module>
from .. import array as da
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/dask/array/__init__.py", line 4, in <module>
from .core import (Array, stack, concatenate, take, tensordot, transpose,
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/dask/array/core.py", line 13, in <module>
from toolz.curried import (pipe, partition, concat, unique, pluck, join, first,
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/toolz/curried/__init__.py", line 53, in <module>
_curry_namespace(vars(toolz)),
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/toolz/curried/__init__.py", line 48, in _curry_namespace
for name, f in ns.items() if '__' not in name
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/toolz/curried/__init__.py", line 48, in <genexpr>
for name, f in ns.items() if '__' not in name
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/toolz/curried/__init__.py", line 42, in _should_curry
return (callable(f) and _nargs(f) > 1 or f in do_curry)
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/site-packages/toolz/curried/__init__.py", line 35, in _nargs
return len(inspect.getargspec(f).args)
File "/home/yehoshaphat_schellekens/anaconda3/lib/python3.5/inspect.py", line 1050, in getargspec
raise ValueError("Function has keyword-only arguments or annotations"
ValueError: Function has keyword-only arguments or annotations, use getfullargspec() API which can support them
Ive tried solutions from here: ImportError with importing keras (like upgrading tensoreflow
) or from here: Getting ImportError while importing keras but they both seem to solve a different problem.
Notice that i have `tensoreflow' installed:
yehoshaphat_schellekens@try-kaggle-toxic:~$ sudo python -c 'import tensorflow as tf; print(tf.__version__)'
1.4.1
Any help on that (or at least an explanation on what is a Function has keyword-only arguments or annotations would be great.
Thanks in advance!