Losses (empanada.losses)#

Confidence weighting of loss that’s efficient.

class empanada.losses.BCLoss(*args: Any, **kwargs: Any)[source]#

Defines the overall loss for a boundary contour prediction model.

Parameters
  • pr_weight – Float, weight to apply to the point rend semantic segmentation loss. Only applies if using a Point Rend enabled model.

  • top_k_percent – Float, fraction of largest semantic segmentation loss values to consider in BootstrapCE.

class empanada.losses.PanopticLoss(*args: Any, **kwargs: Any)[source]#

Defines the overall panoptic loss function which combines semantic segmentation, instance centers and offsets.

Parameters
  • ce_weight – Float, weight to apply to the semantic segmentation loss.

  • mse_weight – Float, weight to apply to the centers heatmap loss.

  • l1_weight – Float, weight to apply to the center offsets loss.

  • pr_weight – Float, weight to apply to the point rend semantic segmentation loss. Only applies if using a Point Rend enabled model.

  • top_k_percent – Float, fraction of largest semantic segmentation loss values to consider in BootstrapCE.