Skip to content

Commit 13bd4ee

Browse files
feat: Update pyhf to v0.7.6 (#88)
* Update to pyhf v0.7.6. - Update URLs to point to v0.7.6. * Update pixi.toml and pixi.lock. * Update requirements.txt and upgrade lock file.
1 parent d5a293e commit 13bd4ee

12 files changed

+38
-38
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# `pyhf` Tutorial
22

3-
**The tutorial is based off of [`pyhf` `v0.7.5`](https://pypi.org/project/pyhf/0.7.5/)**
3+
**The tutorial is based off of [`pyhf` `v0.7.6`](https://pypi.org/project/pyhf/0.7.6/)**
44

55
[![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/pyhf/pyhf-tutorial/main?urlpath=lab)
66
[![JupyterLite](https://jupyterlite.rtfd.io/en/latest/_static/badge.svg)](https://pyhf.github.io/pyhf-tutorial/live/lab/index.html?path=jupyterlite.ipynb)

binder/requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
pyhf[xmlio,minuit,contrib]==0.7.5
1+
pyhf[xmlio,minuit,contrib]==0.7.6
22
# visualization
33
ipywidgets~=8.1.1
44
ipympl~=0.9.3

book/HelloWorld.ipynb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
"cell_type": "markdown",
5050
"metadata": {},
5151
"source": [
52-
"What did we just make? This returns a [`pyhf.pdf.Model`](https://pyhf.readthedocs.io/en/v0.7.5/_generated/pyhf.pdf.Model.html#pyhf.pdf.Model) object. Let's check out the specification."
52+
"What did we just make? This returns a [`pyhf.pdf.Model`](https://pyhf.readthedocs.io/en/v0.7.6/_generated/pyhf.pdf.Model.html#pyhf.pdf.Model) object. Let's check out the specification."
5353
]
5454
},
5555
{
@@ -144,7 +144,7 @@
144144
"\n",
145145
"where $n = \\{n_1, n_2\\}$ for a 2-bin model (we're being slightly fast and loose with our mathematical notation here), and similarly for $s$, $b$, and $\\gamma$.\n",
146146
"\n",
147-
"The 'shapesys' is defined in the [HistFactory paper](https://cds.cern.ch/record/1456844)... however, it can be a little hard to extract out the necessary information. We've provided a nice table of [Modifiers and Constraints](https://pyhf.readthedocs.io/en/v0.7.5/intro.html#id24) in the introduction of our pyhf documentation to use as reference.\n",
147+
"The 'shapesys' is defined in the [HistFactory paper](https://cds.cern.ch/record/1456844)... however, it can be a little hard to extract out the necessary information. We've provided a nice table of [Modifiers and Constraints](https://pyhf.readthedocs.io/en/v0.7.6/intro.html#id24) in the introduction of our pyhf documentation to use as reference.\n",
148148
"\n",
149149
"![modifiers and constraints](assets/modifiers_and_constraints.png)"
150150
]
@@ -515,7 +515,7 @@
515515
"cell_type": "markdown",
516516
"metadata": {},
517517
"source": [
518-
"We're not performing inference just yet. We're simply computing the 'logpdf' of the model specified by the parameters $\\theta$ against the provided data. To perform a fit, we use the [inference API](https://pyhf.readthedocs.io/en/v0.7.5/api.html#inference) via `pyhf.infer`.\n",
518+
"We're not performing inference just yet. We're simply computing the 'logpdf' of the model specified by the parameters $\\theta$ against the provided data. To perform a fit, we use the [inference API](https://pyhf.readthedocs.io/en/v0.7.6/api.html#inference) via `pyhf.infer`.\n",
519519
"\n",
520520
"When fitting a model to data, we usually want to find the $\\hat{\\theta}$ which refers to the \"Maximum Likelihood Estimate\" of the model parameters. This is often referred to mathematically by\n",
521521
"\n",
@@ -675,7 +675,7 @@
675675
"source": [
676676
"## Simple Upper Limit\n",
677677
"\n",
678-
"To get upper limits, we just need to run multiple hypothesis tests for a lot of different null hypotheses of BSM with $\\mu \\in [0, \\ldots, 5.0]$ and then find the value of $\\mu$ for which the null hypothesis is rejected (a 95% $\\text{CL}_\\text{s}$). We can do all of this very easily just using the [`upper_limits.upper_limit` API](https://pyhf.readthedocs.io/en/v0.7.5/_generated/pyhf.infer.intervals.upper_limits.upper_limit.html#pyhf.infer.intervals.upper_limits.upper_limit), which also can calculate the upper limit by interpolating"
678+
"To get upper limits, we just need to run multiple hypothesis tests for a lot of different null hypotheses of BSM with $\\mu \\in [0, \\ldots, 5.0]$ and then find the value of $\\mu$ for which the null hypothesis is rejected (a 95% $\\text{CL}_\\text{s}$). We can do all of this very easily just using the [`upper_limits.upper_limit` API](https://pyhf.readthedocs.io/en/v0.7.6/_generated/pyhf.infer.intervals.upper_limits.upper_limit.html#pyhf.infer.intervals.upper_limits.upper_limit), which also can calculate the upper limit by interpolating"
679679
]
680680
},
681681
{

book/Modifiers.ipynb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@
88
"source": [
99
"# Modifiers\n",
1010
"\n",
11-
"In our simple examples so far, we've only used two types of modifiers, but HistFactory allows for a handful of modifiers that have proven to be sufficient to model a wide range of uncertainties. Each of the modifiers is further described in the [Modifiers section](https://pyhf.readthedocs.io/en/v0.7.5/likelihood.html#modifiers) of the pyhf docs on model specification.\n",
11+
"In our simple examples so far, we've only used two types of modifiers, but HistFactory allows for a handful of modifiers that have proven to be sufficient to model a wide range of uncertainties. Each of the modifiers is further described in the [Modifiers section](https://pyhf.readthedocs.io/en/v0.7.6/likelihood.html#modifiers) of the pyhf docs on model specification.\n",
1212
"\n",
13-
"There is an addtional table of [Modifiers and Constraints](https://pyhf.readthedocs.io/en/v0.7.5/intro.html#id24) in the introduction of the pyhf documentation to use as reference.\n",
13+
"There is an addtional table of [Modifiers and Constraints](https://pyhf.readthedocs.io/en/v0.7.6/intro.html#id24) in the introduction of the pyhf documentation to use as reference.\n",
1414
"\n",
1515
"![modifiers and constraints](assets/modifiers_and_constraints.png)\n",
1616
"\n",

book/SerializationAndPatching.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@
107107
"source": [
108108
"## Patching in Signals\n",
109109
"\n",
110-
"Let's look at this [`pyhf.PatchSet`](https://pyhf.readthedocs.io/en/v0.7.5/_generated/pyhf.patchset.PatchSet.html#pyhf.patchset.PatchSet) object which provides a user-friendly way to interact with many signal patches at once.\n",
110+
"Let's look at this [`pyhf.PatchSet`](https://pyhf.readthedocs.io/en/v0.7.6/_generated/pyhf.patchset.PatchSet.html#pyhf.patchset.PatchSet) object which provides a user-friendly way to interact with many signal patches at once.\n",
111111
"\n",
112112
"### PatchSet"
113113
]

book/SimpleWorkspace.ipynb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@
6767
"cell_type": "markdown",
6868
"metadata": {},
6969
"source": [
70-
"What did we just make? This returns a [`pyhf.Workspace`](https://pyhf.readthedocs.io/en/v0.7.5/_generated/pyhf.workspace.Workspace.html#pyhf.workspace.Workspace) object. Let's check out the specification."
70+
"What did we just make? This returns a [`pyhf.Workspace`](https://pyhf.readthedocs.io/en/v0.7.6/_generated/pyhf.workspace.Workspace.html#pyhf.workspace.Workspace) object. Let's check out the specification."
7171
]
7272
},
7373
{
@@ -142,7 +142,7 @@
142142
"source": [
143143
"What does this mean for us though? Well, when we ask for a model, we specify the measurement that we want to use with it. Each of these measurements above have no additional parameter configurations on top of the existing model specification. Additionally, they all declare that the parameter of interest is `mu`.\n",
144144
"\n",
145-
"See the [documentation](https://pyhf.readthedocs.io/en/v0.7.5/_generated/pyhf.workspace.Workspace.html#pyhf.workspace.Workspace.model) for more information. In this case, let's build the model for the default measurement."
145+
"See the [documentation](https://pyhf.readthedocs.io/en/v0.7.6/_generated/pyhf.workspace.Workspace.html#pyhf.workspace.Workspace.model) for more information. In this case, let's build the model for the default measurement."
146146
]
147147
},
148148
{

book/WorkspaceManipulations.ipynb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,7 @@
207207
"\n",
208208
"### via the command line\n",
209209
"\n",
210-
"So pyhf comes with a lot of nifty utilities you can access. The documentation for the command line can be found via `pyhf --help` or [online](https://pyhf.readthedocs.io/en/v0.7.5/cli.html)."
210+
"So pyhf comes with a lot of nifty utilities you can access. The documentation for the command line can be found via `pyhf --help` or [online](https://pyhf.readthedocs.io/en/v0.7.6/cli.html)."
211211
]
212212
},
213213
{
@@ -229,7 +229,7 @@
229229
"python -m pip install pyhf[xmlio]\n",
230230
"```\n",
231231
"\n",
232-
"Again, the online documentation for this option is found [here](https://pyhf.readthedocs.io/en/v0.7.5/cli.html#pyhf-xml2json)."
232+
"Again, the online documentation for this option is found [here](https://pyhf.readthedocs.io/en/v0.7.6/cli.html#pyhf-xml2json)."
233233
]
234234
},
235235
{
@@ -292,7 +292,7 @@
292292
"\n",
293293
"Nearly at the end, the next part of this specification is for the `observations` (observed data) on line 113. Each observation corresponds with the channel, where `channel1` has two bins, and `channel2` also has two bins.\n",
294294
"\n",
295-
"Finally, we have a `version` which specifies the version of the schema used for the JSON HistFactory. In this case, we're using `1.0.0` which has the [https://pyhf.readthedocs.io/en/v0.7.5/schemas/1.0.0/workspace.json](https://pyhf.readthedocs.io/en/v0.7.5/schemas/1.0.0/workspace.json) definition which refers to the [https://pyhf.readthedocs.io/en/v0.7.5/schemas/1.0.0/defs.json](https://pyhf.readthedocs.io/en/v0.7.5/schemas/1.0.0/defs.json).\n",
295+
"Finally, we have a `version` which specifies the version of the schema used for the JSON HistFactory. In this case, we're using `1.0.0` which has the [https://pyhf.readthedocs.io/en/v0.7.6/schemas/1.0.0/workspace.json](https://pyhf.readthedocs.io/en/v0.7.6/schemas/1.0.0/workspace.json) definition which refers to the [https://pyhf.readthedocs.io/en/v0.7.6/schemas/1.0.0/defs.json](https://pyhf.readthedocs.io/en/v0.7.6/schemas/1.0.0/defs.json).\n",
296296
"\n",
297297
"What's really nice about the schema definition is that it allows anyone to write their own tooling/scripting to build up the workspace and quickly check if it matches the schema. This will get you 90% of the way there in having a valid workspace to work with.\n",
298298
"\n",
@@ -330,7 +330,7 @@
330330
"cell_type": "markdown",
331331
"metadata": {},
332332
"source": [
333-
"So we're not going to dump this out. We already did that above. Let's just quickly go ahead and load it into a [`pyhf.Workspace`](https://pyhf.readthedocs.io/en/v0.7.5/_generated/pyhf.workspace.Workspace.html#pyhf.workspace.Workspace) object because we can."
333+
"So we're not going to dump this out. We already did that above. Let's just quickly go ahead and load it into a [`pyhf.Workspace`](https://pyhf.readthedocs.io/en/v0.7.6/_generated/pyhf.workspace.Workspace.html#pyhf.workspace.Workspace) object because we can."
334334
]
335335
},
336336
{

book/introduction.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ The 'minuit' extra installs [`iminuit`](https://iminuit.readthedocs.io/).
151151

152152
::::
153153

154-
See our [installation docs](https://pyhf.readthedocs.io/en/v0.7.5/installation.html) for more information about installation options.
154+
See our [installation docs](https://pyhf.readthedocs.io/en/v0.7.6/installation.html) for more information about installation options.
155155

156156
### Dependencies for this tutorial
157157

@@ -198,11 +198,11 @@ If you want to also get the dependencies to build and explore the Jupyter Book f
198198
(pyhf-tutorial) $ pyhf --citation
199199
@software{pyhf,
200200
author = {Lukas Heinrich and Matthew Feickert and Giordon Stark},
201-
title = "{pyhf: v0.7.5}",
202-
version = {0.7.5},
201+
title = "{pyhf: v0.7.6}",
202+
version = {0.7.6},
203203
doi = {10.5281/zenodo.1169739},
204204
url = {https://doi.org/10.5281/zenodo.1169739},
205-
note = {https://github.com/scikit-hep/pyhf/releases/tag/v0.7.5}
205+
note = {https://github.com/scikit-hep/pyhf/releases/tag/v0.7.6}
206206
}
207207
208208
@article{pyhf_joss,
@@ -219,7 +219,7 @@ If you want to also get the dependencies to build and explore the Jupyter Book f
219219
}
220220
```
221221

222-
Alternatively, [check the website](https://pyhf.readthedocs.io/en/v0.7.5/citations.html).
222+
Alternatively, [check the website](https://pyhf.readthedocs.io/en/v0.7.6/citations.html).
223223

224224
### Statistics References
225225

book/requirements.lock

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1394,9 +1394,9 @@ pygments==2.19.1 \
13941394
# pydata-sphinx-theme
13951395
# rich
13961396
# sphinx
1397-
pyhf==0.7.5 \
1398-
--hash=sha256:51aa26bb87c13f493221371e94e693528378779137499029801f99cc10d8d5b2 \
1399-
--hash=sha256:83a73f1f662c5be3aa15126351eb29c5154c000d87e2a5d9f0f9f9df20b1c28c
1397+
pyhf==0.7.6 \
1398+
--hash=sha256:01b2401b9fdc53d94fa28256128c4898c380c64f71446f1695580fb18fba349d \
1399+
--hash=sha256:d41d9cdce5555863a77a37efd0784ad81d84b817295aa07ebc1cfa5ec50cc78c
14001400
# via -r requirements.txt
14011401
pyparsing==3.2.1 \
14021402
--hash=sha256:506ff4f4386c4cec0590ec19e6302d3aedb992fdc02c761e90416f158dacf8e1 \

lite/jupyterlite.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
import micropip
1818

1919
# Install pyhf in the browser
20-
await micropip.install(["pyhf==0.7.5", "matplotlib>=3.0.0"])
20+
await micropip.install(["pyhf==0.7.6", "matplotlib>=3.0.0"])
2121
# %matplotlib inline
2222
import pyhf
2323

@@ -30,4 +30,4 @@
3030
import micropip
3131

3232
# Install pyhf in the browser
33-
await micropip.install(["pyhf==0.7.5", "matplotlib>=3.0.0"])
33+
await micropip.install(["pyhf==0.7.6", "matplotlib>=3.0.0"])

0 commit comments

Comments
 (0)