聊城网站备案,农业电商网站建设方案,阿里云域名注册官网叫什么,郑州网站建设三猫网络使用传统CNN网络训练图像分类模型
1. MNIST
首先,定义一下超参数等
import torch# dataset
input_shape = 28
num_classes = 10# hyper
batch_size = 64
num_epochs = 5
learning_rate = 1e-3# gpu
device = torch.device(cuda使用传统CNN网络训练图像分类模型
1. MNIST
首先,定义一下超参数等
import torch# dataset
input_shape = 28
num_classes = 10# hyper
batch_size = 64
num_epochs = 5
learning_rate = 1e-3# gpu
device = torch.device('cuda'