• 人工智能部分视频学习内容报错未解决


    garbage_classify项目报错没有解决:
    
    48/49 [============================>.] - ETA: 9s - loss: 3.7486 - accuracy: 0.0365 Traceback (most recent call last):
      File "C:\Workspace\python3.7\lib\site-packages\tensorflow_core\python\ops\gen_resource_variable_ops.py", line 569, in read_variable_op
        "dtype", dtype)
    tensorflow.python.eager.core._FallbackException: This function does not handle the case of the path where all inputs are not already EagerTensors.
    
    During handling of the above exception, another exception occurred:
    
    Traceback (most recent call last):
      File "C:/Workspace/4_cv/第四章 Tensorflow框架/garbage_classify/train.py", line 119, in <module>
        train_model(args)
      File "C:/Workspace/4_cv/第四章 Tensorflow框架/garbage_classify/train.py", line 113, in train_model
        shuffle=True
      File "C:\Workspace\python3.7\lib\site-packages\tensorflow_core\python\keras\engine\training.py", line 1297, in fit_generator
        steps_name='steps_per_epoch')
      File "C:\Workspace\python3.7\lib\site-packages\tensorflow_core\python\keras\engine\training_generator.py", line 332, in model_iteration
        callbacks.on_epoch_end(epoch, epoch_logs)
      File "C:\Workspace\python3.7\lib\site-packages\tensorflow_core\python\keras\callbacks.py", line 298, in on_epoch_end
        callback.on_epoch_end(epoch, logs)
      File "C:\Workspace\python3.7\lib\site-packages\tensorflow_core\python\keras\callbacks.py", line 1614, in on_epoch_end
        self._log_weights(epoch)
      File "C:\Workspace\python3.7\lib\site-packages\tensorflow_core\python\keras\callbacks.py", line 1693, in _log_weights
        weight = K.get_value(weight)
      File "C:\Workspace\python3.7\lib\site-packages\tensorflow_core\python\keras\backend.py", line 3267, in get_value
        return x.numpy()
      File "C:\Workspace\python3.7\lib\site-packages\tensorflow_core\python\ops\resource_variable_ops.py", line 577, in numpy
        return self.read_value().numpy()
      File "C:\Workspace\python3.7\lib\site-packages\tensorflow_core\python\ops\resource_variable_ops.py", line 630, in read_value
        value = self._read_variable_op()
      File "C:\Workspace\python3.7\lib\site-packages\tensorflow_core\python\ops\resource_variable_ops.py", line 608, in _read_variable_op
        self._dtype)
      File "C:\Workspace\python3.7\lib\site-packages\tensorflow_core\python\ops\gen_resource_variable_ops.py", line 574, in read_variable_op
        resource, dtype=dtype, name=name, ctx=_ctx)
      File "C:\Workspace\python3.7\lib\site-packages\tensorflow_core\python\ops\gen_resource_variable_ops.py", line 612, in read_variable_op_eager_fallback
        attrs=_attrs, ctx=_ctx, name=name)
      File "C:\Workspace\python3.7\lib\site-packages\tensorflow_core\python\eager\execute.py", line 76, in quick_execute
        raise e
      File "C:\Workspace\python3.7\lib\site-packages\tensorflow_core\python\eager\execute.py", line 61, in quick_execute
        num_outputs)
    TypeError: An op outside of the function building code is being passed
    a "Graph" tensor. It is possible to have Graph tensors
    leak out of the function building context by including a
    tf.init_scope in your function building code.
    For example, the following function will fail:
      @tf.function
      def has_init_scope():
        my_constant = tf.constant(1.)
        with tf.init_scope():
          added = my_constant * 2
    The graph tensor has name: conv2d/kernel:0
    
    Process finished with exit code 1
    

      

    Tensorboard目录启动关系(No dashboards are active for the current data set

  • 相关阅读:
    在energia中添加新的库
    KEIL3中出现的字符不对齐的情况解决办法
    VHDL硬件描述语言实现数字钟
    51单片机软件I2C驱动中的CY
    自问自答:在VB中如何实现像C++一样printf的功能
    [转][译] 分分钟学会一门语言之 Python 篇
    杂谈PID控制算法——最终篇:C语言实现51单片机中的PID算法
    Eclipse 安装与配置
    win10 环境安装 jdk 11.0.2
    解决网络问题神奇工具
  • 原文地址:https://www.cnblogs.com/xhzd/p/15982865.html
Copyright © 2020-2023  润新知