-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Bring back logps #6272
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
Bring back logps #6272
Conversation
fd9a6f5
to
aefb017
Compare
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## main #6272 +/- ##
==========================================
+ Coverage 90.39% 94.25% +3.86%
==========================================
Files 111 111
Lines 23869 23930 +61
==========================================
+ Hits 21577 22556 +979
+ Misses 2292 1374 -918
|
2c83bcc
to
db4f688
Compare
I am curious to see how you are going to do attribution here since you're breaking Git history. In AePPL history this seems to come from this commit by Brandon, who is not a PyMC member. |
Good question. In this specific case I don't see any issues. There was a previous PR that removed all the logp methods involved in this PR towards Aeppl, and no questions of attribution or git history were raised then: #4887 For future PRs, do you have any suggestion? A non-inconsequent portion of the Aeppl code was originally developed in PyMC and moved to Aeppl for unclear reasons. |
pymc/distributions/continuous.py
Outdated
@@ -1898,19 +1714,6 @@ def moment(rv, size, nu, mu, sigma): | |||
return mu | |||
|
|||
def logp(value, nu, mu, sigma): | |||
""" |
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.
Because they were wrong since V4 began, and it's not supposed to be a user-facing method anyway
@ricardoV94 git is being a bit flaky for me, i understand why the comments are removed! you had mentioned it at in the PR body which I missed my apologies! |
Interesting that you've unnecessarily decided on an approach to all this that removes the original Git history of the material you're taking, especially since you've already forked AePPL itself. Was that intended or do you have some sort of excuse for doing things this way?
Wow, that's a bold and curiously aggressive and unbacked claim with some very overtly negative implications about me and everyone else who worked on that material across both AePPL and PyMC. Please, demonstrate to us exactly where attribution in AePPL was appropriate and missing. Don't forget to check who originally wrote the code that was moved! |
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.
My 2 cents readd the docstrings from dropped in d34b557b5e0a0806842e2d4ec5aa5a842dbf8dfe
for two reasons
-
Even though theyre stale they contain some useful information such as on here. https://github.com/pymc-devs/pymc/pull/6272/files#diff-9ac5fc2380425e161c832a41b1a173cac7693410b99e9c746d39507d96a8d357L1024-L1042
-
To update them its a great issue for beginners, and its simpler for beginners to start with an existing docstring and modify than start one from scratch
Per slack convo
- Keeping them is bad because they're stale
- When new logps get added they wont have docstrings so things will be inconsistent
- We could autogenerate them
One question about autogeneration in this example here for instance, how would an autogenerated docstring tell us what the parameters good
and bad
mean? If I was a developer working on this in the future where would I get this information of what these mean?
@brandonwillard @rlouf in all sincerity I appreciate you bringing up these concerns. I think there's low probability that any sort of understanding will be reached on this PR. Given that is another mode of discussion possible? Happy with whatever your suggestion is. |
@brandonwillard @rlouf How about we add you as co-authors on the commits? |
@twiecki I appreciate the offer, but for one I wouldn't want to be credited for a piece of code I didn't write. I looked around and found this answer very helpful: https://opensource.stackexchange.com/questions/11631/how-to-properly-attribute-others-people-work-on-github |
@rlouf Thanks, that's helpful. Yeah, let's find out the best way of including that in the copyright and license information. There are already some similar references there, e.g. https://github.com/aesara-devs/aesara/blob/main/doc/LICENSE.txt#L11 @brandonwillard Let me know if you want to be co-authored on the commits in addition to the above, or what you think the appropriate way of attributioning is. |
Building upon other people's work instead of copy/pasting avoids all this hassle. The full git history is kept and attribution is simple. The file you're pointing to is an excellent example: https://github.com/aesara-devs/aesara/commits/main/doc/LICENSE.txt |
db4f688
to
9dd4ef6
Compare
6a2dc2d
to
4a476d9
Compare
Copyright (c) 2009-2017 The PyMC developers (see contributors to pymc-devs on GitHub) | ||
Copyright (c) 2009-2022 The PyMC developers (see contributors to pymc-devs on GitHub) | ||
|
||
Contains code from Aeppl, Copyright (c) 2021-2022, Aesara Developers |
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.
@rlouf @brandonwillard Are you happy with this?
@@ -6,7 +6,10 @@ PyMC is distributed under the Apache License, Version 2.0 | |||
|
|||
Copyright (c) 2006 Christopher J. Fonnesbeck (Academic Free License) | |||
Copyright (c) 2007-2008 Christopher J. Fonnesbeck, Anand Prabhakar Patil, David Huard (Academic Free License) | |||
Copyright (c) 2009-2017 The PyMC developers (see contributors to pymc-devs on GitHub) | |||
Copyright (c) 2009-2022 The PyMC developers (see contributors to pymc-devs on GitHub) |
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.
while we are editing this, this copyright sentence should not have end date
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.
How should it be?
- Copyright (c) 2009 The PyMC developers (see contributors to pymc-devs on GitHub)
- Copyright (c) 2009- The PyMC developers (see contributors to pymc-devs on GitHub)
- Copyright (c) 2009-present The PyMC developers (see contributors to pymc-devs on GitHub)
Or something else?
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.
I like the 2009-present
version most
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.
@ricardoV94 @OriolAbril, let's fix the dates later, because then "while we're at it" we can update it in all places
for all intents and purposes of this PR it's ready to merge now that the attribution part has been taken care of
@@ -6,7 +6,10 @@ PyMC is distributed under the Apache License, Version 2.0 | |||
|
|||
Copyright (c) 2006 Christopher J. Fonnesbeck (Academic Free License) | |||
Copyright (c) 2007-2008 Christopher J. Fonnesbeck, Anand Prabhakar Patil, David Huard (Academic Free License) | |||
Copyright (c) 2009-2017 The PyMC developers (see contributors to pymc-devs on GitHub) | |||
Copyright (c) 2009-2022 The PyMC developers (see contributors to pymc-devs on GitHub) |
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.
@ricardoV94 @OriolAbril, let's fix the dates later, because then "while we're at it" we can update it in all places
for all intents and purposes of this PR it's ready to merge now that the attribution part has been taken care of
Also add parameter check to uniform logcdf
4a476d9
to
b95d30c
Compare
This PR brings back univariate continuous logp methods that had been moved to Aeppl
I also removed all old logp/logcdf docstrings. They were both wrong and too cumbersome to update.Will do in a separate PRCloses #5329
Major / Breaking Changes
Bugfixes / New features
Docs / Maintenance
logp
andlogcdf
docstrings