Class UtilDenseOpticalFlow


public class UtilDenseOpticalFlow extends Object
Useful functions when computing dense optical flow
  • Constructor Details

    • UtilDenseOpticalFlow

      public UtilDenseOpticalFlow()
  • Method Details

    • standardPyramid

      public static <T extends ImageGray<T>> PyramidFloat<T> standardPyramid(int width, int height, double scale, double sigma, int minSize, int maxLayers, Class<T> imageType)

      Create a standard image pyramid used by dense optical flow parameters. The first layer is the size of the input image and the last layer is ≥ the minSize. The sigma for each layer is computed using the following formula:

      sigmaLayer = sigma*sqrt( scale^-2 - 1 )

      If the scale is 1 then a single layer pyramid will be created. If the scale is 0 then the scale will be determined by the maxLayers parameter.

      Type Parameters:
      T - Image type
      width - Width of input image.
      height - Height of input image.
      scale - Scale between layers. 0 ≤ scale ≤ 1. Try 0.7
      sigma - Adjusts the amount of blur applied to each layer. If sigma ≤ 0 then no blur is applied.
      minSize - The minimum desired image size in the pyramid
      maxLayers - The maximum number of layers in the pyramid.
      imageType - Type of image for each layer
      The image pyramid.