LoginSignup
0
0

More than 3 years have passed since last update.

Google Earth Engineで標高

Posted at

概要

Google Earth Engineで、標高、計算してみた。

写真

無題.jpg

サンプルコード

var srtm = ee.Image('USGS/SRTMGL1_003');
var pt = ee.Geometry.Point(139.7978, 35.6028);
var lines = ee.List.sequence(0, 4000, 200);
var contourlines = lines.map(function(line) {
    var mycontour = srtm.convolve(ee.Kernel.gaussian(5, 3)).subtract(ee.Image.constant(line)).zeroCrossing().multiply(ee.Image.constant(line)).toFloat();
    return mycontour.mask(mycontour);
});
contourlines = ee.ImageCollection(contourlines).mosaic();
Map.addLayer(contourlines, {
    min: 0, 
    max: 5000, 
    palette: ['00ff00', 'ff0000']
}, 'contours');
Map.centerObject(pt, 7);



以上。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0