code: def add_docstring(add_example=True):
      def wrapper(class_):
          example_docstring = _EXAMPLE_DOCSTRING
          if "ReversibleTransformation" in (
              cls.__name__ for cls in class_.mro()
          ):
              example_docstring = _REVERSIBLE_EXAMPLE_DOCSTRING
          new_doc = [f"{class_.__doc__}", f"{_ATTRIBUTES_DOCSTRING}"]
          if add_example:
              new_doc.append("Example:")
              new_doc.append(
                  f"\t{example_docstring.format(class_name=class_.__name__)}"
              )
  
          class_.__doc__ = "\n".join(new_doc)
          return class_
  
      return wrapper
  
imports: import collections
  import copy
  import functools
  import itertools
  import operator
  import warnings
  from abc import ABC, abstractmethod
  from typing import TYPE_CHECKING, List
  import torch
  from transformers.file_utils import add_end_docstrings
  from transformers.utils.fx import _gen_constructor_wrapper
label_desc: Use image node_id 1 for calling a global function with example usage: add_docstring(add_example) and returns: wrapper, class_