<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><br class=""><div><blockquote type="cite" class=""><div class="">Le 16 sept. 2018 à 21:26, Kirill Kouzoubov <<a href="mailto:kirill888@gmail.com" class="">kirill888@gmail.com</a>> a écrit :</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">This would be very useful, reducing storage costs while simultaneously allowing faster preview functionality. </div></div></blockquote><div><br class=""></div><br class=""><blockquote type="cite" class=""><div class=""><div dir="ltr" class="">One issue to consider is `dtype` support/conversion. My understanding is that JPEG is best supported at 8 bit, and can not go beyond 12, while many sensors have more than 8 bits worth of data per band, and even more than 12.</div></div></blockquote><div><br class=""></div>Yeah absolutely, so this would be only for 8bit/12bit RGB dataset (noting that enabling different photogrammetric configuration could save more space too for YCBCR+JPEG). </div><div class=""><br class=""><blockquote type="cite" class=""><div class=""><div dir="ltr" class=""> So one would need bit-depth reduction as well. To complicated things further, one might have 14-bit data stored in 16-bit image, so bit-depth reduction is not a trivial operation.</div></div></blockquote><div class=""><br class=""></div><div class="">Yeah I don’t want to overthink this, and create complex dataset (data difference between overview and high res, just thinking about compression) </div><br class=""><blockquote type="cite" class=""><div class=""><div dir="ltr" class=""> Also `nodata` comes into play as well.</div></div></blockquote><div class=""><br class=""></div>I think using internal bitmask is a better solution than nodata IMO but that’s another subject :D . <br class=""><div class=""><br class=""></div><div class="">Vincent </div><br class=""><blockquote type="cite" class=""><div class=""><div dir="ltr" class=""><div class=""><br class=""></div><div class="">Kirill </div></div><br class=""><div class="gmail_quote"><div dir="ltr" class="">On Mon, Sep 17, 2018 at 10:39 AM Vincent Sarago <<a href="mailto:vincent.sarago@gmail.com" class="">vincent.sarago@gmail.com</a>> wrote:<br class=""></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">What do I mean about `mixed` compression ? <br class="">
JPEG (or WEBP) compression are great for storage saving (and also for small http request) but they are `bad` because they are not lossless (WEBP can be set to be lossless but compression is then not as great) so my idea is to package both lossless and non-lossless in one COG. e.g keeping high resolution data to a ZSTD/DEFLATE compression but the overview in JPEG.<br class="">
<br class="">
Why ? <br class="">
For web application we mostly want fast tile serving while for processing we will mostly want to read full resolution lossless data, a file with mixed compression could make both world happy ? <br class="">
<br class="">
The gain won’t be astonishing but might be worth a try ? <br class="">
<br class="">
Vincent <br class="">
_______________________________________________<br class="">
COG mailing list<br class="">
<a href="mailto:COG@lists.osgeo.org" target="_blank" class="">COG@lists.osgeo.org</a><br class="">
<a href="https://lists.osgeo.org/mailman/listinfo/cog" rel="noreferrer" target="_blank" class="">https://lists.osgeo.org/mailman/listinfo/cog</a><br class="">
</blockquote></div>
</div></blockquote></div><br class=""></body></html>