Class Yolo2OutputLayer.Builder

    • Constructor Detail

      • Builder

        public Builder()
    • Method Detail

      • lambdaCoord

        public Yolo2OutputLayer.Builder lambdaCoord​(double lambdaCoord)
        Loss function coefficient for position and size/scale components of the loss function. Default (as per paper): 5
        Parameters:
        lambdaCoord - Lambda value for size/scale component of loss function
      • lambdaNoObj

        public Yolo2OutputLayer.Builder lambdaNoObj​(double lambdaNoObj)
        Loss function coefficient for the "no object confidence" components of the loss function. Default (as per paper): 0.5
        Parameters:
        lambdaNoObj - Lambda value for no-object (confidence) component of the loss function
      • lossPositionScale

        public Yolo2OutputLayer.Builder lossPositionScale​(ILossFunction lossPositionScale)
        Loss function for position/scale component of the loss function
        Parameters:
        lossPositionScale - Loss function for position/scale
      • lossClassPredictions

        public Yolo2OutputLayer.Builder lossClassPredictions​(ILossFunction lossClassPredictions)
        Loss function for the class predictions - defaults to L2 loss (i.e., sum of squared errors, as per the paper), however Loss MCXENT could also be used (which is more common for classification).
        Parameters:
        lossClassPredictions - Loss function for the class prediction error component of the YOLO loss function
      • boundingBoxPriors

        public Yolo2OutputLayer.Builder boundingBoxPriors​(INDArray boundingBoxes)
        Bounding box priors dimensions [width, height]. For N bounding boxes, input has shape [rows, columns] = [N, 2] Note that dimensions should be specified as fraction of grid size. For example, a network with 13x13 output, a value of 1.0 would correspond to one grid cell; a value of 13 would correspond to the entire image.
        Parameters:
        boundingBoxes - Bounding box prior dimensions (width, height)