自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(2)
  • 收藏
  • 关注

原创 ValueError: Using a target size (torch.Size([1, 531])) that is different to the input size (torch.Si

ValueError: Using a target size (torch.Size([1, 531])) that is different to the input size (torch.Size([531, 1])) is deprecated. Please ensure they have the same size.问题分析:发现是输出特征数据Y的张量写错了,行列不一致。修改.reshape((1,-1))为.reshape((-1,1)),可以正常训练。问题:训练网络时出现。

2024-08-20 22:08:31 90

原创 遇到NameError: name ‘self‘ is not defined

在写def __init__(self)函数时注意空格,直接按下回车键,不要敲多了空格切记切记!问题:NameError: name 'self' is not defined。解决方法: '''搭建神经网络各层'''上述两行代码前面的空格要一致,就不会报错了。

2024-08-20 20:42:19 92

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除