class_docstr: This subclass of `argparse.ArgumentParser` uses type hints on dataclasses to generate arguments.
  
  The class is designed to play well with the native argparse. In particular, you can add more (non-dataclass backed)
  arguments to the parser after initialization and you'll get the output back after parsing as an additional
  namespace. Optional: To create sub argument groups use the `_argument_group_name` attribute in the dataclass.
docstr: Args:
      dataclass_types:
          Dataclass type, or list of dataclass types for which we will "fill" instances with the parsed args.
      kwargs (`Dict[str, Any]`, *optional*):
          Passed to `argparse.ArgumentParser()` in the regular way.
docstr_tok: ["Args",":","dataclass_types",":","Dataclass","type",",","or","list","of","dataclass","types","for","which","we","will","``","fill","''","instances","with","the","parsed","args",".","kwargs","(","`","Dict","[","str",",","Any","]","`",",","*","optional","*",")",":","Passed","to","`","argparse.ArgumentParser","(",")","`","in","the","regular","way","."]
code: def __init__(
      self,
      dataclass_types: Union[DataClassType, Iterable[DataClassType]],
      **kwargs,
  ):
      """
      Args:
          dataclass_types:
              Dataclass type, or list of dataclass types for which we will "fill" instances with the parsed args.
          kwargs (`Dict[str, Any]`, *optional*):
              Passed to `argparse.ArgumentParser()` in the regular way.
      """
      # To make the default appear when using --help
      if "formatter_class" not in kwargs:
          kwargs["formatter_class"] = ArgumentDefaultsHelpFormatter
      super().__init__(**kwargs)
      if dataclasses.is_dataclass(dataclass_types):
          dataclass_types = [dataclass_types]
      self.dataclass_types = list(dataclass_types)
      for dtype in self.dataclass_types:
          self._add_dataclass_arguments(dtype)
  
imports: import dataclasses
  import json
  import sys
  import types
  from argparse import ArgumentDefaultsHelpFormatter, ArgumentParser, ArgumentTypeError
  from copy import copy
  from enum import Enum
  from inspect import isclass
  from pathlib import Path
  from typing import Any, Callable, Dict, Iterable, List, Literal, NewType, Optional, Tuple, Union, get_type_hints
  import yaml
label_desc: Use image node_id 1 to create a new HfArgumentParser object from inherited base classes: ArgumentParser with example: obj = HfArgumentParser(dataclass_types)