class_docstr: This class is the parent class of all model weights. Each model building method receives an optional `weights`
  parameter with its associated pre-trained weights. It inherits from `Enum` and its values should be of type
  `Weights`.
  
  Args:
      value (Weights): The data class entry with the weight information.
code: def verify(cls, obj: Any) -> Any:
      if obj is not None:
          if type(obj) is str:
              obj = cls[obj.replace(cls.__name__ + ".", "")]
          elif not isinstance(obj, cls):
              raise TypeError(
                  f"Invalid Weight class provided; expected {cls.__name__} but received {obj.__class__.__name__}."
              )
      return obj
  
imports: import fnmatch
  import importlib
  import inspect
  import sys
  from dataclasses import dataclass
  from enum import Enum
  from functools import partial
  from inspect import signature
  from types import ModuleType
  from typing import Any, Callable, Dict, Iterable, List, Mapping, Optional, Set, Type, TypeVar, Union
  from torch import nn
  from .._internally_replaced_utils import load_state_dict_from_url
label_desc: Use image node_id 1 for calling the WeightsEnum obj's underlying member method code with example usage: obj.verify(cls, obj) and returns: obj