Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

P.72 data_tf lose reshape? 书72页是否缺失一维化转换 #18

Open
Iamyang opened this issue Jul 14, 2018 · 1 comment
Open

P.72 data_tf lose reshape? 书72页是否缺失一维化转换 #18

Iamyang opened this issue Jul 14, 2018 · 1 comment

Comments

@Iamyang
Copy link

Iamyang commented Jul 14, 2018

72页定义了数据转换:
data_tf=transforms.Compose([transforms.ToTensor(),transforms.Normalize([0.5],[0.5])])
运行之后出错,
RuntimeError: size mismatch, m1: [1792 x 28], m2: [784 x 300] at c:\programdata\miniconda3\conda-bld\pytorch-cpu_1524541161962\work\aten\src\th\generic/THTensorMath.c:2033
书中和deep-nn代码里面的data_tf不同,代码样例里面data_tf有reshape操作

@L1aoXingyu
Copy link
Owner

以 deep-nn 的代码为准,等1.0出来之后书会更新的

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants