EDSR
- class biapy.models.edsr.EDSR(ndim=2, num_filters=64, num_of_residual_blocks=16, upsampling_factor=2, num_channels=3)[source]
Bases:
Module
Enhanced Deep Residual Networks for Single Image Super-Resolution (EDSR) model.
Reference: Enhanced Deep Residual Networks for Single Image Super-Resolution.
Code adapted from https://keras.io/examples/vision/edsr
- forward(x)[source]
Defines the computation performed at every call.
Should be overridden by all subclasses.
Note
Although the recipe for forward pass needs to be defined within this function, one should call the
Module
instance afterwards instead of this since the former takes care of running the registered hooks while the latter silently ignores them.
- class biapy.models.edsr.SR_convblock(conv, num_filters)[source]
Bases:
Module
Super-resolution upsampling block.
- Parameters:
conv (Torch convolutional layer) – Convolutional layer to use.
num_filters (Int) – Number of filter to apply in the convolutional layer.
- forward(x)[source]
Defines the computation performed at every call.
Should be overridden by all subclasses.
Note
Although the recipe for forward pass needs to be defined within this function, one should call the
Module
instance afterwards instead of this since the former takes care of running the registered hooks while the latter silently ignores them.
- class biapy.models.edsr.SR_upsampling(conv, num_filters, factor=2)[source]
Bases:
Module
Super-resolution upsampling block.
- Parameters:
conv (Torch convolutional layer) – Convolutional layer to use.
num_filters (Int) – Number of filter to apply in the convolutional layer.
factor (int, optional) – Upscaling factor to be made to the input image.
- forward(x)[source]
Defines the computation performed at every call.
Should be overridden by all subclasses.
Note
Although the recipe for forward pass needs to be defined within this function, one should call the
Module
instance afterwards instead of this since the former takes care of running the registered hooks while the latter silently ignores them.