• Stars
    star
    1,544
  • Rank 30,296 (Top 0.6 %)
  • Language
    Python
  • License
    Other
  • Created over 10 years ago
  • Updated almost 5 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Spearmint Bayesian optimization codebase

Spearmint

Spearmint is a software package to perform Bayesian optimization. The Software is designed to automatically run experiments (thus the code name spearmint) in a manner that iteratively adjusts a number of parameters so as to minimize some objective in as few runs as possible.

IMPORTANT: Spearmint is under an Academic and Non-Commercial Research Use License. Before using spearmint please be aware of the license. If you do not qualify to use spearmint you can ask to obtain a license as detailed in the license or you can use the older open source code version (which is somewhat outdated) at https://github.com/JasperSnoek/spearmint.

Relevant Publications

Spearmint implements a combination of the algorithms detailed in the following publications:

Practical Bayesian Optimization of Machine Learning Algorithms  
Jasper Snoek, Hugo Larochelle and Ryan Prescott Adams  
Advances in Neural Information Processing Systems, 2012  

Multi-Task Bayesian Optimization  
Kevin Swersky, Jasper Snoek and Ryan Prescott Adams  
Advances in Neural Information Processing Systems, 2013  

Input Warping for Bayesian Optimization of Non-stationary Functions  
Jasper Snoek, Kevin Swersky, Richard Zemel and Ryan Prescott Adams  
International Conference on Machine Learning, 2014  

Bayesian Optimization and Semiparametric Models with Applications to Assistive Technology  
Jasper Snoek, PhD Thesis, University of Toronto, 2013  

Bayesian Optimization with Unknown Constraints
Michael Gelbart, Jasper Snoek and Ryan Prescott Adams
Uncertainty in Artificial Intelligence, 2014

Setting up Spearmint

STEP 1: Installation

  1. Install python, numpy, scipy, pymongo. For academic users, the anaconda distribution is great. Use numpy 1.8 or higher. We use python 2.7.
  2. Download/clone the spearmint code
  3. Install the spearmint package using pip: pip install -e \</path/to/spearmint/root\> (the -e means changes will be reflected automatically)
  4. Download and install MongoDB: https://www.mongodb.org/
  5. Install the pymongo package using e.g., pip pip install pymongo or anaconda conda install pymongo

STEP 2: Setting up your experiment

  1. Create a callable objective function. See ./examples/simple/branin.py as an example
  2. Create a config file. There are 3 example config files in the ../examples directory. Note 1: There are more parameters that can be set in the config files than what is shown in the examples, but these parameters all have default values. Note 2: By default Spearmint assumes your function is noisy (non-deterministic). If it is noise-free, you should set this explicitly as in the ../examples/simple/config.json file.

STEP 3: Running spearmint

  1. Start up a MongoDB daemon instance:
    mongod --fork --logpath <path/to/logfile\> --dbpath <path/to/dbfolder\>
  2. Run spearmint: python main.py \</path/to/experiment/directory\>

STEP 4: Looking at your results
Spearmint will output results to standard out / standard err. You can also load the results from the database and manipulate them directly.

More Repositories

1

autograd

Efficiently computes derivatives of NumPy code.
Python
6,959
star
2

neural-fingerprint

Convolutional nets which can take molecular graphs of arbitrary size as input.
TeX
494
star
3

hypergrad

Exploring differentiation with respect to hyperparameters
Python
296
star
4

Kayak

Kayak is a library for automatic differentiation with applications to deep neural networks.
Python
227
star
5

Probabilistic-Backpropagation

Implementation in C and Theano of the method Probabilistic Backpropagation for scalable Bayesian inference in deep neural networks.
C
191
star
6

molecule-autoencoder

A project to enable optimization of molecules by transforming them to and from a continuous representation.
Python
154
star
7

pgmult

Dependent multinomials made easy: stick-breaking with the Pรณlya-gamma augmentation
Python
60
star
8

hips-lib

Library of common tools for machine learning research.
Python
40
star
9

author-roulette

LaTeX package for randomizing author order based on a public seed.
TeX
39
star
10

firefly-monte-carlo

Implementation of an algorithm for Markov chain Monte Carlo with data subsampling
Python
31
star
11

maxwells-daemon

Fastidious accounting of entropy streams into and out of optimization and sampling algorithms.
TeX
31
star
12

DESI-MCMC

MCMC for the Dark Energy Spectroscopic Instrument
Jupyter Notebook
13
star
13

BayesianStructuredSparsity

Code for performing Bayesian regression with structured sparsity from a Gaussian field.
8
star
14

autopaint

Gradient-based variational autoencoders to generate class-conditional natural images.
Python
6
star
15

gpu_numpy

A Numpy wrapper that adds a gpufloat32 dtype to Numpy.
Python
6
star
16

trusty_scribe_viewer

Website for viewing a git repo as a lab notebook. Figures and text files can be included with markdown-like syntax.
Python
4
star
17

optofit

A python framework for fitting biophysical models to optically recorded neural signals.
Python
4
star
18

lpickle

Linefeed-delimited pickle for Unix-style piping of arbitrary Python data
Python
2
star
19

Matrical

A simple abstraction layer for matrix computations in Python, making it easy to switch between CPU and NVIDIA or Intel coprocessors.
2
star