Master_B_mao 2021-06-23 22:07 采纳率: 100%
浏览 524
已采纳

Not found: Failed to c reate a NewWriteableFile:

使用tensorflow时,遇到问题

2021-06-23 21:19:41.397079: W tensorflow/core/framework/op_kernel.cc:1767] OP_REQUIRES failed at save_restore_v2_ops.cc:109 : Not found: Failed to c
reate a NewWriteableFile: C:/Users/12162/Desktop/model\online_train\read_comment\model.ckpt-0_temp\part-00000-of-00001.data-00000-of-00001.tempstate
1255047267071366445 : 系统找不到指定的路径。
; No such process
Traceback (most recent call last):
  File "D:/wechat/data/wechart_tensorflow.py", line 276, in <module>
    tf.app.run(main)
  File "D:\vippython\venv\lib\site-packages\tensorflow\python\platform\app.py", line 40, in run
    _run(main=main, argv=argv, flags_parser=_parse_flags_tolerate_undef)
  File "D:\vippython\venv\lib\site-packages\absl\app.py", line 303, in run
    _run_main(main, args)
  File "D:\vippython\venv\lib\site-packages\absl\app.py", line 251, in _run_main
    sys.exit(main(argv))
  File "D:/wechat/data/wechart_tensorflow.py", line 228, in main
    model.train()
  File "D:/wechat/data/wechart_tensorflow.py", line 111, in train
    self.estimator.train(
  File "D:\vippython\venv\lib\site-packages\tensorflow_estimator\python\estimator\estimator.py", line 349, in train
    loss = self._train_model(input_fn, hooks, saving_listeners)
  File "D:\vippython\venv\lib\site-packages\tensorflow_estimator\python\estimator\estimator.py", line 1175, in _train_model
    return self._train_model_default(input_fn, hooks, saving_listeners)
  File "D:\vippython\venv\lib\site-packages\tensorflow_estimator\python\estimator\estimator.py", line 1206, in _train_model_default
    return self._train_with_estimator_spec(estimator_spec, worker_hooks,
  File "D:\vippython\venv\lib\site-packages\tensorflow_estimator\python\estimator\estimator.py", line 1497, in _train_with_estimator_spec
    with training.MonitoredTrainingSession(
  File "D:\vippython\venv\lib\site-packages\tensorflow\python\training\monitored_session.py", line 602, in MonitoredTrainingSession
    return MonitoredSession(
  File "D:\vippython\venv\lib\site-packages\tensorflow\python\training\monitored_session.py", line 1035, in __init__
    super(MonitoredSession, self).__init__(
  File "D:\vippython\venv\lib\site-packages\tensorflow\python\training\monitored_session.py", line 750, in __init__
    self._sess = _RecoverableSession(self._coordinated_creator)
  File "D:\vippython\venv\lib\site-packages\tensorflow\python\training\monitored_session.py", line 1232, in __init__
    _WrappedSession.__init__(self, self._create_session())
  File "D:\vippython\venv\lib\site-packages\tensorflow\python\training\monitored_session.py", line 1237, in _create_session
    return self._sess_creator.create_session()
  File "D:\vippython\venv\lib\site-packages\tensorflow\python\training\monitored_session.py", line 910, in create_session
    hook.after_create_session(self.tf_sess, self.coord)
  File "D:\vippython\venv\lib\site-packages\tensorflow\python\training\basic_session_run_hooks.py", line 587, in after_create_session
    self._save(session, global_step)
  File "D:\vippython\venv\lib\site-packages\tensorflow\python\training\basic_session_run_hooks.py", line 619, in _save
    self._get_saver().save(session, self._save_path, global_step=step,
  File "D:\vippython\venv\lib\site-packages\tensorflow\python\training\saver.py", line 1188, in save
    model_checkpoint_path = sess.run(
  File "D:\vippython\venv\lib\site-packages\tensorflow\python\client\session.py", line 967, in run
    result = self._run(None, fetches, feed_dict, options_ptr,
  File "D:\vippython\venv\lib\site-packages\tensorflow\python\client\session.py", line 1190, in _run
    results = self._do_run(handle, final_targets, final_fetches,
  File "D:\vippython\venv\lib\site-packages\tensorflow\python\client\session.py", line 1368, in _do_run
    return self._do_call(_run_fn, feeds, fetches, targets, options,
  File "D:\vippython\venv\lib\site-packages\tensorflow\python\client\session.py", line 1375, in _do_call
    return fn(*args)
  File "D:\vippython\venv\lib\site-packages\tensorflow\python\client\session.py", line 1359, in _run_fn
    return self._call_tf_sessionrun(options, feed_dict, fetch_list,
  File "D:\vippython\venv\lib\site-packages\tensorflow\python\client\session.py", line 1451, in _call_tf_sessionrun
    return tf_session.TF_SessionRun_wrapper(self._session, options, feed_dict,
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xd5 in position 185: invalid continuation byte

 

  • 写回答

1条回答 默认 最新

  • CSDN专家-AlanMax 2021-06-23 23:03
    关注

    把原始数据转为utf-8格式就行了。现在应该是GB2312国标码

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 使用deepspeed训练,发现想要训练的参数没有梯度
  • ¥15 寻找一块做为智能割草机的驱动板(标签-stm32|关键词-m3)
  • ¥15 信息管理系统的查找和排序
  • ¥15 基于STM32,电机驱动模块为L298N,四路运放电磁传感器,三轮智能小车电磁组电磁循迹(两个电机,一个万向轮),怎么用读取的电磁传感器信号表示小车所在的位置
  • ¥15 如何解决y_true和y_predict数据类型不匹配的问题(相关搜索:机器学习)
  • ¥15 PB中矩阵文本型数据的总计问题。
  • ¥40 宿舍管理系统设计(c#)
  • ¥15 MATLAB卫星二体模型仿真
  • ¥15 怎么让数码管亮的同时让led执行流水灯代码
  • ¥20 SAP HANA SQL Script 。如何判断字段值包含某个字符串