Plotting
Plotting Module.
plot_autocorrelation(image, crop_center=True, fig_size=(8, 5.5), save_path=None)
Plot training and validation losses.
Parameters:
-
image(NDArray) –Input image.
-
crop_center(bool, default:True) –Whether to crop the autocorrelation image around the center pixel or not.
-
fig_size(tuple[float, float], default:(8, 5.5)) –Size of the figure to be plotted. Default is (8, 5.5).
-
save_path(Path | str | None, default:None) –Path to save the figure. If None, the figure will not be saved. Default is None.
plot_loss(training_report, fig_size=(8, 5.5), save_path=None, plot_metrics=True, plot_learning_rate=True)
Plot training and validation losses.
Parameters:
-
training_report(TrainingReport) –Dataclass containing train and validation loss, learning rate, and any discovered validation metrics.
-
fig_size(tuple[float, float], default:None) –Size of the figure to be plotted. If
None, then default settings are applied depending onplot_metricsandplot_learning_rate. -
save_path(Path | str | None, default:None) –Path to save the figure. If None, the figure will not be saved.
-
plot_metrics(bool, default:True) –Whether to plot the metrics.
-
plot_learning_rate(bool, default:True) –Whether to plot the learning rate.
plot_noise_model_distribution(noise_model, signal_bin_index, histogram, channel=None, number_of_bins=100, save_path=None)
Plot probability distribution P(x|s) for a certain ground truth signal.
Predictions from both Histogram and GMM-based Noise models are displayed for comparison.
Parameters:
-
noise_model(GaussianMixtureNoiseModel) –Trained GaussianMixtureNoiseModel.
-
signal_bin_index(int) –Index of signal bin. Values go from 0 to number of bins (
n_bin). -
histogram(NDArray) –Histogram based noise model.
-
channel(Optional[str], default:None) –Channel name used for plotting. Default is None.
-
number_of_bins(int, default:100) –Number of bins in the resulting histogram. Default is 100.
-
save_path(Path | str | None, default:None) –Path to save the figure. If None, the figure will not be saved. Default is None.