cherab.phix.tools.visualize.show_phix_profiles#

cherab.phix.tools.visualize.show_phix_profiles(profiles, fig=None, clabel='', cmap='inferno', rtc=None, vmax=None, vmin=None, axes_pad=0.02, cbar_mode='single', scientific_notation=True, plot_mode='scalar')Source#

Show in-phix-limiter 2D profiles such as emission profile.

This function can show several 2D profiles with matplotlib imshow style.

Parameters:
  • profiles (list[NDArray] | NDArray) – 2D-array-like (nr, nz) profile inner PHiX limiter if you want to show several profiles, you must put one list containing 2D array-like data.

  • fig (Figure | None) – Figure object, by default plt.figure()

  • clabel (str) – colobar label

  • cmap (str) – color map, by default "inferno"

  • rtc (RayTransferCylinder | None) – cherab’s raytransfer objects, by default the instance loaded by import_phix_rtc.

  • vmax (float | None) – to set the upper color limitation, by default maximum value of all profiles, if cbar_mode=="single"

  • vmin (float | None) – to set the lower color limitation, by default minimal value of all profiles, if cbar_mode=="single"

  • axes_pad (float) – ImageGrid’s parameter to set the interval between axes, by default 0.02

  • cbar_mode (str) – ImgeGrid’s parameter to set colorbars in "single" axes or "each" axes, by default "single"

  • scientific_notation (bool) – whether or not to set colorbar format with scientific notation, by default True

  • plot_mode (str) – change the way of normalize the data scale. Must select one in {"scalar", "log", "centered"}, by default "scalar"

Returns:

tuple containing matplotlib figure object and instance of ImageGrid.

Return type:

tuple[Figure, ImageGrid]