class_docstr: Document Classification with Huggingface backbones. Inherit from HFAutoModelForTextPrediction.
docstr: Update the model input data based on the model argument.
  For example, microsoft/layoutlm-base-uncased has a "bbox" argument;
  microsoft/layoutlmv3-base has arguments: "bbox" and "image".
  Text only bert does not have these two arguments.
  
  Parameters
  ----------
  input_data
      A dictionary containing the model input data.
  batch:
      A dictionary containing the input mini-batch data.
      We need to use the keys with the model prefix to index required data.
  keys:
      A dictionary containing the model arguments and corresponding batch keys.
docstr_tok: ["Update","the","model","input","data","based","on","the","model","argument",".","For","example",",","microsoft\/layoutlm-base-uncased","has","a","``","bbox","''","argument",";","microsoft\/layoutlmv3-base","has","arguments",":","``","bbox","''","and","``","image","''",".","Text","only","bert","does","not","have","these","two","arguments",".","Parameters","--","--","--","--","--","input_data","A","dictionary","containing","the","model","input","data",".","batch",":","A","dictionary","containing","the","input","mini-batch","data",".","We","need","to","use","the","keys","with","the","model","prefix","to","index","required","data",".","keys",":","A","dictionary","containing","the","model","arguments","and","corresponding","batch","keys","."]
code: def update_input_data(
      self,
      input_data: dict,
      batch: dict,
      keys: dict,
  ):
      """
      Update the model input data based on the model argument.
      For example, microsoft/layoutlm-base-uncased has a "bbox" argument;
      microsoft/layoutlmv3-base has arguments: "bbox" and "image".
      Text only bert does not have these two arguments.
  
      Parameters
      ----------
      input_data
          A dictionary containing the model input data.
      batch:
          A dictionary containing the input mini-batch data.
          We need to use the keys with the model prefix to index required data.
      keys:
          A dictionary containing the model arguments and corresponding batch keys.
      """
      model_args = list(
          inspect.signature(self.model.forward).parameters.keys()
      )
      for key, value in keys.items():
          if key in model_args:
              input_data.update({key: batch[value]})
  
file_path: autogluon/multimodal/src/autogluon/multimodal/models/document_transformer.py
imports: import inspect
  import logging
  from typing import Callable, Dict, List, Optional, Tuple, Union, cast
  from transformers import logging
  from ..constants import ATTENTION_MASK, AUTOMM, BBOX, COLUMN, COLUMN_FEATURES, FEATURES, IMAGE, INPUT_IDS, LABEL, LOGITS, MASKS, PIXEL_VALUES, TEXT_SEGMENT_IDS, TEXT_TOKEN_IDS, TEXT_VALID_LENGTH, TOKEN_TYPE_IDS
  from .huggingface_text import HFAutoModelForTextPrediction
  from .utils import get_column_features
label_desc: Use image node_id 6 for calling the DocumentTransformer obj's underlying member method code with example usage: obj.update_input_data(input_data, batch, keys) without return types