摘要:
import torch from torch import nn from d2l import torch as d2l batch_size = 256 train_iter, test_iter = d2l.load_data_fashion_mnist(batch_size) num_in 阅读全文
摘要:
import torch from torch import nn from d2l import torch as d2l batch_size = 256 train_iter, test_iter = d2l.load_data_fashion_mnist(batch_size) # PyTo 阅读全文
摘要:
import torch from IPython import display from d2l import torch as d2l # from d2l.mxnet import Accumulator batch_size = 256 # 每次读256张图片,返回训练iter和测试iter 阅读全文
摘要:
import random import torch from d2l import torch as d2l def synthetic_data(w,b,num_examples): """生成y=Xw+b+噪声""" x = torch.normal(0,1,(num_examples,len 阅读全文