Skip to content

Marginalized Total Mass Model. #5147

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

kkacanja
Copy link
Contributor

This pull request introduces a new inference model that performs marginalization over total mass by rescaling a reference waveform across a specified total mass grid. This model is designed to apply brute-force marginalization on top of an existing base model using waveform rescaling, making it simple and modular to include in existing analyses.

… marginalizes overtop by rescaling one waveform to different total masses.
@kkacanja kkacanja requested a review from ahnitz June 27, 2025 18:16
@WuShichao
Copy link
Member

Does it work with different mass ratio q?

@kkacanja
Copy link
Contributor Author

Does it work with different mass ratio q?

Yea, you can set a prior on q. You need mass ratio in order to get mass1 and mass2 for the waveform generation

@WuShichao
Copy link
Member

WuShichao commented Jun 27, 2025

Does it work with different mass ratio q?

Yea, you can set a prior on q. You need mass ratio in order to get mass1 and mass2 for the waveform generation

So, for a (2,2)-mode BBH, in principle, you can only sample spin parameters + mass ratio, and marginalize over all other parameters?

@WuShichao WuShichao added inference 3g-detectors Code needed to aid with third generation detector analyses labels Jun 27, 2025
@kkacanja
Copy link
Contributor Author

kkacanja commented Jun 27, 2025

Does it work with different mass ratio q?

Yea, you can set a prior on q. You need mass ratio in order to get mass1 and mass2 for the waveform generation

So, for a (2,2)-mode BBH, in principle, you can only sample spin parameters + mass ratio, and marginalize over all other parameters?

Yup. One way I am using this is to marginalize over mtotal, tc, sky location, polarization and phase (so you specify the base model as marginalized time) and only sampling over eccentricity q and spins. This model may be beneficial for very slow waveform models

So you can do something like this in the config

[model]
name = marginalized_mtotal
base_model = marginalized_time
marginalize_mtotal = True
fiducial_mtotal = 8
mtotal_grid_num = 100
sample_rate = 2048
marginalize_vector_params = tc, ra, dec, polarization
marginalize_vector_samples = 5000
low-frequency-cutoff = H1:20 L1:22 V1:20
ignore-failed-waveforms =
marginalize_phase = True
marginalize_distance = True
marginalize_distance_param = distance
marginalize_distance_interpolator = True
marginalize_distance_snr_range = 1, 30
marginalize_distance_density = 200, 200
marginalize_distance_samples = 10000

So far this model only works with the marginalized time model since I have to specify custom waveforms. I have to see if there is another way around this other than modifying each base model to take in a custom waveform.

@ahnitz
Copy link
Member

ahnitz commented Jul 4, 2025

@kkacanja Before merging this, can you add an example and unittest for the model.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3g-detectors Code needed to aid with third generation detector analyses inference
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants