Skip to content

Halo lc hod#28

Merged
lgarrison merged 13 commits intomasterfrom
halo-lc-hod
Jan 26, 2022
Merged

Halo lc hod#28
lgarrison merged 13 commits intomasterfrom
halo-lc-hod

Conversation

@boryanah
Copy link
Collaborator

Code that allows the user to generate light cone catalogs using Abacus HOD

Copy link
Member

@lgarrison lgarrison left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great, thanks! Just a few minor comments.

Also, can you add an entry to CHANGES.rst? You can make a section called New Features and add something like - HOD module now works with halo light cone catalogs [#28].

Could you also try adding a test to tests/test_hod.py? Just something that runs the LC HOD code and compares it to a saved result. There is a small halo LC output in the repo here that you can use as the input. It might be so small it breaks your code, but it does work with the CompaSOHaloCatalog reader, so it's worth trying.

Comment on lines +125 to +127
box0 = np.array([0., 0., 0.])-origin
box1 = np.array([0., 0., Lbox])-origin
box2 = np.array([0., Lbox, 0.])-origin
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this specifically for the base simulation light cone geometry? Will it work with the huge box geometry?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see you have a comment about the huge box geometry below! But just to check: if we run sims with another LC geometry in the future, will this work with that? Even if it's too hard to generalize the code, could we add an error if the LightConeOrigins don't match what's expected for this code?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes sure! I'll add that -- I will also add indentation for box1 and box2. It should work for any origin but not any geometry (unless we have exactly one box or the current L-shape geometry) since this assumes either observer in the center or observer of an L-shaped geometry

@lgarrison
Copy link
Member

Looks great, thanks @boryanah!

One small thing I noticed while looking at the tests is that the ELG.dat and LRG.dat files don't flag that they came from halo light cones. In fact, they don't contain any simulation or cosmology information, just the HOD parameter information (Acen, Asat, etc). I've kind of lost track of what file format we're using to distribute AbacusSummit mocks, but we might want to check that we are echoing the simulation/cosmology information to those files. Maybe we're already doing that though, just not in the tests; @SandyYuan, do you know?

@lgarrison
Copy link
Member

Going to merge this and open an issue to remind us to look into the metadata question.

@lgarrison lgarrison merged commit 8f6a5f1 into master Jan 26, 2022
@boryanah
Copy link
Collaborator Author

Great, thanks! I agree we should add metadata to the mocks! We should also mark centrals and satellites in the dat files, so a user can choose the sample they want to use, which as far as I remember we are not doing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants