Skip to content

Sensible Defaults #184

@willtebbutt

Description

@willtebbutt

While the example in the README is important in that it exposes all of the useful bits of AdvancedHMC, it would be nice if it were possible to define a couple of sensible defaults. e.g.

vanilla_hmc_sampler = HMC(step_size, n_steps)
reasonably_sensible_nuts_sampler = NUTS(step_size)

I think that this kind of thing would be a helpful addition to the package, as it makes it more straightforward for a new user to get up and running with their first sampler / for an expert to prototype stuff before optimising.

In particular, it would make writing examples for Stheno.jls documentation quite a lot less verbose.

edit:

I think the above would likely tie a sampler and an adapter together. The sampling API would be something like

samples, stats = sample(h, vanilla_hmc_sampler, n_samples_to_draw; progress=true)

and by default it would maybe spend n_samples_to_draw steps burning in / adapting, then draw the samples.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions