Skip to content

Conversation

@ricardoV94
Copy link
Member

@ricardoV94 ricardoV94 commented Nov 8, 2025

(* non even powers)

This way we get icdf easily for InverseGamma and LogitNormal. I removed the latter in favor of a CustomDist. I didn't do it for InverseGamma because that's a pretty popular distribution and don't want to risk messing with precision

closes #7619
closes #7917
closes #7916

ricardoV94 and others added 3 commits November 8, 2025 12:39
Co-authored-by: Ricardo Vieira <28983449+ricardov94@users.noreply.github.com>
Co-authored-by: lucaseckes
@codecov
Copy link

codecov bot commented Nov 8, 2025

Codecov Report

❌ Patch coverage is 72.22222% with 5 lines in your changes missing coverage. Please review.
✅ Project coverage is 86.85%. Comparing base (3a0186e) to head (dfa599c).
⚠️ Report is 9 commits behind head on main.

Files with missing lines Patch % Lines
pymc/distributions/continuous.py 64.28% 5 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #7956      +/-   ##
==========================================
- Coverage   91.47%   86.85%   -4.63%     
==========================================
  Files         116      116              
  Lines       18947    18931      -16     
==========================================
- Hits        17332    16442     -890     
- Misses       1615     2489     +874     
Files with missing lines Coverage Δ
pymc/distributions/moments/means.py 0.00% <ø> (-100.00%) ⬇️
pymc/logprob/transforms.py 95.43% <100.00%> (+0.02%) ⬆️
pymc/distributions/continuous.py 67.66% <64.28%> (-30.59%) ⬇️

... and 10 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@jessegrabowski
Copy link
Member

Tests are failing because you can't pass rng to the new signatures

Copy link
Member

@larryshamalama larryshamalama left a comment

Choose a reason for hiding this comment

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

Hi @ricardoV94 , great work as always :) I haven't followed much of recent codebase progress, as per @jessegrabowski 's comment other changes seem necessary w.r.t. test failures. I just added minor questions that came to mind as per usual as I read this PR

msg="alpha > 0, beta > 0",
)

def icdf(value, alpha, beta):
Copy link
Member

Choose a reason for hiding this comment

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

I don't visualize the math on top of my head. I presume this is what test_inverse_gamma_icdf below checks?

lambda value, alpha, beta: st.invgamma.logcdf(value, alpha, scale=beta),
)

def test_inverse_gamma_icdf(self):
Copy link
Member

Choose a reason for hiding this comment

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

Some distributions have all functionality tests (logp, logcdf, icdf) under a single method (test_half_cauchy), whereas other distributions have one method per functionality. Is there any particular reason for this?

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants