1.0.0
The objective of this release is to stabilize Pyro's interface and thereby make it safer to build high level components on top of Pyro.
Stability statement
- Behavior of documented APIs will remain stable across minor releases, except for bug fixes and features marked EXPERIMENTAL or DEPRECATED.
- Serialization formats will remain stable across patch releases, but may change across minor releases (e.g. if you save a model in 1.0.0, it will be safe to load it in 1.0.1, but not in 1.1.0).
- Undocumented APIs, features marked EXPERIMENTAL or DEPRECATED, and anything in
pyro.contrib
may change at any time (though we aim for stability). - All deprecated features throw a
FutureWarning
and specify possible work-arounds. Features marked as deprecated will not be maintained, and are likely to be removed in a future release. - If you want more stability for a particular feature, contribute a unit test.
New features
- pyro.infer.Predictive is a new utility for serving models, supporting jit tracing and serialization.
- pyro.distributions.transforms has many new transforms, and includes helper functions to easily create a variety of normalizing flows. The transforms library has also been reorganized.
- pyro.contrib.timeseries is an experimental new module with fast Gaussian Process inference for univariate and multivariate time series and state space models.
- pyro.nn.PyroModule is an experimental new interface that adds Pyro effects to an
nn.Module
.PyroModule
is already used internally byAutoGuide
,EasyGuide
pyro.contrib.gp
,pyro.contrib.timeseries
, and elsewhere. - FoldedDistribution is a new distribution factory, essentially equivalent to
TransformedDistribution(-, AbsTransform())
but providing a.log_prob()
method. - A new tutorial illustrates the usage of pyro.contrib.oed in the context of adaptive election polling.
Breaking changes
- Autoguides have slightly changed interfaces:
AutoGuide
andEasyGuide
are nownn.Module
s and can be serialized separately from the param store. This enables serving via torch.jit.trace_module.- The
Auto*Normal
family of autoguides now haveinit_scale
arguments, andinit_loc_fn
has better support. Autoguides no longer support initialization by writing directly to the param store.
- Many transforms have been renamed to enforce a consistent interface, such as the renaming of
InverseAutoregressiveFlow
toAffineAutoregressive
. pyro.generic
has been moved to a separate project pyroapi.- poutine.do has slightly changed semantics to follow Single World Intervention Graph semantics.
pyro.contrib.glmm
has been moved topyro.contrib.oed.glmm
and will eventually be replaced by BRMP.- Existing
DeprecationWarning
s have been promoted toFutureWarning
s.
Deprecated features
pyro.random_module
: Thepyro.random_module
primitive has been deprecated in favor of PyroModule which can be used to create Bayesian modules fromtorch.nn.Module
instances.SVI.run
: TheSVI.run
method is deprecated and users are encouraged to use the .step method directly to run inference. For drawing samples from the posterior distribution, we recommend using the Predictive utility class, or directly by using thetrace
andreplay
effect handlers.TracePredictive
: TheTracePredictive
class is deprecated in favor of Predictive, that can be used to gather samples from the posterior and predictive distributions in SVI and MCMC.mcmc.predictive
: This utility function has been absorbed into the more general Predictive class.