Microscopy Image Browser 2.91
MIB
Loading...
Searching...
No Matches
dicePixelCustomClassificationLayer Class Reference

This layer implements the generalized Dice loss function for training semantic segmentation networks. More...

Inheritance diagram for dicePixelCustomClassificationLayer:
Collaboration diagram for dicePixelCustomClassificationLayer:

Public Member Functions

 dicePixelCustomClassificationLayer (name, dataDimension, useClasses)
 layer = dicePixelClassificationLayer(name, dataDimension, useClasses) creates a Dice pixel classification layer with the specified name.
 
function loss = forwardLoss (Y, T)
 loss = forwardLoss(layer, Y, T) returns the Dice loss between the predictions Y and the training targets T.
 
 dicePixelCustomClassificationLayer (name, dataDimension)
 layer = dicePixelClassificationLayer(name) creates a Dice pixel classification layer with the specified name.
 
function loss = forwardLoss (Y, T)
 
function dLdY = backwardLoss (Y, T)
 dLdY = backwardLoss(layer, Y, T) returns the derivatives of the Dice loss with respect to the predictions Y.
 

Public Attributes

 dataDimension
 use mask as the last material of the model value defining dimension of the data: 2, 2.5, 3
 
 useClasses = "[]"
 indices of class ids to be used for calculation of loss
 

Static Public Attributes

static const  Epsilon = 1e-8
 Small constant to prevent division by zero.
 

Detailed Description

This layer implements the generalized Dice loss function for training semantic segmentation networks.

Constructor & Destructor Documentation

◆ dicePixelCustomClassificationLayer() [1/2]

dicePixelCustomClassificationLayer.dicePixelCustomClassificationLayer ( name,
dataDimension,
useClasses )

layer = dicePixelClassificationLayer(name, dataDimension, useClasses) creates a Dice pixel classification layer with the specified name.

Parameters
namename of the layer
useClassesvector with classes to use for calculation of the loss function, when empty all classes are taken into account
dimensionnumber specifying data dimension, 2-2D or 2.5D, 3-3D

References dataDimension, and useClasses.

◆ dicePixelCustomClassificationLayer() [2/2]

dicePixelCustomClassificationLayer.dicePixelCustomClassificationLayer ( name,
dataDimension )

layer = dicePixelClassificationLayer(name) creates a Dice pixel classification layer with the specified name.

Parameters
namename of the layer

References dataDimension.

Member Function Documentation

◆ backwardLoss()

function dLdY = dicePixelCustomClassificationLayer.backwardLoss ( Y,
T )

dLdY = backwardLoss(layer, Y, T) returns the derivatives of the Dice loss with respect to the predictions Y.

References backwardLoss(), and N.

Referenced by backwardLoss().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ forwardLoss() [1/2]

function loss = dicePixelCustomClassificationLayer.forwardLoss ( Y,
T )

loss = forwardLoss(layer, Y, T) returns the Dice loss between the predictions Y and the training targets T.

References N.

◆ forwardLoss() [2/2]

function loss = dicePixelCustomClassificationLayer.forwardLoss ( Y,
T )

References dataDimension, Epsilon, N, and useClasses.

Member Data Documentation

◆ dataDimension

dicePixelCustomClassificationLayer.dataDimension

use mask as the last material of the model value defining dimension of the data: 2, 2.5, 3

Referenced by dicePixelCustomClassificationLayer(), dicePixelCustomClassificationLayer(), and forwardLoss().

◆ Epsilon

static const dicePixelCustomClassificationLayer.Epsilon = 1e-8
static

Small constant to prevent division by zero.


Default: 1e-8

Referenced by forwardLoss().

◆ useClasses

dicePixelCustomClassificationLayer.useClasses = "[]"

indices of class ids to be used for calculation of loss


Default: "[]"

Referenced by dicePixelCustomClassificationLayer(), and forwardLoss().


The documentation for this class was generated from the following files: