Skip to content

Commit

Permalink
Restore cython tutorial (#1026)
Browse files Browse the repository at this point in the history
Remove nitpicky mode, fix link check.

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
  • Loading branch information
HDembinski and pre-commit-ci[bot] authored Aug 22, 2024
1 parent 2436bef commit 1478105
Show file tree
Hide file tree
Showing 7 changed files with 404 additions and 8 deletions.
23 changes: 20 additions & 3 deletions doc/_static/interactive_demo.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,23 @@
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"outputs": [
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "1ef533261cdf44c88ab722730615534d",
"version_major": 2,
"version_minor": 0
},
"text/plain": [
"HBox(children=(Output(), VBox(children=(HBox(children=(Button(description='Fit', style=ButtonStyle()), ToggleB…"
]
},
"execution_count": null,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"import numpy as np\n",
"from scipy.stats import norm\n",
Expand All @@ -36,6 +52,7 @@
}
],
"metadata": {
"keep_output": true,
"kernelspec": {
"display_name": "Python 3.8.13 ('venv': venv)",
"language": "python",
Expand All @@ -50,8 +67,8 @@
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "python3",
"version": "3.9.13"
"pygments_lexer": "ipython3",
"version": "3.12.4"
},
"vscode": {
"interpreter": {
Expand Down
4 changes: 2 additions & 2 deletions doc/bibliography.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.. _scipy: https://www.scipy.org/
.. _scipy: https://scipy.org/
.. _scipy.optimize: https://docs.scipy.org/doc/scipy/tutorial/optimize.html
.. _numba: https://numba.pydata.org
.. _numba_stats: https://github.com/HDembinski/numba-stats
Expand All @@ -10,7 +10,7 @@
.. _threeML: https://github.com/threeML/threeML
.. _Veusz: https://github.com/veusz/veusz
.. _TensorProb: https://github.com/tensorprob/tensorprob
.. _Scikit-HEP: http://scikit-hep.org
.. _Scikit-HEP: https://scikit-hep.org
.. _probfit: https://github.com/scikit-hep/probfit
.. _gammapy: https://github.com/gammapy/gammapy
.. _flavio: https://github.com/flav-io/flavio
Expand Down
4 changes: 3 additions & 1 deletion doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,5 +83,7 @@
"--InlineBackend.rc=figure.dpi=96",
]

linkcheck_timeout = 3
linkcheck_timeout = 10
linkcheck_allow_unauthorized = True
linkcheck_report_timeouts_as_broken = False
linkcheck_ignore = ["https://doi.org/10.2307%2F2347496"]
376 changes: 376 additions & 0 deletions doc/notebooks/cython.ipynb

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions doc/tutorials.rst
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ Important for most users are only the first two entries.
notebooks/roofit
notebooks/external_minimizer
notebooks/generic_least_squares
notebooks/cython

RooFit tutorials
----------------
Expand Down
3 changes: 1 addition & 2 deletions noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,6 @@ def doc(session: nox.Session) -> None:
# link check
session.run(
"sphinx-build",
"-n", # nitpicky mode
"-T", # full tracebacks
"-v",
"-b=html",
Expand All @@ -95,7 +94,7 @@ def doc(session: nox.Session) -> None:


@nox.session(python="3.11", reuse_venv=True)
def linkcheck(session: nox.Session) -> None:
def links(session: nox.Session) -> None:
"""Check all links in the documentation."""
session.install("--only-binary=:all:", "-e.[test,doc]")

Expand Down
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ pydocstyle.convention = "numpy"
"test_*.py" = ["B", "D"]
"*.ipynb" = ["D"]
"automatic_differentiation.ipynb" = ["F821"]
"cython.ipynb" = ["F821"]
".ci/*.py" = ["D"]
"bench/*.py" = ["D"]
"doc/*.py" = ["D"]
Expand Down

0 comments on commit 1478105

Please sign in to comment.