Skip to content

Commit

Permalink
Update documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
dustinvtran committed Nov 3, 2017
1 parent 71b1270 commit 2f63603
Show file tree
Hide file tree
Showing 6 changed files with 697 additions and 0 deletions.
8 changes: 8 additions & 0 deletions api/observations.html
Original file line number Diff line number Diff line change
Expand Up @@ -125,11 +125,16 @@ <h2 id="functions">Functions</h2>
<p><a href="./observations/fashion_mnist"><code>fashion_mnist(...)</code></a>: Load the Fashion MNIST data set <span class="citation">(Xiao, Rasul, &amp; Vollgraf, 2017)</span>.</p>
<p><a href="./observations/insteval"><code>insteval(...)</code></a>: Load the InstEval data set <span class="citation">(Bates, Maechler, Bolker, Walker, &amp; others, 2014)</span>.</p>
<p><a href="./observations/iris"><code>iris(...)</code></a>: Load the Iris Plants data set <span class="citation">(Fisher, 1936)</span>.</p>
<p><a href="./observations/jsb_chorales"><code>jsb_chorales(...)</code></a>: Load the corpus of 382 four-part harmonized chorales from J.S. Bach.</p>
<p><a href="./observations/karate"><code>karate(...)</code></a>: Load Zachary's Karate Club <span class="citation">(Zachary, 1977)</span>.</p>
<p><a href="./observations/lsun"><code>lsun(...)</code></a>: Load data set(s) from the Large-Scale Understanding Challenge</p>
<p><a href="./observations/maybe_download_and_extract"><code>maybe_download_and_extract(...)</code></a>: Download file from url unless it already exists in specified directory.</p>
<p><a href="./observations/mnist"><code>mnist(...)</code></a>: Load the MNIST data set <span class="citation">(LeCun, Bottou, Bengio, &amp; Haffner, 1998)</span>.</p>
<p><a href="./observations/multi_mnist"><code>multi_mnist(...)</code></a>: Load the multiple MNIST data set <span class="citation">(Eslami et al., 2016)</span>. It modifies</p>
<p><a href="./observations/musedata"><code>musedata(...)</code></a>: Load the MuseData library of music scores.</p>
<p><a href="./observations/nips"><code>nips(...)</code></a>: Load the NIPS conference papers 1987-2015 data set <span class="citation">(Perrone, Jenkins, Spano, &amp; Teh, 2016)</span>.</p>
<p><a href="./observations/nottingham"><code>nottingham(...)</code></a>: Load the Nottingham database of 1200 British and American folk tunes.</p>
<p><a href="./observations/piano_midi_de"><code>piano_midi_de(...)</code></a>: Load the classical piano archive of piano-midi.de.</p>
<p><a href="./observations/ptb"><code>ptb(...)</code></a>: Load the Penn Treebank data set <span class="citation">(Marcus, Marcinkiewicz, &amp; Santorini, 1993)</span>.</p>
<p><a href="./observations/sick"><code>sick(...)</code></a>: Load the Sentences Involving Compositional Knowledge (SICK) data</p>
<p><a href="./observations/small32_imagenet"><code>small32_imagenet(...)</code></a>: Load the small 32x32 ImageNet data set <span class="citation">(Oord, Kalchbrenner, &amp; Kavukcuoglu, 2016)</span>.</p>
Expand All @@ -152,6 +157,9 @@ <h2 id="other-members">Other Members</h2>
<div id="ref-campbell1974multivariate">
<p>Campbell, N., &amp; Mahon, R. (1974). A multivariate study of variation in two species of rock crab of the genus leptograpsus. <em>Australian Journal of Zoology</em>, <em>22</em>(3), 417–425.</p>
</div>
<div id="ref-eslami2016attend">
<p>Eslami, S. A., Heess, N., Weber, T., Tassa, Y., Szepesvari, D., Hinton, G. E., &amp; others. (2016). Attend, infer, repeat: Fast scene understanding with generative models. In <em>Neural information processing systems</em>.</p>
</div>
<div id="ref-fisher1936use">
<p>Fisher, R. A. (1936). The use of multiple measurements in taxonomic problems. <em>Annals of Human Genetics</em>, <em>7</em>(2), 179–188.</p>
</div>
Expand Down
138 changes: 138 additions & 0 deletions api/observations/jsb_chorales.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,138 @@
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="Content-Style-Type" content="text/css" />
<meta name="generator" content="pandoc" />
<title>Edward – observations.jsb_chorales</title>
<!-- Mobile Specific Metas -->
<meta name="viewport" content="width=device-width, initial-scale=1">

<!-- FONT -->
<link href="https://fonts.googleapis.com/css?family=Lora:400,400i,700" rel="stylesheet">

<!-- CSS -->
<link rel="stylesheet" href="/css/normalize.css">
<link rel="stylesheet" href="/css/skeleton.css">
<!-- Dynamically resize logo for mobile -->
<style type="text/css">
.logo-width {
width: 100%;
box-sizing: border-box;
margin-bottom: 15%;
}
/* Roughly the point when website is single column */
@media (max-width: 850px) {
.logo-width {
width: 50%;
box-sizing: border-box;
margin-bottom: 5%;
}
}
/* Downgrade API's header styles without explicitly modifying their type. */
div.nine.columns h1 { text-align: left; }
div.nine.columns h1 { font-size: 3.0rem; line-height: 1.25; letter-spacing: -.1rem; }
div.nine.columns h2 { font-size: 2.4rem; line-height: 1.3; letter-spacing: -.1rem; }
div.nine.columns h3 { font-size: 2.4rem; line-height: 1.35; letter-spacing: -.08rem; }
div.nine.columns h4 { font-size: 1.8rem; line-height: 1.5; letter-spacing: -.05rem; }
div.nine.columns h5 { font-size: 1.5rem; line-height: 1.6; letter-spacing: 0; }
@media (min-width: 550px) {
div.nine.columns h1 { font-size: 3.6rem; }
div.nine.columns h2 { font-size: 3.0rem; }
div.nine.columns h3 { font-size: 3.0rem; }
div.nine.columns h4 { font-size: 2.5rem; }
div.nine.columns h5 { font-size: 1.5rem; }
}
</style>

<!-- KaTeX -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.7.1/katex.min.js"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.7.1/katex.min.css" />
<script src="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.7.1/contrib/auto-render.min.js"></script>

<!-- highlight.js -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.4.0/highlight.min.js"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.4.0/styles/github.min.css">

<!-- Favicon -->
<link rel="apple-touch-icon" sizes="57x57" href="/icons/apple-touch-icon-57x57.png">
<link rel="apple-touch-icon" sizes="60x60" href="/icons/apple-touch-icon-60x60.png">
<link rel="apple-touch-icon" sizes="72x72" href="/icons/apple-touch-icon-72x72.png">
<link rel="apple-touch-icon" sizes="76x76" href="/icons/apple-touch-icon-76x76.png">
<link rel="apple-touch-icon" sizes="114x114" href="/icons/apple-touch-icon-114x114.png">
<link rel="apple-touch-icon" sizes="120x120" href="/icons/apple-touch-icon-120x120.png">
<link rel="apple-touch-icon" sizes="144x144" href="/icons/apple-touch-icon-144x144.png">
<link rel="apple-touch-icon" sizes="152x152" href="/icons/apple-touch-icon-152x152.png">
<link rel="apple-touch-icon" sizes="180x180" href="/icons/apple-touch-icon-180x180.png">
<link rel="icon" type="image/png" href="/icons/favicon-32x32.png" sizes="32x32">
<link rel="icon" type="image/png" href="/icons/android-chrome-192x192.png" sizes="192x192">
<link rel="icon" type="image/png" href="/icons/favicon-96x96.png" sizes="96x96">
<link rel="icon" type="image/png" href="/icons/favicon-16x16.png" sizes="16x16">
<link rel="manifest" href="/icons/manifest.json">
<link rel="mask-icon" href="/icons/safari-pinned-tab.svg" color="#5bbad5">
<link rel="shortcut icon" href="/icons/favicon.ico">
<meta name="msapplication-TileColor" content="#da532c">
<meta name="msapplication-TileImage" content="/icons/mstile-144x144.png">
<meta name="msapplication-config" content="/icons/browserconfig.xml">
<meta name="theme-color" content="#ffffff">
</head>
<body>
<div class="container">
<div class="row" style="margin-top: 5%">
<div class="three columns">
<h1><a href="/">Edward</a></h1>
<a href="/">
<center>
<img src="/images/edward.png" class="logo-width" alt="Edward" />
</center>
</a>
<a class="button u-full-width" href="/api/">API</a>
<hr style="margin-top: 1rem; margin-bottom: 1.5rem;"/>
<a class="button u-full-width" href="/api/reference">Reference</a>
<a class="button u-full-width" href="/api/ed/criticisms">ed.criticisms</a>
<a class="button u-full-width" href="/api/ed/inferences">ed.inferences</a>
<a class="button u-full-width" href="/api/ed/models">ed.models</a>
<a class="button u-full-width" href="/api/ed/util">ed.util</a>
<a class="button u-full-width" href="/api/observations">observations</a>

<div class="row" style="padding-bottom: 5%"> </div>
<a class="button2 u-pull-right" style="padding-right:10%"
href="https://github.com/blei-lab/edward">
<span style="vertical-align:middle;">Github</span>&nbsp;
<img src="/images/github-mark.svg" style="vertical-align:middle;"
alt="Edward on Github" />
</a>
<div class="row" style="padding-bottom: 5%"> </div>
</div>
<div class="nine columns">

<div itemscope="" itemtype="http://developers.google.com/ReferenceObject">
<meta itemprop="name" content="observations.jsb_chorales" />
</div>
<h1 id="observations.jsb_chorales">observations.jsb_chorales</h1>
<pre class="python"><code>jsb_chorales(path)</code></pre>
<p>Load the corpus of 382 four-part harmonized chorales from J.S. Bach. There are 202 chorales in major keys of which 121 were used for training and 81 used for testing; and 180 chorales in minor keys split as 108 and 72 respectively <span class="citation">(Allan &amp; Williams, 2005)</span>. Data is loaded in the piano-roll representation <span class="citation">(Boulanger-Lewandowski, Bengio, &amp; Vincent, 2012)</span>, i.e., a binary matrix specifying which notes occur at each time step.</p>
<h4 id="args">Args:</h4>
<ul>
<li><b><code>path</code></b>: str. Path to directory which either stores file or otherwise file will be downloaded and extracted there. Filename is <code>JSB%20Chorales.pickle</code>.</li>
</ul>
<h4 id="returns">Returns:</h4>
<p>list of <code>x_train, x_test, x_valid</code>, where each is a list of sequences. Each sequence is itself a list of time steps, and each time step is a list of the non-zero elements in the piano-roll at this instant (in MIDI note numbers, between 21 and 108 inclusive).</p>
<div id="refs" class="references">
<div id="ref-allan2005harmonising">
<p>Allan, M., &amp; Williams, C. (2005). Harmonising chorales by probabilistic inference. In <em>Neural information processing systems</em>.</p>
</div>
<div id="ref-boulanger2012modeling">
<p>Boulanger-Lewandowski, N., Bengio, Y., &amp; Vincent, P. (2012). Modeling temporal dependencies in high-dimensional sequences: Application to polyphonic music generation and transcription. In <em>International conference on machine learning</em>.</p>
</div>
</div>
</div>
</div>
<div class="row" style="padding-bottom: 25%"> </div>
</div>
<script>
hljs.initHighlightingOnLoad();
renderMathInElement(document.body);
</script>
</body>
</html>
143 changes: 143 additions & 0 deletions api/observations/multi_mnist.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,143 @@
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="Content-Style-Type" content="text/css" />
<meta name="generator" content="pandoc" />
<title>Edward – observations.multi_mnist</title>
<!-- Mobile Specific Metas -->
<meta name="viewport" content="width=device-width, initial-scale=1">

<!-- FONT -->
<link href="https://fonts.googleapis.com/css?family=Lora:400,400i,700" rel="stylesheet">

<!-- CSS -->
<link rel="stylesheet" href="/css/normalize.css">
<link rel="stylesheet" href="/css/skeleton.css">
<!-- Dynamically resize logo for mobile -->
<style type="text/css">
.logo-width {
width: 100%;
box-sizing: border-box;
margin-bottom: 15%;
}
/* Roughly the point when website is single column */
@media (max-width: 850px) {
.logo-width {
width: 50%;
box-sizing: border-box;
margin-bottom: 5%;
}
}
/* Downgrade API's header styles without explicitly modifying their type. */
div.nine.columns h1 { text-align: left; }
div.nine.columns h1 { font-size: 3.0rem; line-height: 1.25; letter-spacing: -.1rem; }
div.nine.columns h2 { font-size: 2.4rem; line-height: 1.3; letter-spacing: -.1rem; }
div.nine.columns h3 { font-size: 2.4rem; line-height: 1.35; letter-spacing: -.08rem; }
div.nine.columns h4 { font-size: 1.8rem; line-height: 1.5; letter-spacing: -.05rem; }
div.nine.columns h5 { font-size: 1.5rem; line-height: 1.6; letter-spacing: 0; }
@media (min-width: 550px) {
div.nine.columns h1 { font-size: 3.6rem; }
div.nine.columns h2 { font-size: 3.0rem; }
div.nine.columns h3 { font-size: 3.0rem; }
div.nine.columns h4 { font-size: 2.5rem; }
div.nine.columns h5 { font-size: 1.5rem; }
}
</style>

<!-- KaTeX -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.7.1/katex.min.js"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.7.1/katex.min.css" />
<script src="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.7.1/contrib/auto-render.min.js"></script>

<!-- highlight.js -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.4.0/highlight.min.js"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.4.0/styles/github.min.css">

<!-- Favicon -->
<link rel="apple-touch-icon" sizes="57x57" href="/icons/apple-touch-icon-57x57.png">
<link rel="apple-touch-icon" sizes="60x60" href="/icons/apple-touch-icon-60x60.png">
<link rel="apple-touch-icon" sizes="72x72" href="/icons/apple-touch-icon-72x72.png">
<link rel="apple-touch-icon" sizes="76x76" href="/icons/apple-touch-icon-76x76.png">
<link rel="apple-touch-icon" sizes="114x114" href="/icons/apple-touch-icon-114x114.png">
<link rel="apple-touch-icon" sizes="120x120" href="/icons/apple-touch-icon-120x120.png">
<link rel="apple-touch-icon" sizes="144x144" href="/icons/apple-touch-icon-144x144.png">
<link rel="apple-touch-icon" sizes="152x152" href="/icons/apple-touch-icon-152x152.png">
<link rel="apple-touch-icon" sizes="180x180" href="/icons/apple-touch-icon-180x180.png">
<link rel="icon" type="image/png" href="/icons/favicon-32x32.png" sizes="32x32">
<link rel="icon" type="image/png" href="/icons/android-chrome-192x192.png" sizes="192x192">
<link rel="icon" type="image/png" href="/icons/favicon-96x96.png" sizes="96x96">
<link rel="icon" type="image/png" href="/icons/favicon-16x16.png" sizes="16x16">
<link rel="manifest" href="/icons/manifest.json">
<link rel="mask-icon" href="/icons/safari-pinned-tab.svg" color="#5bbad5">
<link rel="shortcut icon" href="/icons/favicon.ico">
<meta name="msapplication-TileColor" content="#da532c">
<meta name="msapplication-TileImage" content="/icons/mstile-144x144.png">
<meta name="msapplication-config" content="/icons/browserconfig.xml">
<meta name="theme-color" content="#ffffff">
</head>
<body>
<div class="container">
<div class="row" style="margin-top: 5%">
<div class="three columns">
<h1><a href="/">Edward</a></h1>
<a href="/">
<center>
<img src="/images/edward.png" class="logo-width" alt="Edward" />
</center>
</a>
<a class="button u-full-width" href="/api/">API</a>
<hr style="margin-top: 1rem; margin-bottom: 1.5rem;"/>
<a class="button u-full-width" href="/api/reference">Reference</a>
<a class="button u-full-width" href="/api/ed/criticisms">ed.criticisms</a>
<a class="button u-full-width" href="/api/ed/inferences">ed.inferences</a>
<a class="button u-full-width" href="/api/ed/models">ed.models</a>
<a class="button u-full-width" href="/api/ed/util">ed.util</a>
<a class="button u-full-width" href="/api/observations">observations</a>

<div class="row" style="padding-bottom: 5%"> </div>
<a class="button2 u-pull-right" style="padding-right:10%"
href="https://github.com/blei-lab/edward">
<span style="vertical-align:middle;">Github</span>&nbsp;
<img src="/images/github-mark.svg" style="vertical-align:middle;"
alt="Edward on Github" />
</a>
<div class="row" style="padding-bottom: 5%"> </div>
</div>
<div class="nine columns">

<div itemscope="" itemtype="http://developers.google.com/ReferenceObject">
<meta itemprop="name" content="observations.multi_mnist" />
</div>
<h1 id="observations.multi_mnist">observations.multi_mnist</h1>
<pre class="python"><code>multi_mnist(
path,
max_digits=2,
canvas_size=50,
seed=42
)</code></pre>
<p>Load the multiple MNIST data set <span class="citation">(Eslami et al., 2016)</span>. It modifies the original MNIST such that each image contains a number of non-overlapping random MNIST digits with equal probability.</p>
<h4 id="args">Args:</h4>
<ul>
<li><b><code>path</code></b>: str. Path to directory which either stores file or otherwise file will be downloaded and extracted there. Filename is <code>'multi_mnist_{}_{}_{}.npz'.format(max_digits, canvas_size, seed)</code>.</li>
<li><b><code>max_digits</code></b>: int, optional. Maximum number of non-overlapping MNIST digits per image to generate if not cached.</li>
<li><b><code>canvas_size</code></b>: list of two int, optional. Width x height pixel size of generated images if not cached.</li>
<li><b><code>seed</code></b>: int, optional. Random seed to generate the data set from MNIST if not cached.</li>
</ul>
<h4 id="returns">Returns:</h4>
<p>Tuple of (np.ndarray of dtype uint8, list) <code>(x_train, y_train), (x_test, y_test)</code>. Each element in the y's is a np.ndarray of labels, one label for each digit in the image.</p>
<div id="refs" class="references">
<div id="ref-eslami2016attend">
<p>Eslami, S. A., Heess, N., Weber, T., Tassa, Y., Szepesvari, D., Hinton, G. E., &amp; others. (2016). Attend, infer, repeat: Fast scene understanding with generative models. In <em>Neural information processing systems</em>.</p>
</div>
</div>
</div>
</div>
<div class="row" style="padding-bottom: 25%"> </div>
</div>
<script>
hljs.initHighlightingOnLoad();
renderMathInElement(document.body);
</script>
</body>
</html>
Loading

0 comments on commit 2f63603

Please sign in to comment.