We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
bug描述 描述一下你遇到的bug, 例如报错位置、报错信息(重要, 可以直接截个图)等
版本信息 pytorch: torchvision: torchtext: ... %matplotlib inline import numpy as np import time import torch from torch import nn, optim import sys sys.path.append("..") import d2lzh_pytorch as d2l
def get_data_ch7(): # 本函数已保存在d2lzh_pytorch包中方便以后使用 data = np.genfromtxt('../../data/airfoil_self_noise.dat', delimiter='\t') data = (data - data.mean(axis=0)) / data.std(axis=0) return torch.tensor(data[:1500, :-1], dtype=torch.float32), torch.tensor(data[:1500, -1], dtype=torch.float32) # 前1500个样本(每个样本5个特征)
features, labels = get_data_ch7() features.shape # torch.Size([1500, 5])
The text was updated successfully, but these errors were encountered:
No branches or pull requests
bug描述
描述一下你遇到的bug, 例如报错位置、报错信息(重要, 可以直接截个图)等
版本信息
pytorch:
torchvision:
torchtext:
...
%matplotlib inline
import numpy as np
import time
import torch
from torch import nn, optim
import sys
sys.path.append("..")
import d2lzh_pytorch as d2l
def get_data_ch7(): # 本函数已保存在d2lzh_pytorch包中方便以后使用
data = np.genfromtxt('../../data/airfoil_self_noise.dat', delimiter='\t')
data = (data - data.mean(axis=0)) / data.std(axis=0)
return torch.tensor(data[:1500, :-1], dtype=torch.float32),
torch.tensor(data[:1500, -1], dtype=torch.float32) # 前1500个样本(每个样本5个特征)
features, labels = get_data_ch7()
features.shape # torch.Size([1500, 5])
The text was updated successfully, but these errors were encountered: