-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Add start_sigma
to ADVI
#6096
Merged
Merged
Add start_sigma
to ADVI
#6096
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
junpenglao
reviewed
Sep 6, 2022
junpenglao
approved these changes
Sep 6, 2022
junpenglao
reviewed
Sep 6, 2022
junpenglao
reviewed
Sep 6, 2022
Codecov Report
@@ Coverage Diff @@
## main #6096 +/- ##
==========================================
+ Coverage 87.29% 90.39% +3.10%
==========================================
Files 72 86 +14
Lines 12927 17873 +4946
==========================================
+ Hits 11284 16157 +4873
- Misses 1643 1716 +73
|
ricardoV94
added a commit
to ricardoV94/pymc
that referenced
this pull request
Sep 15, 2022
This reverts commit ec27b5c.
ricardoV94
added
the
no releasenotes
Skipped in automatic release notes generation
label
Sep 15, 2022
junpenglao
pushed a commit
that referenced
this pull request
Sep 15, 2022
This reverts commit ec27b5c.
Hi @markusschmaus sorry we need to revert this because there is a test failing - could you send in the PR again? |
5 tasks
@junpenglao Here is the new PR: |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Introduces the
start_sigma
argument which allows to set a starting value for the sigmas of mean field approximation inADVI
. I am using theordering
property to create the mapping between the variables and the flat 1d array required byADVI
.See also:
https://discourse.pymc.io/t/quality-of-life-improvements-to-advi/10254
Checklist
Major / Breaking Changes
Bugfixes / New features
start_sigma
being given tofit
.ASVGD
forward the key word argumentsstart
andrandom_seed
to the constructor of the default approximationFullRank
instead of sending them tosuper().__init__
which can't process them_iterate_with_loss
to run withn=0
by giving an appropriate logger message. This allows to check initialization values, which is useful for testing, but could also be useful for debugging a user modelDocs / Maintenance
start
argument was outdated, it claimed typePoint
, but it gets passed through to a function that requiresStartDict
. Since users are probably unfamiliar with this custom type (Dict[Union[Variable, str], Union[np.ndarray, Variable, str]]
), I decided to also mention the most relevant and most commonly used subtypedict[str, np.ndarray]
.