class_docstr: FORMAT: col: col1 | col2 | col 3 row 1 : val1 | val2 | val3 row 2 : ...
docstr: Given a table, TableLinearize aims at converting it into a flatten sequence with special symbols.
docstr_tok: ["Given","a","table",",","TableLinearize","aims","at","converting","it","into","a","flatten","sequence","with","special","symbols","."]
code: def process_table(self, table_content: Dict):
      """
      Given a table, TableLinearize aims at converting it into a flatten sequence with special symbols.
      """
      assert (
          "header" in table_content and "rows" in table_content
      ), self.PROMPT_MESSAGE
      # process header
      table_str = self.process_header(table_content["header"]) + " "
      # process rows
      for i, row_example in enumerate(table_content["rows"]):
          # NOTE: the row should start from row 1 instead of 0
          table_str += (
              self.process_row(row_example, row_index=i + 1) + " "
          )
      return table_str.strip()
  
imports: import json
  import os
  import random
  from functools import lru_cache
  from typing import Dict, List, Optional, Tuple, Union
  import regex
  from ....file_utils import ExplicitEnum, PaddingStrategy, TensorType, add_end_docstrings, is_pandas_available
  from ....tokenization_utils import AddedToken, PreTrainedTokenizer
  from ....tokenization_utils_base import ENCODE_KWARGS_DOCSTRING, BatchEncoding, TextInput, TruncationStrategy
  from ....utils import logging
label_desc: Use image node_id 1 for calling the IndexedRowTableLinearize obj's underlying member method code with example usage: obj.process_table(table_content) and returns: table_str