Comments (7)
Hi @pabloazurduy,
- Comments like "the "migration guide" it's a joke." are not productive, and infact offensive to the authors of that content. Do you agree?
- A lot has changed in PyMC3 since this book was written, so yes, things are out-of-date. This is a common problem in software. Part of a developers job is determining the best path forward, given this problem.
- Chapters may need to be rewritten completely, or removed altogether.
I appreciate your efforts in porting content to use PyMC4 (it's a great learning exercise I'm sure). There's lots of freedom in how to port it, too, and I'm open to suggestions and PRs on how it's done.
from probabilistic-programming-and-bayesian-methods-for-hackers.
Yeah, the modeling API is mostly intact but otherwise things definitely changed, and this great book definitely teachers more than just the modeling API. A more comprehensive migration guide is definitely required. For now, you can read https://github.com/pymc-devs/pymc/blob/main/RELEASE-NOTES.md#pymc-400 to get some pointers.
from probabilistic-programming-and-bayesian-methods-for-hackers.
@CamDavidsonPilon Thanks!
is it correct that there's not yet a beta release for pymc v4?
Correct, but we'll release the beta today or tomorrow.
from probabilistic-programming-and-bayesian-methods-for-hackers.
4.0! Congrats!
I'd like to invite any motivated volunteers watching to help port examples over (ideally entire chapters at a time). @twiecki is it correct that there's not yet a beta release for pymc v4?
from probabilistic-programming-and-bayesian-methods-for-hackers.
Beta is out if someone wants to take this on!
from probabilistic-programming-and-bayesian-methods-for-hackers.
Hi!
(I bought the book a few months ago) I'm struggling with translating the code from Chapter 2 to the PYMC4 standard. Almost all Chapter2 is useless, the "migration guide" it's a joke. In the PYMC docs claiming that "Yes, you can just keep your existing PyMC modeling code without having to change anything (in most cases) and get all the improvements for free" seems like or either this book is too outdated vs the last version of PYMC3 (even the online version "ported to PYMC3") or the statement is false. Some of the issues that I found:
print("parameter.value =", parameter.value)
.value
does not exist anymore
the models are no longer declared as in the example:
import pymc as pm
parameter = pm.Exponential("poisson_param", 1)
data_generator = pm.Poisson("data_generator", parameter)
data_plus_one = data_generator + 1
tau.random()
.random()
method does not exist anymore
etc etc, TBH I'm trying to re-write the code on this chapter, but it seems not only that the API has changed completely like I think is better to re-write the chapter using this "new library" or the missing methods are available somewhere but the documentation it's just not giving any hint. Am I missing something? is this chapter that outdated?
Thanks !
from probabilistic-programming-and-bayesian-methods-for-hackers.
hey @CamDavidsonPilon,
Thanks for the fast replay! 😊
- The API changed a LOT from what I can tell, maybe it has major changes between versions of PYMC3 (that will explain that "migration guide"). I was not aware of that, but that will make sense. Didn't want to sound disrespectful, just being sarcastic there.
- that's probably the reason behind (1), although I think the "changes" on the interface of the library have been massive, a sample of that is that almost all snippets on this book don't work anymore, and because I have the printer version on my hands I can tell that is not infrequent with PYMC. As you mention that's common in software, however, I must argue that this level of changes (3 completely different interfaces in 2 versions seems kind of an exception rather than a rule). Anyway, this is under PYMC dev guidelines, not sure if there's anything that we can do about it (except /rant about it). my frustration comes from the lack of guides on these changes or documentation in the library itself, probably one of the reasons behind writing a book about it, I can't even know if some methods are completely gone or replaced by other methods.
3+end. I will be more than happy to help, I was trying too! and then I realized that either, you know how to use PYMC3 and then learn how to port it to PYMC4, or you know PYMC4 and write a chapter about it, I think I don't belong to either of those groups 😂😂 (That's why I bought the book on the first place). I found the migration guide, but not very helpful, maybe there is a PYMC3 v1.0 to migration guide somewhere ?. Anyway, thanks for the context, and sorry to sound rude (not my intention ! )
from probabilistic-programming-and-bayesian-methods-for-hackers.
Related Issues (20)
- definition of a continuous distribution in chap 1
- Bug in Ch6_priors_pymc3.ipynb
- Chapter 2 link to GreenhillWardSacks paper is broken. HOT 1
- Bug in Chapter 1 Pyro Version: Exponential Distribution Input HOT 2
- Chapter2 -- error in plot_artificial_sms_dataset() function
- Chpt #6; Example stock returns: ystockquote is not working
- Chapter 2 -- tfp.bijectors.AffineScalar is deprecated
- Chapter 2: description regarding the separation plot for Fig. 2.3.2
- Chapter 3 minor question
- Crack
- Chapter 6: Bayesian Multi-armed Bandits Code
- Chapter 1 TF2: from __future__ imports must occur at the beginning of the file
- TypeError (cycler) when trying to update matplotlib 3.5.2 with the custom styles HOT 2
- Ch3.type error at Example: Unsupervised Clustering using a Mixture Model HOT 2
- `pandas_datareader` error in chapter 6 HOT 1
- Chapter 1: Bug in plotting prior & posterior probabilities due to giving lw a string as an input HOT 1
- Recommend Turing.jl for tech stack
- chapter 1 - running on mac metal m2 with tfp - run into error InvalidArgumentError: 730 nodes in a cycle HOT 1
- Chapter 2: model.initial_values AttributeError: 'Model' object has no attribute 'initial_values' HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from probabilistic-programming-and-bayesian-methods-for-hackers.