Keras 3 API 文件 / KerasCV / 損失 / SmoothL1Loss 損失

SmoothL1Loss 損失

[來源]

SmoothL1Loss 類別

keras_cv.losses.SmoothL1Loss(l1_cutoff=1.0, **kwargs)

實作 Smooth L1 損失。

SmoothL1Loss 實作 SmoothL1 函數,其中小於 l1_cutoff 的值根據其平方差對整體損失做出貢獻,而大於 l1_cutoff 的值則根據其原始差值做出貢獻。

參數

  • l1_cutoff:大於 l1_cutoff 的 y_true 和 y_pred 之差將被視為 L1