
我运行了几个模型,这里显示了我的结果。然而,没有办法为模型有一个更有意义的名称(以黄色突出显示)。你知道吗?
否则,了解对应关系的唯一方法是从拟合阶段手动检查日志。
发布于 2022-01-14 13:41:15
名称取决于保存日志的目录。如果将日志保存到"./logs/ /train",将出现在tensorboard。
我通常定义一个模型名,包括一个时间戳。这样,每次运行时都会更改名称。它可能看起来像s.th。就像这样:
import time
import os
import tensorflow as tf
modelName = f"My_model_{int(time.time())}"
with tf.summary.create_file_writer(os.path.join("logs",modelName,"train")):
tf.summary.scalar("epoch_loss", data=epoch_loss, step=epoch, description="loss at every epoch")我认为要在step=epoch登录的损失值存储在变量epoch_loss中。
https://stackoverflow.com/questions/70709255
复制相似问题