Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
mariogeiger committed Nov 6, 2023
1 parent 22ed24d commit e366b3c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 1 addition & 1 deletion e3nn_jax/_src/irreps_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -146,4 +146,4 @@ def test_D(keys, ir):
w = e3nn.angles_to_log_coordinates(*angles)
Dw = ir.D_from_log_coordinates(w)

np.testing.assert_allclose(Da, Dw, atol=1e-6)
np.testing.assert_allclose(Da, Dw, atol=1e-10, rtol=0.0008)
4 changes: 1 addition & 3 deletions e3nn_jax/_src/spherical_harmonics/recursive.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@ def recursive_spherical_harmonics(
normalization: str,
algorithm: Tuple[str],
) -> sympy.Array:
context.update(dict(jnp=jnp, clebsch_gordan=e3nn.clebsch_gordan))

if l == 0:
if 0 not in context:
if normalization == "integral":
Expand All @@ -37,7 +35,7 @@ def recursive_spherical_harmonics(
elif normalization == "component":
context[1] = math.sqrt(3) * input
else:
context[1] = input
context[1] = 1 * input

return sympy.Array([1, 0, 0])

Expand Down

0 comments on commit e366b3c

Please sign in to comment.