Mask is applied to 2D images to sort out unwanted pixels from further data processing. It is mainly used to mask out pixels affected by existence of beamtop.
Hot pixels and intermodulus ones are automatically masked out by pilatus giving them the value of -2. Usually we create manually a mask (at beginning of a run) to take away other 'invalid' pixels, mainly thouse shadowed or perturbed by the beamstop in the beam. However, it can be use for any kind of unwanted features (as a crazy pixel or mysterious cloud suddenly appering in a part of detector area) which can appear any time for various reason. How to proceed to create a new mask: