v0.7.0 #2030
Unanswered
matthewfeickert
asked this question in
General
v0.7.0
#2030
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
This is a minor release from
v0.6.3
→v0.7.0
.Important Notes
Please note this release has API breaking changes and carefully read these notes while updating your code to the
v0.7.0
API.All backends are now fully compatible and tested with Python 3.10. (PR build: Add support for Python 3.10 across all backends #1809)
The$$\lim_{\lambda \to 0} ,\mathrm{Pois}(n | \lambda)$$ is well defined. (PR feat: Allow zero rate Poisson #1657)
pyhf.tensorlib.poisson
API now allows for the expected rate parameterlam
to be0
in the case that the observed eventsn
is0
given that the limitpyhf.readxml.parse
now supports reading of XML configurations with absolute paths. To support this,pyhf xlm2json
now has a-v/--mount
option. (PR feat: Handle absolute paths in XML config files (xml2json / readxml) #1909)Support for model specifications without a parameter of interest defined is added. (PRs feat: Add POI-less specification support #1638, feat: Allow POI-less models via Workspace.model #1636)
The
pyhf.parameters.paramsets
classessuggested_fixed
attribute behavior has been updated. To access the behavior used inpyhf
v0.6.x
use thesuggested_fixed_as_bool
attribute. (PR refactor: Simplified parameters #1639)pyhf.pdf._ModelConfig.par_names
is changed to be a property attribute. (PR feat: Makepar_names
a _ModelConfig property attribute #2027)The order of model parameters is now sorted by model parameter name. (PR feat: Add setup for custom modifiers #1625)
Support for writing user custom modifiers is added. (PRs feat: Add setup for custom modifiers #1625, fix: custom modifier / new parameter support and test #1644)
Performance in
pyhf.readxml
is increased by improvements topyhf.readxml.import_root_histogram
. (PR fix: Speed-up readxml by caching key lookup instead of using try/except #1691)pyhf.contrib.utils.download
is now more robust to different target file types. (PRs refactor: Make contrib.utils.download robust to archive file types #1697, fix: Accept tar and zip headers in contrib.utils.download requests #1704)A
pyhf.default_backend
has been added that is configurable through adefault
kwarg inpyhf.set_backend
. (PR feat: Configurable default backend #1646) This is part of work to makepyhf
fully automatic differentiable. (Issue Making pyhf differentiable #882)Schema validation now allows for both
list
andpyhf.tensorlib
objects to exist in the model specification. (PR feat: Add support for arrayful JSON #1647)The minimum required dependencies have been updated to support added features:
scipy>=1.2.0
(PR feat: Add autoscan for upper limit using TOMS Algorithm 748 #1274)click>=8.0.0
(PRs feat: Handle absolute paths in XML config files (xml2json / readxml) #1909, build: Update lower bound of click to v8.0.0 #1958)jsonschema>=4.15.0
(PRs fix: Base URI for jsonschema.RefResolver has better behavior #1976, build: Update lower bounds to jsonschema v4.15.0, importlib-resources v1.4.0 #1979)importlib_resources>=1.4.0
(for Python 3.7, 3.8) (PR build: Update lower bounds to jsonschema v4.15.0, importlib-resources v1.4.0 #1979)typing_extensions>=3.7.4.3
(for Python 3.7 only) (PRs feat: Add typehints to pyhf.tensor #1940, build: Update lower bound of typing-extensions to v3.7.4.3 #1961)The minimum required backend versions have been updated to support added features:
jax>=0.2.10
,jaxlib>=0.1.61
(PR build: Update lower bounds to tensorflow v2.7.0, jaxlib v0.1.61 #1962)torch>=1.10.0
(PR feat: Allow zero rate Poisson #1657)tensorflow>=2.7.0
,tensorflow-probability>=0.11.0
(PRs build: Update lower bounds to tensorflow v2.7.0, jaxlib v0.1.61 #1962, feat: Allow zero rate Poisson #1657)iminuit>=2.7.0
(PR build: Update lower bound on iminuit to v2.7.0 #1895)'xmlio'
extra requiresuproot>=4.1.1
(PR feat: Drop uproot3 for uproot4 for writing ROOT files #1567)Fixes
Use improvements to
jsonschema.RefResolver
to avoidjsonschema.exceptions.RefResolutionError
. (PR fix: Base URI for jsonschema.RefResolver has better behavior #1976)Use the conditional maximum likelihood estimators of the nuisance parameters to create the sampling distributions for
pyhf.infer.calculators.ToyCalculator
. (PR fix: Use MLEs of NPs to create sampling distributions in ToyCalculator #1610) This follows the joint recommendations of the ATLAS and CMS experiments in Procedure for the LHC Higgs boson search combination in Summer 2011.Features
Python API
The following functions have been added to the
pyhf.tensorlib
API:pyhf.tensorlib.transpose
(PR feat: Add transpose function to tensorlib #1696)pyhf.tensorlib.percentile
(PR feat: Add percentile function to tensorlib #817)pyhf.readxml.parse
now supports reading of XML configurations with absolute paths with the addition of themounts
optional argument. (PR feat: Handle absolute paths in XML config files (xml2json / readxml) #1909)Support for overriding the paths for finding schemas is added, using the
pyhf
installed location as a base viapyhf.utils.schemas
. (PRs feat: Alternative Schema Locations #1753, feat: Add contextlib support to pyhf.schema API #1818)In
pyhf.workspace.Workspace.model
the parameter of interest specified in the measurement may now be overridden using the addedpoi_name
kwarg. (PR feat: Allow POI-less models via Workspace.model #1636)The
pyhf.parameters.paramsets
classessuggested_fixed
attribute behavior has been updated to return alist
ofbool
of lengthn_parameters
. To access the behavior used inpyhf
v0.6.x
use thesuggested_fixed_as_bool
attribute. (PR refactor: Simplified parameters #1639)pyhf.pdf._ModelConfig.par_names
is changed to be a property attribute. (PR feat: Makepar_names
a _ModelConfig property attribute #2027)The order of model parameters is now sorted by model parameter name. (PR feat: Add setup for custom modifiers #1625)
Support for writing user custom modifiers is added.
(PRs feat: Add setup for custom modifiers #1625, fix: custom modifier / new parameter support and test #1644) This is still in the stage where it is targeted at expert users.
{modifier}_builder
classes are added for all modifiers. (PRs feat: Add setup for custom modifiers #1625) For example,pyhf.modifiers.histosys.histosys_builder
.When using
pyhf.writexml
and thenormfactor
parameter config is missinginits
orbounds
, fall back to using default values. (PRs fix: writexml handles missing parameter configs for normfactor #1819)Supported options for
pyhf.infer.hypotest
can now be passed as kwargs through thepyhf.infer.intervals.upper_limits.upper_limit
API. (PR feat: Add hypotest kwargs to pyhf.infer.intervals.upperlimit #1613) This now enables things like usingpyhf.infer.calculators.ToyCalculator
as the calculator used for the hypothesis test scan:Allow for fit parameter values from required fits in
pyhf.infer.test_statistics
functions to be returned by use ofreturn_fitted_pars
kwarg with thepyhf.infer.test_statistics
functions andreturn_calculator
kwarg withpyhf.infer.hypotest
. (PR feat: Expose fitted parameter values of implicit fits in test statistic calls #1554)A
validate
kwarg has been added topyhf.workspace.Workspace
andpyhf.pdf.Model
to allow skipping validation. (PR feat: Configurable default backend #1646) This should only be used by expert users who understand the risks.A
pyhf.default_backend
has been added that is configurable through adefault
kwarg inpyhf.set_backend
. (PR feat: Configurable default backend #1646) This allows setting thepyhf.default_backend
to be different from the value ofpyhf.tensorlib
returned bypyhf.get_backend
, which can be useful in situations where differentiable model construction is needed.Schema validation now allows for both
list
andpyhf.tensorlib
objects to exist in the model specification. (PR feat: Add support for arrayful JSON #1647)CLI API
The
pyhf xlm2json
CLI API now has a-v/--mount
option to support reading XML configurations with absolute paths. (PR feat: Handle absolute paths in XML config files (xml2json / readxml) #1909) Similar to Docker volume mounts, the options allows a user to pass two fields separated by a colon (:). The first field is a local path and the second field is the absolute path specified in the XML configuration to be substituted. Without the
-v/--mount` option a user would have to manually edit the absolute path in each XML file it appeared in!Deprecations
Python API
pyhf.infer.intervals.upperlimit
API has been deprecated in favor ofpyhf.infer.intervals.upper_limits.upper_limit
.The
pyhf.infer.intervals.upperlimit
API will removed inpyhf
v0.9.0
.(PR feat: Add autoscan for upper limit using TOMS Algorithm 748 #1274)
Removals
Python API
The
pyhf.simplemodels.hepdata_like
API, deprecated sincepyhf
v0.6.2
, has been removed.(PR feat: Remove pyhf.simplemodels.hepdata_like from API #1670)
Use the
pyhf.simplemodels.uncorrelated_background
API instead.pyhf.workspace.Workspace
'sparameters
attribute is removed in favor ofusing
pyhf.pdf._ModelConfig
'sparameters
.(PR feat: Add setup for custom modifiers #1625)
pyhf.workspace.Workspace.get_measurement
has thepoi_name
kwarg removed.(PR feat: Allow POI-less models via Workspace.model #1636)
Contributors
v0.7.0
benefited from contributions from:Changes
include_auxdata
kwarg forpyhf.Workspace.data
by @matthewfeickert in fix: Update notebooks to useinclude_auxdata
kwarg forpyhf.Workspace.data
#1588pyhf.pdf._ModelConfig.channels
is a list by @RhnSharma in docs: Correct v0.6.3 release notes to notepyhf.pdf._ModelConfig.channels
is a list #1592jupyter-black
pre-commit hook overnbqa-black
by @matthewfeickert in ci: Usejupyter-black
pre-commit hook overnbqa-black
#1598uproot4
writing speedup to v0.6.3 release notes by @matthewfeickert in docs: Adduproot4
writing speedup to v0.6.3 release notes #1601Accept
header to requests incontrib.utils.download
by @matthewfeickert in refactor: PassAccept
header to requests incontrib.utils.download
#1673_ModelConfig.suggested_fixed
list contains only booleans for all modifiers by @alexander-held in fix: Ensure_ModelConfig.suggested_fixed
list contains only booleans for all modifiers #1706pyhf.contrib.utils.download
by @matthewfeickert in fix: Skip doctest ofpyhf.contrib.utils.download
#1715tolist
fallback by @matthewfeickert in fix: Accept ValueError for JAX backendtolist
fallback #1746RuntimeWarning
from NumPy by @matthewfeickert in fix: Allow for true_divide or divideRuntimeWarning
from NumPy #1873github.workflow
property to ensure unique concurrency group by @matthewfeickert in ci: Usegithub.workflow
property to ensure unique concurrency group #1879find_namespace:
to ensure discovery of package data by @matthewfeickert in build: Usefind_namespace:
to ensure discovery of package data #1881license_files
in setup.cfg by @matthewfeickert in build: Uselicense_files
in setup.cfg #1883build
error on warnings by @matthewfeickert in ci: Makebuild
error on warnings #1887defs.json
again by @lhenkelm in fix: Populate the schema cache with localdefs.json
again #1917validate
kwarg to top-level functions inpyhf.simplemodels
by @phinate in feat: Promotevalidate
kwarg to top-level functions inpyhf.simplemodels
#1858_ModelConfig.set_poi(None)
to unset model POI by @kratsg in feat: Add support for_ModelConfig.set_poi(None)
to unset model POI #1985--no-extras
functionality by @matthewfeickert in fix: Pin codemetapy to v0.3.5 for--no-extras
functionality #1995par_names
a _ModelConfig property attribute by @matthewfeickert in feat: Makepar_names
a _ModelConfig property attribute #2027New Contributors
pyhf.pdf._ModelConfig.channels
is a list #1592validate
kwarg to top-level functions inpyhf.simplemodels
#1858Full Changelog: v0.6.3...v0.7.0
This discussion was created from the release v0.7.0.
Beta Was this translation helpful? Give feedback.
All reactions