code: def get_indexes_from_datatable(
      data: list, list_index: Optional[list] = None
  ) -> Optional[list]:
      """Get the indexes of the data. If list_index is given and is the same length than
      the indexes, there is no subset selected.
  
      Parameters
      ----------
      data : list
          Data from the table
      list_index : Optional[list], optional
          Default index list to compare the subset with, by default None
  
      Returns
      -------
      Optional[list]
          Indexes of the data
      """
      indexes = [d["_index_"] for d in data]
      if list_index is not None and (
          len(indexes) == len(list_index) or len(indexes) == 0
      ):
          indexes = None
      return indexes
  
imports: from typing import Optional, Tuple
  import numpy
  import pandas
  import datetime
  from dash import dcc, html
  import dash_bootstrap_components
label_desc: Use image node_id 9 for calling a global function with example usage: get_indexes_from_datatable(data, list_index) and returns: indexes