class_docstr: This class is used to register function or :class:`functools.partial` class to a registry.
class_docstr_tok: ["This","class","is","used","to","register","function","or",":","class",":","`","functools.partial","`","class","to","a","registry","."]
docstr: This function is used to register new functions to the registry along their metadata.
  
  Functions can be filtered using metadata using the ``get`` function.
docstr_tok: ["This","function","is","used","to","register","new","functions","to","the","registry","along","their","metadata",".","Functions","can","be","filtered","using","metadata","using","the","``","get","``","function","."]
code: def __call__(
      self,
      fn: Optional[Callable[..., Any]] = None,
      name: Optional[str] = None,
      override: bool = False,
      providers: Optional[Union[Provider, List[Provider]]] = None,
      **metadata,
  ) -> Callable:
      """This function is used to register new functions to the registry along their metadata.
  
      Functions can be filtered using metadata using the ``get`` function.
  
      """
      if providers is not None:
          metadata["providers"] = providers
  
      if fn is not None:
          self._register_function(
              fn=fn, name=name, override=override, metadata=metadata
          )
          return fn
  
      # raise the error ahead of time
      if not (name is None or isinstance(name, str)):
          raise TypeError(f"`name` must be a str, found {name}")
  
      def _register(cls):
          self._register_function(
              fn=cls, name=name, override=override, metadata=metadata
          )
          return cls
  
      return _register
  
imports: import functools
  import inspect
  import itertools
  from typing import Any, Callable, Dict, List, Optional, Union
  from pytorch_lightning.utilities import rank_zero_info
  from flash.core.utilities.providers import Provider
label_desc: Use image node_id 10 for calling the FlashRegistry obj's underlying member method code with example usage: obj.__call__(fn, name, override, providers) and returns: _register, fn, cls