Advanced Parameters

The parameters Batch Size, Window Size and Masking Ratio are three advanced parameters to adjust the Noise2Void (N2V) based training. For general information on denoising and N2V, see Intellesis Denoising.

Parameter

Description

Model

Displays the name of the current model.

Number of Epochs

Defines the number of times that the model is trained with the images.

The "number of epochs" refers to the number of times the training dataset is passed through the neural network during the training process. Each pass through the dataset is called an epoch (an epoch consists of a fixed number of samples drawn from the dataset). In N2V, the number of epochs is a user-defined parameter that determines how many times the neural network will be trained on the full dataset. If the number of epochs is too short, the model may not be able to learn the underlying patterns in the data, resulting in underfitting. On the other hand, if the number of epochs is too long, the model may start to memorize the training data, resulting in overfitting, which makes it less effective at denoising new images.

Batch Size

Only visible if Show All is activated
Defines the batch size, a number of optimization steps that are executed simultaneously. Note that the higher you set the batch size, the higher is the memory usage.

The "batch size" refers to the number of samples (image patches) that are processed by the neural network at once. During each epoch, the training data set is typically divided into several smaller batches, and the neural network is updated based on the average loss across the batch. The batch size is another user-defined parameter that controls how many samples are processed in each batch. If the batch size is too small, the model may converge slowly and can result in poor generalization. If the batch size is too large, it may result in the model being unable to fit into memory, slowing down the training process, and potentially leading to poor generalization. The default batch size in ZEN is 64, but it is advisable to experiment with smaller sizes, such as 32 or 16, if memory errors occur.

Window Size

Only visible if Show All is activated
Defines the size of the window from which the pixels are taken.

Given a pixel to be masked, the "window size" parameter determines the size of the surrounding area to sample replacement pixel. Specifically, N2V divides the input image into overlapping patches of a fixed size (determined by the window size parameter) and trains a neural network to predict the central pixel of each patch based on the other pixels in the patch. During inference (denoising), N2V processes the input image in a sliding-window fashion, applying the trained neural network to each patch in turn to produce a denoised output image. If the window size is too small, it may not capture enough information to properly denoise the image. If the window size is too large, it may include too much information, leading to overfitting, increased computation time, and reduced performance. The default window size of 5 is optimal for most images.

Masking Ratio

Only visible if Show All is activated
Defines the ratio between pixels that are replaced and the overall number of pixels.

The "masking ratio" parameter determines the proportion of pixels within each patch that are randomly masked during N2V training. The best denoising performance is achieved by using sampling replacement pixels from the areas surrounding the masked pixels (not by replacing the masked pixel with zero) and N2V forces the neural network to learn a more robust representation of the underlying image structure, rather than simply memorizing the specific noise patterns in the input image. The masking ratio controls the level of noise injection during training, with higher values leading to more aggressive masking and generally better performance on noisy datasets. If the masking ratio is too small, the model may not be able to learn the noise distribution effectively, which can lead to poor denoising performance. In general, the optimal values for these parameters will depend on the specific characteristics of the input image and the amount and type of noise present in the data. It is often necessary to experiment with different values to determine the best combination for a given task.

Defaults

Resets all parameters to their default values.

Train and Denoise

Trains the model based on the current parameter settings.

Finish

Saves the model and all changes and closes the training interface.

Cancel

Closes the training interface without saving.