AttributeError: module 'keras.la
2018-05-28 本文已影响0人
Carrie_Hou
has no attribute的问题多半是因为版本的问题,就比如题目上这个,在之前两台服务器上运行都没有问题,但是新的服务器上就报错:AttributeError: module 'keras.layers' has no attribute 'subtract'。经过反复改正,发现是keras版本的问题,将其更新至2.1以后版本即可,运行:
pip install --upgrade keras==2.1.6
祝编码顺利!