Bugfix and enhancement in heterodyned likelihood#222
Conversation
…erodynedTransientLikelihoodFD
…use TransientLikelihoodFD
…ss to remove self parameter
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
SSL32081
left a comment
There was a problem hiding this comment.
This PR removes the evaluate_original function from Heterodyne likelihood, and calls the evaluate function from super class instead.
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
|
@thomasckng I think this is addressed in #237, can you double check if there is anything remained in this PR that is not included? Otherwise we can close this PR |
|
@SSL32081 I have resolved the conflicts. Can you take a look at the recent commits and see if I missed anything? |
…ransientLikelihoodFD
There was a problem hiding this comment.
Pull Request Overview
This PR addresses bugfixes and enhancements in the heterodyned likelihood implementation. The changes focus on improving code correctness, performance optimization through vectorization, and code maintainability.
Key changes include:
- Fixed critical bugs in reference parameter handling and frequency variable usage
- Replaced inefficient loop-based coefficient computation with vectorized operations using JAX/NumPy broadcasting
- Improved code organization by moving frequency grid initialization to proper location
Comments suppressed due to low confidence (2)
src/jimgw/core/single_event/likelihood.py:492
- [nitpick] The variable name
polis not descriptive. Consider usingpolarizationorpol_keyto make the code more readable and self-documenting.
jnp.array([jnp.abs(h_sky[pol]) for pol in h_sky.keys()]), axis=0
src/jimgw/core/single_event/likelihood.py:745
- [nitpick] Using
_to discard the returnedrng_keyis appropriate, but consider adding a comment explaining what value is being discarded for clarity.
_, best_fit, log_prob = optimizer.optimize(
…terodynedTransientLikelihoodFD
|
@kazewong This PR has been updated. The major changes are a bugfix at line 558 and a significant enhancement in |
No description provided.