mirror of
https://github.com/DifferentiableUniverseInitiative/JaxPM.git
synced 2025-04-11 21:50:55 +00:00
fix tests
This commit is contained in:
parent
f3b8f4160e
commit
f8325b1c67
1 changed files with 5 additions and 7 deletions
|
@ -37,12 +37,12 @@ def test_distrubted_pm(simulation_config, initial_conditions, cosmo, order,
|
||||||
particles,
|
particles,
|
||||||
a=0.1,
|
a=0.1,
|
||||||
order=order)
|
order=order)
|
||||||
ode_fn = ODETerm(make_diffrax_ode(cosmo, mesh_shape))
|
ode_fn = ODETerm(make_diffrax_ode(mesh_shape))
|
||||||
y0 = jnp.stack([particles + dx, p])
|
y0 = jnp.stack([particles + dx, p])
|
||||||
else:
|
else:
|
||||||
dx, p, _ = lpt(cosmo, initial_conditions, a=0.1, order=order)
|
dx, p, _ = lpt(cosmo, initial_conditions, a=0.1, order=order)
|
||||||
ode_fn = ODETerm(
|
ode_fn = ODETerm(make_diffrax_ode(mesh_shape,
|
||||||
make_diffrax_ode(cosmo, mesh_shape, paint_absolute_pos=False))
|
paint_absolute_pos=False))
|
||||||
y0 = jnp.stack([dx, p])
|
y0 = jnp.stack([dx, p])
|
||||||
|
|
||||||
solver = Dopri5()
|
solver = Dopri5()
|
||||||
|
@ -94,8 +94,7 @@ def test_distrubted_pm(simulation_config, initial_conditions, cosmo, order,
|
||||||
sharding=sharding)
|
sharding=sharding)
|
||||||
|
|
||||||
ode_fn = ODETerm(
|
ode_fn = ODETerm(
|
||||||
make_diffrax_ode(cosmo,
|
make_diffrax_ode(mesh_shape,
|
||||||
mesh_shape,
|
|
||||||
halo_size=halo_size,
|
halo_size=halo_size,
|
||||||
sharding=sharding))
|
sharding=sharding))
|
||||||
|
|
||||||
|
@ -108,8 +107,7 @@ def test_distrubted_pm(simulation_config, initial_conditions, cosmo, order,
|
||||||
halo_size=halo_size,
|
halo_size=halo_size,
|
||||||
sharding=sharding)
|
sharding=sharding)
|
||||||
ode_fn = ODETerm(
|
ode_fn = ODETerm(
|
||||||
make_diffrax_ode(cosmo,
|
make_diffrax_ode(mesh_shape,
|
||||||
mesh_shape,
|
|
||||||
paint_absolute_pos=False,
|
paint_absolute_pos=False,
|
||||||
halo_size=halo_size,
|
halo_size=halo_size,
|
||||||
sharding=sharding))
|
sharding=sharding))
|
||||||
|
|
Loading…
Add table
Reference in a new issue