Skip to content

Standardize and Update Notebook Gallery #34

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Closed
12 of 24 tasks
AlexAndorra opened this issue Jun 12, 2020 · 12 comments
Closed
12 of 24 tasks

Standardize and Update Notebook Gallery #34

AlexAndorra opened this issue Jun 12, 2020 · 12 comments

Comments

@AlexAndorra
Copy link
Collaborator

[BEGINNER-FRIENDLY]
Our notebooks gallery is quite big, so:

  • Many of them use an old style and could use an updating with ArviZ color style instead (not listed).
  • Many notebooks show FutureWarnings that should be addressed (not listed).
  • Some notebooks fail to run because they use outdated third-party APIs or exotic packages (listed below).

So this issue is here to signal it would be nice if people want to take some time updating and re-running the notebooks below with PyMC 3.9, according to this style page 🎉
Do it in small batches though, to not get bored and enjoy it 😉 Thanks a lot in advance for your help and don't hesitate to ask your questions below!
PyMCheers 🖖

Here is an up-to-date list of the most outdated and problematic NBs (those not listed here should be checked for style and updating accordingly):

Exotic

  • blackbox_external_likelihood needs Cython
  • convolutional_vae_keras_advi needs Keras

Other Issues

  • GLM theano.gof.fg.MissingInputError
  • GLM-poisson-regression KeyError: "['hpd_2.5', 'hpd_97.5'] not in index"
  • GLM-negative-binomial-regression KeyError: "['hpd_97.5', 'hpd_2.5'] not in index"
  • GLM-model-selection KeyError: 'var names: "['sd_log__'] are not present" in dataset'
  • GP-MaunaLoa2 ValueError: Units 'M' and 'Y' are no longer supported
  • GP-MaunaLoa ValueError: Units 'M' and 'Y' are no longer supported, as they do not represent unambiguous timedelta values durations.
  • GP-TProcess runs but has way too many divergences; timed out after 14_000 seconds
  • PyMC3_tips_and_heuristic KeyError: Rhat
  • dependent_density_regression AttributeError: 'DataFrame' object has no attribute 'range'
  • hierarchical_partial_pooling not enough values to unpack (expected 2, got 1)
  • lda-advi-aevb TypeError: init() got an unexpected keyword argument 'n_topics'
  • marginalized_gaussian_mixture_model AttributeError: 'Rectangle' object has no property 'normed'
  • GLM-logistic AttributeError: 'Rectangle' object has no property 'normed'
  • model_averaging FileNotFoundError: File ../data/milk.csv does not exist
  • model_comparison AttributeError: 'ELPDData' object has no attribute 'WAIC'
  • multilevel_modeling More chains (4000) than draws (2) and some plots may be wrong
  • profiling has a shape error
  • rugby_analytics ValueError: not enough values to unpack (expected 2, got 1)
  • sampling_callback has a shape error (looks like a threading problem)
  • survival_analysis cell 11 raises a NotImplementedError in numpy/pandas
  • weibull_aft AttributeError: module 'statsmodels' has no attribute 'datasets'
  • ODE_with_manual_gradients ValueError: array must not contain infs or NaNs
@Sayam753
Copy link
Member

Hi @AlexAndorra
I am willing to update the notebooks dealing with Variational Inference and restyling according to the guide. I have one question though - do we need to re-run the notebooks on the current state of the PyMC3 codebase or running them on the latest released version (3.8)?

@AlexAndorra
Copy link
Collaborator Author

AlexAndorra commented Jun 12, 2020 via email

@AlexAndorra AlexAndorra changed the title Standardize and Updated Notebook Gallery Standardize and Update Notebook Gallery Jun 13, 2020
@OriolAbril
Copy link
Member

I can work on rugby, radon (multilevel_modeling) and model comparison ones. I like the first two because after rerunning them I will be able to update the ArviZ examples with the new InferenceData objects (see arviz-devs/arviz#1132). Regarding the third one, I am very familiar with loo/waic api and therefore I don't expect to find many issues (nor spend too much time on it).

@AlexAndorra
Copy link
Collaborator Author

Thanks @OriolAbril ! Actually, I think @Sayam753 already updated the rugby NB. Now that pymc-devs/pymc#3955 is merged, he'll probably open a new PR and it should be merged in master pretty soon 😉
For the radon NB, it should be quick: I updated it a couple of months ago and it was reviewed so I think it's a false positive -- the More chains (4000) than draws (2) warning is because of a known ArviZ issue that we didn't have time to look at yet, and I don't expect many plots to be wrong. But it's alway good to have a second pair of eyes!
Finally, I think you're the perfect person for the model_comparison NB 😉

@Sayam753
Copy link
Member

I will open a PR regarding rugby notebook and will be happy @OriolAbril reviewing the same.

@OriolAbril
Copy link
Member

Great! Please ping me in the PR and I'll review :)

@aloctavodia
Copy link
Member

Count on me to fix the model comparison and model averaging notebooks.

junpenglao referenced this issue in pymc-devs/pymc Jun 16, 2020
Should reduce the frequency of getting "Mass matrix contains zeros on the diagonal" during warmup and fix a bunch of issue in https://github.com/pymc-devs/pymc3/issues/3959
@fonnesbeck
Copy link
Member

I am working on the GP notebooks.

@AmitKus
Copy link

AmitKus commented Jul 16, 2020

I submitted a PR for weibull_aft. It's my first PR so will greatly appreciate if one of you can review it! @AlexAndorra
Thanks.

@ricardoV94
Copy link
Member

Should we transfer this to pymc-examples? It doesn't show as an option if I click transfer issue ->.

@OriolAbril
Copy link
Member

Sounds good, I think I can transfer the issue

@OriolAbril
Copy link
Member

closing this in favour of the tracker project and all the other issues (each notebook has its own issue now)

twiecki pushed a commit that referenced this issue Jan 17, 2023
* update to use _moments

* update pymc

* update conda-envs

* pip install

* pip install

* pip install

* dll error

* dll error

* dll error

* dll error
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants