PyMC v3.8 Release Notes
Release Date: 2019-11-29 // over 4 years ago-
๐ New features
- ๐ Implemented robust u turn check in NUTS (similar to stan-dev/stan#2800). See PR [#3605]
- โ Add capabilities to do inference on parameters in a differential equation with
DifferentialEquation
. See #3590 and #3634. - Distinguish between
Data
andDeterministic
variables when graphing models with graphviz. PR #3491. - Sequential Monte Carlo - Approximate Bayesian Computation step method is now available. The implementation is in an experimental stage and will be further improved.
- โ Added
Matern12
covariance function for Gaussian processes. This is the Matern kernel with nu=1/2. - Progressbar reports number of divergences in real time, when available #3547.
- Sampling from variational approximation now allows for alternative trace backends [#3550].
- Infix
@
operator now works with random variables and deterministics #3619. - ArviZ is now a requirement, and handles plotting, diagnostics, and statistical checks.
- Can use GaussianRandomWalk in sample_prior_predictive and sample_prior_predictive #3682
- Now 11 years of S&P returns in data set#3682
๐ง Maintenance
- Moved math operations out of
Rice
,TruncatedNormal
,Triangular
andZeroInflatedNegativeBinomial
random
methods. Math operations on values returned bydraw_values
might not broadcast well, and all thesize
aware broadcasting is left togenerate_samples
. Fixes #3481 and #3508 - Parallelization of population steppers (
DEMetropolis
) is now set via thecores
argument. (#3559) - ๐ Fixed a bug in
Categorical.logp
. In the case of multidimensionalp
's, the indexing was done wrong leading to incorrectly shaped tensors that consumedO(n**2)
memory instead ofO(n)
. This fixes issue #3535 - Fixed a defect in
OrderedLogistic.__init__
that unnecessarily increased the dimensionality of the underlyingp
. Related to issue issue #3535 but was not the true cause of it. - SMC: stabilize covariance matrix 3573
- SMC: is no longer a step method of
pm.sample
now it should be called usingpm.sample_smc
3579 - SMC: improve computation of the proposal scaling factor 3594 and 3625
- SMC: reduce number of logp evaluations 3600
- ๐ SMC: remove
scaling
andtune_scaling
arguments as is a better idea to always allow SMC to automatically compute the scaling factor 3625 - Now uses
multiprocessong
rather thanpsutil
to count CPUs, which results in reliable core counts on Chromebooks. sample_posterior_predictive
now preallocates the memory required for its output to improve memory usage. Addresses problems raised in this discourse thread.- ๐ Fixed a bug in
Categorical.logp
. In the case of multidimensionalp
's, the indexing was done wrong leading to incorrectly shaped tensors that consumedO(n**2)
memory instead ofO(n)
. This fixes issue #3535 - Fixed a defect in
OrderedLogistic.__init__
that unnecessarily increased the dimensionality of the underlyingp
. Related to issue issue #3535 but was not the true cause of it. - ๐ Wrapped
DensityDist.rand
withgenerate_samples
to make it aware of the distribution's shape. Added control flow attributes to still be able to behave as in earlier versions, and to control how to interpret thesize
parameter in therandom
callable signature. Fixes 3553 - Added
theano.gof.graph.Constant
to type checks done in_draw_value
(fixes issue 3595) HalfNormal
did not used to work properly indraw_values
,sample_prior_predictive
, orsample_posterior_predictive
(fixes issue 3686)- ๐ Random variable transforms were inadvertently left out of the API documentation. Added them. (See PR 3690).
- Refactored
pymc3.model.get_named_nodes_and_relations
to use the ancestors and descendents, in a way that is consistent withtheano
's naming convention. - Changed the way in which
pymc3.model.get_named_nodes_and_relations
computes nodes without ancestors to make it robust to changes in var_name orderings (issue #3643)