-
Notifications
You must be signed in to change notification settings - Fork 219
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
Remove usage of DynamicPPL.tonamedtuple
#2071
Conversation
introduced immutable invlink, and make use of getparams in transition constructions
… Bijectors.invlink
Btw, @sethaxen do you have any thoughts about what we should return for the See https://github.com/TuringLang/DynamicPPL.jl/blob/ba16e3bc91e293c58b03ad287637472d6e11f52f/src/utils.jl#L1020-L1043 for where this is decided. |
different transition types
How does the user encounter this return value? If it's just for storage in a But if currently what is being returned is
Here's where my assumptions about flattening don't seem to follow. If the goal is flattening, then an iterator is returned, and I'm not sure how it would be relevant if the |
Just in how it will be represented in the chain. Currently we just flatten
In the sense of, we return the flattened EDIT:
Btw, what do you mean when you say "strict triangle" here? You mean excluding the diagonal? |
I like this suggestion, if we indeed go down that route:) |
Ah okay, then yes, this is also my preference. The only thing I don't like about it is that
Yes, because, the diagonal entries are constrained to be 1s. |
Yeah, unfortunately it's a bit "annoying" to show the strict triangle with the current implementation since it requires knowledge of the distribution (the current flattening-approach just takes into account the value itself, not the distribution, etc.), hence why I didn't do that. I think for now, we do |
Codecov ReportPatch and project coverage have no change.
Additional details and impacted files@@ Coverage Diff @@
## master #2071 +/- ##
======================================
Coverage 0.00% 0.00%
======================================
Files 22 21 -1
Lines 1492 1447 -45
======================================
+ Misses 1492 1447 -45
☔ View full report in Codecov by Sentry. |
This finally looks ready to be reviewed @yebai ! This is technically a non-breaking release given how we don't export this functionality, but I'm in favour of making it breaking as there are bound to be some downstream issues with this. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @torfjelde , it looks good to me!
* Update Utilities.jl * remove obsolete functionality. * remove obsolete utility module * removes more references to utilities.
Co-authored-by: Hong Ge <[email protected]>
* Update Turing.jl * Update Project.toml * Update Turing.jl * Update Essential.jl
Now that we have
DynamicPPL.varname_and_value_leaves
we no longer need to make use oftonamedtuple
.EDIT: I should also point out that with this PR we can also properly put non-array types, e.g.
Cholesky
, into chains:and it's easy to add support for further types by overloading
DynamicPPL.varname_and_value_leaves_inner
👍