code: def icnr(x, scale=2, init=nn.init.kaiming_normal_):
      "ICNR init of `x`, with `scale` and `init` function."
      ni,nf,h,w = x.shape
      ni2 = int(ni/(scale**2))
      k = init(torch.zeros([ni2,nf,h,w])).transpose(0, 1)
      k = k.contiguous().view(ni2, nf, -1)
      k = k.repeat(1, 1, scale**2)
      k = k.contiguous().view([nf,ni,h,w]).transpose(0, 1)
      x.data.copy_(kf icnr(x, scale=2, init=nn.init.kaiming_normal_):
      "ICNR init of `x`, with `scale` and `init` function."
      ni,nf,h,w = x.shape
      ni2 = int(ni/(scale**2))
      k = init(torch.zeros([ni2,nf,h,w])).transpose(0, 1)
      k = k.contiguous().view(ni2, nf, -1)
      k = k.repeat(1, 1, scale**2)
      k = k.contiguous().view([nf,ni,h,w]).transpose(0, 1)
      x.data.copy_(k)
docs: ICNR init of `x`, with `scale` and `init` function.