Mask disc¶
The Mask disc operation is used to apply a circular mask on the diffraction pattern before performing the Hough transform. This allows to remove the noise located around the diffraction pattern by selecting a region of interest containing high diffraction information.
Parameters¶
The mask is defined by the position (X and Y) of the circle’s center and the circle’s radius. The X position is along the width of the pattern and the Y position is along the height of the pattern.
If a value of -1 is specified for the X and Y position, the circular mask will be located at the center of the pattern. If the radius has a value of -1, the radius will be calculated as being the radius of the greatest circle that can be inscribed in the pattern image (width/2 or height/2, depending on the aspect ratio).
When a radius less than -1 is specified, the specified value is subtracted from the radius calculated for a value of -1. For example, a radius of -3 is equivalent to the radius for a value of -1 minus two pixels.