code: def get_supported_models(type: ModelType):
      """
  
      :param type: (ModelType):
          classification or segmentation
      :return: list (strings) of supported models
      """
  
      import pkgutil
  
      if type == ModelType.SEGMENTATION:
          excludes = []  # <-- exclude non-model names
          for importer, modname, ispkg in pkgutil.walk_packages(
              path=segmentation.__path__,
              prefix=segmentation.__name__ + ".",
              onerror=lambda x: None,
          ):
              excludes.append(modname.split(".")[-1])
          return [
              x
              for x in segmentation.__dict__.keys()
              if ("__" not in x and x not in excludes)
          ]  # filter out hidden object attributes and module names
      elif type == ModelType.CLASSIFICATION:
          pywick_excludes = []
          for importer, modname, ispkg in pkgutil.walk_packages(
              path=classification.__path__,
              prefix=classification.__name__ + ".",
              onerror=lambda x: None,
          ):
              pywick_excludes.append(modname.split(".")[-1])
          pywick_names = [
              x
              for x in classification.__dict__.keys()
              if "__" not in x and x not in pywick_excludes
          ]  # includes directory and filenames
  
          pt_excludes = []
          for importer, modname, ispkg in pkgutil.walk_packages(
              path=torch_models.__path__,
              prefix=torch_models.__name__ + ".",
              onerror=lambda x: None,
          ):
              pt_excludes.append(modname.split(".")[-1])
          pt_names = [
              x
              for x in torch_models.__dict__
              if "__" not in x and x not in pt_excludes
          ]  # includes directory and filenames
  
          torch_hub_names = torch.hub.list(
              rwightman_repo, force_reload=True
          )
  
          return pywick_names + pt_names + torch_hub_names
      else:
          return None
  
imports: from functools import partial
  from typing import Callable
  from torchvision.models.resnet import Bottleneck
  from .None import classification
  from .segmentation import *
  from .None import segmentation
  from enum import Enum
  from torchvision import models
  from torchvision.models.inception import InceptionAux
  import torch
  import torch.nn
  import os
  import errno
label_desc: Use image node_id 3 for calling a global function with example usage: get_supported_models(type) and returns: unknown, unknown, None