Skip to content
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

Update GP-Latent example to V4 #371

Merged
merged 2 commits into from
Jun 10, 2022
Merged

Conversation

bwengals
Copy link
Collaborator

@bwengals bwengals commented Jun 5, 2022

Update GP-Latent to V4

Addresses issue #72. Is a replacement for PR #237. Upgrades the notebook to V4. Tried to follow the style guide and passed pre-commit locally, but please let me know what's not correct. I also cleaned up some of the text and example models a bit.

Helpful links

@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@bwengals bwengals mentioned this pull request Jun 5, 2022
@bwengals
Copy link
Collaborator Author

bwengals commented Jun 7, 2022

ty @twiecki, if it's all good, do you mind hitting the big green merge button? I dont have write access it seems

Copy link
Member

@OriolAbril OriolAbril left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The table of contents is messed up:

image

IMO, the first heading Gaussian Processes: Latent Variable Implementation should be the only level 1 heading. Then Latent variable implementation, example 1..., example 2..., Authors should be level 2 and so on.

Note: When there is a single level 1 heading at the top of the file, it is excluded from the toc so everything looks better, see for example: https://pymcio--371.org.readthedocs.build/projects/examples/en/371/generalized_linear_models/GLM-simpsons-paradox.html

---

```{raw-cell}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should not be a raw cell, it should be markdown cell. It is not rendering correctly in the preview due to that: https://pymcio--371.org.readthedocs.build/projects/examples/en/371/gaussian_processes/GP-Latent.html. The title is not shown, neither are the notebook badges and the tags are not recognized.

```{code-cell} ipython3
%load_ext watermark
%watermark -n -u -v -iv -w
```

```{raw-cell}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should not be a raw cell either. There should not be any raw cells in the notebook

---

```{raw-cell}
(notebook_name)=
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The target should not be literally notebook_name but the actual name of the notebook. The text within the parenthesis is what will be used to reference this notebook from other places in the docs, it needs to be unique to this notebook. https://docs.pymc.io/en/latest/contributing/jupyter_style.html#first-cell

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm right where it says it in that big red box labeled important that I managed to miss

@bwengals
Copy link
Collaborator Author

Thanks for the review @OriolAbril!

@OriolAbril OriolAbril merged commit c323de9 into pymc-devs:main Jun 10, 2022
@bwengals
Copy link
Collaborator Author

Hey @OriolAbril, I noticed today that the changes made in this PR were accidentally overwritten by something else a day later (history: https://github.com/pymc-devs/pymc-examples/commits/main/examples/gaussian_processes/GP-Latent.ipynb). If you look at the version of this notebook in main it's old and still has "pymc3" everywhere.

What's the best way to fix this? I can open a new PR and copy over the final state of this PR into it, but that sounds like bad git practices. Any recommendation?

@bwengals
Copy link
Collaborator Author

Actually, I found some code that was commented that should be deleted. I can PR a fix for that that will fix everything else.

@OriolAbril
Copy link
Member

I think a new PR is perfectly fine, even needed. Having updated notebooks can never be trumped by trying to enforce some git good practices imo. Thanks for catching this by the way.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants