Crappifier#

Crappifier Abstract Base Class for custom Crappifier implementations.

from pssr.crappifiers import Crappifier
class pssr.crappifiers.Crappifier#

Crappifier base class for custom crappifiers. Override the crappify() method for logic.

pssr.crappifiers.Crappifier.crappify(self, image: ndarray)#

An abstract function for degrading a low resolution image to simulate undersampling.

This method is not responsible for downscaling the image, only for injecting noise.

Parameters:

image (np.ndarray) – Low resolution image to crappify.

Returns:

The low resolution image, only now has it been crappified.

Return type:

crap (np.ndarray)