code: def extract_rows_data(table, flavor):
      rows_data = [
          extract_row_data(row, table.cells, flavor, rowIndex)
          for rowIndex, row in enumerate(table.cells, 0)
      ]
  
      # if the table starts with an empty cell, camelot will ignore
      # so this is to ensure it is available on the output
      if rows_data[0]:
          if rows_data[0][0]["location"]["x"] > table.cells[0][0].x1:
              rows_data = add_first_cell(rows_data, table.cells[0][0])
  
      no_empty_rows_data = list(filter(lambda x: len(x) > 0, rows_data))
      if len(no_empty_rows_data) == 0:
          return None
  
      return no_empty_rows_data
  
file_path: doc-parsr/server/assets/TableDetectionScript.py
imports: import camelot
  import json
label_desc: Use image node_id 11 for calling a global function with example usage: extract_rows_data(table, flavor) and returns: no_empty_rows_data, None