简体   繁体   English

在 MacBook 上运行 tensorboard 时,此错误不断出现:当前数据集没有活动的仪表板

[英]When running tensorboard on MacBook, this error keeps showing up: No dashboards are active for the current data set

I'm running a CNN training model with tensorflow.我正在使用 tensorflow 运行一个 CNN 训练模型。 I want to visualize accuracy of the training model with Tensorboard.我想用 Tensorboard 可视化训练模型的准确性。 I tried the following variations:我尝试了以下变体:

tensorboard --logdir=/Users/Desktop/model_folder 
tensorboard --logdir="/Users/Desktop/model_folder" 

But every time I try to load Tensorflow in my browser, the error is: no dashboards are active for the current data set.但是每次我尝试在浏览器中加载 Tensorflow 时,都会出现错误:当前数据集没有活动的仪表板。

I saw some solutions for Windows where they specified the network drive;我看到了一些 Windows 的解决方案,他们指定了网络驱动器; however, mac does not have a network drive, so I'm not sure how to proceed.但是,mac 没有网络驱动器,所以我不确定如何进行。

Are there solutions to this error for MacBook?是否有针对 MacBook 的此错误的解决方案? Or are there other ways of visualizing training model accuracy with python?或者还有其他方法可以用 python 可视化训练模型的准确性吗?

To simply visualise you don't specifically need tensorboard and can just use history object that the fit method returns:为了简单地可视化,您不需要特别需要张量板,只需使用fit方法返回的history对象:

import pandas as pd

#### here you create your model ####

hist = fit(x, y)
histdf = pd.DataFrame(hist)

# Plot loss
hist_df.loc[:, ['train_loss', 'val_loss']].plot(kind='line')
# Plot accuracy
hist_df.loc[:, ['train_accuracy', 'val_accuracy']].plot(kind='line')

You can of course also import matplotlib and set up plots in more detail.您当然也可以导入 matplotlib 并更详细地设置绘图。

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

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM