radshap.plot.plot_pet

radshap.plot.plot_pet(shapley_values, image_path, masks_paths, save_path=None, alpha=0.7, max_suv=10, threshold_suv=None, cmap_name='seismic', cmap_lim=None, plot_colorbar=True, title=None)[source]

Display the Shapley values of different instances on the Maxumum Intensity Projection (MIP) of a PET image. The different values are represented with a color scale.

Parameters:
shapley_values1D array shape (n_shapley_values,)

Shapley values.

image_path: string.

Path of the PET image. The PET image format should be compatible with simpleitk. Nifti images (.nii.gz) are recommended

masks_paths: list of strings.

List of paths for the masks of the regions of interest associated with the Shapley values. Nifti images (.nii.gz) are recommended

save_path: string or None, optional.

Path to save the plot. If None the plotis not saved. The default is None.

alpha: float in [0, 1], optional.

Parameter to regulate the transparancy of the colored masks. The default is 0.7

max_suv: float, optional

Upper limit for the binary color mapping of the SUV intensities. The default is 10.

threshold_suv: float, optional

Lower SUV threshold to resegment the masks before displaying the Shapley values. If None, no resegmentation is performed. The default is None.

cmap_name: string, optional

The default is ‘seismic’.

cmap_lim: float or None, optional

The default is None.

plot_colorbar: bool, optional

The default is True.

title: string or None, optional

Title of the plot. If None no title will be displayed. The default is None.

Returns:
None.