code: def load_torch_params(paddle_model, torch_patams):
      paddle_params = paddle_model.state_dict()
  
      fc_names = ["classifier"]
      for key, torch_value in torch_patams.items():
          if "num_batches_tracked" in key:
              continue
          key = (
              key.replace("running_var", "_variance")
              .replace("running_mean", "_mean")
              .replace("module.", "")
          )
          torch_value = torch_value.detach().cpu().numpy()
          if key in paddle_params:
              flag = [i in key for i in fc_names]
              if any(flag) and "weight" in key:  # ignore bias
                  new_shape = [1, 0] + list(range(2, torch_value.ndim))
                  print(
                      f"name: {key}, ori shape: {torch_value.shape}, new shape: {torch_value.transpose(new_shape).shape}"
                  )
                  torch_value = torch_value.transpose(new_shape)
              paddle_params[key] = torch_value
          else:
              print(f"{key} not in paddle")
      paddle_model.set_state_dict(paddle_params)
  
imports: import math
  import paddle
  from paddle import nn
label_desc: Use image node_id 3 for calling a global function with example usage: load_torch_params(paddle_model, torch_patams) without return types