Giter VIP home page Giter VIP logo

djsutherland / opt-mmd Goto Github PK

View Code? Open in Web Editor NEW
206.0 13.0 73.0 100 KB

Learning kernels to maximize the power of MMD tests

Home Page: https://arxiv.org/abs/1611.04488

License: BSD 3-Clause "New" or "Revised" License

Python 72.60% Jupyter Notebook 26.74% Shell 0.65%
machine-learning hypothesis-testing generative-adversarial-network maximum-mean-discrepancy shogun theano tensorflow python kernel-methods statistical-tests

opt-mmd's Issues

Missing coefficient for cross term in MMD

Apologies if I'm missing something obvious, but the estimate defined in equation (3) of https://www.jmlr.org/papers/volume13/gretton12a/gretton12a.pdf looks slightly different to the MMD estimate implemented here.

The first term makes sense to me, and subtracting m accounts for the summation over i != j (since diagonal of RBF kernel will add to m). Likewise for second term.
However the third term seems to be missing a factor 1 / (m*n).

m = K_XX.shape[0]
n = K_YY.shape[0]
mmd2 = ((K_XX.sum() - m) / (m * (m - 1))
+ (K_YY.sum() - n) / (n * (n - 1))
- 2 * K_XY.mean())

Is this implementation intended to match the estimate linked above?

Cheers

tmmd not maximizing the test power

Hi,
Thanks for sharing. In the tmmd_model.py file, the optimizer seems just trys to minimize the ratio-loss, which should be the approximated test power mentioned in the paper. Shouldn't we increase the test power? I can't find any "-" there. Do I miss anything?

Python package tables is required but not automatically installed

Issue: python package tables is required by pandas, but not automatically installed.

How to reproduce:

python fixed_run.py -n 500 --blobs 1

Error message:

HDFStore requires PyTables, "No module named tables" problem importing

Fix:
pip install tables fixed the problem for me.
Add requirement tables to requirements.txt

System:
MacOS 10.11., python 2.7.12

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.