Class MultiBoxPrior.Builder

  • Enclosing class:
    MultiBoxPrior

    public static final class MultiBoxPrior.Builder
    extends java.lang.Object
    The Builder to construct a MultiBoxPrior object.
    • Method Detail

      • setSizes

        public MultiBoxPrior.Builder setSizes​(java.util.List<java.lang.Float> sizes)
        Sets the sizes of the anchor boxes to be generated around each pixel.
        Parameters:
        sizes - the size of the anchor boxes generated around each pixel
        Returns:
        this Builder
      • setRatios

        public MultiBoxPrior.Builder setRatios​(java.util.List<java.lang.Float> ratios)
        Sets the aspect ratios of the anchor boxes to be generated around each pixel.
        Parameters:
        ratios - the aspect ratios of the anchor boxes to be generated around each pixel
        Returns:
        this Builder
      • optSteps

        public MultiBoxPrior.Builder optSteps​(java.util.List<java.lang.Float> steps)
        Sets the step across \(x\) and \(y\) dimensions. Defaults to -1 across both dimensions.
        Parameters:
        steps - the step across \(x\) and \(y\) dimensions
        Returns:
        this Builder
      • optOffsets

        public MultiBoxPrior.Builder optOffsets​(java.util.List<java.lang.Float> offsets)
        Sets the value of the center-box offsets across \(x\) and \(y\) dimensions. Defaults to 0.5 across both dimensions.
        Parameters:
        offsets - the value of the center-box offsets across \(x\) and \(y\) dimensions
        Returns:
        this Builder
      • optClip

        public MultiBoxPrior.Builder optClip​(boolean clip)
        Sets the boolean parameter that indicates whether to clip out-of-boundary boxes. It is set to false by default.
        Parameters:
        clip - whether to clip out-of-boundary boxes
        Returns:
        this Builder