pygsti.report.besttxtcolor

pygsti.report.besttxtcolor(x, cmap, norm)

Determinining function for whether text should be white or black

Parameters:
  • x (float) – Value of the cell in question
  • cmap (matplotlib colormap) – Colormap assigning colors to the cells
  • norm (matplotlib normalizer) – Function to map cell values to the interval [0, 1] for use by a colormap
Returns:

Return type:

{“white”,”black”}