node.js - model.predict.print() 未在 tensorflow.js 中显示所有结果
问题描述
加载模型后,预测结果如下:
Tensor
[[0.5050125, 0.6573772],
[0.5050992, 0.6576715],
[0.5049844, 0.6572819],
...,
[0.5045587, 0.6558315],
[0.5050324, 0.6574449],
[0.5043802, 0.6552206]]
如何让它显示所有结果而不是“...”?
解决方案
这边走:
import tensorflow as tf
#Let's create a simulated data...
Tensor=tf.random.normal([10,2])
#...and print every row on screen:
for i in range(len(Tensor)):
print(Tensor[i].numpy())
推荐阅读
- docker - 如何使用 xunit 在 Dockerfile 中运行测试
- go - 如何在 gin url 中有一个带有斜杠的参数
- android - ImageView绑定Url后RecyclerView中不加载图片
- c - 如何声明和初始化指向 char 指针数组的指针数组?
- geopandas - Geopandas 使用 bytesIO 或等效 (python3X) 将 shapefile 保存在内存中
- apache-spark - 将附加参数传递给 pyspark 中的 foreachBatch
- firebase - firebase 是否会回收令牌?
- javascript - 如何以编程方式添加下标(html标签)?
- jenkins - Windows 上 Jenkins 声明性管道中的变量扩展
- c# - 可以将表添加到不属于原始 Db 的复制 Db 中吗?