scenic icon indicating copy to clipboard operation
scenic copied to clipboard

Bug in NCR loss.py

Open zch42 opened this issue 2 years ago • 0 comments

Incorrect Syntax in l2_normalize Function

https://github.com/google-research/scenic/blob/46959b8f2de75f6c1abd2fd7606c60aaf98bcd60/scenic/projects/ncr/loss.py#L70C20-L70C20

return tensor / jnp.linalg.norm(tensor, axis=axis, keepdims=True + epsilon) should be return tensor / (jnp.linalg.norm(tensor, axis=axis, keepdims=True) + epsilon)

zch42 avatar Oct 05 '23 05:10 zch42