def __init__(self, dim: int = 1, eps: float = 1e-8) -> None:
        """Initializes the NegativeCosineSimilarity module the specified parameters.

        Same parameters as in torch.nn.CosineSimilarity

        Args:
            dim:
                Dimension where cosine similarity is computed.
            eps:
                Small value to avoid division by zero.
        """
        super().__init__()
        self.dim = dim
        self.eps = eps
Initializes the NegativeCosineSimilarity module the specified parameters.

        Same parameters as in torch.nn.CosineSimilarity

        Args:
            dim:
                Dimension where cosine similarity is computed.
            eps:
                Small value to avoid division by zero.
        
lightly/loss/negative_cosine_similarity.py