View source on GitHub |
Computes the matting loss function based on the matting Laplacian.
tfg.image.matting.loss(
matte: type_alias.TensorLike,
laplacian: type_alias.TensorLike,
name: str = 'matting_loss'
) -> tf.Tensor
Computes the matting loss function based on the laplacian
generated by the
build_matrices
function which implements the approach proposed by Levin
et al. in "A Closed Form Solution to Natural Image Matting".
Returns | |
---|---|
A tensor containing a scalar value defining the matting loss. |