Import theano gives the AttributeError: module 'theano' has no attribute 'gof'

前端 未结 3 1456
面向向阳花
面向向阳花 2021-01-02 05:37

I have python 3. I installed \"Theano\" bleeding edge and \"Keras\" using

pip install --upgrade --no-deps git+git://github.com/Theano/Theano.git
3条回答
  •  野趣味
    野趣味 (楼主)
    2021-01-02 06:06

    I used conda to install theano and still got the same error. After much trial and error and StackOverflow searches, what worked for me was to first run:

    conda install m2w64-toolchain
    

    followed by:

    conda install theano
    

    Alternatively you can chain the modules together when you create an environment, for example:

    conda create -n myenv python=3.5 m2w64-toolchain theano
    

    Also important to follow @gtnbz2nyt's advice and restart your Python instance.

提交回复
热议问题