Change Log
v0.4.0 (13/07/2026)
Added
Voronoi2DSpherefor trans-dimensional tessellations on the sphere, with great-circle nearest-site geometry, uniform-per-area site sampling, isotropic spherical perturbations, polygon andMultiPolygondomains, configurable longitude seams, and 2-D map and 3-D sphere plotting.Added exact incremental nearest-site interpolation for fixed query positions to
Voronoi2DandVoronoi2DSphere, avoiding a full-grid nearest-neighbour query on every Markov-chain iteration.Added public
InvalidProposalExceptionfor deliberately inadmissible proposals. These now produce one counted rejected iteration instead of a state-dependent redraw, preserving detailed balance.Added
on_forward_error={"reject", "raise"}to Markov chains and inversion interfaces. Unexpected forward errors reject proposals by default and can be configured to raise for debugging.Unexpected errors raised by user perturbation functions now propagate instead of being silently retried. Raise
InvalidProposalExceptionfor deliberate proposal rejection.Fixed scalar initialization of position-dependent Gaussian, Laplace, and custom priors in multidimensional and spherical domains.
Unified the state-local KD-tree and fixed-position interpolation lifecycle of
Voronoi2DandVoronoi2DSpherewhile preserving their public API and eager/lazy cache behaviour. Cache updates now also use the exact removed-site index, including when a tessellation contains duplicate sites.Completed cache handling for initialized, prior-sampled, nested-birth, user-created, and pickled states, including process- and thread-based parallel chains. NumPy integer scalars are now accepted for fixed
n_dimensions.Hardened Voronoi polygon validation and bounded polygon sampling, restored Shapely’s internal query preparation after pickling, and validated tessellation-ensemble input lengths.
Fixed spherical plotting of
GeometryCollectionseam results and added a user-controlled surface-mesh spacing andcenter_lonlatcamera control for three-dimensional rendering.Fixed planar Voronoi plotting for duplicate, axis-aligned, and far-offset sites; avoided redundant KD-tree rebuilds for rejected dimension changes; and accelerated polygon containment checks with Shapely’s coordinate API.
v0.3.12 (10/07/2026)
Bug fix: Voronoi-site perturbations in
Voronoi,Voronoi1D, andVoronoi2Dnow reject proposals falling outside the discretization domain rather than redrawing them until valid. The redraw scheme made the effective proposal a truncated Gaussian whose normalization depends on the current site position, breaking detailed balance and biasing the sampled site positions within a fewperturb_stdof the domain boundaries (or of the polygon edges inVoronoi2D)Bug fix: fixed a
TypeErrorraised during birth perturbations when aParameterSpaceis nested inside a trans-dimensional discretization withbirth_from="neighbour"(the default)
v0.3.11 (30/06/2026)
Bug fix: replaced deprecated
np.row_stackwithnp.vstackin Voronoi birth perturbations, fixingVoronoi2D.birth()compatibility with NumPy >= 2.5
v0.3.10 (23/03/2026)
Bug fix: Python 3.14 compatibility — added explicit type casts at Cython call sites to prevent
TypeErrorwhen numpy scalars are passed to typed Cython parameters (issue #25)Refactor: moved all 1D-specific logic from
VoronoiintoVoronoi1Doverrides, removing dimension conditionals from the base classVoronoinow raisesValueErrorif directly instantiated withspatial_dimensionsof 1 or 2, recommendingVoronoi1DorVoronoi2Dinstead
v0.3.9 (23/03/2026)
Bug fix:
Voronoi1D.sample_site()now returns a Pythonfloatinstead of a shape-(1,) NumPy array, fixing aTypeErrorin birth perturbation with Cython extensions compiled against older Cython versions and NumPy >= 2.0
v0.3.8 (13/03/2026)
Fixed docstring of BayesianInversion
v0.3.7 (19/11/2025)
Change to setup.py: avoid “-march=native” for “arm64” and “aarch64” machines
v0.3.6 (11/11/2025)
Enhancement: SimulatedAnnealing now accepts the argument
cooling_fraction
v0.3.5 (08/10/2025)
Enhancement:
Stategenerated byParameterization.initialize()now validated when creating aMarkovChain
v0.3.4 (02/08/2025)
Bug fix: added else condition in
bayesbay.prior.CustomPrior.perturb_value()to accommodateis_birth=False
v0.3.3 (16/04/2025)
Enhancement: More robust checks when custom starting states (
walkers_starting_states) are passed to BayesianInversion
v0.3.2 (16/04/2025)
Enhancement: Enabled custom starting states in high-level API
BayesianInversion now takes optional argument
walkers_starting_statesMarkovChain now takes optional argument
starting_state
v0.3.1 (20/03/2024)
API change: removed
DimensionalityExceptionDimensionalityException replaced with -math.inf log probability in birth and death perturbations
New feature:
Voronoi1DVoronoi1D.compute_interface_positions()added
Enhancement:
Voronoi1D.compute_cell_extentsnow deals with negative lower boundaries
v0.3.0 (15/03/2024)
New feature: Nested parameter space (and discretization)
v0.2.4 (07/03/2024)
Enhancement:
__repr__in some classes
v0.2.3 (07/03/2024)
New feature:
bayesbay.prior.LaplacePriorNew feature:
bayesbay.LogLikelihood.__repr__New feature:
bayesbay.Target.__repr__
v0.2.2 (04/03/2024)
New feature:
Voronoi2DVoronoi2D.get_tessellation_statistics()added
API change:
Voronoi1Dgeneralized all static methods:
interpolate_tessellation
_interpolate_tessellations
get_tessellation_statistics
plot_tessellation
plot_tessellations
plot_tessellation_statistics
plot_tessellation_density
v0.2.1 (27/02/2024)
New feature:
Voronoi2DVoronoi2D.interpolate_tessellation()addedVoronoi2D.polygonadded, allowing for prior probabilities defined within polygons
API change:
bayesbay.samplers._samplersmultiprocessing now carried out with
joblib
v0.2.0 (14/02/2024)
New feature:
Voronoi2Dadded
New feature:
pertubation_weightsweights can be updated
BaseBayesianInversion.set_perturbation_funcs(funcs, weights)BaseMarkovChain.set_perturbation_funcs(funcs, weights)
weights can be assigned during initialization
BaseBayesianInversion(perturbation_weights, ...)BaseMarkovChain(perturbation_weights, ...)MarkovChain(perturbation_weights, ...)
API change:
bayesbay.parameters->bayesbay.priorUniformParameter->UniformPriorGaussianParameter->GaussianPriorCustomParameter->CustomPrior
API change:
ParameterSpaceStateandStatecacheadded toParameterSpaceStatesave_to_cache,load_from_cache,saved_in_cacheadded toParameterSpaceStateBy default, the
ParameterSpaceState.cacheis carried over when callingState.copy(), i.e., it is copied to the new ParameterSpaceState
API change:
bayesbay.discretization._voronoiAll methods in
Voronoi1D, except for static ones, have been moved toVoronoi, which is now more general
v0.1.9 (05/02/2024)
API change:
LogLikelihoodcan accept log likelihood function or log likelihood ratio functionAPI change:
BayesianInversionnow takes in instance ofLogLikelihood, instead of a list of targets and forward functionsNew API:
LogLikelihood.add_targets()method that allows more data to join the inversionNew API:
BayesianInversion.get_results_from_chainsNew API:
Parameter.samplemethodEnhancement:
__repr__and__str__for all classesFix: bug in nearest index when birth from neighbour
v0.1.1 (15/01/2024)
Add pyx file to Manifest.in
v0.1.0 (15/01/2024)
First release