Closed andreufont closed 7 years ago
This is the code I use:
from randspectra import RandSpectra sim_dir = "../Sims/L10_N128_z9_MPI12/output/" snap_num = 4
rr = RandSpectra(snap_num, sim_dir, thresh=0., numlos=10) rr.get_tau("H",1,1215)
This is warning you that you ran MP-Gadget in a mode that fake_spectra does not (yet) support. fake_spectra only support cubic spline kernels, as used in the old-school vanilla Gadget SPH. The quintic and quartic splines have different smoothing length definitions and so need to be interpolated differently, which I have not yet implemented.
You can get a snapshot that fake_spectra will read by setting DensityKernelType=cubic in MP-Gadget's parameter file. You should probably also turn off DENSITY_INDEPENDENT_SPH
Thanks for the clarification.
I recompiled the code without that FLAG, changed the parameter file to use cubic interpolation, and rerun the simulation. It works!
I believe this might explain why I was having low values of the mean flux (I started an issue in MP-Gadget about it). Will confirm soon.
We could close this issue.
Low mean flux would indeed be the result of doing this! Each particle would be smeared over a wide area.
I generated a box using MP-Gadget, and when I read the BigFile outputs using fake_spectra I get the following error:
assert kernel == 1 AssertionError
This error is thrown at the end of get_kernel function in abstractsnapshot.py
When I run the code, kernel has a value of 2, so the code crashes. If I fix it to 1 by hand, it runs fine...