code: def check_valid_pt2_backend(backend: str) -> bool:
      backend_values = [member.value for member in PT2Backend]
      if backend in backend_values:
          return True
      else:
          logger.warning(f"{backend} is not a supported backend")
      return False
  
imports: import enum
  import inspect
  import itertools
  import json
  import logging
  import os
  import re
  from functools import wraps
  from warnings import warn
  import yaml
label_desc: Use image node_id 2 for calling a global function with example usage: check_valid_pt2_backend(backend) and returns: False, True