code: def build(seg_num=8, target_size=224):
      image_shape = [1, seg_num, 3, target_size, target_size]
  
      image = static.data(
          name="image", shape=image_shape, dtype="float32"
      )
  
      model = TSM()
      return model(image)
  
file_path: DALI/docs/examples/use_cases/paddle/tsm/infer.py
imports: import argparse
  import json
  import os
  import paddle
  import paddle.static
  from nvidia.dali.pipeline import Pipeline
  import nvidia.dali.types
  import nvidia.dali.fn
  from nvidia.dali.plugin.paddle import DALIGenericIterator
  from tsm import TSM
  from utils import load_weights
label_desc: Use image node_id 2 for calling a global function with example usage: build(seg_num, target_size) and returns: model