PySAGAS Utilities

pysagas.utilities.add_sens_data(cells, data, verbosity=1, match_tolerance=1e-05, rounding_tolerance=1e-08, force=False)[source]

Appends shape sensitivity data to a list of Cell objects.

Parameters:
  • cells (List[Cell]) – A list of cell objects.

  • data (pd.DataFrame) – The sensitivity data to be transcribed onto the cells.

  • verbosity (int, optional) – The verbosity. The default is 1.

  • match_tolerance (float, optional) – The precision tolerance for matching point coordinates. The default is 1e-5.

  • rounding_tolerance (float, optional) – The tolerance to round data off to. The default is 1e-8.

  • force (bool, optional) – Force the sensitivity data to be added, even if a cell already has sensitivity data. This can be used if new data is being used, or if the append is being repeated with a different matching tolerance. The default is False.

Returns:

match_fraction – The fraction of points matched.

Return type:

float