我就废话不多说了,大家还是直接看代码吧~
import torch
import torch.nn as nn
import torch.nn.functional as F
class VGG16(nn.Module):
def __init__(self):
super(VGG16, self).__init__()
# 3 * 224 * 224
self.conv1_1 = nn.Conv2d(3, 64, 3) # 64 * 222 * 222
self.conv1_2 = nn.Conv2d(64, 64, 3, padding=(1, 1)) # 64 * 2
2021-10-26 11:53:20
61KB
c
OR
教程
1