简体   繁体   English

OSError:SavedModel 文件不存在于:cnnCat2.h5\{saved_model.pbtxt|saved_model.pb}

[英]OSError: SavedModel file does not exist at: cnnCat2.h5\{saved_model.pbtxt|saved_model.pb}

Sublime Text Project Structure Sublime Text 项目结构

Error Displaying错误显示

2021-06-15 11:48:41.978235: W tensorflow/stream_executor/platform/default/dso_loader.cc:64] Could not load dynamic library 'cudart64_110.dll'; dlerror: cudart64_110.dll not found
2021-06-15 11:48:41.978656: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine.
pygame 2.0.1 (SDL 2.0.14, Python 3.9.4)
Hello from the pygame community. https://www.pygame.org/contribute.html
Traceback (most recent call last):
  File "C:\Users\washi\Desktop\Driver-drowsiness-detection-CNN-Keras-OpenCV-master\final.py", line 17, in <module>
    model = load_model('cnnCat2.h5')
  File "D:\Program Files\Python39\lib\site-packages\keras\saving\save.py", line 206, in load_model
    return saved_model_load.load(filepath, compile, options)
  File "D:\Program Files\Python39\lib\site-packages\keras\saving\saved_model\load.py", line 109, in load
    meta_graph_def = loader_impl.parse_saved_model(path).meta_graphs[0]
  File "D:\Program Files\Python39\lib\site-packages\tensorflow\python\saved_model\loader_impl.py", line 113, in parse_saved_model
    raise IOError(
OSError: SavedModel file does not exist at: cnnCat2.h5\{saved_model.pbtxt|saved_model.pb}
[Finished in 5.2s]

Run the final.py script with tensorflow as a backend, The script continuously monitors the the user's eye state and classifies whether the person is drowsy or not.以 tensorflow 为后端运行 final.py 脚本,该脚本持续监控用户的眼睛 state 并对人是否昏昏欲睡进行分类。 model.py is the script used to training the CNN classifier model. model.py 是用于训练 CNN 分类器 model 的脚本。 but I get this type of error what should I do?但我得到这种类型的错误我该怎么办?

in your code try to use "" and not '' in specifying the directory在您的代码中尝试使用""而不是''来指定目录

for example例如

model_path = os.path.join(join(dirname(realpath(__file__))), "example.h5")

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 OSError:SavedModel 文件不存在于:/content\model\2016/{saved_model.pbtxt|saved_model.pb} - OSError: SavedModel file does not exist at: /content\model\2016/{saved_model.pbtxt|saved_model.pb} OSError:SavedModel 文件不存在于:../dnn/mpg_model.h5/{saved_model.pbtxt|saved_model.pb} - OSError: SavedModel file does not exist at: ../dnn/mpg_model.h5/{saved_model.pbtxt|saved_model.pb} OSError:SavedModel 文件不存在于:model/CPN_Model.h5\{saved_model.pbtxt|saved_model.pb} - OSError: SavedModel file does not exist at: model/CPN_Model.h5\{saved_model.pbtxt|saved_model.pb} OSError:SavedModel 文件不存在于:model\mymodel.h5/{saved_model.pbtxt|saved_model.pb} - OSError: SavedModel file does not exist at: model\mymodel.h5/{saved_model.pbtxt|saved_model.pb} SavedModel 文件不存在于:model.h5/{saved_model.pbtxt|saved_model.pb} - SavedModel file does not exist at: model.h5/{saved_model.pbtxt|saved_model.pb} 腌制文件存在但其中没有任何内容 OSError:SavedModel 文件不存在于:{saved_model.pbtxt|saved_model.pb} - a pickled file exists but nothing in it OSError: SavedModel file does not exist at: {saved_model.pbtxt|saved_model.pb} OSError:SavedModel 文件不存在于:C:\Users\Munib\New folder/{saved_model.pbtxt|saved_model.pb} - OSError: SavedModel file does not exist at: C:\Users\Munib\New folder/{saved_model.pbtxt|saved_model.pb} OSError:SavedModel 文件不存在于:C:/User/A/model/saved_model.pb - OSError: SavedModel file does not exist at: C:/User/A/model/saved_model.pb FAILED_PRECONDITION:错误:SavedModel目录gs:// mybucket1 /应该完全包含[saved_model.pb,saved_model.pbtxt]中的一个 - FAILED_PRECONDITION: Error: SavedModel directory gs://mybucket1/ is expected contain exactly one of [saved_model.pb, saved_model.pbtxt] 如何正确创建saved_model.pb? - How to correctly create saved_model.pb?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM