您当前的位置: 首页 >  Python
  • 0浏览

    0关注

    2393博文

    0收益

  • 0浏览

    0点赞

    0打赏

    0留言

私信
关注
热门博文

成功解决AttributeError: module 'tensorflow.python.keras' has no attribute 'Model'

一个处女座的程序猿 发布时间:2018-09-28 21:35:00 ,浏览量:0

成功解决AttributeError: module 'tensorflow.python.keras' has no attribute 'Model'

 

目录

解决问题

解决方法

 

 

 

 

解决问题
  File "object_detection/builders/model_builder_test.py", line 24, in 
    from object_detection.builders import model_builder
  File "F:\File_Python\Python_example\models-master\research\object_detection\builders\model_builder.py", line 22, in 
    from object_detection.builders import box_predictor_builder
  File "F:\File_Python\Python_example\models-master\research\object_detection\builders\box_predictor_builder.py", line 21, in 
    from object_detection.predictors import convolutional_box_predictor
  File "F:\File_Python\Python_example\models-master\research\object_detection\predictors\convolutional_box_predictor.py", line 19, in 
    from object_detection.core import box_predictor
  File "F:\File_Python\Python_example\models-master\research\object_detection\core\box_predictor.py", line 137, in 
    class KerasBoxPredictor(tf.keras.Model):
AttributeError: module 'tensorflow.python.keras' has no attribute 'Model'

 

 

 

解决方法

升级tensorflow到最新版本即可!

pip install -U tensorflow

 

 

 

关注
打赏
1664196048
查看更多评论
立即登录/注册

微信扫码登录

0.0442s