Skip to content
fitoprincipe edited this page Sep 13, 2019 · 4 revisions

This module holds batch processes. It's divided in scopes. At the moment there is only one:

NOTE: Import the module:

var batch = require('users/fitoprincipe/geetools:batch');

Download

ImageCollection.toAsset(collection, assetFolder, options)

Download every image of an ee.ImageCollection to an Asset.

IMPORTANT: It can't create folders or collections in assets, so they must be created before executing this function

Argument options:

  • name: name of the ImageCollection (not the images inside)
  • scale
  • maxPixels
  • region: if this argument is not defined or null it will try to use each image footprint

ImageCollection.toDrive(collection, folder, options)

Download every image of an ee.ImageCollection to Google Drive.

Argument options:

  • name: a name pattern to name each image. Keywords between brackets will be replaced. You can use all image properties and two special keywords:
    • {id}: the image id
    • {system_date}: the date of the image
  • dateFormat: the date format to use for {system_date}, defaults to yyyy-MM-dd
  • scale
  • maxPixels
  • region: if this argument is not defined or null it will try to use each image footprint
  • type: one of float, byte, int, double, long, short, int8, int16, int32, int64, uint8 , uint16, uint32