Implemented ZCV for cross-spectrum#188
Conversation
| matter_pos += Lbox / 2.0 # I think necessary for cross correlations | ||
| matter_pos %= Lbox |
There was a problem hiding this comment.
Is this shift matching something that the tracers are doing? Usually I try to wrap just the negative positions rather than shift all particles (since that changes the origin), but maybe the tracers are already being shifted somewhere?
There was a problem hiding this comment.
This shift was matching something the tracers were doing, yes.
|
Cool, thanks! I'll let @boryanah review the science parts of the code, but could you make sure the tests are exercising the new code? Here is where we test the existing ZCV: Line 152 in 7d1775d It's not actually testing the correctness of the outputs, which is something we should fix at some point. But if you could at least add another ZCV call that generates the cross-spectrum, that would be great. It looks like the existing ZCV test is failing, too; could you take a look at that? |
I am creating a pull request at Boryana's recommendation because I have code that successfully implements ZCV for the tracer-matter cross-power spectrum. Doing so requires reading in the particle positions and adding them to the mock dictionary (example in abacus_ZCV_cross.ipynb). I have added flags to the functions that do this so as not to break existing code. If there are questions or concerns with the code as written, please reach out to me.