Skip to content
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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Drop nuts init method from pm.sample #3863

Merged
merged 3 commits into from
Mar 31, 2020

Conversation

AlexAndorra
Copy link
Contributor

As discussed in #3861, the nuts init method is a left-over in pm.sample init methods and should just be dropped. This PR does it.
Thanks in advance for the review, and tell me if any edit is needed 馃枛

@codecov
Copy link

codecov bot commented Mar 31, 2020

Codecov Report

Merging #3863 into master will decrease coverage by 0.03%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #3863      +/-   ##
==========================================
- Coverage   90.73%   90.69%   -0.04%     
==========================================
  Files         135      135              
  Lines       21190    21185       -5     
==========================================
- Hits        19227    19214      -13     
- Misses       1963     1971       +8
Impacted Files Coverage 螖
pymc3/sampling.py 84.52% <酶> (-0.1%) 猬囷笍
pymc3/tests/test_sampling.py 99.64% <100%> (酶) 猬嗭笍
pymc3/tuning/scaling.py 57.4% <0%> (-12.97%) 猬囷笍
pymc3/backends/base.py 87.25% <0%> (-0.39%) 猬囷笍

@@ -1865,14 +1864,12 @@ def init_nuts(
* advi: Run ADVI to estimate posterior mean and diagonal mass matrix.
* advi_map: Initialize ADVI with MAP and use MAP as starting point.
* map: Use the MAP as starting point. This is discouraged.
* nuts: Run NUTS and estimate posterior mean and mass matrix from
the trace.
* adapt_full: Adapt a dense mass matrix using the sample covariances
chains: int
Number of jobs to start.
n_init: int
Copy link
Member

Choose a reason for hiding this comment

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

I think n_init is only used for advi now, right? COuld make that clear in the doc string.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

@twiecki
Copy link
Member

twiecki commented Mar 31, 2020

Thanks! Also release-notes :).

@twiecki twiecki merged commit bf8552e into pymc-devs:master Mar 31, 2020
@twiecki
Copy link
Member

twiecki commented Mar 31, 2020

Thanks!

twiecki pushed a commit that referenced this pull request Apr 1, 2020
* Added wrapper for gamma sampling in negative binomial distribution.

* Fixed typo in posterior sampling warnings.

* Drop nuts init method from pm.sample (#3863)

* Dropped nuts init method

* Dropped nuts init method from tests

* Refined doc string and added release note

* Added wrapper for gamma sampling in negative binomial distribution.

* Fixed typo in posterior sampling warnings.

* Added test for negative binomial input shape.

* Updating release notes with changes to negative binomial sampling.

Co-authored-by: Alexandre ANDORRA <andorra.alexandre@gmail.com>
@AlexAndorra AlexAndorra deleted the drop-init-nuts branch May 13, 2020 17:18
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.

None yet

2 participants