import torch nn = torch.nn class Unet(nn.Module): def __init__(self,cn=3): super(Unet,self).__init__() # copu = convolution + pooling self.copu1 = nn.Sequential( nn.Conv2d(cn,48,3,stride=1,padding=1), nn.ReLU(inplace=True), nn.Conv2d(48,48,3,padding=1), nn.ReLU(inplace=True), nn.MaxPool2d(2) ) for i in range(2,6): #copu2, copu3, copu4, copu5 self.add_module('copu%d'%i, nn.Sequential( nn.Conv2d(48,