Skip to content

tensorflow module vERROR #39

@gaferguz

Description

@gaferguz

Hi everyone, I am facing an issue when running Deepbinner to demultiplex my fast5 files on a Mac Os:

(base)$ deepbinner classify --rapid ./fast5_pass/ > classifications
Traceback (most recent call last):
  File "/Users/Comms/.local/bin/deepbinner", line 8, in <module>
    sys.exit(main())
  File "/Users/Comms/.local/lib/python3.7/site-packages/deepbinner/deepbinner.py", line 60, in main
    classify(args)
  File "/Users/Comms/.local/lib/python3.7/site-packages/deepbinner/classify.py", line 33, in classify
    set_tensorflow_threads(args)
  File "/Users/Comms/.local/lib/python3.7/site-packages/deepbinner/classify.py", line 418, in set_tensorflow_threads
    config = tf.ConfigProto(intra_op_parallelism_threads=args.intra_op_parallelism_threads,
AttributeError: module 'tensorflow' has no attribute 'ConfigProto'

Since 'ConfigProto' is only available for older tensorflow versions (I checked ant it was remove in version 2.0), I tried pip install with tensorflow 1.15 version and got the following error:

$ deepbinner classify --rapid fast5_pass/ > classifications
Traceback (most recent call last):
  File "/Users/Comms/.local/lib/python3.7/site-packages/keras/__init__.py", line 3, in <module>
    from tensorflow.keras.layers.experimental.preprocessing import RandomRotation
ModuleNotFoundError: No module named 'tensorflow.keras.layers.experimental.preprocessing'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/Comms/.local/bin/deepbinner", line 8, in <module>
    sys.exit(main())
  File "/Users/Comms/.local/lib/python3.7/site-packages/deepbinner/deepbinner.py", line 59, in main
    from .classify import classify
  File "/Users/Comms/.local/lib/python3.7/site-packages/deepbinner/classify.py", line 24, in <module>
    from keras.models import load_model
  File "/Users/Comms/.local/lib/python3.7/site-packages/keras/__init__.py", line 6, in <module>
    'Keras requires TensorFlow 2.2 or higher. '
ImportError: Keras requires TensorFlow 2.2 or higher. Install TensorFlow via `pip install tensorflow`

I am not sure if I am doing things right or if I must install a specific tensorflow version on my system to work it out, but I still getting the first Error when using version 2.0 or above. I would appreciate any help on this.

Thanks in advance.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions