def __init__(self, in_ch, out_ch, base_ch=64):
    super(R2UNet, self).__init__()
    self.inc = DoubleConv(in_ch, base_ch)
    self.down = nn.MaxPool2d(kernel_size=2, stride=2)
    self.down1 = self._Down(base_ch, (base_ch * 2))
    self.down2 = self._Down((base_ch * 2), (base_ch * 4))
    self.down3 = self._Down((base_ch * 4), (base_ch * 8))
    self.down4 = self._Down((base_ch * 8), (base_ch * 16))
    self.up1 = self._Up((base_ch * 16), (base_ch * 8))
    self.up2 = self._Up((base_ch * 8), (base_ch * 4))
    self.up3 = self._Up((base_ch * 4), (base_ch * 2))
    self.up4 = self._Up((base_ch * 2), base_ch)
    self.outc = nn.Conv2d(base_ch, out_ch, kernel_size=1, stride=1, padding=0)
def __init__(self, in_ch, out_ch, base_ch=64):
    super(R2UNet, self).__init__()
    self.inc = DoubleConv(in_ch, base_ch)
    self.down = nn.MaxPool2d(kernel_size=2, stride=2)
    self.down1 = self._Down(base_ch, (base_ch * 2))
    self.down2 = self._Down((base_ch * 2), (base_ch * 4))
    self.down3 = self._Down((base_ch * 4), (base_ch * 8))
    self.down4 = self._Down((base_ch * 8), (base_ch * 16))
    self.up1 = self._Up((base_ch * 16), (base_ch * 8))
    self.up2 = self._Up((base_ch * 8), (base_ch * 4))
    self.up3 = self._Up((base_ch * 4), (base_ch * 2))
    self.up4 = self._Up((base_ch * 2), base_ch)
    self.outc = nn.Conv2d(base_ch, out_ch, kernel_size=1, stride=1, padding=0)