Compare commits

..

No commits in common. "7623e60581f274a6ae71bbc3701bb51c0398d921" and "f391a7921182fe963cef77ab524e6d7a3afe44eb" have entirely different histories.

4 changed files with 2 additions and 5 deletions

View file

@ -35,8 +35,6 @@ jobs:
pip install pytest
pip install diffrax
pip install .
echo "numpy version installed:"
python -c "import numpy; print(numpy.__version__)"
- name: Run Single Device Tests
run: |

View file

@ -166,7 +166,7 @@ def uniform_particles(mesh_shape, sharding=None):
axis=-1)
def normal_field(seed, shape, sharding=None, dtype=float):
def normal_field(seed , shape, sharding=None, dtype='float32'):
"""Generate a Gaussian random field with the given power spectrum."""
gpu_mesh = sharding.mesh if sharding is not None else None
if gpu_mesh is not None and not (gpu_mesh.empty):

View file

@ -131,7 +131,7 @@ def linear_field(mesh_shape, box_size, pk, seed, sharding=None):
Generate initial conditions.
"""
# Initialize a random field with one slice on each gpu
field = normal_field(seed=seed, shape=mesh_shape, sharding=sharding)
field = normal_field(seed=seed , shape=mesh_shape, sharding=sharding)
field = fft3d(field)
kvec = fftk(field)
kmesh = sum((kk / box_size[i] * mesh_shape[i])**2

View file

@ -1,4 +1,3 @@
pfft-python @ git+https://github.com/MP-Gadget/pfft-python
pmesh @ git+https://github.com/MP-Gadget/pmesh
fastpm @ git+https://github.com/ASKabalan/fastpm-python
numpy==2.2.6