Permalink
Browse files

Fix doc generation script.

  • Loading branch information...
1 parent 1daaf64 commit 500a7ef12b0ca20c7b8c1455a25d30b52c1f0e5a @eightysteele eightysteele committed Jul 22, 2012
Showing with 1,743 additions and 8 deletions.
  1. +0 −2 .gitignore
  2. +168 −0 doc/css/default.css
  3. +127 −0 doc/forma.classify.logistic.html
  4. +53 −0 doc/forma.date-time.html
  5. +14 −0 doc/forma.gfw.cdm.html
  6. +3 −0 doc/forma.hadoop.cli.html
  7. +15 −0 doc/forma.hadoop.io.html
  8. +30 −0 doc/forma.hadoop.jobs.cdm.html
  9. +32 −0 doc/forma.hadoop.jobs.forma.html
  10. +7 −0 doc/forma.hadoop.jobs.modis.html
  11. +34 −0 doc/forma.hadoop.jobs.neighbors.html
  12. +9 −0 doc/forma.hadoop.jobs.preprocess.html
  13. +6 −0 doc/forma.hadoop.jobs.scatter.html
  14. +18 −0 doc/forma.hadoop.jobs.timeseries.html
  15. +5 −0 doc/forma.hadoop.pail.html
  16. +64 −0 doc/forma.hadoop.predicate.html
  17. +19 −0 doc/forma.hoptree.html
  18. +84 −0 doc/forma.matrix.utils.html
  19. +46 −0 doc/forma.matrix.walk.html
  20. +10 −0 doc/forma.ops.classify.html
  21. +4 −0 doc/forma.playground.html
  22. +48 −0 doc/forma.postprocess.output.html
  23. +98 −0 doc/forma.reproject.html
  24. +45 −0 doc/forma.schema.html
  25. +124 −0 doc/forma.source.fire.html
  26. +7 −0 doc/forma.source.gadmiso.html
  27. +33 −0 doc/forma.source.hdf.html
  28. +68 −0 doc/forma.source.rain.html
  29. +31 −0 doc/forma.source.static.html
  30. +7 −0 doc/forma.source.tilesets.html
  31. +53 −0 doc/forma.static.html
  32. +20 −0 doc/forma.testing.html
  33. +52 −0 doc/forma.thrift.html
  34. +86 −0 doc/forma.trends.analysis.html
  35. +88 −0 doc/forma.trends.filter.html
  36. +11 −0 doc/forma.trends.stretch.html
  37. +38 −0 doc/forma.utils.html
  38. +111 −0 doc/index.html
  39. +4 −0 doc/js/jquery.min.js
  40. +64 −0 doc/js/page_effects.js
  41. +7 −6 tools/gendoc.sh
View
2 .gitignore
@@ -7,14 +7,12 @@ native
logs/
classes
docs
-doc
autodoc
.#*
*#*
.classpath
.settings/
.project
-doc/
.lein-deps-sum
.DS_Store
.repl
View
168 doc/css/default.css
@@ -0,0 +1,168 @@
+body {
+ font-family: sans-serif;
+ font-size: 11pt;
+}
+
+pre, code {
+ font-family: Monaco, DejaVu Sans Mono, Consolas, monospace;
+ font-size: 9pt;
+}
+
+h2 {
+ font-weight: normal;
+ font-size: 18pt;
+ margin: 10px 0 0.4em 0;
+}
+
+#header, #content, .sidebar {
+ position: fixed;
+}
+
+#header {
+ top: 0;
+ left: 0;
+ right: 0;
+ height: 20px;
+ background: #444;
+ color: #fff;
+ padding: 5px;
+}
+
+#content {
+ top: 30px;
+ right: 0;
+ bottom: 0;
+ overflow: auto;
+ background: #fff;
+ color: #333;
+ padding: 0 1em;
+}
+
+.sidebar {
+ position: fixed;
+ top: 30px;
+ bottom: 0;
+ overflow: auto;
+}
+
+#namespaces {
+ background: #e6e6e6;
+ border-right: solid 1px #bbb;
+ left: 0;
+ width: 250px;
+}
+
+#vars {
+ background: #eeeeee;
+ border-right: solid 1px #ccc;
+ left: 251px;
+ width: 200px;
+}
+
+.namespace-index {
+ left: 251px;
+}
+
+.namespace-docs {
+ left: 452px;
+}
+
+#header {
+ background: -moz-linear-gradient(top, #555 0%, #222 100%);
+ background: -webkit-linear-gradient(top, #555 0%, #333 100%);
+ background: -o-linear-gradient(top, #555 0%, #222 100%);
+ background: -ms-linear-gradient(top, #555 0%, #222 100%);
+ background: linear-gradient(top, #555 0%, #222 100%);
+ box-shadow: 0 0 10px #555;
+ z-index: 100;
+}
+
+#header h1 {
+ margin: 0;
+ padding: 0;
+ font-size: 12pt;
+ font-weight: normal;
+ text-shadow: -1px -1px 0px #333;
+}
+
+#header a, .sidebar a {
+ display: block;
+ color: #333;
+ text-decoration: none;
+}
+
+#header a {
+ color: #fff;
+}
+
+.sidebar a {
+ color: #333;
+}
+
+.sidebar h3 {
+ margin: 0;
+ padding: 10px 0.5em 0 0.5em;
+ font-size: 14pt;
+ font-weight: normal
+}
+
+.sidebar ul {
+ padding: 0.5em 0em;
+ margin: 0;
+}
+
+.sidebar li {
+ display: block;
+}
+
+.sidebar li a {
+ padding: 0.5em 0.8em;
+}
+
+#namespaces li.current a {
+ border-left: 0.3em solid #a33;
+ padding-left: 0.5em;
+ color: #a33;
+}
+
+#vars li.current a {
+ border-left: 0.3em solid #33a;
+ padding-left: 0.5em;
+ color: #33a;
+}
+
+#content h3 {
+ margin-bottom: 0.5em;
+ font-size: 13pt;
+ font-weight: bold;
+}
+
+.public {
+ margin-top: 1.5em;
+ margin-bottom: 2.0em;
+}
+
+.public:last-child {
+ margin-bottom: 20%;
+}
+
+.index {
+ padding: 0;
+}
+
+.index * {
+ display: inline;
+}
+
+.index li {
+ padding: 0 .5em;
+}
+
+.index ul {
+ padding-left: 0;
+}
+
+.usage code {
+ display: block;
+ color: #008;
+}
View
127 doc/forma.classify.logistic.html
@@ -0,0 +1,127 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.classify.logistic documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li class="current"><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.classify.logistic.html#var-bernoulli-var"><span>bernoulli-var</span></a></li><li><a href="forma.classify.logistic.html#var-beta-increment"><span>beta-increment</span></a></li><li><a href="forma.classify.logistic.html#var-beta-update"><span>beta-update</span></a></li><li><a href="forma.classify.logistic.html#var-info-matrix"><span>info-matrix</span></a></li><li><a href="forma.classify.logistic.html#var-initial-beta"><span>initial-beta</span></a></li><li><a href="forma.classify.logistic.html#var-log-likelihood"><span>log-likelihood</span></a></li><li><a href="forma.classify.logistic.html#var-logistic-beta-vector"><span>logistic-beta-vector</span></a></li><li><a href="forma.classify.logistic.html#var-logistic-fn"><span>logistic-fn</span></a></li><li><a href="forma.classify.logistic.html#var-logistic-prob"><span>logistic-prob</span></a></li><li><a href="forma.classify.logistic.html#var-probability-calc"><span>probability-calc</span></a></li><li><a href="forma.classify.logistic.html#var-ridge-correction"><span>ridge-correction</span></a></li><li><a href="forma.classify.logistic.html#var-score-seq"><span>score-seq</span></a></li><li><a href="forma.classify.logistic.html#var-to-double-matrix"><span>to-double-matrix</span></a></li><li><a href="forma.classify.logistic.html#var-to-double-rowmat"><span>to-double-rowmat</span></a></li><li><a href="forma.classify.logistic.html#var-total-log-likelihood"><span>total-log-likelihood</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.classify.logistic documentation</h2><pre class="doc"></pre><div class="public" id="var-bernoulli-var"><h3>bernoulli-var</h3><div class="usage"><code>(bernoulli-var row-prob)</code></div><pre class="doc">returns the variance of a bernoulli random variable, given a row
+matrix of probabilities `row-prob`. Both arguments and return
+values are DoubleMatrix instances.
+
+Example:
+ (def row-prob (to-double-rowmat [0.5 0.5]))
+ (bernoulli-var row-prob) =&gt; #&lt;DoubleMatrix [0.25, 0.25]&gt;
+
+Reference:
+ http://en.wikipedia.org/wiki/Bernoulli_distribution</pre></div><div class="public" id="var-beta-increment"><h3>beta-increment</h3><div class="usage"><code>(beta-increment info-mat scores rdg-cons)</code></div><pre class="doc">returns a DoubleMatrix row vector to increment the parameter
+vector, based on the information matrix. The increment does not
+include a correction for the addition of a ridge factor.
+
+Example:
+ (def beta (to-double-rowmat [0 0]))
+ (def feat (to-double-matrix [[1 2] [4 5]]))
+ (def label (to-double-rowmat [1 0]))
+ (def score (score-seq beta label feat))
+ (def info (info-matrix beta feat))
+ (beta-increment info score 1e-2)
+ =&gt; #&lt;DoubleMatrix [-3.8961038961039076; 2.7449822904368464]&gt;
+
+NOTE: cannot refactor DoubleMatrix/eye since it changes in memory,
+i.e., jBLAS objects don't behave like clojure data structures</pre></div><div class="public" id="var-beta-update"><h3>beta-update</h3><div class="usage"><code>(beta-update beta-row label-row feature-mat rdg-cons)</code></div><pre class="doc">returns a beta update, including the ridge correction
+</pre></div><div class="public" id="var-info-matrix"><h3>info-matrix</h3><div class="usage"><code>(info-matrix beta-row feature-mat)</code></div><pre class="doc">returns the (symmetric) information matrix at the current iteration
+of the scoring algorithm (specifically the Newton-Raphson method.
+
+Example:
+ (def beta (to-double-rowmat [0 0]))
+ (def feat (to-double-matrix [[1 2] [4 5]]))
+ (info-matrix beta feat) =&gt; #&lt;DoubleMatrix [4.25, 5.5; 5.5, 7.25]&gt;
+
+Reference:
+ http://en.wikipedia.org/wiki/Scoring_algorithm
+ http://en.wikipedia.org/wiki/Fisher_information</pre></div><div class="public" id="var-initial-beta"><h3>initial-beta</h3><div class="usage"><code>(initial-beta feature-mat)</code></div><pre class="doc">returns a vector of intial weights; this can be changed to reflect
+the method of moments estimator as a starting point, but for now it
+is fine to assume no knowledge about the betas. The probabilities
+start a 0.5 and are pushed to the 0 and 1 extremes as the likelihood
+function is maximized.</pre></div><div class="public" id="var-log-likelihood"><h3>log-likelihood</h3><div class="usage"><code>(log-likelihood beta-seq label feature-seq)</code></div><pre class="doc">returns the log likelihood of a given pixel, conditional on its
+label (0-1) and the probability of label equal to 1.</pre></div><div class="public" id="var-logistic-beta-vector"><h3>logistic-beta-vector</h3><div class="usage"><code>(logistic-beta-vector label-row feature-mat rdg-cons converge-threshold max-iter)</code></div><pre class="doc">return the estimated parameter vector (persistent vector); which is
+used, in turn, to calculate the estimated probability of the binary
+label. The beta vector is based on the training labels and
+associated features collected in the feature matrix. The output can
+be applied to new features using `probability-calc` in this
+namespace.
+
+Example:
+ (def feat (to-double-matrix [[1 2] [4 5]]))
+ (def label (to-double-rowmat [1 0]))
+ (logistic-beta-vector label feat 1e-8 1e-6 250)
+ =&gt; [-49.06118492894668 34.891861487354284]
+
+NOTES: the initial beta-diff value is an arbitrarily large value.</pre></div><div class="public" id="var-logistic-fn"><h3>logistic-fn</h3><div class="usage"><code>(logistic-fn x)</code></div><pre class="doc">returns the value of the logistic curve at supplied `x` value;
+output is a DoubleMatrix (org.jblas.DoubleMatrix).
+
+Argument:
+ DoubleMatrix instance (org.jblas.DoubleMatrix) with only one
+ value
+
+Example:
+ (logistic-fn (to-double-rowmat [0])) =&gt; #&lt;DoubleMatrix [0.5]&gt;
+
+Reference:
+ http://en.wikipedia.org/wiki/Logistic_function</pre></div><div class="public" id="var-logistic-prob"><h3>logistic-prob</h3><div class="usage"><code>(logistic-prob beta-rowmat features-rowmat)</code></div><pre class="doc">returns the DoubleMatrix value of the logistic curve at the value
+given by the dot product of the parameter vector and the feature
+vector. Both arguments and return values are DoubleMatrix instances.
+
+Arguments:
+ beta-rowmat: DoubleMatrix row vector
+ features-rowmat: DoubleMatrix row vector, of equal length as
+ beta-rowmat
+
+Example:
+ (def beta (to-double-rowmat [0 0]))
+ (def features (to-double-rowmat [1 2]))
+ (logistic-prob beta features) =&gt; #&lt;DoubleMatrix [0.5]&gt;</pre></div><div class="public" id="var-probability-calc"><h3>probability-calc</h3><div class="usage"><code>(probability-calc beta-rowmat feature-mat)</code></div><pre class="doc">returns a DoubleMatrix row vector of probabilities given by the
+in-place dot product (read: matrix multiplication) of the beta
+vector and the feature vectors collected in the feature matrix. Both
+arguments and return values are DoubleMatrix instances.
+
+Example:
+ (def beta (to-double-rowmat [0 0]))
+ (def feat (to-double-matrix [[1 2] [4 5]]))
+ (probability-calc beta feat) =&gt; #&lt;DoubleMatrix [0.5, 0.5]&gt;</pre></div><div class="public" id="var-ridge-correction"><h3>ridge-correction</h3><div class="usage"><code>(ridge-correction info-mat scores rdg-cons)</code></div><pre class="doc">returns a vector of corrections to the beta-update, given the
+current iteration of the information matrix and score sequence.
+
+NOTES: The vector a is analogous to f(rdg_cons) = a*rdg_cons + b,
+and we are interested in the correction factor that is calculated as
+follows: Let v = rdg_cons. Then we originally assume that f(0) =
+f(v) [equivalent to no added constant along the diagnol], which may
+not be correct. A better approximation is f(0) - b, where b = f(v)
+- a*v. Then, correction = f(0) - b = f(v) - f(v) + a*v = a*v.</pre></div><div class="public" id="var-score-seq"><h3>score-seq</h3><div class="usage"><code>(score-seq beta labels feature-mat)</code></div><pre class="doc">returns the score for each parameter at the current iteration,
+based on the estimated probabilities and the true labels. Both
+arguments and return values are DoubleMatrix instances.
+
+Example:
+ (def beta (to-double-rowmat [0 0]))
+ (def feat (to-double-matrix [[1 2] [4 5]]))
+ (def label (to-double-rowmat [1 0]))
+ (score-seq beta label feat) =&gt; #&lt;DoubleMatrix [-1.5; -1.5]&gt;
+
+Reference:
+ http://en.wikipedia.org/wiki/Scoring_algorithm</pre></div><div class="public" id="var-to-double-matrix"><h3>to-double-matrix</h3><div class="usage"><code>(to-double-matrix mat)</code></div><pre class="doc">converts a clojure matrix representation to a DoubleMatrix instance
+for use with jBLAS functions
+
+Argument:
+ vector of vectors; clojure representation of a matrix
+
+Example:
+ (to-double-matrix [0]) =&gt; #&lt;DoubleMatrix []&gt;
+ (to-double-matrix [[0]]) =&gt; #&lt;DoubleMatrix [0.0]&gt;
+ (to-double-matrix [[0] [1]]) =&gt; #&lt;DoubleMatrix [0.0; 1.0]&gt;
+
+Reference:
+ http://jblas.org/javadoc/org/jblas/DoubleMatrix.html</pre></div><div class="public" id="var-to-double-rowmat"><h3>to-double-rowmat</h3><div class="usage"><code>(to-double-rowmat coll)</code></div><pre class="doc">converts a clojure vector to a DoubleMatrix row vector
+
+Argument:
+ persistent vector
+
+Example:
+ (to-double-rowmat [1 2 3]) =&gt; #&lt;DoubleMatrix [1.0, 2.0, 3.0]&gt;
+
+Reference:
+ http://jblas.org/javadoc/org/jblas/DoubleMatrix.html</pre></div><div class="public" id="var-total-log-likelihood"><h3>total-log-likelihood</h3><div class="usage"><code>(total-log-likelihood beta-seq label-seq feature-mat)</code></div><pre class="doc">returns the total log likelihood for a group of pixels; input
+labels and features for the group of pixels, aligned correctly so
+that the first label and feature correspond to the first pixel.</pre></div></div></body></html>
View
53 doc/forma.date-time.html
@@ -0,0 +1,53 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.date-time documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li class="current"><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.date-time.html#var-beginning"><span>beginning</span></a></li><li><a href="forma.date-time.html#var-convert"><span>convert</span></a></li><li><a href="forma.date-time.html#var-convert-period-res"><span>convert-period-res</span></a></li><li><a href="forma.date-time.html#var-current-period"><span>current-period</span></a></li><li><a href="forma.date-time.html#var-date-offset"><span>date-offset</span></a></li><li><a href="forma.date-time.html#var-datetime-%3Eperiod"><span>datetime-&gt;period</span></a></li><li><a href="forma.date-time.html#var-delta-periods"><span>delta-periods</span></a></li><li><a href="forma.date-time.html#var-diff-in-days"><span>diff-in-days</span></a></li><li><a href="forma.date-time.html#var-monthly-msec-range"><span>monthly-msec-range</span></a></li><li><a href="forma.date-time.html#var-msecs-from-epoch"><span>msecs-from-epoch</span></a></li><li><a href="forma.date-time.html#var-ordinal"><span>ordinal</span></a></li><li><a href="forma.date-time.html#var-parse"><span>parse</span></a></li><li><a href="forma.date-time.html#var-per-year"><span>per-year</span></a></li><li><a href="forma.date-time.html#var-period-%3Edatetime"><span>period-&gt;datetime</span></a></li><li><a href="forma.date-time.html#var-period-span"><span>period-span</span></a></li><li><a href="forma.date-time.html#var-periodize"><span>periodize</span></a></li><li><a href="forma.date-time.html#var-relative-period"><span>relative-period</span></a></li><li><a href="forma.date-time.html#var-shift-resolution"><span>shift-resolution</span></a></li><li><a href="forma.date-time.html#var-unparse"><span>unparse</span></a></li><li><a href="forma.date-time.html#var-within-dates%3F"><span>within-dates?</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.date-time documentation</h2><pre class="doc"></pre><div class="public" id="var-beginning"><h3>beginning</h3><div class="usage"><code>(beginning res string)</code><code>(beginning res string format)</code></div><pre class="doc">Accepts a string representation of a date-time object, and returns
+a new string object representing the absolute beginning of time period
+in which `string` lies (according to the supplied resolution, `res`).</pre></div><div class="public" id="var-convert"><h3>convert</h3><div class="usage"><code>(convert s from-format to-format)</code></div><pre class="doc">Converts the supplied string `s` between the two supplied
+formats. Options for each format keyword can be viewed with a call
+to `(clj-time.format/show-formatters)`.</pre></div><div class="public" id="var-convert-period-res"><h3>convert-period-res</h3><div class="usage"><code>(convert-period-res res-in res-out period)</code></div><pre class="doc">Convert a period from in-res to corresponding period at out-res.
+
+By converting a period to a date, we get the first date within a period. Converting date to period, we get the period in which that first date falls, at the new resolution.</pre></div><div class="public" id="var-current-period"><h3>current-period</h3><div class="usage"><code>(current-period res)</code></div><pre class="doc">Returns the current time period for the supplied resolution. For
+example:
+
+ (current-period &quot;32&quot;)
+ =&gt; 495 ;; (on April 27, 2011, this function's birthday!)</pre></div><div class="public" id="var-date-offset"><h3>date-offset</h3><div class="usage"><code>(date-offset from-res from-period to-res to-period)</code></div><pre class="doc">Returns the difference in ordinal days between the beginnings of
+ the two supplied periods. For example:
+
+(date-offset &quot;16&quot; 1 &quot;32&quot; 1) =&gt; 15</pre></div><div class="public" id="var-datetime-%3Eperiod"><h3>datetime-&gt;period</h3><div class="usage"><code>(datetime-&gt;period res datestring)</code><code>(datetime-&gt;period res datestring format)</code></div><pre class="doc">Converts a formatted datestring, into an integer time period at the
+supplied temporal resolution. The default format is
+`:year-month-day`, or `YYYY-MM-DD`.</pre></div><div class="public" id="var-delta-periods"><h3>delta-periods</h3><div class="usage"><code>(delta-periods unit span start end)</code></div><pre class="doc">Calculates the difference between the supplied start and end dates
+in span-sized groups of unit (months or ordinals). [unit span] could be
+[ordinal 16], for example.</pre></div><div class="public" id="var-diff-in-days"><h3>diff-in-days</h3><div class="usage"><code>(diff-in-days one-date two-date)</code></div><pre class="doc">Returns the difference in ordinal days between the supplied date
+strings.</pre></div><div class="public" id="var-monthly-msec-range"><h3>monthly-msec-range</h3><div class="usage"><code>(monthly-msec-range start-date end-date)</code></div><pre class="doc">Returns a sequence of msec values corresponding to each time period
+at monthly resolution from the supplied `start-date` (inclusive) to
+the `end-date` (exclusive). Both inputs must be date-time objects
+created with `clj-time.core/date-time`.</pre></div><div class="public" id="var-msecs-from-epoch"><h3>msecs-from-epoch</h3><div class="usage"><code>(msecs-from-epoch date)</code></div><pre class="doc">Total number of milliseconds passed since January 1st, 1970 (the
+Unix epoch).</pre></div><div class="public" id="var-ordinal"><h3>ordinal</h3><div class="usage"><code>(ordinal dt)</code></div><pre class="doc">Returns the ordinal day index of a given date.
+</pre></div><div class="public" id="var-parse"><h3>parse</h3><div class="usage"><code>(parse s format)</code></div><pre class="doc">Returns a `DateTime` object generated by parsing the supplied
+string `s` using the supplied format. Options for `format` can be
+viewed with a call to `(clj-time.format/show-formatters)`.</pre></div><div class="public" id="var-per-year"><h3>per-year</h3><div class="usage"><code>(per-year unit span)</code></div><pre class="doc">Calculates how many periods of the given span of supplied units can
+be found in a year. Includes the final period, even if that period
+isn't full.</pre></div><div class="public" id="var-period-%3Edatetime"><h3>period-&gt;datetime</h3><div class="usage"><code>(period-&gt;datetime res period)</code><code>(period-&gt;datetime res period format)</code></div><pre class="doc">Converts an integer time period at the supplied temporal resolution
+into a formatted datestring. The default format is
+`:year-month-day`, or `YYYY-MM-DD`.</pre></div><div class="public" id="var-period-span"><h3>period-span</h3><div class="usage"><code>(period-span t-res pd)</code></div><pre class="doc">Returns the length in days of the supplied period at the supplied
+resolution. For example:
+
+(period-span &quot;32&quot; 11) =&gt; 31</pre></div><div class="public" id="var-periodize"><h3>periodize</h3><div class="usage"><code>(periodize temporal-res date)</code></div><pre class="doc">Converts the supplied `org.joda.time.DateTime` object into a
+reference time interval at the supplied temporal
+resolution. `DateTime` objects can be created with `clj-time`'s
+`date-time` function.</pre></div><div class="public" id="var-relative-period"><h3>relative-period</h3><div class="usage"><code>(relative-period t-res start period-seq)</code></div><pre class="doc">convert periods (string) to an integer value that is relative to
+the start period.
+
+Example usage:
+(relative-period &quot;32&quot; 391 [&quot;2005-02-01&quot; &quot;2005-03-01&quot;])
+=&gt; (30 31)</pre></div><div class="public" id="var-shift-resolution"><h3>shift-resolution</h3><div class="usage"><code>(shift-resolution from-res to-res period)</code></div><pre class="doc">Takes a period at `from-res`, returns the corresponding period at
+`to-res`.</pre></div><div class="public" id="var-unparse"><h3>unparse</h3><div class="usage"><code>(unparse dt format)</code></div><pre class="doc">Returns a string generated by unparsing the supplied `DateTime`
+object using the supplied format. Options for `format` can be viewed
+with a call to `(clj-time.format/show-formatters)`.</pre></div><div class="public" id="var-within-dates%3F"><h3>within-dates?</h3><div class="usage"><code>(within-dates? start end dt &amp; {:keys [format], :or {format :year-month-day}})</code></div><pre class="doc">Returns true if the supplied datestring `dt` falls within the dates
+described by start and start end (exclusive)`, false otherwise. the
+`:format` keyword argument can be used to specify the format of the
+datestrings. Options for `:format` can be viewed with a call
+to `(clj-time.format/show-formatters)`.
+
+For example:
+ (within? &quot;2005-12-01&quot; &quot;2011-01-02&quot; &quot;2011-01-01&quot;)
+ ;=&gt; true</pre></div></div></body></html>
View
14 doc/forma.gfw.cdm.html
@@ -0,0 +1,14 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.gfw.cdm documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li class="current"><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.gfw.cdm.html#var--%3EAlert"><span>-&gt;Alert</span></a></li><li><a href="forma.gfw.cdm.html#var-GlobalMercator"><span>GlobalMercator</span></a></li><li><a href="forma.gfw.cdm.html#var-map-%3EAlert"><span>map-&gt;Alert</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.gfw.cdm documentation</h2><pre class="doc">This namespace defines functions for transforming coordinate-based FORMA data
+alerts into Google map tile coordinates:
+
+https://developers.google.com/maps/documentation/javascript/maptypes#TileCoordinates
+
+Many of the functions here were ported from the following Python script:
+
+http://www.maptiler.org/google-maps-coordinates-tile-bounds-projection/globalmaptiles.py
+</pre><div class="public" id="var--%3EAlert"><h3>-&gt;Alert</h3><div class="usage"><code>(-&gt;Alert lat lon zoom)</code></div><pre class="doc">Positional factory function for class forma.gfw.cdm.Alert.
+</pre></div><div class="public" id="var-GlobalMercator"><h3>GlobalMercator</h3><div class="usage"></div><pre class="doc">Protocol for generating map tile coordinates in Spherical Mercator
+projection EPSG:900913, from latitude and longitude coordinates in
+WGS84 Datum.</pre></div><div class="public" id="var-map-%3EAlert"><h3>map-&gt;Alert</h3><div class="usage"><code>(map-&gt;Alert m__5665__auto__)</code></div><pre class="doc">Factory function for class forma.gfw.cdm.Alert, taking a map of keywords to field values.
+</pre></div></div></body></html>
View
3 doc/forma.hadoop.cli.html
@@ -0,0 +1,3 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.hadoop.cli documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li class="current"><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul></ul></div><div class="namespace-docs" id="content"><h2>forma.hadoop.cli documentation</h2><pre class="doc">CLI for managing and manipulating FORMA's operations on the Hadoop
+cluster.</pre></div></body></html>
View
15 doc/forma.hadoop.io.html
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.hadoop.io documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li class="current"><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.hadoop.io.html#var-globstring"><span>globstring</span></a></li><li><a href="forma.hadoop.io.html#var-hfs-wholefile"><span>hfs-wholefile</span></a></li><li><a href="forma.hadoop.io.html#var-whole-file"><span>whole-file</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.hadoop.io documentation</h2><pre class="doc"></pre><div class="public" id="var-globstring"><h3>globstring</h3><div class="usage"><code>(globstring &amp; pieces)</code></div><pre class="doc">Takes a path ending in `/` and collections of nested
+subdirectories, and returns a globstring formatted for cascading's
+GlobHFS. (`*` may be substituted in for any argument but path.)
+
+ Example Usage:
+ (globstring &quot;s3n://bucket/&quot; [&quot;ndvi&quot; &quot;evi&quot;] [&quot;1000-32&quot;] *)
+ ;=&gt; &quot;s3://bucket/{ndvi,evi}/{1000-32}/*&quot;
+
+ (globstring &quot;s3n://bucket/&quot; * * [&quot;008006&quot; &quot;033011&quot;])
+ ;=&gt; &quot;s3://bucket/*/*/{008006,033011}&quot;</pre></div><div class="public" id="var-hfs-wholefile"><h3>hfs-wholefile</h3><div class="usage"><code>(hfs-wholefile path &amp; opts)</code></div><pre class="doc">Subquery to return distinct files in the supplied directory. Files
+will be returned as 2-tuples, formatted as `&lt;filename, file&gt;` The
+filename is a text object, while the entire, unchopped file is
+encoded as a Hadoop `BytesWritable` object.</pre></div><div class="public" id="var-whole-file"><h3>whole-file</h3><div class="usage"><code>(whole-file field-names)</code></div><pre class="doc">Custom scheme for dealing with entire files.
+</pre></div></div></body></html>
View
30 doc/forma.hadoop.jobs.cdm.html
@@ -0,0 +1,30 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.hadoop.jobs.cdm documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li class="current"><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.hadoop.jobs.cdm.html#var-first-hit"><span>first-hit</span></a></li><li><a href="forma.hadoop.jobs.cdm.html#var-forma-%3Ecdm"><span>forma-&gt;cdm</span></a></li><li><a href="forma.hadoop.jobs.cdm.html#var-hansen-latlon-%3Ecdm"><span>hansen-latlon-&gt;cdm</span></a></li><li><a href="forma.hadoop.jobs.cdm.html#var-hansen-xy-%3Ecdm"><span>hansen-xy-&gt;cdm</span></a></li><li><a href="forma.hadoop.jobs.cdm.html#var-min-period"><span>min-period</span></a></li><li><a href="forma.hadoop.jobs.cdm.html#var-split-line"><span>split-line</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.hadoop.jobs.cdm documentation</h2><pre class="doc">Functions and Cascalog queries for converting data into map tile
+coordinates.</pre><div class="public" id="var-first-hit"><h3>first-hit</h3><div class="usage"><code>(first-hit thresh series)</code></div><pre class="doc">Returns the index of the first value in a vector of numbers that is
+greater than or equal to a threshold. `thresh` - The threshold
+value. `series` - A vector of numbers.
+
+Example usage:
+ (first-hit 5 [1 2 3 4 5 6 7 8 9 10]) =&gt; 4</pre></div><div class="public" id="var-forma-%3Ecdm"><h3>forma-&gt;cdm</h3><div class="usage"><code>(forma-&gt;cdm src gadm-src zoom tres tres-out start thresh)</code></div><pre class="doc">Returns a Cascalog generator that transforms FORMA data into map
+ tile coordinates. `start` - Estimation start period date string.
+ `src` - The source tap for FORMA data. `gadm-src` - a sequence
+ file source with mod-h, mod-v, sample, line, and gadm. `thresh` -
+ The threshold number for valid detections (0-100, integer).
+ `tres` - The input temporal resolution (string). `tres-out` - The
+ output temporal resolution (string). `zoom` - The map zoom
+ level (integer).
+
+Example usage:
+ (forma-&gt;cdm (hfs-seqfile &quot;/home/dan/Dropbox/local/output&quot;)
+ (hfs-seqfile &quot;/tmp/forma/data/gadm-path&quot;)
+ 17
+ &quot;16&quot;
+ &quot;32&quot;
+ &quot;2005-12-31&quot;
+ 50)</pre></div><div class="public" id="var-hansen-latlon-%3Ecdm"><h3>hansen-latlon-&gt;cdm</h3><div class="usage"><code>(hansen-latlon-&gt;cdm src zoom tres)</code></div><pre class="doc">Returns a Cascalog query that transforms Hansen latlon data into map tile
+coordinates. `src` - The source tap. `zoom` - The map zoom level.
+`tres` - The temporal resolution.</pre></div><div class="public" id="var-hansen-xy-%3Ecdm"><h3>hansen-xy-&gt;cdm</h3><div class="usage"><code>(hansen-xy-&gt;cdm src zoom tres)</code></div><pre class="doc">Returns a Cascalog query that transforms Hansen xy data into map tile
+coordinates. `src` - The source tap. `zoom` - The map zoom level.
+`tres` - The temporal resolution.</pre></div><div class="public" id="var-min-period"><h3>min-period</h3><div class="usage"><code>(min-period tuples)</code></div><pre class="doc">Returns the minimum value in tuples.
+</pre></div><div class="public" id="var-split-line"><h3>split-line</h3><div class="usage"><code>(split-line line re)</code></div><pre class="doc">Split a line of text using the supplied regular expression
+</pre></div></div></body></html>
View
32 doc/forma.hadoop.jobs.forma.html
@@ -0,0 +1,32 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.hadoop.jobs.forma documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li class="current"><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.hadoop.jobs.forma.html#var-analyze-trends"><span>analyze-trends</span></a></li><li><a href="forma.hadoop.jobs.forma.html#var-beta-data-prep"><span>beta-data-prep</span></a></li><li><a href="forma.hadoop.jobs.forma.html#var-beta-gen"><span>beta-gen</span></a></li><li><a href="forma.hadoop.jobs.forma.html#var-consolidate-static"><span>consolidate-static</span></a></li><li><a href="forma.hadoop.jobs.forma.html#var-dynamic-clean"><span>dynamic-clean</span></a></li><li><a href="forma.hadoop.jobs.forma.html#var-dynamic-filter"><span>dynamic-filter</span></a></li><li><a href="forma.hadoop.jobs.forma.html#var-fire-tap"><span>fire-tap</span></a></li><li><a href="forma.hadoop.jobs.forma.html#var-forma-estimate"><span>forma-estimate</span></a></li><li><a href="forma.hadoop.jobs.forma.html#var-forma-query"><span>forma-query</span></a></li><li><a href="forma.hadoop.jobs.forma.html#var-forma-tap"><span>forma-tap</span></a></li><li><a href="forma.hadoop.jobs.forma.html#var-mk-timeseries"><span>mk-timeseries</span></a></li><li><a href="forma.hadoop.jobs.forma.html#var-process-neighbors"><span>process-neighbors</span></a></li><li><a href="forma.hadoop.jobs.forma.html#var-tele-clean"><span>tele-clean</span></a></li><li><a href="forma.hadoop.jobs.forma.html#var-unnest-all"><span>unnest-all</span></a></li><li><a href="forma.hadoop.jobs.forma.html#var-unnest-series"><span>unnest-series</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.hadoop.jobs.forma documentation</h2><pre class="doc"></pre><div class="public" id="var-analyze-trends"><h3>analyze-trends</h3><div class="usage"><code>(analyze-trends est-map clean-src)</code></div><pre class="doc">Accepts an est-map, and sources for ndvi and rain timeseries and
+vcf values split up by pixel.
+
+We break this apart from dynamic-filter to force the filtering to
+occur before the analysis. Note that all variable names within this
+query are TIMESERIES, not individual values.</pre></div><div class="public" id="var-beta-data-prep"><h3>beta-data-prep</h3><div class="usage"><code>(beta-data-prep {:keys [t-res est-start min-coast-dist]} dynamic-src static-src)</code></div><pre class="doc">for example, static-path can equal this on dan's local machine:
+&quot;/mnt/hgfs/Dropbox/local/static-out&quot;</pre></div><div class="public" id="var-beta-gen"><h3>beta-gen</h3><div class="usage"><code>(beta-gen {:keys [t-res est-start ridge-const convergence-thresh max-iterations min-coast-dist]} src)</code></div><pre class="doc">query to return the beta vector associated with each ecoregion
+</pre></div><div class="public" id="var-consolidate-static"><h3>consolidate-static</h3><div class="usage"><code>(consolidate-static vcf-limit vcf-src gadm-src hansen-src ecoid-src border-src)</code></div><pre class="doc">Due to an issue with Pail, we consolidate separate sequence files
+of static data with one big join</pre></div><div class="public" id="var-dynamic-clean"><h3>dynamic-clean</h3><div class="usage"><code>(dynamic-clean est-map dynamic-src)</code></div><pre class="doc">Accepts an est-map, and sources for ndvi and rain timeseries and
+vcf values split up by pixel.
+
+We break this apart from dynamic-filter to force the filtering to
+occur before the analysis. Note that all variable names within this
+query are TIMESERIES, not individual values.</pre></div><div class="public" id="var-dynamic-filter"><h3>dynamic-filter</h3><div class="usage"><code>(dynamic-filter ndvi-src reli-src rain-src)</code></div><pre class="doc">Returns a new generator of ndvi and rain timeseries obtained by
+filtering out all pixels with VCF less than the supplied
+`vcf-limit`.</pre></div><div class="public" id="var-fire-tap"><h3>fire-tap</h3><div class="usage"><code>(fire-tap est-map fire-src)</code></div><pre class="doc">Accepts an est-map and a query source of fire timeseries. Note that
+this won't work, pulling directly from the pail!</pre></div><div class="public" id="var-forma-estimate"><h3>forma-estimate</h3><div class="usage"><code>(forma-estimate beta-src dynamic-src static-src)</code></div><pre class="doc">query to end all queries: estimate the probabilities for each
+period after the training period.</pre></div><div class="public" id="var-forma-query"><h3>forma-query</h3><div class="usage"><code>(forma-query est-map forma-val-src)</code></div><pre class="doc">final query that walks the neighbors and spits out the values.
+</pre></div><div class="public" id="var-forma-tap"><h3>forma-tap</h3><div class="usage"><code>(forma-tap t-res est-map dynamic-src fire-src)</code></div><pre class="doc">Accepts an est-map and sources for
+
+Note that all values internally discuss timeseries.
+
+Also note that !!fire is an ungrounding variable, and triggers a
+left join with the trend result variables.</pre></div><div class="public" id="var-mk-timeseries"><h3>mk-timeseries</h3><div class="usage"><code>(mk-timeseries tuples)</code></div><pre class="doc">A very specific function that accepts all probabilities for a given
+pixel for all time series, sorts them by the observed period and
+then returns a single series of probabilities; used only in the
+`forma-estimate` query below.</pre></div><div class="public" id="var-process-neighbors"><h3>process-neighbors</h3><div class="usage"><code>(process-neighbors window)</code></div><pre class="doc">Processes all neighbors... Returns the index within the chunk, the
+value, and the aggregate of the neighbors.</pre></div><div class="public" id="var-tele-clean"><h3>tele-clean</h3><div class="usage"><code>(tele-clean {:keys [est-start est-end t-res]} good-set bad-set start-period val-ts reli-ts)</code></div><pre class="doc">Return clean timeseries with telescoping window, nil if no (or not
+enough) good training data</pre></div><div class="public" id="var-unnest-all"><h3>unnest-all</h3><div class="usage"><code>(unnest-all &amp; series)</code></div><pre class="doc">Unnest series coming out of trends-cleanup of form
+[[&quot;500&quot; 28 8 0 0 693 694 [[0.1 0.1]] [[0.2 0.2]] [[0.3 0.3]] [[0.4 0.4]]]]</pre></div><div class="public" id="var-unnest-series"><h3>unnest-series</h3><div class="usage"><code>(unnest-series series)</code></div><pre class="doc">Remove extraneous vectors from around a series
+</pre></div></div></body></html>
View
7 doc/forma.hadoop.jobs.modis.html
@@ -0,0 +1,7 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.hadoop.jobs.modis documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li class="current"><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.hadoop.jobs.modis.html#var--main"><span>-main</span></a></li><li><a href="forma.hadoop.jobs.modis.html#var-modis-chunker"><span>modis-chunker</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.hadoop.jobs.modis documentation</h2><pre class="doc"></pre><div class="public" id="var--main"><h3>-main</h3><div class="usage"><code>(-main path pail-path date &amp; tiles)</code></div><pre class="doc">See project wiki for example usage.
+</pre></div><div class="public" id="var-modis-chunker"><h3>modis-chunker</h3><div class="usage"><code>(modis-chunker subsets chunk-size in-path pattern pail-path)</code></div><pre class="doc">Cascalog job that takes set of dataset identifiers, a chunk size, a
+directory containing MODIS HDF files, or a link directly to such a
+file, and an output dir, harvests tuples out of the HDF files, and
+sinks them into a custom directory structure inside of
+`output-dir`.</pre></div></div></body></html>
View
34 doc/forma.hadoop.jobs.neighbors.html
@@ -0,0 +1,34 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.hadoop.jobs.neighbors documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li class="current"><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.hadoop.jobs.neighbors.html#var-assign-vals"><span>assign-vals</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html#var-create-window"><span>create-window</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html#var-filtered-sample-query"><span>filtered-sample-query</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html#var-global-coll-%3Ewindow-coll"><span>global-coll-&gt;window-coll</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html#var-neighbor-src"><span>neighbor-src</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html#var-neighbors"><span>neighbors</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html#var-process-neighbors"><span>process-neighbors</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html#var-sample-query"><span>sample-query</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html#var-window-attribute-src"><span>window-attribute-src</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html#var-window-map"><span>window-map</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.hadoop.jobs.neighbors documentation</h2><pre class="doc"></pre><div class="public" id="var-assign-vals"><h3>assign-vals</h3><div class="usage"><code>(assign-vals tuples)</code></div><pre class="doc">Accepts a sequence of tuples within a `?group` field and returns a
+sequence of tuples with fields for a global-index and
+smoothed-value; in this case, the sum of all neighboring pixel
+values.</pre></div><div class="public" id="var-create-window"><h3>create-window</h3><div class="usage"><code>(create-window window-coll &amp; {:keys [nrows ncols], :or {nrows 0, ncols 0}})</code></div><pre class="doc">Acceots a sequence of tuples of the form [idx val], where idx is
+the unique identifier of the pixel within a designated window.</pre></div><div class="public" id="var-filtered-sample-query"><h3>filtered-sample-query</h3><div class="usage"><code>(filtered-sample-query sres select-src full-src)</code></div><pre class="doc">Filters the `sample-query` return values, so that only the indices
+that are contained within the selected pixel source are returned.</pre></div><div class="public" id="var-global-coll-%3Ewindow-coll"><h3>global-coll-&gt;window-coll</h3><div class="usage"><code>(global-coll-&gt;window-coll sres wmap idx-val)</code></div><pre class="doc">Accepts a spatial resolution, a map that identifies a MODIS window,
+and a sequence of tuples of the form [idx val], where the index is
+the unique global index. Returns the same form where the index has
+been transformed to the relative window index.</pre></div><div class="public" id="var-neighbor-src"><h3>neighbor-src</h3><div class="usage"><code>(neighbor-src sres select-src)</code></div><pre class="doc">Accepts a source with the MODIS coordinates and group ID (e.g.,
+GADM) of a selection of pixels. Returns a tap with the unique,
+global pixel IDs of all neighbors that are relevant for neighbor
+analysis for a selection of pixels.</pre></div><div class="public" id="var-neighbors"><h3>neighbors</h3><div class="usage"><code>(neighbors sres idx)</code></div><pre class="doc">Accepts a spatial resolution and a unique, global index for a
+single pixel. Returns a sequence of indices of the 8 adjacent pixels
+to the supplied pixel, as well as the own-pixel index.</pre></div><div class="public" id="var-process-neighbors"><h3>process-neighbors</h3><div class="usage"><code>(process-neighbors sres wmap f window-mat)</code></div><pre class="doc">Accepts a spatial resolution, a map of window parameters, a
+function to apply over a 9-pixel square of neighbors, and a
+rectangular matrix of pixel-level values. Returns a sequence of
+tuples of the form [idx val] where the index is the global, unique
+MODIS index and the value is the transformed values as a result of
+spatial smoothing.</pre></div><div class="public" id="var-sample-query"><h3>sample-query</h3><div class="usage"><code>(sample-query sres select-src full-src)</code></div><pre class="doc">Accepts a spatial resolution; a selection of pixels for which
+neighborhood attributes are required; and a full selection of
+indices and values for the region that contains all the group-level
+pixels. Returns a tap with the transformed values assigned to the
+full set of indices.</pre></div><div class="public" id="var-window-attribute-src"><h3>window-attribute-src</h3><div class="usage"><code>(window-attribute-src sres select-src full-src)</code></div><pre class="doc">Accepts two sources (1) coordinates and group ID of a selection of
+pixels that are to be assigned neighbor values; (2) all pixels in
+the region that contains the groups, so that all of the pixels
+in (1) are represented.. Returns the selection of pixels and their
+values that are relevant for neighbor processing by screening out
+all unneccessary pixels.</pre></div><div class="public" id="var-window-map"><h3>window-map</h3><div class="usage"><code>(window-map sres global-idx-coll)</code></div><pre class="doc">Accepts a spatial resolution (as a string) and a collection of
+global, unique indices. Returns a defining map of the rectangular
+window that bounds all pixels in the collection. The window is
+fully identified by the topleft corner in the form of [row
+column], along with the width and height in pixels of the
+rectangular window.</pre></div></div></body></html>
View
9 doc/forma.hadoop.jobs.preprocess.html
@@ -0,0 +1,9 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.hadoop.jobs.preprocess documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li class="current"><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.hadoop.jobs.preprocess.html#var-PreprocessAscii"><span>PreprocessAscii</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html#var-PreprocessFire"><span>PreprocessFire</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html#var-PreprocessRain"><span>PreprocessRain</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html#var-PreprocessStatic"><span>PreprocessStatic</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html#var-rain-chunker"><span>rain-chunker</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html#var-static-chunker"><span>static-chunker</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.hadoop.jobs.preprocess documentation</h2><pre class="doc"></pre><div class="public" id="var-PreprocessAscii"><h3>PreprocessAscii</h3><div class="usage"><code>(PreprocessAscii dataset ascii-path pail-path s-res &amp; countries)</code></div><pre class="doc">TODO: This is only good for hansen datasets looking to be combined
+Tidy up. This needs to be combined with PreprocessStatic.</pre></div><div class="public" id="var-PreprocessFire"><h3>PreprocessFire</h3><div class="usage"><code>(PreprocessFire type path pail-path m-res)</code></div><pre class="doc">Path for running FORMA fires processing. See the forma-clj wiki for
+more details. m-res is the resolution of the other MODIS data we are
+using, likely &quot;500&quot;</pre></div><div class="public" id="var-PreprocessRain"><h3>PreprocessRain</h3><div class="usage"><code>(PreprocessRain source-path sink-path s-res &amp; locations)</code></div><pre class="doc">The locations can be ISO keywords or [h v] tuples.
+</pre></div><div class="public" id="var-PreprocessStatic"><h3>PreprocessStatic</h3><div class="usage"><code>(PreprocessStatic dataset ascii-path output-path s-res &amp; countries)</code></div><pre class="doc">See project wiki for example usage.
+</pre></div><div class="public" id="var-rain-chunker"><h3>rain-chunker</h3><div class="usage"><code>(rain-chunker m-res chunk-size tiles source-path sink-path)</code></div><pre class="doc">Like `modis-chunker`, for NOAA PRECL data files.
+</pre></div><div class="public" id="var-static-chunker"><h3>static-chunker</h3><div class="usage"><code>(static-chunker m-res chunk-size tile-seq dataset agg ascii-path pail-path)</code></div><pre class="doc">m-res - MODIS resolution.
+</pre></div></div></body></html>
View
6 doc/forma.hadoop.jobs.scatter.html
@@ -0,0 +1,6 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.hadoop.jobs.scatter documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li class="current"><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.hadoop.jobs.scatter.html#var-adjusted-precl-tap"><span>adjusted-precl-tap</span></a></li><li><a href="forma.hadoop.jobs.scatter.html#var-static-tap"><span>static-tap</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.hadoop.jobs.scatter documentation</h2><pre class="doc">Namespace for arbitrary queries.
+</pre><div class="public" id="var-adjusted-precl-tap"><h3>adjusted-precl-tap</h3><div class="usage"><code>(adjusted-precl-tap ts-path s-res base-t-res t-res src)</code></div><pre class="doc">Document... returns a tap that adjusts for the incoming
+resolution.</pre></div><div class="public" id="var-static-tap"><h3>static-tap</h3><div class="usage"><code>(static-tap chunk-src)</code></div><pre class="doc">Accepts a source of DataChunks containing vectors as values, and
+returns a new query with all relevant spatial information plus the
+actual value.</pre></div></div></body></html>
View
18 doc/forma.hadoop.jobs.timeseries.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.hadoop.jobs.timeseries documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li class="current"><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.hadoop.jobs.timeseries.html#var-DynamicTimeseries"><span>DynamicTimeseries</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html#var-aggregate-fires"><span>aggregate-fires</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html#var-create-fire-series"><span>create-fire-series</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html#var-extract-tseries"><span>extract-tseries</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html#var-fire-query"><span>fire-query</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html#var-form-tseries"><span>form-tseries</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html#var-merge-firevals"><span>merge-firevals</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html#var-running-fire-sum"><span>running-fire-sum</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html#var-timeseries"><span>timeseries</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.hadoop.jobs.timeseries documentation</h2><pre class="doc"></pre><div class="public" id="var-DynamicTimeseries"><h3>DynamicTimeseries</h3><div class="usage"><code>(DynamicTimeseries source-pail-path ts-pail-path s-res t-res datasets)</code></div><pre class="doc">TODO: Process a pattern, here
+</pre></div><div class="public" id="var-aggregate-fires"><h3>aggregate-fires</h3><div class="usage"><code>(aggregate-fires src t-res)</code></div><pre class="doc">Converts the datestring into a time period based on the supplied
+temporal resolution.</pre></div><div class="public" id="var-create-fire-series"><h3>create-fire-series</h3><div class="usage"><code>(create-fire-series src t-res start end)</code></div><pre class="doc">Aggregates fires into timeseries.
+</pre></div><div class="public" id="var-extract-tseries"><h3>extract-tseries</h3><div class="usage"><code>(extract-tseries tile-chunk-src missing-val)</code></div><pre class="doc">Given a source of chunks, this subquery extracts the proper
+position information and outputs new datachunks containing
+timeseries.</pre></div><div class="public" id="var-fire-query"><h3>fire-query</h3><div class="usage"><code>(fire-query source-pail-path m-res t-res start end)</code></div><pre class="doc">Returns a source of fire timeseries data chunk objects.
+</pre></div><div class="public" id="var-form-tseries"><h3>form-tseries</h3><div class="usage"><code>(form-tseries missing-val)</code></div><pre class="doc">Returns a predicate macro aggregator that generates a timeseries,
+given `?chunk`, `?temporal-resolution` and `?date`. Currently only
+functions when `?chunk` is a vector.</pre></div><div class="public" id="var-merge-firevals"><h3>merge-firevals</h3><div class="usage"></div><pre class="doc">Aggregates a number of fire values by adding up the values of each
+`FireValue` property.</pre></div><div class="public" id="var-running-fire-sum"><h3>running-fire-sum</h3><div class="usage"><code>(running-fire-sum start tseries)</code></div><pre class="doc">Special case of `running-sum` for fire objects.
+</pre></div><div class="public" id="var-timeseries"><h3>timeseries</h3><div class="usage"><code>(timeseries tuples)</code></div><pre class="doc">Takes in a number of `&lt;t-period, modis-chunk&gt;` tuples,
+sorted by time period, and transposes these into (n = chunk-size)
+4-tuples, formatted as `&lt;pixel-idx, start, end, t-series&gt;`, where
+the `t-series` field is represented by a vector.
+
+Entering chunks should be sorted by `t-period` in ascending
+order. `modis-chunk` tuple fields must be vectors.</pre></div></div></body></html>
View
5 doc/forma.hadoop.pail.html
@@ -0,0 +1,5 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.hadoop.pail documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li class="current"><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.hadoop.pail.html#var-%3Fpail-"><span>?pail-</span></a></li><li><a href="forma.hadoop.pail.html#var-%3Fpail-*"><span>?pail-*</span></a></li><li><a href="forma.hadoop.pail.html#var-to-pail"><span>to-pail</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.hadoop.pail documentation</h2><pre class="doc"></pre><div class="public" id="var-%3Fpail-"><h3>?pail-</h3><div class="usage"><code>(?pail- [tap path] query)</code></div><pre class="doc">Executes the supplied query into the pail located at the supplied
+path, consolidating when finished.</pre></div><div class="public" id="var-%3Fpail-*"><h3>?pail-*</h3><div class="usage"><code>(?pail-* tap pail-path query)</code></div><pre class="doc">Executes the supplied query into the DataChunkPailStructure pail
+located at the supplied path, consolidating when finished.</pre></div><div class="public" id="var-to-pail"><h3>to-pail</h3><div class="usage"><code>(to-pail pail-path query)</code></div><pre class="doc">Executes the supplied `query` into the pail at `pail-path`. This
+pail must make use of the `DataChunkPailStructure`.</pre></div></div></body></html>
View
64 doc/forma.hadoop.predicate.html
@@ -0,0 +1,64 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.hadoop.predicate documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li class="current"><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.hadoop.predicate.html#var-add-fields"><span>add-fields</span></a></li><li><a href="forma.hadoop.predicate.html#var-break"><span>break</span></a></li><li><a href="forma.hadoop.predicate.html#var-chunkify"><span>chunkify</span></a></li><li><a href="forma.hadoop.predicate.html#var-converter"><span>converter</span></a></li><li><a href="forma.hadoop.predicate.html#var-defpredsummer"><span>defpredsummer</span></a></li><li><a href="forma.hadoop.predicate.html#var-flatten-window"><span>flatten-window</span></a></li><li><a href="forma.hadoop.predicate.html#var-index"><span>index</span></a></li><li><a href="forma.hadoop.predicate.html#var-liberate"><span>liberate</span></a></li><li><a href="forma.hadoop.predicate.html#var-mangle"><span>mangle</span></a></li><li><a href="forma.hadoop.predicate.html#var-pixel-generator"><span>pixel-generator</span></a></li><li><a href="forma.hadoop.predicate.html#var-sparse-expansion"><span>sparse-expansion</span></a></li><li><a href="forma.hadoop.predicate.html#var-sparse-windower"><span>sparse-windower</span></a></li><li><a href="forma.hadoop.predicate.html#var-swap-syms"><span>swap-syms</span></a></li><li><a href="forma.hadoop.predicate.html#var-vals-%3Esparsevec"><span>vals-&gt;sparsevec</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.hadoop.predicate documentation</h2><pre class="doc"></pre><div class="public" id="var-add-fields"><h3>add-fields</h3><div class="usage"><code>(add-fields &amp; fields)</code></div><pre class="doc">Adds an arbitrary number of fields to tuples in a cascalog query.
+</pre></div><div class="public" id="var-break"><h3>break</h3><div class="usage"></div><pre class="doc">Takes a source of textlines representing rows of a gridded
+dataset (with indices prepended onto each row), and generates a
+source of `row`, `col` and `val`.</pre></div><div class="public" id="var-chunkify"><h3>chunkify</h3><div class="usage"><code>(chunkify size)</code></div><pre class="doc">Return a Cascalog predicate macro that emits a tile DataChunk of a specified size.
+
+Example usage:
+ (use `forma.playground)
+ (let [src [[&quot;fire&quot; nil &quot;500&quot; &quot;16&quot; 8 0 0 [1 1 1 1]]]
+ query (chunkify 24000)]
+ (??&lt;-
+ [?tile-chunk]
+ (src ?name !date ?s-res ?t-res ?h ?v ?id ?val)
+ (query ?name !date ?s-res ?t-res ?h ?v ?id ?val :&gt; ?tile-chunk)))</pre></div><div class="public" id="var-converter"><h3>converter</h3><div class="usage"></div><pre class="doc">Converts between a textline with two numbers encoded as strings and
+their integer representations.</pre></div><div class="public" id="var-defpredsummer"><h3>defpredsummer</h3><div class="usage"><code>(defpredsummer name vals pred)</code></div><pre class="doc">Generates cascalog defaggregateops for counting items that satisfy
+some custom predicate. Defaggregateops don't allow anonymous
+functions, so we went this route instead.</pre></div><div class="public" id="var-flatten-window"><h3>flatten-window</h3><div class="usage"><code>(flatten-window window)</code></div><pre class="doc">Flattens a window of nested clojure vectors into a single
+vector. For example:
+
+ (flatten-window ?chunk :&gt; ?vector)</pre></div><div class="public" id="var-index"><h3>index</h3><div class="usage"><code>(index xs &amp; {:keys [zero-index], :or {zero-index 0}})</code></div><pre class="doc">splits a sequence of values into nested 2-tuples formatted as
+`&lt;idx, val&gt;`. Index supports the `zero-index` keyword argument; this
+defaults to zero.</pre></div><div class="public" id="var-liberate"><h3>liberate</h3><div class="usage"><code>(liberate line)</code></div><pre class="doc">Takes a line with an index as the first value and numbers as the
+rest, and converts it into a 2-tuple formatted as `[idx, row-vals]`,
+where `row-vals` are sealed inside a clojure vector.
+
+Example usage:
+
+ (liberate &quot;1 12 13 14 15&quot;)
+ ;=&gt; [1 [12 13 14 15]]</pre></div><div class="public" id="var-mangle"><h3>mangle</h3><div class="usage"><code>(mangle line)</code></div><pre class="doc">Splits textlines using the supplied regex.
+</pre></div><div class="public" id="var-pixel-generator"><h3>pixel-generator</h3><div class="usage"><code>(pixel-generator tmp-path res tileseq)</code></div><pre class="doc">Returns a Cascalog generator that emits MODIS pixel tuples
+[?mod-h ?mod-v ?sample ?line] for a set of MODIS tiles at a given spatial
+resolution.
+
+Arguments:
+ tmp-path - A staging directory for writing tuples to a sequence file.
+ res - The spatial resolution.
+ tileseq - Map of country ISO keywords to MODIS tiles (see: forma.source.tilesets)</pre></div><div class="public" id="var-sparse-expansion"><h3>sparse-expansion</h3><div class="usage"><code>(sparse-expansion tuples)</code></div><pre class="doc">Receives 2-tuple pairs of the form `&lt;idx, val&gt;`, inserts each
+`val` into a sparse vector at the corresponding `idx`. The `idx` of
+the first tuple will be treated as the zero value. The first tuple
+will `missing-val` will be substituted for any missing value.</pre></div><div class="public" id="var-sparse-windower"><h3>sparse-windower</h3><div class="usage"><code>(sparse-windower gen in-syms dim-vec val sparse-val)</code></div><pre class="doc">Aggregates cascalog generator values up into multidimensional
+windows of nested vectors of `split-length` based on the supplied
+vector of spatial variables. Any missing values will be filled with
+`sparse-val`. This is useful for aggregating spatial data into
+windows or chunks suitable for storage, or to scan across for
+nearest neighbors.
+
+`in-syms` should be a vector containing the name of each spatial
+dimension variable, plus the name of the value to be aggregated. For
+example, with some source `s` that would generate
+
+ (s ?mod-h ?mod-v ?col ?row ?val)
+
+one could wrap s like so:
+
+ (sparse-windower s [&quot;?sample&quot; &quot;?line&quot;] 3000 &quot;?val&quot; 0)
+
+to produce a new generator that would create
+
+ (s ?mod-h ?mod-v ?window-col ?window-row ?window)</pre></div><div class="public" id="var-swap-syms"><h3>swap-syms</h3><div class="usage"><code>(swap-syms gen in-syms out-syms)</code></div><pre class="doc">Returns a vector of dynamic variable outputs from a cascalog
+generator, with `in-syms` swapped for `out-syms`.</pre></div><div class="public" id="var-vals-%3Esparsevec"><h3>vals-&gt;sparsevec</h3><div class="usage"><code>(vals-&gt;sparsevec empty-val)</code><code>(vals-&gt;sparsevec length empty-val)</code><code>(vals-&gt;sparsevec start length empty-val)</code></div><pre class="doc">Returns an aggregating predicate macro that stitches values into a
+sparse vector with all `?val`s at `?idx`, and `empty-val` at all
+other places. Lines are divided into `splits` based on that input
+parameter. Currently, we require that `splits` divide evenly into
+`final-length`.</pre></div></div></body></html>
View
19 doc/forma.hoptree.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.hoptree documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li class="current"><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.hoptree.html#var--%3EGlobalIndex"><span>-&gt;GlobalIndex</span></a></li><li><a href="forma.hoptree.html#var--%3EGlobalRowCol"><span>-&gt;GlobalRowCol</span></a></li><li><a href="forma.hoptree.html#var--%3ETileRowCol"><span>-&gt;TileRowCol</span></a></li><li><a href="forma.hoptree.html#var--%3EWindowIndex"><span>-&gt;WindowIndex</span></a></li><li><a href="forma.hoptree.html#var--%3EWindowRowCol"><span>-&gt;WindowRowCol</span></a></li><li><a href="forma.hoptree.html#var-global-dims"><span>global-dims</span></a></li><li><a href="forma.hoptree.html#var-in-window%3F"><span>in-window?</span></a></li><li><a href="forma.hoptree.html#var-map-%3EGlobalIndex"><span>map-&gt;GlobalIndex</span></a></li><li><a href="forma.hoptree.html#var-map-%3EGlobalRowCol"><span>map-&gt;GlobalRowCol</span></a></li><li><a href="forma.hoptree.html#var-map-%3ETileRowCol"><span>map-&gt;TileRowCol</span></a></li><li><a href="forma.hoptree.html#var-map-%3EWindowIndex"><span>map-&gt;WindowIndex</span></a></li><li><a href="forma.hoptree.html#var-map-%3EWindowRowCol"><span>map-&gt;WindowRowCol</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.hoptree documentation</h2><pre class="doc"></pre><div class="public" id="var--%3EGlobalIndex"><h3>-&gt;GlobalIndex</h3><div class="usage"><code>(-&gt;GlobalIndex idx)</code></div><pre class="doc">Positional factory function for class forma.hoptree.GlobalIndex.
+</pre></div><div class="public" id="var--%3EGlobalRowCol"><h3>-&gt;GlobalRowCol</h3><div class="usage"><code>(-&gt;GlobalRowCol rowcol)</code></div><pre class="doc">Positional factory function for class forma.hoptree.GlobalRowCol.
+</pre></div><div class="public" id="var--%3ETileRowCol"><h3>-&gt;TileRowCol</h3><div class="usage"><code>(-&gt;TileRowCol mod-h mod-v sample line)</code></div><pre class="doc">Positional factory function for class forma.hoptree.TileRowCol.
+</pre></div><div class="public" id="var--%3EWindowIndex"><h3>-&gt;WindowIndex</h3><div class="usage"><code>(-&gt;WindowIndex idx)</code></div><pre class="doc">Positional factory function for class forma.hoptree.WindowIndex.
+</pre></div><div class="public" id="var--%3EWindowRowCol"><h3>-&gt;WindowRowCol</h3><div class="usage"><code>(-&gt;WindowRowCol rowcol)</code></div><pre class="doc">Positional factory function for class forma.hoptree.WindowRowCol.
+</pre></div><div class="public" id="var-global-dims"><h3>global-dims</h3><div class="usage"><code>(global-dims sres)</code></div><pre class="doc">accepts a spatial resolution and returns a tuple of the form [row
+column] with the total number of rows and columns of the entire
+world at the supplied resolution.
+
+EXAMPLE:
+(global-dims &quot;500&quot;) =&gt; (43200 86400)</pre></div><div class="public" id="var-in-window%3F"><h3>in-window?</h3><div class="usage"><code>(in-window? window-map tuple)</code></div><pre class="doc">returns true if the tuple of the form [row col] is within the
+window that is defined by window-map that has
+keys :topleft-rowcol, :height, and :width.</pre></div><div class="public" id="var-map-%3EGlobalIndex"><h3>map-&gt;GlobalIndex</h3><div class="usage"><code>(map-&gt;GlobalIndex m__5665__auto__)</code></div><pre class="doc">Factory function for class forma.hoptree.GlobalIndex, taking a map of keywords to field values.
+</pre></div><div class="public" id="var-map-%3EGlobalRowCol"><h3>map-&gt;GlobalRowCol</h3><div class="usage"><code>(map-&gt;GlobalRowCol m__5665__auto__)</code></div><pre class="doc">Factory function for class forma.hoptree.GlobalRowCol, taking a map of keywords to field values.
+</pre></div><div class="public" id="var-map-%3ETileRowCol"><h3>map-&gt;TileRowCol</h3><div class="usage"><code>(map-&gt;TileRowCol m__5665__auto__)</code></div><pre class="doc">Factory function for class forma.hoptree.TileRowCol, taking a map of keywords to field values.
+</pre></div><div class="public" id="var-map-%3EWindowIndex"><h3>map-&gt;WindowIndex</h3><div class="usage"><code>(map-&gt;WindowIndex m__5665__auto__)</code></div><pre class="doc">Factory function for class forma.hoptree.WindowIndex, taking a map of keywords to field values.
+</pre></div><div class="public" id="var-map-%3EWindowRowCol"><h3>map-&gt;WindowRowCol</h3><div class="usage"><code>(map-&gt;WindowRowCol m__5665__auto__)</code></div><pre class="doc">Factory function for class forma.hoptree.WindowRowCol, taking a map of keywords to field values.
+</pre></div></div></body></html>
View
84 doc/forma.matrix.utils.html
@@ -0,0 +1,84 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.matrix.utils documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li class="current"><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.matrix.utils.html#var-above-x%3F"><span>above-x?</span></a></li><li><a href="forma.matrix.utils.html#var-coll-avg"><span>coll-avg</span></a></li><li><a href="forma.matrix.utils.html#var-column-matrix"><span>column-matrix</span></a></li><li><a href="forma.matrix.utils.html#var-idx-%3Erowcol"><span>idx-&gt;rowcol</span></a></li><li><a href="forma.matrix.utils.html#var-insert-at"><span>insert-at</span></a></li><li><a href="forma.matrix.utils.html#var-insert-into-val"><span>insert-into-val</span></a></li><li><a href="forma.matrix.utils.html#var-is-square%3F"><span>is-square?</span></a></li><li><a href="forma.matrix.utils.html#var-logical-replace"><span>logical-replace</span></a></li><li><a href="forma.matrix.utils.html#var-matrix-of"><span>matrix-of</span></a></li><li><a href="forma.matrix.utils.html#var-ones-column"><span>ones-column</span></a></li><li><a href="forma.matrix.utils.html#var-outer-product"><span>outer-product</span></a></li><li><a href="forma.matrix.utils.html#var-pred-replace"><span>pred-replace</span></a></li><li><a href="forma.matrix.utils.html#var-revolve"><span>revolve</span></a></li><li><a href="forma.matrix.utils.html#var-rowcol-%3Eidx"><span>rowcol-&gt;idx</span></a></li><li><a href="forma.matrix.utils.html#var-singular%3F"><span>singular?</span></a></li><li><a href="forma.matrix.utils.html#var-sparse-expander"><span>sparse-expander</span></a></li><li><a href="forma.matrix.utils.html#var-transpose"><span>transpose</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.matrix.utils documentation</h2><pre class="doc">A set of useful and general functions for matrix operations or
+filters.</pre><div class="public" id="var-above-x%3F"><h3>above-x?</h3><div class="usage"><code>(above-x? x)</code></div><pre class="doc">Returns a partial function that accepts a single number. Returns
+true if that number of greater than `x`, false otherwise.
+
+Example usage:
+ ((above-x? 5) 5) =&gt; falsey</pre></div><div class="public" id="var-coll-avg"><h3>coll-avg</h3><div class="usage"><code>(coll-avg coll)</code></div><pre class="doc">Returns the average value of the supplied collection of numbers.
+
+Example usage:
+ (coll-avg [1 2 3 4]) =&gt; 2.5</pre></div><div class="public" id="var-column-matrix"><h3>column-matrix</h3><div class="usage"><code>(column-matrix val cols)</code></div><pre class="doc">Returns an incanter column matrix of length `cols` filled with
+`val`.
+
+Example usage:
+ (column-matrix 4 3) =&gt; [4.0 4.0 4.0]</pre></div><div class="public" id="var-idx-%3Erowcol"><h3>idx-&gt;rowcol</h3><div class="usage"><code>(idx-&gt;rowcol edge idx)</code><code>(idx-&gt;rowcol nrows ncols idx)</code></div><pre class="doc">Takes an index within a row vector, and returns the appropriate row
+and column within a matrix with the supplied dimensions. If only one
+dimension is supplied, assumes a square matrix.
+
+Example usage:
+ (idx-&gt;rowcol 10 2) =&gt; [0 2]
+ (idx-&gt;rowcol 10 4 18) =&gt; [4 2]</pre></div><div class="public" id="var-insert-at"><h3>insert-at</h3><div class="usage"><code>(insert-at idx ins-coll coll)</code></div><pre class="doc">Inserts `ins-coll` into `coll` at the supplied `idx`.
+
+Example usage:
+ (insert-at 1 [[2 1]] [4 5 6]) =&gt; [4 [2 1] 5 6]</pre></div><div class="public" id="var-insert-into-val"><h3>insert-into-val</h3><div class="usage"><code>(insert-into-val val insertion-idx length xs)</code></div><pre class="doc">Insert vector `xs` into a repeated sequence of the supplied
+length (filled with `val`) at the supplied insertion index.
+
+Example usage:
+ (insert-into-val 0 1 4 [1 2 3]) =&gt; [0 1 2 3]</pre></div><div class="public" id="var-is-square%3F"><h3>is-square?</h3><div class="usage"><code>(is-square? mat)</code></div><pre class="doc">Returns true if input matrix is square, and false otherwise.
+
+Example usage:
+ (is-square? (i/matrix (range 4) 2)) =&gt; true</pre></div><div class="public" id="var-logical-replace"><h3>logical-replace</h3><div class="usage"><code>(logical-replace op compare-val new-val coll)</code></div><pre class="doc">Special version of `pred-replace` tailored for logical
+operators. `op` should be one of #{&lt;, &gt;, &gt;=, &lt;=, =}. if a value in
+the supplied collection returns true when compared to `compare-val`
+by `op`, `new-val` will be subbed into the sequence.
+
+Example usage:
+ (logical-replace &gt; 3 2 [1 2 5 6]) =&gt; (1 2 2 2)</pre></div><div class="public" id="var-matrix-of"><h3>matrix-of</h3><div class="usage"><code>(matrix-of val rows cols)</code></div><pre class="doc">Returns a matrix of dimension rows-by-cols with all elements equal
+to `val`.
+
+Example usage:
+ (matrix-of 2 1 4) =&gt; [2 2 2 2]
+ (matrix-of 0 2 2) =&gt; [[0 0] [0 0]]</pre></div><div class="public" id="var-ones-column"><h3>ones-column</h3><div class="usage"></div><pre class="doc">Convenient wrapper for column-matrix to create a matrix of ones.
+
+Example usage:
+ (ones-column 4) =&gt; [1.0 1.0 1.0 1.0]</pre></div><div class="public" id="var-outer-product"><h3>outer-product</h3><div class="usage"><code>(outer-product coll)</code></div><pre class="doc">Returns a flattened vector of the matrix product of a vector and its
+transpose.
+
+Example usage:
+ (outer-product [1 2]) =&gt; '(1.0 2.0 2.0 4.0)</pre></div><div class="public" id="var-pred-replace"><h3>pred-replace</h3><div class="usage"><code>(pred-replace pred val coll)</code></div><pre class="doc">Selectively replaces values in `coll` based on the return value of
+the supplied predicate. `pred` will receive each value in turn; a
+truthy return will trigger a replacement of the seq item with
+`val`.
+
+Example usage:
+ (pred-replace #{:cake} 3 [1 2 :cake 4]) =&gt; '(1 2 3 4)</pre></div><div class="public" id="var-revolve"><h3>revolve</h3><div class="usage"><code>(revolve coll)</code></div><pre class="doc">Returns a lazy sequence of revolutions of the supplied
+collection. (Note that the entire sequence must be realized, as the
+first item is cycled to the end for each revolution.)
+
+Example usage:
+ (rotate [1 2 3]) =&gt; ([1 2 3] [2 3 1] [3 1 2])</pre></div><div class="public" id="var-rowcol-%3Eidx"><h3>rowcol-&gt;idx</h3><div class="usage"><code>(rowcol-&gt;idx edge row col)</code><code>(rowcol-&gt;idx nrows ncols row col)</code></div><pre class="doc">For the supplied column and row in a rectangular matrix of
+dimensions (height, width), returns the corresponding index within a
+row vector of size (* width height). If only one dimension is
+supplied, assumes a square matrix.
+
+Example usage:
+ (rowcol-&gt;idx 3 4 2 2) =&gt; 10
+ (rowcol-&gt;idx 3 4 2 3) =&gt; 11
+ (rowcol-&gt;idx 3 4 2 4) =&gt; nil</pre></div><div class="public" id="var-singular%3F"><h3>singular?</h3><div class="usage"><code>(singular? mat)</code></div><pre class="doc">Returns if square input matrix is singular, and false otherwise.
+
+Example usage:
+ (singular? (i/matrix [[1 0] [1 0]])) =&gt; true
+ (singular? (i/matrix [[1 0] [0 1]])) =&gt; false</pre></div><div class="public" id="var-sparse-expander"><h3>sparse-expander</h3><div class="usage"><code>(sparse-expander placeholder tuples &amp; {:keys [start length]})</code></div><pre class="doc">Accepts a sequence of 2-tuples of the form `&lt;idx, val&gt;` and
+generates a sparse expansion with each `val` inserted at its
+corresponding `idx`. Missing values will be set to the supplied
+placeholder.
+
+If no starting index is supplied, `sparse-expander` assumes that
+counting begins with the first `&lt;idx, val&gt;` pair.
+
+Example usage:
+ (sparse-expander 0 [[10 1] [13 8]]) =&gt; [1 0 0 8]
+ (sparse-expander 0 [[10 1] [13 8]] :start 9) =&gt; [0 1 0 0 8]</pre></div><div class="public" id="var-transpose"><h3>transpose</h3><div class="usage"><code>(transpose coll)</code></div><pre class="doc">Returns the transposition of a collection of vectors.
+
+Example usage:
+ (transpose [[1 2 3] [4 5 6]]) =&gt; '([1 4] [2 5] [3 6])</pre></div></div></body></html>
View
46 doc/forma.matrix.walk.html
@@ -0,0 +1,46 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.matrix.walk documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li class="current"><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.matrix.walk.html#var-buffer-matrix"><span>buffer-matrix</span></a></li><li><a href="forma.matrix.walk.html#var-neighbor-scan"><span>neighbor-scan</span></a></li><li><a href="forma.matrix.walk.html#var-walk-matrix"><span>walk-matrix</span></a></li><li><a href="forma.matrix.walk.html#var-windowed-function"><span>windowed-function</span></a></li><li><a href="forma.matrix.walk.html#var-wipe-out"><span>wipe-out</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.matrix.walk documentation</h2><pre class="doc">Functions that move along a 2D array, collecting features of the
+moving window.</pre><div class="public" id="var-buffer-matrix"><h3>buffer-matrix</h3><div class="usage"><code>(buffer-matrix buffer-size val [row :as mat])</code></div><pre class="doc">For the supplied matrix `mat`, returns a new matrix generated by
+padding the beginning and end of each row and column with the
+supplied value, repeated `buffer-size` times.
+
+Example usage:
+ (def test-matrix [[0 1 2]
+ [3 4 5]])
+ (buffer-matrix 2 1 test-matrix) =&gt; [[1 1 1 1 1 1 1]
+ [1 1 1 1 1 1 1]
+ [1 1 0 1 2 1 1]
+ [1 1 3 4 5 1 1]
+ [1 1 1 1 1 1 1]
+ [1 1 1 1 1 1 1]]</pre></div><div class="public" id="var-neighbor-scan"><h3>neighbor-scan</h3><div class="usage"><code>(neighbor-scan num-neighbors mat)</code></div><pre class="doc">Iterates across the supplied two dimensional matrix, returning a
+lazy sequence of 2-element vectors of the form `[matrix entry,
+neighbor-seq]`. Neighbors outside the matrix are reported as
+nil.
+
+Example usage:
+ (def test-matrix [[:0 :1 :2 :3]
+ [:4 :5 :6 :7]
+ [:8 :9 :a :b]
+ [:c :d :e :f]])
+
+ (first (neighbor-scan 1 test-matrix))
+ =&gt; [:0 ((nil nil nil) (nil :1) (nil :4 :5))]</pre></div><div class="public" id="var-walk-matrix"><h3>walk-matrix</h3><div class="usage"><code>(walk-matrix m window)</code></div><pre class="doc">Returns a sequence of matrices, after walking along the rows and
+columns of the given matrix a the specified window size and
+returning all window-by-window snapshots.
+
+Example usage:
+ (def mat [[0 1 2] [3 4 5]])
+ (walk-matrix mat 2) =&gt; [[[0 1]
+ [3 4]]
+ [[1 2]
+ [4 5]]]</pre></div><div class="public" id="var-windowed-function"><h3>windowed-function</h3><div class="usage"><code>(windowed-function num-neighbors f mat)</code></div><pre class="doc">Returns a sequence of the results of calling the supplied function
+`f` on each sub-matrix of matrix `mat`. Each submatrix is a series
+of `(inc (* 2 num-neighbors))` nested vectors; each element sits at
+the middle of a single submatrix, and is suqrrounded by its
+neighbors (or `nil` if it sits on an edge.)</pre></div><div class="public" id="var-wipe-out"><h3>wipe-out</h3><div class="usage"><code>(wipe-out coll [k &amp; ks])</code></div><pre class="doc">Accepts a nested collection and a sequence of keys, and returns a new
+collection generated by removing the value located at the position
+indicated by the supplied key sequence.
+
+Example usage:
+ (def test-matrix [[0 1 2] [3 4 5]])
+ (wipe-out test-matrix [1 2]) =&gt; [[0 1 2] [3 4]]</pre></div></div></body></html>
View
10 doc/forma.ops.classify.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.ops.classify documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li class="current"><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.ops.classify.html#var-beta-dict"><span>beta-dict</span></a></li><li><a href="forma.ops.classify.html#var-logistic-beta-wrap"><span>logistic-beta-wrap</span></a></li><li><a href="forma.ops.classify.html#var-logistic-prob-wrap"><span>logistic-prob-wrap</span></a></li><li><a href="forma.ops.classify.html#var-unpack-feature-vec"><span>unpack-feature-vec</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.ops.classify documentation</h2><pre class="doc">Convenient wrapper functions for the classify.logistic namespace,
+used mainly to compose cascalog queries.</pre><div class="public" id="var-beta-dict"><h3>beta-dict</h3><div class="usage"><code>(beta-dict beta-src)</code></div><pre class="doc">Accepts a source of beta vectors, indexed by ecoregion; returns a
+dictionary with the ecoregions as keys and the beta vectors as
+values.</pre></div><div class="public" id="var-logistic-beta-wrap"><h3>logistic-beta-wrap</h3><div class="usage"><code>(logistic-beta-wrap tuples)</code></div><pre class="doc">Accepts all tuples within an ecoregion and returns a coefficient
+vector resulting from a logistic regression.</pre></div><div class="public" id="var-logistic-prob-wrap"><h3>logistic-prob-wrap</h3><div class="usage"><code>(logistic-prob-wrap beta-vec val neighbor-val)</code></div><pre class="doc">Accepts the approrpiate coefficient (beta) vector for a given
+pixel, along with that pixel's features (within-pixel and
+neighboring values); returns the probability of deforestation.</pre></div><div class="public" id="var-unpack-feature-vec"><h3>unpack-feature-vec</h3><div class="usage"><code>(unpack-feature-vec forma-val neighbor-val)</code></div><pre class="doc">Creates a persistent vector from forma- and neighbor-val objects;
+building the vector for the logistic classifier. The `[1]`
+indicates the mandatory intercept in the logistic regression.</pre></div></div></body></html>
View
4 doc/forma.playground.html
@@ -0,0 +1,4 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.playground documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li class="current"><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul></ul></div><div class="namespace-docs" id="content"><h2>forma.playground documentation</h2><pre class="doc">This namespace is a playground for playing in the playground with play things.
+It mostly includes handy Thrift objects and Thrift memory taps for playing with
+at the REPL.</pre></div></body></html>
View
48 doc/forma.postprocess.output.html
@@ -0,0 +1,48 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.postprocess.output documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li class="current"><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.postprocess.output.html#var-backward-looking-mavg"><span>backward-looking-mavg</span></a></li><li><a href="forma.postprocess.output.html#var-clean-probs"><span>clean-probs</span></a></li><li><a href="forma.postprocess.output.html#var-error-map"><span>error-map</span></a></li><li><a href="forma.postprocess.output.html#var-precision"><span>precision</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.postprocess.output documentation</h2><pre class="doc">Functions to smooth and clean FORMA probability series, and then a
+few supporting functions to assess the accuracy of the estimates by
+counting false negatives, true positives, etc.</pre><div class="public" id="var-backward-looking-mavg"><h3>backward-looking-mavg</h3><div class="usage"><code>(backward-looking-mavg window series)</code></div><pre class="doc">Moving average calculated up to a given element (i.e. looking backwards),
+rather than starting with a given element. Ensures that only
+information up to and including given element is incorporated in the
+moving average.
+
+Expanded timeseries includes pre-pended nils. So moving average is
+actually forward looking, but starting with non-existing (and
+filtered out) 'prior' nil values.
+
+For example,
+
+ (backward-looking-mavg 3 [1 2 3 4])
+
+expands to
+
+ [nil nil 1 2 3 4]
+
+where the nils are filtered out, so the output is effectively:
+
+ [(average [1]) (average [1 2]) (average [1 2 3]) (average 2 3 4)]
+
+Example usage:
+ (backward-looking-mavg 3 [1 2 3 4]) =&gt; '(1.0 1.5 2.0 3.0)</pre></div><div class="public" id="var-clean-probs"><h3>clean-probs</h3><div class="usage"><code>(clean-probs ts)</code></div><pre class="doc">Accepts a timeseries of probabilities, and returns a nested vector
+'cleaned' time series. Specifically, the cleaned timeseries Smooth
+the probabilities with a backward-looking moving average, make the
+series monotonically increasing, and finally make each probability
+0-&gt;1 an integer 0-&gt;100. Note that the moving average window, here,
+is set to 3 periods. This is hard-coded, since this function's
+expressed purpose is to clean the FORMA probability time series.
+That is, in some sense, FORMA is defined by the 3-length window.
+
+Example usage:
+ (clean-probs [0.1 0.2 0.3 0.4 0.5]) =&gt; [[10 15 20 30 40]]</pre></div><div class="public" id="var-error-map"><h3>error-map</h3><div class="usage"><code>(error-map threshold m)</code></div><pre class="doc">returns a vector indicating one of four possiblities: false
+positive, false negative, true positive, true negative. This is
+used as an intermediate function to a cascalog query, where the
+order of the elements of the returned vector matters:
+[?false-pos ?true-neg ?true-pos ?false-neg]
+
+Example use case:
+ (defn error-tap []
+ (??&lt;- [?fp-sum ?tn-sum ?tp-sum ?fn-sum]
+ (sample-output-map ?m)
+ (error-map 0.05 ?m :&gt; ?fp ?tn ?tp ?fn)
+ (c/sum ?fp ?tn ?tp ?fn :&gt; ?fp-sum ?tn-sum ?tp-sum ?fn-sum)))</pre></div><div class="public" id="var-precision"><h3>precision</h3><div class="usage"><code>(precision error-dict)</code></div><pre class="doc">returns
+</pre></div></div></body></html>
View
98 doc/forma.reproject.html
@@ -0,0 +1,98 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.reproject documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li class="current"><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.reproject.html#var-bucket"><span>bucket</span></a></li><li><a href="forma.reproject.html#var-chunk-dims"><span>chunk-dims</span></a></li><li><a href="forma.reproject.html#var-constrain"><span>constrain</span></a></li><li><a href="forma.reproject.html#var-dataset-info"><span>dataset-info</span></a></li><li><a href="forma.reproject.html#var-dimensions-for-step"><span>dimensions-for-step</span></a></li><li><a href="forma.reproject.html#var-global-mags-%3Emodis"><span>global-mags-&gt;modis</span></a></li><li><a href="forma.reproject.html#var-global-mags-%3Esinu-xy"><span>global-mags-&gt;sinu-xy</span></a></li><li><a href="forma.reproject.html#var-hv-%3Etilestring"><span>hv-&gt;tilestring</span></a></li><li><a href="forma.reproject.html#var-latlon-%3Emodis"><span>latlon-&gt;modis</span></a></li><li><a href="forma.reproject.html#var-latlon-%3Erowcol"><span>latlon-&gt;rowcol</span></a></li><li><a href="forma.reproject.html#var-latlon-%3Esinu-xy"><span>latlon-&gt;sinu-xy</span></a></li><li><a href="forma.reproject.html#var-latlon-rad-%3Esinu-xy"><span>latlon-rad-&gt;sinu-xy</span></a></li><li><a href="forma.reproject.html#var-line-torus"><span>line-torus</span></a></li><li><a href="forma.reproject.html#var-modis-%3Eglobal-mags"><span>modis-&gt;global-mags</span></a></li><li><a href="forma.reproject.html#var-modis-%3Elatlon"><span>modis-&gt;latlon</span></a></li><li><a href="forma.reproject.html#var-modis-indexer"><span>modis-indexer</span></a></li><li><a href="forma.reproject.html#var-pixel-length"><span>pixel-length</span></a></li><li><a href="forma.reproject.html#var-rowcol-%3Elatlon"><span>rowcol-&gt;latlon</span></a></li><li><a href="forma.reproject.html#var-sinu-xy-%3Eglobal-mags"><span>sinu-xy-&gt;global-mags</span></a></li><li><a href="forma.reproject.html#var-sinu-xy-%3Elatlon"><span>sinu-xy-&gt;latlon</span></a></li><li><a href="forma.reproject.html#var-tile-position"><span>tile-position</span></a></li><li><a href="forma.reproject.html#var-tilestring-%3Ehv"><span>tilestring-&gt;hv</span></a></li><li><a href="forma.reproject.html#var-travel"><span>travel</span></a></li><li><a href="forma.reproject.html#var-valid-modis%3F"><span>valid-modis?</span></a></li><li><a href="forma.reproject.html#var-valid-rowcol%3F"><span>valid-rowcol?</span></a></li><li><a href="forma.reproject.html#var-valid-tiles"><span>valid-tiles</span></a></li><li><a href="forma.reproject.html#var-wgs84-indexer"><span>wgs84-indexer</span></a></li><li><a href="forma.reproject.html#var-wgs84-resolution"><span>wgs84-resolution</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.reproject documentation</h2><pre class="doc"></pre><div class="public" id="var-bucket"><h3>bucket</h3><div class="usage"><code>(bucket step-size val)</code></div><pre class="doc">Takes a floating-point value and step size, and returns the
+step-sized bucket into which the value falls. For example:
+
+ (bucket 0.4 1.3)
+ ;=&gt; 3
+
+ (bucket 0.9 1.3)
+ ;=&gt; 1</pre></div><div class="public" id="var-chunk-dims"><h3>chunk-dims</h3><div class="usage"><code>(chunk-dims m-res chunk-size)</code></div><pre class="doc">Returns the width and height in pixels of a chunk at the supplied
+resolution with `chunk-size` total entries.
+
+`chunk-size` must be a whole number multiple of the number of pixels
+per row in a MODIS tile of the supplied resolution `m-res`.</pre></div><div class="public" id="var-constrain"><h3>constrain</h3><div class="usage"><code>(constrain range start val)</code></div><pre class="doc">Constrains the supplied `val` to the range obtained by traveling
+`range` in the positive direction from the supplied starting
+value. If the value falls outside these bounds, it wraps around to
+the other edge.</pre></div><div class="public" id="var-dataset-info"><h3>dataset-info</h3><div class="usage"></div><pre class="doc">Returns the temporal resolution of the supplied MODIS short product
+name.</pre></div><div class="public" id="var-dimensions-for-step"><h3>dimensions-for-step</h3><div class="usage"><code>(dimensions-for-step step-size)</code></div><pre class="doc">returns the &lt;horz, vert&gt; dimensions of a WGS84 grid with the
+supplied spatial step-size between pixels.</pre></div><div class="public" id="var-global-mags-%3Emodis"><h3>global-mags-&gt;modis</h3><div class="usage"><code>(global-mags-&gt;modis res mag-x mag-y)</code></div><pre class="doc">Returns the MODIS pixel coordinate reached after traveling the
+supplied meter distances in the positive X and negative Y directions
+from the origin of the sinusoidal MODIS grid, located at its top
+left.</pre></div><div class="public" id="var-global-mags-%3Esinu-xy"><h3>global-mags-&gt;sinu-xy</h3><div class="usage"><code>(global-mags-&gt;sinu-xy mag-x mag-y)</code></div><pre class="doc">Returns the coordinate position on a sinusoidal grid reached after
+traveling the supplied magnitudes in the x and y directions. The
+origin of the sinusoidal grid is fixed in the top left corner.</pre></div><div class="public" id="var-hv-%3Etilestring"><h3>hv-&gt;tilestring</h3><div class="usage"><code>(hv-&gt;tilestring mod-h mod-v)</code></div><pre class="doc">Returns a 0-padded tilestring of format `HHHVVV`, for the supplied
+MODIS h and v coordinates. For example:
+
+ (tilestring 8 6)
+ ;=&gt; &quot;008006&quot;</pre></div><div class="public" id="var-latlon-%3Emodis"><h3>latlon-&gt;modis</h3><div class="usage"><code>(latlon-&gt;modis modis-res lat lon)</code></div><pre class="doc">Converts the supplied latitude and longitude into MODIS pixel
+ coordinates at the supplied resolution. The resolution is
+ expected to be either 1000, 500, or 250.
+
+Example usage:
+
+ (latlon-&gt;modis &quot;1000&quot; 29.89583 -115.2290)
+ ;=&gt; [8 6 12 12]</pre></div><div class="public" id="var-latlon-%3Erowcol"><h3>latlon-&gt;rowcol</h3><div class="usage"><code>(latlon-&gt;rowcol step-size lat-dir lon-dir lat-corner lon-corner lat lon)</code></div><pre class="doc">Takes a coordinate pair and returns its [row, col] position on a
+WGS84 grid with the supplied spatial resolution and width in
+columns.</pre></div><div class="public" id="var-latlon-%3Esinu-xy"><h3>latlon-&gt;sinu-xy</h3><div class="usage"><code>(latlon-&gt;sinu-xy lat lon)</code></div><pre class="doc">Returns the sinusoidal x and y coordinates for the supplied
+latitude and longitude (in degrees).</pre></div><div class="public" id="var-latlon-rad-%3Esinu-xy"><h3>latlon-rad-&gt;sinu-xy</h3><div class="usage"><code>(latlon-rad-&gt;sinu-xy lat lon)</code></div><pre class="doc">Returns the sinusoidal x and y coordinates for the supplied
+latitude and longitude (in radians).</pre></div><div class="public" id="var-line-torus"><h3>line-torus</h3><div class="usage"><code>(line-torus dir range corner val)</code></div><pre class="doc">Returns the magnitude of the difference between the supplied value
+and the corner point within the supplied range. Values are assumed
+to wrap around at the edge of the range. For example,
+
+ (line-torus + 10 -2 1) =&gt; 3
+ (line-torus + 10 -2 -3) =&gt; 9
+
+The -3 value is assumed to have wrapped around the edge of the
+range. Note that this function will wrap any number of times:
+
+ (line-torus + 10 -2 54) =&gt; 6</pre></div><div class="public" id="var-modis-%3Eglobal-mags"><h3>modis-&gt;global-mags</h3><div class="usage"><code>(modis-&gt;global-mags res mod-h mod-v sample line)</code></div><pre class="doc">Returns the distance traveled in meters from the top left of the
+sinusoidal MODIS grid that corresponds with the supplied MODIS pixel
+coordinates at the given resolution</pre></div><div class="public" id="var-modis-%3Elatlon"><h3>modis-&gt;latlon</h3><div class="usage"><code>(modis-&gt;latlon res mod-h mod-v sample line)</code></div><pre class="doc">Converts the supplied MODIS coordinates into `[lat, lon]` based on
+ the supplied resolution.
+
+Example usage:
+
+ (modis-&gt;latlon &quot;1000&quot; 8 6 12 12)
+ ;=&gt; (29.89583333333333 -115.22901262147285)</pre></div><div class="public" id="var-modis-indexer"><h3>modis-indexer</h3><div class="usage"><code>(modis-indexer m-res {:keys [step corner travel]} row col)</code></div><pre class="doc">Accepts WGS84 coordinates and returns the corresponding `[mod-h,
+mod-v, sample, line]` in the modis grid at the supplied resolution
+for an ASCII grid with the supplied step-size, corner coordinates
+and directions traveled for each axis.</pre></div><div class="public" id="var-pixel-length"><h3>pixel-length</h3><div class="usage"><code>(pixel-length res)</code></div><pre class="doc">The length, in meters, of the edge of a MODIS pixel at the supplied
+resolution.</pre></div><div class="public" id="var-rowcol-%3Elatlon"><h3>rowcol-&gt;latlon</h3><div class="usage"><code>(rowcol-&gt;latlon step-size lat-dir lon-dir lat-corner lon-corner row col)</code></div><pre class="doc">Returns the coordinates of the centroid of the point defined by
+`row` and `col` on an ascii grid with the supplied corner point and
+step size.</pre></div><div class="public" id="var-sinu-xy-%3Eglobal-mags"><h3>sinu-xy-&gt;global-mags</h3><div class="usage"><code>(sinu-xy-&gt;global-mags x y)</code></div><pre class="doc">Returns the magnitudes (in meters) required to reach the supplied
+coordinate position on a the MODIS sinusoidal grid. The origin of
+the sinusoidal grid is fixed in the top left corner.</pre></div><div class="public" id="var-sinu-xy-%3Elatlon"><h3>sinu-xy-&gt;latlon</h3><div class="usage"><code>(sinu-xy-&gt;latlon x y)</code></div><pre class="doc">Returns the latitude and longitude (in degrees) for a given set of
+sinusoidal map coordinates (in meters).</pre></div><div class="public" id="var-tile-position"><h3>tile-position</h3><div class="usage"><code>(tile-position m-res chunk-size chunk-row idx)</code><code>(tile-position win-width win-height win-col win-row idx)</code></div><pre class="doc">General version accepts a window's dimensions and position and a
+pixel index within that window, and returns the global sample and
+line. For example:
+
+ (tile-position 10 10 2 1 0) =&gt; [20 10]
+
+ Special-case version accepts a MODIS resolution, a chunk-size, and a
+ pixel's index within that chunk, and returns the tile sample and
+ line. For example:
+
+ (tile-position &quot;1000&quot; 24000 2 1231) =&gt; [31 41]</pre></div><div class="public" id="var-tilestring-%3Ehv"><h3>tilestring-&gt;hv</h3><div class="usage"><code>(tilestring-&gt;hv tilestr)</code></div><pre class="doc">Extracts integer representations of the MODIS H and V coordinates
+referenced by the supplied MODIS tilestring, of format 'HHHVVV'.</pre></div><div class="public" id="var-travel"><h3>travel</h3><div class="usage"><code>(travel step-size dir start idx)</code></div><pre class="doc">Returns the value obtained by traveling `idx` steps, each
+`step-size` large, in the supplied direction from the value
+`start`. (The function takes an extra half-step, so as to return the
+centroid of the point reached.) For example:
+
+ (travel 0.5 + 0 2)
+ =&gt; 1.25
+ (start, travel, end at centroid.)
+ 0.0 --&gt; 0.5 --&gt; 1.0 -*- 1.5</pre></div><div class="public" id="var-valid-modis%3F"><h3>valid-modis?</h3><div class="usage"><code>(valid-modis? tileseq)</code><code>(valid-modis? mod-h mod-v)</code><code>(valid-modis? res mod-h mod-v sample line)</code></div><pre class="doc">Checks that the supplied values correspond to a valid MODIS tile,
+at the specified resolution. The single argument version accepts a
+sequence if `[mod-h, mod-v`] vectors.</pre></div><div class="public" id="var-valid-rowcol%3F"><h3>valid-rowcol?</h3><div class="usage"><code>(valid-rowcol? step row col)</code></div><pre class="doc">Determines whether or not the supplied ASCII row and column falls
+within the bounds of an ASCII grid with the supplied step size.</pre></div><div class="public" id="var-valid-tiles"><h3>valid-tiles</h3><div class="usage"></div><pre class="doc">Set of coordinate pairs for all MODIS tiles that contain actual
+data. This set is calculated by taking a vector of offsets,
+representing the first horizontal tile containing data for each row
+of tiles. (For example, the data for row 1 begins with tile 14,
+horizontal.) For a visual representation of the MODIS grid and its
+available data, see http://remotesensing.unh.edu/modis/modis.shtml</pre></div><div class="public" id="var-wgs84-indexer"><h3>wgs84-indexer</h3><div class="usage"><code>(wgs84-indexer m-res ascii-map mod-h mod-v sample line)</code></div><pre class="doc">Accepts MODIS tile coordinates and returns the corresponding `[row,
+col]` within a WGS84 grid of values with the supplied step-size,
+corner coordinates and directions traveled for each axis.</pre></div><div class="public" id="var-wgs84-resolution"><h3>wgs84-resolution</h3><div class="usage"><code>(wgs84-resolution res)</code></div><pre class="doc">Returns the step size on a `&lt;lat, lon&gt;` grid corresponding to the
+supplied MODIS resolution. As each MODIS tile is 10 degrees on a
+side, we find this value by calculating the number of degrees
+spanned by each MODIS pixel. This is not exact, as MODIS uses a
+sinusoidal projection, but it's close enough for rough estimation.</pre></div></div></body></html>
View
45 doc/forma.schema.html
@@ -0,0 +1,45 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.schema documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li class="current"><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.schema.html#var-add-fires"><span>add-fires</span></a></li><li><a href="forma.schema.html#var-adjust"><span>adjust</span></a></li><li><a href="forma.schema.html#var-adjust-fires"><span>adjust-fires</span></a></li><li><a href="forma.schema.html#var-boundaries"><span>boundaries</span></a></li><li><a href="forma.schema.html#var-combine-neighbors"><span>combine-neighbors</span></a></li><li><a href="forma.schema.html#var-create-timeseries"><span>create-timeseries</span></a></li><li><a href="forma.schema.html#var-empty-neighbor-val"><span>empty-neighbor-val</span></a></li><li><a href="forma.schema.html#var-fires-cleanup"><span>fires-cleanup</span></a></li><li><a href="forma.schema.html#var-forma-seq"><span>forma-seq</span></a></li><li><a href="forma.schema.html#var-forma-value"><span>forma-value</span></a></li><li><a href="forma.schema.html#var-merge-neighbors"><span>merge-neighbors</span></a></li><li><a href="forma.schema.html#var-neighbor-value"><span>neighbor-value</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.schema documentation</h2><pre class="doc">A set of functions to structure other queries.
+</pre><div class="public" id="var-add-fires"><h3>add-fires</h3><div class="usage"><code>(add-fires &amp; f-tuples)</code></div><pre class="doc">Returns a new `FireValue` object generated by summing up the fields
+of each of the supplied `FireValue` objects.</pre></div><div class="public" id="var-adjust"><h3>adjust</h3><div class="usage"><code>(adjust &amp; pairs)</code></div><pre class="doc">Appropriately truncates the incoming timeseries values (paired with
+the initial integer period), and outputs a new start and both
+truncated series.
+
+Example usage:
+ (adjust 0 [1 2 3 4] 1 [2 3 4 5]) =&gt; (1 [2 3 4] [2 3 4])</pre></div><div class="public" id="var-adjust-fires"><h3>adjust-fires</h3><div class="usage"><code>(adjust-fires {:keys [est-start est-end t-res]} f-series)</code></div><pre class="doc">Returns a TimeSeries object of fires that are within the bounds of
+the interval defined by :est-start, :est-end, and :t-res. Within
+the FORMA workflow, this function is applied to a series of
+FireValues that is longer (on the tail-end or both the tail- and
+front-end) of the interval based on the info in the estimation
+parameter map. This series may not have any actual fire hits in it;
+but rather is a vector of zero-value fires -- a sort of sparse
+vector where each element is a FireValue.
+
+TODO: preconditions to test that the supplied series matches the
+description above. Then adjust the description to be shorter, more
+understandable.</pre></div><div class="public" id="var-boundaries"><h3>boundaries</h3><div class="usage"><code>(boundaries pair-seq)</code></div><pre class="doc">Accepts a sequence of pairs of &lt;initial time period, collection&gt;
+and returns the maximum start period and the minimum end period.
+
+Example usage:
+ (boundaries [0 [1 2 3 4] 1 [2 3 4 5]]) =&gt; [1 4]</pre></div><div class="public" id="var-combine-neighbors"><h3>combine-neighbors</h3><div class="usage"><code>(combine-neighbors [x &amp; more])</code></div><pre class="doc">Returns a new forma neighbor value generated by merging together
+each entry in the supplied sequence of forma values. See tests for
+example usage.</pre></div><div class="public" id="var-create-timeseries"><h3>create-timeseries</h3><div class="usage"><code>(create-timeseries start-idx series)</code><code>(create-timeseries start-idx end-idx series)</code></div><pre class="doc">Create a TimeSeries from a period start index and a collection of timeseries
+values. The period end index is calculated by adding the size of the
+collection to the period start index.</pre></div><div class="public" id="var-empty-neighbor-val"><h3>empty-neighbor-val</h3><div class="usage"></div><pre class="doc">Returns a NeighborValue object with values for a pixel that should
+have an empty or nil value without breaking the process. TODO:
+figure out what values should be inserted for each feature to truly
+represent the notion of emptiness.</pre></div><div class="public" id="var-fires-cleanup"><h3>fires-cleanup</h3><div class="usage"><code>(fires-cleanup fire-series)</code></div><pre class="doc">If the fire-series is nil, leave it be - it'll be handled in
+`forma-seq-non-thrift`. Else, unpack it</pre></div><div class="public" id="var-forma-seq"><h3>forma-seq</h3><div class="usage"><code>(forma-seq fire-series short-series long-series t-stat-series break-series)</code></div><pre class="doc">Accepts 5 timeseries of equal length and starting position, each
+ representing a time-indexed series of features for a given pixel.
+ Returns the tranposition: a single timeseries of
+ FormaValues.
+
+`fire-series` gets special treatment because it could come into
+ `forma-seq` as nil (i.e. no fires for a given pixel) per the
+ forma-tap query in forma.clj; fires is an ungrounded variable in
+ the cascalog query, forma-tap</pre></div><div class="public" id="var-forma-value"><h3>forma-value</h3><div class="usage"><code>(forma-value fire short param-break long t-stat)</code></div><pre class="doc">Returns a vector containing a FireValue, short-term drop,
+parametrized break, long-term drop and t-stat of the short-term
+drop.</pre></div><div class="public" id="var-merge-neighbors"><h3>merge-neighbors</h3><div class="usage"><code>(merge-neighbors neighbor-val forma-val)</code></div><pre class="doc">Merges the supplied instance of `FormaValue` into the existing
+aggregate collection of `FormaValue`s represented by `neighbor-val`.
+Returns a new neighbor value object representing the merged values.</pre></div><div class="public" id="var-neighbor-value"><h3>neighbor-value</h3><div class="usage"><code>(neighbor-value forma-val)</code><code>(neighbor-value fire neighbors avg-short min-short avg-long min-long avg-stat min-stat avg-param min-param)</code></div><pre class="doc">Accepts either a forma value or a sequence of sub-values.
+</pre></div></div></body></html>
View
124 doc/forma.source.fire.html
@@ -0,0 +1,124 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.source.fire documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li class="current"><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.source.fire.html#var-daily-datestring"><span>daily-datestring</span></a></li><li><a href="forma.source.fire.html#var-fire-characteristics"><span>fire-characteristics</span></a></li><li><a href="forma.source.fire.html#var-fire-pred"><span>fire-pred</span></a></li><li><a href="forma.source.fire.html#var-fire-source-daily"><span>fire-source-daily</span></a></li><li><a href="forma.source.fire.html#var-fire-source-monthly"><span>fire-source-monthly</span></a></li><li><a href="forma.source.fire.html#var-monthly-datestring"><span>monthly-datestring</span></a></li><li><a href="forma.source.fire.html#var-reproject-fires"><span>reproject-fires</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.source.fire documentation</h2><pre class="doc">This namespace has functions and Cascalog queries for processing fire data.
+
+Fires are recorded daily by the Fire Information For Resource Management
+System (http://maps.geog.umd.edu) using the NASA Terra and Aqua satellites.
+They are described using the following attributes which are stored in a CSV
+file:
+
+ http://firefly.geog.umd.edu/firms/faq.htm#attributes
+
+Here's an example CSV file:
+
+ latitude,longitude,brightness,scan,track,acq_date,acq_time,satellite,confidence,version,bright_t31,frp
+ -21.774,-48.371,328.8,2.6,1.6,05/11/2012,0125,T,100,5.0,280.7,164.3
+ -21.770,-48.378,327.4,2.6,1.6,05/11/2012,0125,T,100,5.0,280.3,157.4
+ -16.615,-43.483,307.5,1.1,1.0,05/11/2012,0125,T,55,5.0,285.7,15.8
+
+The FORMA algorithm depends on latitude, longitude, brightness, confidence
+and acq_date. Before these fires can be used, they have to fist get converted
+from latitude and longitude into MODIS pixel coordinates at 500 meter resolution.
+
+Once converted, we store each fire in a DataChunk Thrift object and store it
+into a Pail. Pails are cool because you can append to them. This allows us to
+incrementally process fire data. To see the Thrift object definitions, check
+out the dev/forma.thirft IDL.
+
+After getting converted, here's what a fire DataChunk looks like for a
+single fire.
+
+ DataChunk
+ dataset - The name of the dataset which is just 'fire'
+ locationProperty - The ModisPixelLocation Thrift object.
+ chunkValue - The FireTuple Thrift object.
+ temporalRes - The temporal resolution of fires which is one day.
+ date - The acq_date field for the fire.
+
+The FireTuple Thrift object defines properties of a single fire or multiple
+fires. In this step, it represents a single fire. The 'temp330' is set to 1
+if the fire is greater than 330 degrees Kelvin. The 'conf50' is set to 1 if
+the fire confidence is greater than 50. If 'temp330' and 'conf50' are both 1,
+the 'bothPreds' is set to 1. For a single fire, the 'count' is set to 1.
+
+At the end of this step, we have a single Pail full of DataChunk objects, one
+per fire, each which represents the fire in MODIS pixel coordinates.
+
+Note: We received fire data organized into files by month through February
+2010 from the University of Maryland. These are stored on S3 in the
+s3://modisfiles/MonthlyFires directory. More recent fire data are organized
+into daily files. The difference between them is the date formatting and
+we have functions here to convert between them.
+
+ Daily: MM/DD/YYYY
+ Monthly: YYYYMMDD</pre><div class="public" id="var-daily-datestring"><h3>daily-datestring</h3><div class="usage"><code>(daily-datestring date-str)</code></div><pre class="doc">Returns a daily date string formatted as YYYY-MM-DD.
+
+ Arguments:
+ date-str - Daily date string formatted as MM/DD/YYYY.
+
+Example usage:
+ &gt; (daily-&gt;standard 1977/02/02)
+ 02-1977-02</pre></div><div class="public" id="var-fire-characteristics"><h3>fire-characteristics</h3><div class="usage"></div><pre class="doc">Returns a Cascalog predicate macro that creates a FireTuple Thrift object.
+
+Input variables:
+ ?conf - The fire confidence value.
+ ?kelvin - The fire degress in Kelvin
+
+Output variables:
+ ?tuple - The FireTuple Thrift object.
+
+Example usage:
+
+ &gt; (let [src [[60 380]]]
+ (??&lt;-
+ [?tuple]
+ (src ?conf ?kelvin)
+ (fire-characteristics ?conf ?kelvin :&gt; ?tuple)))</pre></div><div class="public" id="var-fire-pred"><h3>fire-pred</h3><div class="usage"></div><pre class="doc">Returns a Cascalog predicate macro that creates a FireTuple Thrift object.
+
+Input variables:
+ ?s-lat - The string latitude for the fire.
+ ?s-lon - The string latitude for the fire.
+ ?s-kelvin - The string kelvin value for the fire.
+ ?s-conf - The string confidence value for the fire.
+
+Output variables:
+ ?dataset - The fire dataset name (fire).
+ ?t-res - The fire temporal resolution (1 day).
+ ?lat - The fire latitude as a float.
+ ?lon - The fire longitude as a float.
+ ?tuple - The FireTuple Thrift object representing this fire.
+
+Example usage:
+ &gt; (let [src [[&quot;1&quot; &quot;2&quot; &quot;331&quot; &quot;51&quot;]]]
+ (??&lt;-
+ [?dataset ?t-res ?lat ?lon ?fire-tuple]
+ (src ?s-lat ?s-lon ?s-kelvin ?s-conf)
+ (fire-pred ?s-lat ?s-lon ?s-kelvin ?s-conf :&gt; ?dataset ?t-res ?lat ?lon ?tuple)))</pre></div><div class="public" id="var-fire-source-daily"><h3>fire-source-daily</h3><div class="usage"><code>(fire-source-daily src)</code></div><pre class="doc">Returns a Cascalog query that creates tuples for daily fires.
+
+Source:
+ src - An hfs-textline of daily fires (lat lon kelvin _ _ date _ _ conf _ _ _)
+
+Output variables:
+ ?dataset - The dataset name (fires).
+ ?date - The fire date formatted as YYYY-MM-DD.
+ ?t-res - The fire temporal resolution (1).
+ ?lat - The fire latitude as a float.
+ ?lon - The fire longitude as a float.
+ ?tuple - The FireTuple Thrift object representing the fire.</pre></div><div class="public" id="var-fire-source-monthly"><h3>fire-source-monthly</h3><div class="usage"><code>(fire-source-monthly src)</code></div><pre class="doc">Returns a Cascalog query that creates tuples for monthly fires.
+
+Source:
+ src - An hfs-textline of monthly fires (datestring _ _ s-lat s-lon s-kelvin _ _ _ s-conf)
+
+Output variables:
+ ?dataset - The dataset name (fires).
+ ?date - The fire date formatted as YYYY-MM-DD.
+ ?t-res - The fire temporal resolution (1).
+ ?lat - The fire latitude as a float.
+ ?lon - The fire longitude as a float.</pre></div><div class="public" id="var-monthly-datestring"><h3>monthly-datestring</h3><div class="usage"><code>(monthly-datestring date-str)</code></div><pre class="doc">Returns a monthly date string formatted as YYYY-MM-DD.
+
+ Arguments:
+ date-str - Monthly date string formatted as YYYYMMDD.
+
+Example usage:
+ &gt; (monthly-&gt;standard 19770202)
+ 1977-02-02</pre></div><div class="public" id="var-reproject-fires"><h3>reproject-fires</h3><div class="usage"><code>(reproject-fires m-res src)</code></div><pre class="doc">Returns a Cascalog query that creates DataChunk Thrift objects for fires.
+</pre></div></div></body></html>
View
7 doc/forma.source.gadmiso.html
@@ -0,0 +1,7 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.source.gadmiso documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li class="current"><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.source.gadmiso.html#var-gadm-%3Eiso"><span>gadm-&gt;iso</span></a></li><li><a href="forma.source.gadmiso.html#var-gadm-iso"><span>gadm-iso</span></a></li><li><a href="forma.source.gadmiso.html#var-parse-line"><span>parse-line</span></a></li><li><a href="forma.source.gadmiso.html#var-text-map"><span>text-map</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.source.gadmiso documentation</h2><pre class="doc"></pre><div class="public" id="var-gadm-%3Eiso"><h3>gadm-&gt;iso</h3><div class="usage"><code>(gadm-&gt;iso gadm)</code></div><pre class="doc">Accepts an integer GADM ID and returns the associated ISO3 code as
+a string; wraps gadm-iso map for use in a cascalog query</pre></div><div class="public" id="var-gadm-iso"><h3>gadm-iso</h3><div class="usage"></div><pre class="doc">Returns a single hash-map that associates all GADMs and ISO codes.
+</pre></div><div class="public" id="var-parse-line"><h3>parse-line</h3><div class="usage"><code>(parse-line x)</code></div><pre class="doc">Accepts a vectorized string, as outputted by `text-map`, and
+returns a single hash-map with the GADM ID (integer) as the key and
+the ISO3 code (string) as the value.</pre></div><div class="public" id="var-text-map"><h3>text-map</h3><div class="usage"></div><pre class="doc">Returns a sequence of vectorized strings (e.g., [&quot;AFG,1&quot;])
+from the admin-map located in the resources folder.</pre></div></div></body></html>
View
33 doc/forma.source.hdf.html
@@ -0,0 +1,33 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.source.hdf documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li class="current"><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.source.hdf.html#var-dataset-filter"><span>dataset-filter</span></a></li><li><a href="forma.source.hdf.html#var-make-subdataset"><span>make-subdataset</span></a></li><li><a href="forma.source.hdf.html#var-meta-values"><span>meta-values</span></a></li><li><a href="forma.source.hdf.html#var-metadata"><span>metadata</span></a></li><li><a href="forma.source.hdf.html#var-modis-chunks"><span>modis-chunks</span></a></li><li><a href="forma.source.hdf.html#var-modis-subsets"><span>modis-subsets</span></a></li><li><a href="forma.source.hdf.html#var-raster-chunks"><span>raster-chunks</span></a></li><li><a href="forma.source.hdf.html#var-split-id"><span>split-id</span></a></li><li><a href="forma.source.hdf.html#var-subdataset-key"><span>subdataset-key</span></a></li><li><a href="forma.source.hdf.html#var-subdataset-names"><span>subdataset-names</span></a></li><li><a href="forma.source.hdf.html#var-tileid-%3Eres"><span>tileid-&gt;res</span></a></li><li><a href="forma.source.hdf.html#var-unpack-modis"><span>unpack-modis</span></a></li><li><a href="forma.source.hdf.html#var-with-gdal-open"><span>with-gdal-open</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.source.hdf documentation</h2><pre class="doc"></pre><div class="public" id="var-dataset-filter"><h3>dataset-filter</h3><div class="usage"><code>(dataset-filter good-keys)</code></div><pre class="doc">Generates a predicate function that checks a name from the
+SUBDATASETS metadata dictionary against the supplied collection of
+acceptable dataset keys.</pre></div><div class="public" id="var-make-subdataset"><h3>make-subdataset</h3><div class="usage"><code>(make-subdataset path)</code></div><pre class="doc">Accepts a filepath from the SUBDATASETS dictionary of a MODIS Dataset,
+and returns a 2-tuple consisting of the modis-subsets key (&quot;ndvi&quot;)
+ and a gdal.Dataset object representing the unpacked MODIS data.</pre></div><div class="public" id="var-meta-values"><h3>meta-values</h3><div class="usage"><code>(meta-values dataset)</code></div><pre class="doc">Returns metadata values for a given unpacked MODIS Dataset,
+corresponding to the supplied seq of keys.</pre></div><div class="public" id="var-metadata"><h3>metadata</h3><div class="usage"><code>(metadata modis)</code><code>(metadata modis key)</code></div><pre class="doc">Returns the metadata map for the supplied MODIS Dataset.
+</pre></div><div class="public" id="var-modis-chunks"><h3>modis-chunks</h3><div class="usage"><code>(modis-chunks datasets chunk-size source)</code></div><pre class="doc">Takes a cascading source, and returns a number of tuples that fully
+describe chunks of MODIS data for the supplied datasets. Chunks are
+represented as seqs of floats. Be sure to convert chunks to vector
+before running any sort of data analysis, as seqs require linear
+time for lookups.</pre></div><div class="public" id="var-modis-subsets"><h3>modis-subsets</h3><div class="usage"></div><pre class="doc">Map between MODIS dataset identifiers (arbitrarily chosen by the
+REDD team) and corresponding unique substrings, culled from values
+in the &quot;NAMES&quot; entries of the SUBDATASETS hashtable of MOD13A3 HDF
+file. No simple, descriptive tag exists within the metadata, as of
+2/05/2011, so this ends up being the best solution.</pre></div><div class="public" id="var-raster-chunks"><h3>raster-chunks</h3><div class="usage"><code>(raster-chunks data)</code></div><pre class="doc">Unpacks the data inside of a MODIS band and partitions it into
+chunks sized according to the supplied value. Specifically, returns
+a lazy sequence of 2-tuples of the form `[chunk-index, vector]`.</pre></div><div class="public" id="var-split-id"><h3>split-id</h3><div class="usage"><code>(split-id tileid)</code></div><pre class="doc">Returns a sequence containing the modis h and v coordinates, where
+h and v refer to the MODIS tile referenced by the supplied
+TileID. The precondition makes sure that the processed product uses
+a sinusoial projection.</pre></div><div class="public" id="var-subdataset-key"><h3>subdataset-key</h3><div class="usage"><code>(subdataset-key path)</code></div><pre class="doc">Takes a long-form path to a MODIS subdataset, and checks to see if
+any of the values of the `modis-subsets` map can be found as
+substrings. If we find one, we return the associated key, cast to a
+string -- 'ndvi', for example.</pre></div><div class="public" id="var-subdataset-names"><h3>subdataset-names</h3><div class="usage"><code>(subdataset-names hdf-path)</code></div><pre class="doc">Returns the NAME entries of the SUBDATASETS metadata map for the
+dataset at a given filepath.</pre></div><div class="public" id="var-tileid-%3Eres"><h3>tileid-&gt;res</h3><div class="usage"><code>(tileid-&gt;res tileid)</code></div><pre class="doc">Returns a string representation of the resolution (in meters) of
+the tile data referenced by the supplied TileID.The second character
+of a MODIS TileID acts as a key to retrieve this data.</pre></div><div class="public" id="var-unpack-modis"><h3>unpack-modis</h3><div class="usage"><code>(unpack-modis)</code><code>(unpack-modis tdir stream)</code><code>(unpack-modis tdir)</code></div><pre class="doc">Stateful approach to unpacking HDF files. Registers all gdal
+formats, Creates a temp directory, then saves the byte array to
+disk. This byte array is processed with gdal. On teardown, the temp
+directory is destroyed. Function returns the decompressed MODIS file
+as a 1-tuple.</pre></div><div class="public" id="var-with-gdal-open"><h3>with-gdal-open</h3><div class="usage"><code>(with-gdal-open [sym path] &amp; body)</code></div><pre class="doc">Accepts a vector containing a symbol and a path to a file capable
+of being opened with `gdal/Open`, and binds the opened dataset to
+the supplied symbol.</pre></div></div></body></html>
View
68 doc/forma.source.rain.html
@@ -0,0 +1,68 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.source.rain documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li class="current"><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.source.rain.html#var-floats-for-step"><span>floats-for-step</span></a></li><li><a href="forma.source.rain.html#var-rain-chunks"><span>rain-chunks</span></a></li><li><a href="forma.source.rain.html#var-rain-months"><span>rain-months</span></a></li><li><a href="forma.source.rain.html#var-rain-tuples"><span>rain-tuples</span></a></li><li><a href="forma.source.rain.html#var-rain-values"><span>rain-values</span></a></li><li><a href="forma.source.rain.html#var-resample-rain"><span>resample-rain</span></a></li><li><a href="forma.source.rain.html#var-to-datestring"><span>to-datestring</span></a></li><li><a href="forma.source.rain.html#var-to-rows"><span>to-rows</span></a></li><li><a href="forma.source.rain.html#var-unpack-rain"><span>unpack-rain</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.source.rain documentation</h2><pre class="doc"></pre><div class="public" id="var-floats-for-step"><h3>floats-for-step</h3><div class="usage"><code>(floats-for-step step)</code></div><pre class="doc">Length of the row of floats (in # of bytes) representing the earth
+at the specified spatial step.</pre></div><div class="public" id="var-rain-chunks"><h3>rain-chunks</h3><div class="usage"><code>(rain-chunks m-res {:keys [nodata], :as ascii-map} chunk-size file-tap pix-tap)</code></div><pre class="doc">Cascalog subquery to fully process a WGS84 float array at the
+supplied resolution (`:step`, within `ascii-map`) into tuples
+suitable for comparison to any MODIS dataset at the supplied modis
+resolution `m-res`, partitioned by the supplied chunk size.</pre></div><div class="public" id="var-rain-months"><h3>rain-months</h3><div class="usage"><code>(rain-months step)</code></div><pre class="doc">Generates a predicate macro to extract all months from a directory
+of PREC/L datasets, paired with a datestring of the format
+`yyyy-mm-dd`. Filename must be of the format
+
+ precl_mon_v1.0.lnx.YYYY.gri0.5m(.gz, optionally).</pre></div><div class="public" id="var-rain-tuples"><h3>rain-tuples</h3><div class="usage"><code>(rain-tuples step stream)</code></div><pre class="doc">Returns a lazy seq of 2-tuples representing NOAA PREC/L rain
+data. Each 2-tuple is of the form `[idx, month-arr]`, where `idx`
+is the 1-based month and `month-vec` is a `(* 720 360)` float-array.
+
+Note that we take every other element in the `partition-stream` seq,
+skipping data concerning # of gauges.</pre></div><div class="public" id="var-rain-values"><h3>rain-values</h3><div class="usage"><code>(rain-values step source)</code></div><pre class="doc">Generates a cascalog subquery from the supplied WGS84 step size and
+source of `?filename` and `?file` tiles; this subquery returns
+individual rain values, marked by `?row`, `?col` and `?val` from the
+original WGS84 matrix. A date field is also included.</pre></div><div class="public" id="var-resample-rain"><h3>resample-rain</h3><div class="usage"><code>(resample-rain m-res {:keys [step nodata], :as ascii-map} file-tap pix-tap &amp; args)</code></div><pre class="doc">A Cascalog query that takes a tap emitting rain tuples and a tap emitting
+MODIS pixels for a set of MODIS tiles and emits the same rain tuples
+resampled into MODIS pixel coordinates.
+
+For example, given a rain tuple [date row col value]:
+
+ [2000-01-01 239 489 100]
+
+The corresponding rain tuple [h v sample line] in MODIS pixel coordinates is:
+
+ [8 6 0 0]
+
+Definitely note that there's a join happening in this query! The value of ?row
+and ?col must be the same wherever it is used, and since rain-vals and
+wgs84-indexer are separate sources of ?row and ?col, Cascalog will use an
+implicit join to resolve the query. Powerful stuff!
+
+Arguments:
+ m-res - The MODIS resolution as a string.
+ ascii-map - A map containing values for step and nodata values.
+ file-tap - Cascalog generator that emits rain tuples [date row col value].
+ pix-tap - Cascalog generator that emits MODIS pixel tuples [h v sample line].
+ args - Optional memory file-tap of rain tuples used for testing.
+
+Query result variables:
+ ?dataset - The dataset name (precl)
+ ?m-res - The MODIS spatial resolution in meters.
+ ?t-res - The MODIS temporal resolution in days.
+ !date - The nullable date of the rain tuple.
+ ?mod-h - The MODIS h tile coordinate.
+ ?mod-v - The MODIS v tile coordinate.
+ ?sample - The MODIS tile sample coordinate.
+ ?line - The MODIS tile line coordinate.
+ ?val - The rain value.
+
+Example usage:
+ &gt; (??-
+ (let [tile-seq #{[8 6]}
+ file-tap nil
+ test-rain-data [[&quot;2000-01-01&quot; 239 489 100]]
+ pix-tap [[8 6 0 0]]
+ ascii-map {:corner [0 -90] :travel [+ +] :step 0.5 :nodata -999}
+ m-res &quot;500&quot;]
+ (resample-rain m-res ascii-map file-tap pix-tap test-rain-data)))</pre></div><div class="public" id="var-to-datestring"><h3>to-datestring</h3><div class="usage"><code>(to-datestring filename month-int)</code></div><pre class="doc">Processes an NOAA PRECL filename and integer month index, and
+returns a datestring of the format `yyyy-mm-dd`. Filename is assumed
+to by formatted as `precl_mon_v1.0.lnx.YYYY.gri0.5m`, with a single
+group of four digits representing the year.</pre></div><div class="public" id="var-to-rows"><h3>to-rows</h3><div class="usage"><code>(to-rows coll)</code></div><pre class="doc">Converts a month's worth of PRECL data, stored in a vector,
+into single rows of data, based on the supplied step size. `to-rows`
+outputs 2-tuples of the form `[row-idx, row-array]`.</pre></div><div class="public" id="var-unpack-rain"><h3>unpack-rain</h3><div class="usage"><code>(unpack-rain stream)</code></div><pre class="doc">Unpacks a PREC/L binary file for a given year, and returns a lazy
+sequence of 2-tuples, in the form of (month, data). Assumes that
+binary files are packaged as hadoop BytesWritable objects.</pre></div></div></body></html>
View
31 doc/forma.source.static.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.source.static documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li class="current"><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.source.static.html#var-agg-chunks"><span>agg-chunks</span></a></li><li><a href="forma.source.static.html#var-downsample-modis"><span>downsample-modis</span></a></li><li><a href="forma.source.static.html#var-index-textfile"><span>index-textfile</span></a></li><li><a href="forma.source.static.html#var-static-chunks"><span>static-chunks</span></a></li><li><a href="forma.source.static.html#var-static-modis-chunks"><span>static-modis-chunks</span></a></li><li><a href="forma.source.static.html#var-upsample-modis"><span>upsample-modis</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.source.static documentation</h2><pre class="doc"></pre><div class="public" id="var-agg-chunks"><h3>agg-chunks</h3><div class="usage"><code>(agg-chunks val-gen m-res chunk-size nodata)</code></div><pre class="doc">val-gen must generate
+
+?dataset ?m-res ?t-res !date ?mod-h ?mod-v ?sample ?line ?val</pre></div><div class="public" id="var-downsample-modis"><h3>downsample-modis</h3><div class="usage"><code>(downsample-modis m-res dataset pixel-tap line-tap agg)</code></div><pre class="doc">Returns a cascalog query designed to pair each value on an ASCII
+ data grid with a particular MODIS pixel at the specified spatial
+ resolution, `m-res`. The modis pixels produced by the supplied
+ `pixel-tap` act as a set; only pixels with locations matching those
+ produced by `pixel-tap` will be output.
+
+`downsample-modis` handles situations in which the ASCII resolution
+ is higher than the supplied MODIS resolution; more than one value is
+ guaranteed to exist for every MODIS pixel. `agg` (`c/sum` or `c/max`
+ are supported, currently) determines the way in which multiple
+ values are combined.</pre></div><div class="public" id="var-index-textfile"><h3>index-textfile</h3><div class="usage"><code>(index-textfile base-path old-file-name new-file-name num-drop)</code></div><pre class="doc">Prepend a row index to a text file `old-file-name`, located at `base-path`,
+and save in the same directory with new name `new-file-name`. The
+`num-drop` parameter specifies the number of lines to drop from the
+beginning of the text file. Note that indexing begins with the
+first textline not dropped, and starts at 0. This function was
+originally written to clean an ASCII raster file for input into the
+sampling functions.</pre></div><div class="public" id="var-static-chunks"><h3>static-chunks</h3><div class="usage"><code>(static-chunks m-res chunk-size dataset agg line-tap pix-tap)</code></div><pre class="doc">TODO: DOCS!
+</pre></div><div class="public" id="var-static-modis-chunks"><h3>static-modis-chunks</h3><div class="usage"><code>(static-modis-chunks chunk-size dataset agg line-tap pix-tap)</code></div><pre class="doc">TODO: DESTROY. Replace with a better system.
+</pre></div><div class="public" id="var-upsample-modis"><h3>upsample-modis</h3><div class="usage"><code>(upsample-modis m-res dataset pixel-tap line-tap)</code></div><pre class="doc">Returns a cascalog query designed to pair each value on an ASCII
+ data grid with a particular MODIS pixel at the specified spatial
+ resolution, `m-res`.
+
+`upsample-modis` handles the case in which the resolution of the
+ supplied ASCII grid is lower than the supplied MODIS resolution. We
+ accept a source of MODIS coordinates along with the source of text
+ lines, determine the position within the ascii grid of the centroid
+ of each modis coordinate, and perform an inner join on the ASCII
+ data, effectively sampling all ASCII data into a higher resolution.</pre></div></div></body></html>
View
7 doc/forma.source.tilesets.html
@@ -0,0 +1,7 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.source.tilesets documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li class="current"><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.source.tilesets.html#var-country-tiles"><span>country-tiles</span></a></li><li><a href="forma.source.tilesets.html#var-tile-set"><span>tile-set</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.source.tilesets documentation</h2><pre class="doc"></pre><div class="public" id="var-country-tiles"><h3>country-tiles</h3><div class="usage"></div><pre class="doc">MODIS tiles for the selected countries, identified by their ISO3
+codes where each two-vector is the horizontal and vertical position
+of the MODIS tile `[mod-h mod-v]`</pre></div><div class="public" id="var-tile-set"><h3>tile-set</h3><div class="usage"><code>(tile-set &amp; inputs)</code></div><pre class="doc">set of unique MODIS tiles for the specified
+countries (union). Example usage:
+
+ (tile-set [8 6] :IDN :MYS :PHL)</pre></div></div></body></html>
View
53 doc/forma.static.html
@@ -0,0 +1,53 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.static documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li class="current"><a href="forma.static.html"><span>forma.static</span></a></li><li><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.static.html#var-static-datasets"><span>static-datasets</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.static documentation</h2><pre class="doc"></pre><div class="public" id="var-static-datasets"><h3>static-datasets</h3><div class="usage"></div><pre class="doc">These are the static datasets, described briefly
+below. Each dataset must be formatted as:
+
+ {:corner [lon, lat]
+ :travel [lon-dir, lat-dir]
+ :step step-size
+ :nodata no-data-value}
+
+ [NOAA PRECL](http://goo.gl/yDQhA) :: Global precipitation rates in
+ mm/day, by month, gridded at 0.5 degree resolution. The linked dataset
+ is 2.5 degree -- we use a higher resolution dataset in binary
+ format. Considered static relative to frequency of MODIS data.
+
+ gadm :: administrative boundaries, found
+ [here](http://goo.gl/2N5CT), and converted to a raster with the
+ cell value given by ID_2, an integer value corresponding to the
+ most detailed administrative unit. .01 degree resolution chosen
+ for simplicity, but should have limited impact on where a pixel
+ falls aside from at borders.
+
+ ecoid :: ecoregions according to the World Wildlife Fund. The
+ technical paper can be found [here](http://goo.gl/yvssq). The
+ polygons are converted to a raster for sampling - much like the
+ admin boundaries - where each cell is assigned the value of the
+ ecoregion id, the most detailed eco unit. .01 degree resolution
+ chosen for simplicity, but should have limited impact on where
+ a pixel falls aside from at borders.
+
+ hansen :: forest cover loss hotspots data for training at 500m
+ resolution, found [here](http://goo.gl/HqvCW). Note that this has
+ been projected into WGS84 from Sinusoidal (463.3127m res). The
+ time period is 2000-2005. UPDATE: This may be superceded by the
+ use of an unreprojected ascii grid that lines up perfectly with
+ MODIS data and can therefore be assigned to MODIS pixels with
+ no error from reprojection.
+
+ vcf :: vegetation continuous field index, derived from MODIS
+ products for the year 2000, found [here](http://goo.gl/KW8y1), and
+ used to define the extent of the sample area, given by the Forest
+ Cover Loss Hotspots training data set. UPDATE: This may be
+ superceded by the use of an unreprojected ascii grid that lines up
+ perfectly with MODIS data and can therefore be assigned to MODIS
+ pixels with no error from reprojection.
+
+ border :: index from 1-20 representing 500m increments of distance
+ to a coastline as defined by the GADM Level 0 dataset available at
+ GADM.org. Coastlines are defined as the border between land and large
+ bodies of water (water is 0, undefined -9999). Land is defined by the
+ polygon of country boundaries. Projected World Sinusoidal for distance
+ calculations with ~463m resolution. Then reprojected WGS84 with
+ .0083333 resolution for conversion to ascii grid, with bilinear
+ interpolation of pixel values.</pre></div></div></body></html>
View
20 doc/forma.testing.html
@@ -0,0 +1,20 @@
+<!DOCTYPE html>
+<html><head><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>forma.testing documentation</title></head><body><div id="header"><h1><a href="index.html">Forma 0.2.0-SNAPSHOT API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><span>Namespaces</span></h3><ul><li><a href="forma.classify.logistic.html"><span>forma.classify.logistic</span></a></li><li><a href="forma.date-time.html"><span>forma.date-time</span></a></li><li><a href="forma.gfw.cdm.html"><span>forma.gfw.cdm</span></a></li><li><a href="forma.hadoop.cli.html"><span>forma.hadoop.cli</span></a></li><li><a href="forma.hadoop.io.html"><span>forma.hadoop.io</span></a></li><li><a href="forma.hadoop.jobs.cdm.html"><span>forma.hadoop.jobs.cdm</span></a></li><li><a href="forma.hadoop.jobs.forma.html"><span>forma.hadoop.jobs.forma</span></a></li><li><a href="forma.hadoop.jobs.modis.html"><span>forma.hadoop.jobs.modis</span></a></li><li><a href="forma.hadoop.jobs.neighbors.html"><span>forma.hadoop.jobs.neighbors</span></a></li><li><a href="forma.hadoop.jobs.preprocess.html"><span>forma.hadoop.jobs.preprocess</span></a></li><li><a href="forma.hadoop.jobs.scatter.html"><span>forma.hadoop.jobs.scatter</span></a></li><li><a href="forma.hadoop.jobs.timeseries.html"><span>forma.hadoop.jobs.timeseries</span></a></li><li><a href="forma.hadoop.pail.html"><span>forma.hadoop.pail</span></a></li><li><a href="forma.hadoop.predicate.html"><span>forma.hadoop.predicate</span></a></li><li><a href="forma.hoptree.html"><span>forma.hoptree</span></a></li><li><a href="forma.matrix.utils.html"><span>forma.matrix.utils</span></a></li><li><a href="forma.matrix.walk.html"><span>forma.matrix.walk</span></a></li><li><a href="forma.ops.classify.html"><span>forma.ops.classify</span></a></li><li><a href="forma.playground.html"><span>forma.playground</span></a></li><li><a href="forma.postprocess.output.html"><span>forma.postprocess.output</span></a></li><li><a href="forma.reproject.html"><span>forma.reproject</span></a></li><li><a href="forma.schema.html"><span>forma.schema</span></a></li><li><a href="forma.source.fire.html"><span>forma.source.fire</span></a></li><li><a href="forma.source.gadmiso.html"><span>forma.source.gadmiso</span></a></li><li><a href="forma.source.hdf.html"><span>forma.source.hdf</span></a></li><li><a href="forma.source.rain.html"><span>forma.source.rain</span></a></li><li><a href="forma.source.static.html"><span>forma.source.static</span></a></li><li><a href="forma.source.tilesets.html"><span>forma.source.tilesets</span></a></li><li><a href="forma.static.html"><span>forma.static</span></a></li><li class="current"><a href="forma.testing.html"><span>forma.testing</span></a></li><li><a href="forma.thrift.html"><span>forma.thrift</span></a></li><li><a href="forma.trends.analysis.html"><span>forma.trends.analysis</span></a></li><li><a href="forma.trends.filter.html"><span>forma.trends.filter</span></a></li><li><a href="forma.trends.stretch.html"><span>forma.trends.stretch</span></a></li><li><a href="forma.utils.html"><span>forma.utils</span></a></li></ul></div><div class="sidebar" id="vars"><h3>Public Vars</h3><ul><li><a href="forma.testing.html#var-dev-path"><span>dev-path</span></a></li><li><a href="forma.testing.html#var-get-current-directory"><span>get-current-directory</span></a></li><li><a href="forma.testing.html#var-project-path"><span>project-path</span></a></li><li><a href="forma.testing.html#var-resources-path"><span>resources-path</span></a></li><li><a href="forma.testing.html#var-test-path"><span>test-path</span></a></li></ul></div><div class="namespace-docs" id="content"><h2>forma.testing documentation</h2><pre class="doc">These functions provide assistance for directory
+navigation for testing. One compromise we make here is the binding
+of `dev-resources-subdir`; This is defined as `:dev-resources-path`
+in `project.clj`, but reading either of these would force a
+dependency on pallet or cake. We've included a test to make sure
+that `dev` exists on any deployment of the given project; a failing
+test means that this directory should be created.</pre><div class="public" id="var-dev-path"><h3>dev-path</h3><div class="usage"><code>(dev-path)</code><code>(dev-path sub-path)</code></div><pre class="doc">Returns the path within the project to the dev path or a
+subdirectory within dev.
+
+Example usage:
+ (dev-path) =&gt; &quot;forma-clj/dev&quot;