o
    €o™i°  ã                   @  s.   d dl mZ d dlmZ d dlZdd
d„ZdS )é    )Úannotations)ÚOptionalNÚtargetútorch.TensorÚignore_indexúOptional[int]Úreturnú+tuple[torch.Tensor, Optional[torch.Tensor]]c                 C  sB   |d u r| d fS | |k}|  ¡ r| d fS |  ||  d¡¡} | |fS )Né   )ÚallÚwhereÚ	new_zeros)r   r   Útarget_mask© r   úH/home/ubuntu/.local/lib/python3.10/site-packages/kornia/losses/_utils.pyÚmask_ignore_pixels   s   r   )r   r   r   r   r   r	   )Ú
__future__r   Útypingr   Útorchr   r   r   r   r   Ú<module>   s   