rstudio - Tensorboard 未在 Rstudio 中显示图表
问题描述
我正在尝试生成一个少数张量的图表作为 Tensorboard 的实验。但是,没有显示输出。以下是我的配置:
tensorflow::tf_config()
输出:
TensorFlow v2.6.0(C:\Users\mohammed\AppData\Local\Programs\Python\Python39\lib\site-packages\tensorflow_init _.p ) Python v3.9(C:/Users/mohammed/AppData/Local/程序/Python/Python39/python.exe)
加载库
library(dplyr)
library(tensorflow)
library(keras)
tensorflow::tf_config()
mytf <- tf$compat$v1```
TF <- tf$compat$v1
tf$compat$v1$disable_eager_execution() # needed in TF2
# build a graph
a <- TF$constant(5.0, name = "NumChildren")
b <- TF$constant(6.0, name = "NumAdult")
c <- a*b
sess <- tf$compat$v1$Session()
# Evaluate tensor "C"
print(sess$run(c)) # should return 30
# write the session graph
Location <- "D:/FirstGraph"
WriteGraph <- TF$summary$FileWriter(paste0(Location,"/graphs"), sess$graph)
tf$keras$callbacks$TensorBoard(log_dir = WriteGraph)```
# Console Output
```<keras.callbacks_v1.TensorBoard>```
解决方案
推荐阅读
- sql-server - 有没有办法优化从 Oracle 到 SQL Server 的数据迁移并减少花费的时间?
- android - 如何将editText放在视图下方,都在线性布局内
- web-services - 寻址服务时使用什么 HTTP 请求方法?
- sqlite - 外键约束在 SQlite 中不起作用
- sql - 与上年的百分比差异
- c# - 从 DialogContext 获取 TurnState 数据
- python - 将列表成员传递给python函数中的一个变量
- networking - 如何为 Kubernetes 配置这个外部服务?
- dart - 如何在 Flutter 中使用 TextField 中的 onKeyUp 事件
- google-chrome - chrome 扩展 storage.get 无法设置默认值