code: def weight_init(m: Module) -> None:
      if isinstance(m, (nn.Conv2d,)):
          # torch.nn.init.xavier_uniform_(m.weight, gain=1.0)
          torch.nn.init.xavier_normal_(m.weight, gain=1.0)
          # torch.nn.init.normal_(m.weight, mean=0.0, std=0.01)
          if m.weight.data.shape[1] == torch.Size([1]):
              torch.nn.init.normal_(m.weight, mean=0.0)
  
          if m.bias is not None:
              torch.nn.init.zeros_(m.bias)
  
      # for fusion layer
      if isinstance(m, (nn.ConvTranspose2d,)):
          # torch.nn.init.xavier_uniform_(m.weight, gain=1.0)
          torch.nn.init.xavier_normal_(m.weight, gain=1.0)
          # torch.nn.init.normal_(m.weight, mean=0.0, std=0.01)
  
          if m.weight.data.shape[1] == torch.Size([1]):
              torch.nn.init.normal_(m.weight, std=0.1)
          if m.bias is not None:
              torch.nn.init.zeros_(m.bias)
  
imports: from __future__ import annotations
  from collections import OrderedDict
  from typing import Optional
  import torch
  import torch.nn.functional
  from torch import nn
  from kornia.core import Module, Tensor, concatenate
  from kornia.core.check import KORNIA_CHECK
  from kornia.utils import map_location_to_cpu
label_desc: Use image node_id 1 for calling a global function with example usage: weight_init(m) without return types