错误:模块'tensorflow' has no attribute 'gfile' while running tensorflow object detection api tutorial

新手上路,请多包涵

我正在尝试使用张量流 api 中的对象检测教程。我正在使用 python 3 和张量流版本 2。但是出现以下错误。我尝试了几种方法:

 File "C:\Aniruddhya\object_detection\object_detection\utils\label_map_util.py", line 137, in load_labelmap
    with tf.gfile.GFile(path, 'r') as fid:

AttributeError: module 'tensorflow' has no attribute 'gfile'

有人可以帮我运行这个吗?代码链接: https ://drive.google.com/drive/u/3/folders/1XHpnr5rsENzOOSzoWNTvRqhEbLKXaenL

原文由 Andy 发布,翻译遵循 CC BY-SA 4.0 许可协议

阅读 977
1 个回答
撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进