class_docstr: Sample or Padding frame skeleton feature.
  Args:
      window_size (int): Temporal size of skeleton feature.
      random_pad (bool): Whether do random padding when frame length < window size. Default: False.
class_docstr_tok: ["Sample","or","Padding","frame","skeleton","feature",".","Args",":","window_size","(","int",")",":","Temporal","size","of","skeleton","feature",".","random_pad","(","bool",")",":","Whether","do","random","padding","when","frame","length","<","window","size",".","Default",":","False","."]
code: def __call__(self, results):
      data = results
  
      C, T, V, M = data.shape
      T = self.get_frame_num(data)
      if T == self.window_size:
          data_pad = data[:, : self.window_size, :, :]
      elif T < self.window_size:
          begin = (
              random.randint(0, self.window_size - T)
              if self.random_pad
              else 0
          )
          data_pad = np.zeros((C, self.window_size, V, M))
          data_pad[:, begin : begin + T, :, :] = data[:, :T, :, :]
      else:
          if self.random_pad:
              index = np.random.choice(
                  T, self.window_size, replace=False
              ).astype("int64")
          else:
              index = np.linspace(0, T, self.window_size).astype(
                  "int64"
              )
          data_pad = data[:, index, :, :]
  
      return data_pad
  
imports: import os
  import yaml
  import glob
  import cv2
  import numpy
  import math
  import paddle
  import sys
  from paddle.inference import Config, create_predictor
  from python.utils import argsparser, Timer, get_current_memory_mb
  from python.benchmark_utils import PaddleInferBenchmark
  from python.infer import Detector, print_arguments
  from attr_infer import AttrDetector
label_desc: Use image node_id 3 for calling the AutoPadding obj's underlying member method code with example usage: obj.__call__(results) and returns: data_pad