Code Monkey home page Code Monkey logo

Comments (11)

kishorejaganathan avatar kishorejaganathan commented on August 14, 2024

When I googled your error, a lot of the links are pointing to Tensorflow 2.0. Could you open an interactive python session and just try:

import tensorflow as tf
print(tf.__version__)

and make sure you've installed the right version of Tensorflow (we've tested from 1.2 to 1.9)?

Some other things you could try:

  • Install tensorflow via pip
  • Try python 2.7 if that's an option

from spliceai.

kishorejaganathan avatar kishorejaganathan commented on August 14, 2024

Could you also try installing tensorflow via
conda install tensorflow==1.9.0

from spliceai.

davemcg avatar davemcg commented on August 14, 2024

I also saw that which is why I installed tensorflow at 1.2

(spliceai) [mcgaugheyd@cn4177 2019_arno]$ conda list tensorflow
# packages in environment at /data/mcgaugheyd/conda/envs/spliceai:
#
# Name                    Version                   Build  Channel
tensorflow                1.2.0                    py36_0    conda-forge

Though when I check via python....

>>> import tensorflow as tf

>>> print(tf.__version__)
2.0.0

Uh, what happened?

from spliceai.

kishorejaganathan avatar kishorejaganathan commented on August 14, 2024

Yeah I figured you installed 2.0 by mistake, usually it should be == and not = for precise versions. Could you try one of:
conda install tensorflow==1.9.0
or
pip install tensorflow==1.9.0
though I am not sure it will help as your conda list output is as expected...

During the next update, I'll add a patch to make sure it works for versions 2.0 onwards as well...

from spliceai.

davemcg avatar davemcg commented on August 14, 2024

Installed conda create --yes --name spliceai; conda activate spliceai; conda install --yes tensorflow==1.9-0; conda install --yes spliceai but now getting this error:

$ spliceai -h
Using TensorFlow backend.
/data/mcgaugheyd/conda/envs/spliceai/lib/python3.6/site-packages/tensorflow/python/framework/dtypes.py:523: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  _np_qint8 = np.dtype([("qint8", np.int8, 1)])
/data/mcgaugheyd/conda/envs/spliceai/lib/python3.6/site-packages/tensorflow/python/framework/dtypes.py:524: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  _np_quint8 = np.dtype([("quint8", np.uint8, 1)])
/data/mcgaugheyd/conda/envs/spliceai/lib/python3.6/site-packages/tensorflow/python/framework/dtypes.py:525: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  _np_qint16 = np.dtype([("qint16", np.int16, 1)])
/data/mcgaugheyd/conda/envs/spliceai/lib/python3.6/site-packages/tensorflow/python/framework/dtypes.py:526: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  _np_quint16 = np.dtype([("quint16", np.uint16, 1)])
/data/mcgaugheyd/conda/envs/spliceai/lib/python3.6/site-packages/tensorflow/python/framework/dtypes.py:527: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  _np_qint32 = np.dtype([("qint32", np.int32, 1)])
/data/mcgaugheyd/conda/envs/spliceai/lib/python3.6/site-packages/tensorflow/python/framework/dtypes.py:532: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
  np_resource = np.dtype([("resource", np.ubyte, 1)])
Traceback (most recent call last):
  File "/data/mcgaugheyd/conda/envs/spliceai/bin/spliceai", line 8, in <module>
    from spliceai.__main__ import main
  File "/data/mcgaugheyd/conda/envs/spliceai/lib/python3.6/site-packages/spliceai/__main__.py", line 4, in <module>
    from spliceai.utils import Annotator, get_delta_scores
  File "/data/mcgaugheyd/conda/envs/spliceai/lib/python3.6/site-packages/spliceai/utils.py", line 5, in <module>
    from keras.models import load_model
  File "/data/mcgaugheyd/conda/envs/spliceai/lib/python3.6/site-packages/keras/__init__.py", line 3, in <module>
    from . import utils
  File "/data/mcgaugheyd/conda/envs/spliceai/lib/python3.6/site-packages/keras/utils/__init__.py", line 6, in <module>
    from . import conv_utils
  File "/data/mcgaugheyd/conda/envs/spliceai/lib/python3.6/site-packages/keras/utils/conv_utils.py", line 9, in <module>
    from .. import backend as K
  File "/data/mcgaugheyd/conda/envs/spliceai/lib/python3.6/site-packages/keras/backend/__init__.py", line 1, in <module>
    from .load_backend import epsilon
  File "/data/mcgaugheyd/conda/envs/spliceai/lib/python3.6/site-packages/keras/backend/load_backend.py", line 90, in <module>
    from .tensorflow_backend import *
  File "/data/mcgaugheyd/conda/envs/spliceai/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py", line 54, in <module>
    get_graph = tf_keras_backend.get_graph
AttributeError: module 'tensorflow.python.keras.backend' has no attribute 'get_graph'

from spliceai.

kishorejaganathan avatar kishorejaganathan commented on August 14, 2024

Also seems like a 2.0 issue. Could you try installing tensorflow with pip?

from spliceai.

kishorejaganathan avatar kishorejaganathan commented on August 14, 2024

Is this still an issue? I'm reading that it is important to use certain versions of Keras with certain versions of Tensorflow. Could you try Keras==2.2.4 with Tensorflow 1.9 if you still couldn't get this to work?

from spliceai.

mcortes-lopez avatar mcortes-lopez commented on August 14, 2024

I had a similar issue and I tried the installation with Keras 2.24 and Tensorflow 1.9 but the error that i currently have is:

Traceback (most recent call last):
File "/home/mcortesl/.conda/envs/spliceai/bin/spliceai", line 12, in
sys.exit(main())
File "/home/mcortesl/.conda/envs/spliceai/lib/python3.6/site-packages/spliceai/main.py", line 53, in main
ann = Annotator(args.R, args.A)
File "/home/mcortesl/.conda/envs/spliceai/lib/python3.6/site-packages/spliceai/utils.py", line 20, in init
self.genes = df['#NAME'].get_values()
File "/home/mcortesl/.conda/envs/spliceai/lib/python3.6/site-packages/pandas/core/generic.py", line 5274, in getattr
return object.getattribute(self, name)
AttributeError: 'Series' object has no attribute 'get_values'

from spliceai.

JakeHagen avatar JakeHagen commented on August 14, 2024

@mcortes-lopez I think that is a pandas 1.0 issue. Try pandas 0.25.3

from spliceai.

kishorejaganathan avatar kishorejaganathan commented on August 14, 2024

@mcortes-lopez: As pointed out by @JakeHagen, this is a pandas 1.0 issue. We have resolved this in the latest update to the git repo, so you should not have this issue if you clone it now. Alternately, you can also try downgrading pandas version to something like 0.24.2 and that should work as well...

from spliceai.

bw2 avatar bw2 commented on August 14, 2024

Looks like tensorflow v1.9.0 is no longer available on PyPI
This works instead:

python3 -m pip install tensorflow==1.15.3

from spliceai.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.