Skip to content

Comments

Adding Dark and Luminous Substructure to the Main Deflector#2

Open
lobrien6 wants to merge 8 commits intosmericks:mainfrom
lobrien6:substructure
Open

Adding Dark and Luminous Substructure to the Main Deflector#2
lobrien6 wants to merge 8 commits intosmericks:mainfrom
lobrien6:substructure

Conversation

@lobrien6
Copy link

This pull request is being created to monitor the changes to paltas that are needed to add dark and luminous substructure to the main deflectors in double and quad lens systems. Changes include added definitions in existing files and the creation of new scripts to handle new functions.
Note: the main config_handler.py file used to initiate the config files has been replaced with config_handler_catalog.py. This new config handler is able to pull multiple lens parameters from a csv file. The old config_handler.py file is kept for archival purposes only and has since been deprecated for the purposes of generating large test sets with added substructure.

@smericks smericks self-requested a review May 16, 2025 22:07
Copy link
Collaborator

@drphilmarshall drphilmarshall left a comment

Choose a reason for hiding this comment

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

Just a brief note on documentation

Copy link
Owner

@smericks smericks left a comment

Choose a reason for hiding this comment

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

This PR has functions for adding mass and light for a single perturber. It also includes functionality for generating images from a static catalog, I think originally implemented by @padma18-vb? I've added some comments requesting changes, and don't forget @drphilmarshall 's comment about adding docstrings.



@staticmethod
def mag_to_amplitude(mag_apparent,mag_zeropoint,kwargs_list):
Copy link
Owner

Choose a reason for hiding this comment

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

You're duplicating functions already written in the Sersic class object. It would be better to inherit from the Sersic object, and you can use super().mag_to_amplitude() to use this function if you need it, for example.


return light_model_list,light_model_kwargs,light_z_list

class SersicPerturber(SourceBase):
Copy link
Owner

Choose a reason for hiding this comment

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

My understanding of this class object is that it simultaneously returns the light of two objects: the main deflector and the perturber. So we wouldn't use this for painting light on subhalos, this is for the single perturber case, correct? (Just verifying my understanding).

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.

3 participants