code: def _strip_postfix(path):
      path, ext = os.path.splitext(path)
      assert ext in [
          "",
          ".pdparams",
          ".pdopt",
          ".pdmodel",
      ], "Unknown postfix {} from weights".format(ext)
      return path
  
file_path: PaddleDetection/ppdet/utils/checkpoint.py
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  from __future__ import unicode_literals
  import os
  import numpy
  import paddle
  import paddle.nn
  from .download import get_weights_path
  from .logger import setup_logger
label_desc: Use image node_id 2 for calling a global function with example usage: _strip_postfix(path) and returns: path