https://github.com/GPflow/GPflow
Revision db383233eaf595a04b4eafc9872845e66ba54634 authored by Mark van der Wilk on 23 November 2016, 18:31:25 UTC, committed by James Hensman on 23 November 2016, 18:31:25 UTC
This squash-commit contains a large volume of work by @markvdw and @alexisboukouvalas. I'm keeping all of the commit history here for posterity. Interested viewers can see some discussion on github, under pull request #195.

* Initial code for new kernel expectations.
- RBF done.
- Added another transformation in etransforms.py.

* first step to merge gplvm and kernexp approaches

* Added kernel expectations of linear, and eKxz for RBF.
- NB: Linear still need to be tested better.
- Todo: exKxz for linear.

* Added multidimensional quadrature in `Kern` base class for kernel expectations.
- Replaced monte carlo tests with more reliable quadrature tests.
- Added exKxz for `Linear` kernel

* testing new ekernels code, starting on active dimensions, further testing needed as well as modifying Bayesian GPLVM code

* Linear and Polynomial kernels did not respect active_dims properly in Kdiag.
- Added slice call to Linear.Kdiag
- Fixed TestSlice to test more kernels.
- Fxied TestSlice to have the correct inputdim.

* Begin work on sum kernel, smoothing out active_dims for ekernels.

* Fixed `input_dim` in `test_kerns.py`. Added assertion.

* kernexp quadrature now works with `active_dims`.
- exKzx which doesn't work now raises an error from TensorFlow.
- Various other assertions.

* Better deduction of `input_dim` for `kernels.Combination`.

* Small fix of test.

* Fixed issue of KzxKxz in Add kernel. Solution checks for diagonal q(X) and performs quadrature on the covariance of KzxKxz if not diagonal.

* GPLVM now works with new kernel expectation code.
- Added a new DiagMatrix transform.
- Removed legacy code.
- Modified GPLVM to accept full covariance matrices.

* Fixing a small error in DiagMatrix transform.

* Added warnings.

* Removed etransforms code. BlockTriDiagonalTransform is now only used in tests.

* Prevent `TridiagonalBlockRep` from being tested as a `Transform`.

* improvements to DiagonalMatrix transform

* improved testing of kernel slice

* update test to use kernels

* `ekernels.RBF` ARD bug fixed.

* Increased test coverage.

* Increased test coverage.

* docstring for gplvm, removed unused variable in ekernels

* testing composite kernels in gplvm

* Added Prod to `ekernels.py`.

* Fixed usage of `tf.gather_nd`, which does not have a gradient in `_slice_cov()`.

* add GPLVM notebook, increase testing to include Prod kernels, add documentation stub, fix bibliography

* improve GPLVM notebook with working example

* Fixed bug that `X_var` in `BayesianGPLVM` gets slightly different values.

* Quadrature can be switched off, plus the appropriate checks.

* Kernel expectations now accept 2D variances.

* Fix to test.

* Reworked quadrature code in Add in anticipation of adding exact expectations for certain pairs of kernels.

* Added Linear + Add cross terms for overlapping active_dims.

* Initial try for extra test for `ekernels.Add` cross terms.

* `_slice_cov` now again compatible with numpy arrays.


* Requested code reviews.
1 parent 419c43b
Raw File
Tip revision: db383233eaf595a04b4eafc9872845e66ba54634 authored by Mark van der Wilk on 23 November 2016, 18:31:25 UTC
Kernel expectations (#195)
Tip revision: db38323
README.md
# GPflow

GPflow is a package for building Gaussian process models in python, using [TensorFlow](http://www.tensorflow.org). It was originally created and is now managed by [James Hensman](http://www.lancaster.ac.uk/staff/hensmanj/) and [Alexander G. de G. Matthews](http://mlg.eng.cam.ac.uk/?portfolio=alex-matthews). 
The full list of [contributors](http://github.com/GPflow/GPflow/graphs/contributors) (in alphabetical order) is Alexis Boukouvalas, Ivo Couckuyt, Keisuke Fujii, Zoubin Ghahramani, David J. Harris, James Hensman, Pablo Leon-Villagra, Daniel Marthaler, Alexander G. de G. Matthews, Tom Nickson, Valentine Svensson and Mark van der Wilk. GPflow is an open source project so if you feel you have some relevant skills and are interested in contributing then please do contact us.  

[![Python2.7 status](https://codeship.com/projects/26b43920-e96e-0133-3481-02cde9680eda/status?branch=master)](https://codeship.com/projects/147609)
[![Python3.5 Status](https://travis-ci.org/GPflow/GPflow.svg?branch=master)](https://travis-ci.org/GPflow/GPflow)
[![Coverage Status](http://codecov.io/github/GPflow/GPflow/coverage.svg?branch=master)](http://codecov.io/github/GPflow/GPflow?branch=master)
[![Documentation Status](https://readthedocs.org/projects/gpflow/badge/?version=latest)](http://gpflow.readthedocs.io/en/latest/?badge=latest)

# What does GPflow do?

GPflow implements modern Gaussian process inference for composable kernels and likelihoods. The [online user manual](http://gpflow.readthedocs.io/en/latest/) contains more details. The interface follows on from [GPy](http://github.com/sheffieldml/gpy), for more discussion of the comparison see [this page](http://gpflow.readthedocs.io/en/latest/intro.html#what-s-the-difference-between-gpy-and-gpflow).

# Install

## 1) Install TensorFlow. 
Please see instructions on the main TensorFlow [webpage](https://www.tensorflow.org/versions/r0.11/get_started/os_setup.html#download-and-setup). You will need version 0.11. We find that for most users pip installation is the fastest way to get going.

## 2) install package
GPflow includes some tensorflow extensions that are compiled when you run setup.py.  For those interested in modifying the source of GPflow, we recommend  
```
python setup.py develop
```
but installation should work well too:
```
python setup.py install
```
You can run the tests with `python setup.py test`.


# Citing GPflow

To cite GPflow, please reference the [Technical report](https://arxiv.org/abs/1610.08733). Sample Bibtex is given below:

```
@ARTICLE{GPflow2016,
   author = {Matthews, Alexander G. de G. and {van der Wilk}, Mark and Nickson, Tom and 
	Fujii, Keisuke. and {Boukouvalas}, Alexis and {Le{\'o}n-Villagr{\'a}}, Pablo and 
	Ghahramani, Zoubin and Hensman, James},
    title = "{{GP}flow: A {G}aussian process library using {T}ensor{F}low}",
  journal = {arXiv preprint 1610.08733},
     year = 2016,
    month = oct
}
```
back to top