【python】 numpy、torch 打印全部
numpy 打印前添加np.set_printoptions(threshold=np.inf)print(x)torch 打印前添加torch.set_printoptions(profile="full")print(x) # prints the whole tensortorch.set_printoptions(profile="default") # resetprint(x) # p
·
numpy 打印前添加
np.set_printoptions(threshold=np.inf)
print(x)
torch 打印前添加
torch.set_printoptions(profile="full")
print(x) # prints the whole tensor
torch.set_printoptions(profile="default") # reset
print(x) # prints the truncated tensor
更多推荐



所有评论(0)