code: def convert_func(cfg, model_path, out_path, image_size):
      model_module = get_model(
          cfg.network, dropout=0.0, num_features=cfg.embedding_size
      ).to("cuda")
      model_module.eval()
      print(model_module)
      model_graph = ModelGraph(model_module)
      model_graph._compile(
          flow.randn(1, 3, image_size, image_size).to("cuda")
      )
  
      with tempfile.TemporaryDirectory() as tmpdirname:
          new_parameters = dict()
          parameters = flow.load(model_path)
          for key, value in parameters.items():
              if "num_batches_tracked" not in key:
                  if key == "fc.weight":
                      continue
                  val = value
                  new_key = key.replace("backbone.", "")
                  new_parameters[new_key] = val
          model_module.load_state_dict(new_parameters)
          flow.save(model_module.state_dict(), tmpdirname)
          convert_to_onnx_and_check(
              model_graph,
              flow_weight_dir=tmpdirname,
              onnx_model_path="./",
              print_outlier=True,
          )
  
file_path: insightface/recognition/arcface_oneflow/oneflow2onnx.py
imports: import os
  from os import mkdir
  from oneflow_onnx.oneflow2onnx.util import convert_to_onnx_and_check
  import oneflow
  import logging
  from backbones import get_model
  from utils.utils_config import get_config
  import argparse
  import tempfile
label_desc: Use image node_id 1 for calling a global function with example usage: convert_func(cfg, model_path, out_path, image_size) without return types