Class SpatialWindowChannel<T extends Tensor<T>,VT extends SpatialPadding2D<T>>

All Implemented Interfaces:
Function<T>
Direct Known Subclasses:
SpatialAveragePooling_F32, SpatialAveragePooling_F64, SpatialMaxPooling_F32, SpatialMaxPooling_F64

public abstract class SpatialWindowChannel<T extends Tensor<T>,VT extends SpatialPadding2D<T>> extends BaseSpatialWindow<T,VT>
Implementation of BaseSpatialWindow which processes the spatial tensor is processed in BCHW (mini-batch, channel, height, width) order
  • Field Details

    • output

      protected T extends Tensor<T> output
  • Constructor Details

    • SpatialWindowChannel

      public SpatialWindowChannel(ConfigSpatial config, VT padding)
  • Method Details

    • forwardChannel

      protected void forwardChannel(T input, T output)
    • forwardAt_inner

      protected abstract void forwardAt_inner(T input, int batch, int channel, int inY, int inX, int outY, int outX)
      Applies the operations at the specified window and stores the results at the specified output coordinate.
      Parameters:
      input - Input spatial tensor
      batch - Index of input in mini-batch that is being processed
      channel - Channel
      inY - y-axis lower extent, in input coordinates
      inX - x-axis lower extent, in input coordinates
      outY - y-axis output coordinates
      outX - x-axis output coordinates
    • forwardAt_border

      protected abstract void forwardAt_border(VT padded, int batch, int channel, int padY, int padX, int outY, int outX)
      Applies the operations at the specified window and stores the results at the specified output coordinate. For virtual tensor
      Parameters:
      padded - Input spatial virtual tensor
      batch - Index of input in mini-batch that is being processed
      channel - Channel
      padY - y-axis lower extent, in padded coordinates
      padX - x-axis lower extent, in padded coordinates
      outY - y-axis output coordinates
      outX - x-axis output coordinates