<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
</head>
<body>
<p>Hello,</p>
<p><br>
</p>
<p>Just a heads up that the JS bindings for GDAL now have an <i>ExprTk.js
</i>plugin that comes with a stand-alone CLI alternative of <i>gdal_calc.py</i>
- <i>gdal_calc.js</i>.</p>
<p><br>
</p>
<p>While it is geared mostly towards the Node.js GDAL user and it
lacks many of the features of <i>gdal_calc.py</i>, it has a
number of interesting advantages for everyone who is using it for
Earth sciences:<br>
</p>
<blockquote>
<p>* As Earth sciences datasets always have blank spots, when
working with floating-point data types, it automatically
converts <i>NoData</i> values to <i>NaN</i> before applying
the expression and then <i>NaN</i> to <i>NoData</i> when
writing the output - so you don't have to handle it in any
special way - any expression that uses at least one <i>NaN</i>
input automatically produces a <i>NaN</i> output that gets
written as <i>NoData</i> - and this is smart enough to let pass
an unused input in an if/else statement<br>
</p>
<p>* It is fully multithreaded, each input band and each output
band run in separate threads, and the expression evaluation can
even use fork to evaluate series of pixels in separate threads -
though this requires very complex expressions to be of any use -
<i>gdal_calc</i> is mostly I/O bound<br>
</p>
<p>* It supports both JS functions and <i>ExprTk.js</i>
expressions that allow for natural if/else expressions and
complex control blocks</p>
</blockquote>
<p> * It can write multi-band files applying a separate
expression on each band</p>
<p><br>
</p>
<p> <a class="moz-txt-link-freetext" href="https://www.npmjs.com/package/gdal-exprtk">https://www.npmjs.com/package/gdal-exprtk</a></p>
<p><br>
</p>
<pre class="moz-signature" cols="72">--
Momtchil Momtchev <a class="moz-txt-link-rfc2396E" href="mailto:momtchil@momtchev.com"><momtchil@momtchev.com></a>
</pre>
</body>
</html>