Skip to content
master
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

A Python toolkit for (likelihood-free) inference and the mechanization of the scientific method.

Installation

From source

git clone https://github.com/montefiore-ai/hypothesis
cd hypothesis
pip install -e .

Inference

AALR-MCMC

TODO

Adversarial Variational Optimization

TODO

Amortized ratio estimation

TODO

Approximate Bayesian Computation

TODO

Approximate Bayesian Computation - Sequential Monte Carlo

TODO

Likelihood-free Inference by Ratio Estimation

TODO

Metropolis-Hastings

TODO

Benchmark problems

M/G/1

from hypothesis.benchmark.mg1 import Simulator
from hypothesis.benchmark.mg1 import Prior

simulator = Simulator()
prior = Prior()

inputs = prior.sample((10,)) # Draw 10 samples from the prior.
outputs = simulator(inputs)

Biomolecular docking

✔️ Supports experimental design

from hypothesis.benchmark.biomoleculardocking import Simulator
from hypothesis.benchmark.biomoleculardocking import Prior

simulator = Simulator()
prior = Prior()

inputs = prior.sample((10,)) # Draw 10 samples from the prior.
outputs = simulator(inputs)

from hypothesis.benchmark.biomoleculardocking import PriorExperiment # Experimental design space

prior_experiment = PriorExperiment()
experimental_designs = prior_experiment.sample((10,))

outputs = simulator(inputs, experimental_designs)

Stochastic Death model

✔️ Supports experimental design

from hypothesis.benchmark.death import Simulator
from hypothesis.benchmark.death import Prior

simulator = Simulator()
prior = Prior()

inputs = prior.sample((10,)) # Draw 10 samples from the prior.
outputs = simulator(inputs)

from hypothesis.benchmark.death import PriorExperiment # Experimental design space

prior_experiment = PriorExperiment()
experimental_designs = prior_experiment.sample((10,))

outputs = simulator(inputs, experimental_designs)

Stochastic SIR (Susceptible-Infected-Recovered) model

✔️ Supports experimental design

from hypothesis.benchmark.sir import Simulator
from hypothesis.benchmark.sir import Prior

simulator = Simulator()
prior = Prior()

inputs = prior.sample((10,)) # Draw 10 samples from the prior.
outputs = simulator(inputs)

from hypothesis.benchmark.sir import PriorExperiment # Experimental design space

prior_experiment = PriorExperiment()
experimental_designs = prior_experiment.sample((10,))

outputs = simulator(inputs, experimental_designs)

Stochastic Spatial SIR (Susceptible-Infected-Recovered) model

✔️ Supports experimental design

from hypothesis.benchmark.spatialsir import Simulator
from hypothesis.benchmark.spatialsir import Prior

simulator = Simulator()
prior = Prior()

inputs = prior.sample((10,)) # Draw 10 samples from the prior.
outputs = simulator(inputs)

from hypothesis.benchmark.spatialsir import PriorExperiment # Experimental design space

prior_experiment = PriorExperiment()
experimental_designs = prior_experiment.sample((10,))

outputs = simulator(inputs, experimental_designs)

Tractable

from hypothesis.benchmark.tractable import Simulator
from hypothesis.benchmark.tractable import Prior

simulator = Simulator()
prior = Prior()

inputs = prior.sample((10,)) # Draw 10 samples from the prior.
outputs = simulator(inputs)

Weinberg

✔️ Supports experimental design

from hypothesis.benchmark.weinberg import Simulator
from hypothesis.benchmark.weinberg import Prior

simulator = Simulator()
prior = Prior()

inputs = prior.sample((10,)) # Draw 10 samples from the prior.
outputs = simulator(inputs)

from hypothesis.benchmark.weinberg import PriorExperiment # Experimental design space

prior_experiment = PriorExperiment()
experimental_designs = prior_experiment.sample((10,))

outputs = simulator(inputs, experimental_designs)

License

Hypothesis is BSD-style licensed, as found in the LICENSE file.

About

A Python toolkit for (simulation-based) inference and the mechanization of science.

Topics

Resources

License

Releases

No releases published

Packages

No packages published

Languages