class_docstr: Deprecated, will be removed in v0.3.0. See GenericFactory instead
class_docstr_tok: ["Deprecated",",","will","be","removed","in","v0.3.0",".","See","GenericFactory","instead"]
docstr: Create an object, instance of ``cls.__base__``, on first call.
docstr_tok: ["Create","an","object",",","instance","of","``","cls.__base__","``",",","on","first","call","."]
code: def __call__(cls, of_type, *args, **kwargs):
      """Create an object, instance of ``cls.__base__``, on first call."""
      _import_modules(cls)
      _set_typenames(cls)
  
      for name, inherited_class in cls.types.items():
          if name == of_type.lower():
              return inherited_class(*args, **kwargs)
  
      raise NotImplementedError(
          f"Could not find implementation of {cls.__base__.__name__}, type = '{of_type}'\n"
          "Currently, there is an implementation for types:\n"
          f"{sorted(cls.types.keys())}"
      )
  
imports: from __future__ import annotations
  import hashlib
  import logging
  import os
  import signal
  import sys
  from abc import ABCMeta
  from collections import defaultdict
  from contextlib import contextmanager
  from glob import glob
  from importlib import import_module
  from tempfile import NamedTemporaryFile
  from typing import Generic, TypeVar
label_desc: Use image node_id 2 for calling the Factory obj's underlying member method code with example usage: obj.__call__(cls, of_type) and returns: inherited_class