utils module
exportTableToAsset(collection, description, asset_id)
Export FeatureCollection to GEE Asset
Source code in src\rlcms\utils.py
191 192 193 194 195 196 197 198 199 200 201 202 203 204 |
|
exportTableToDrive(collection, description, folder, file_name_prefix, selectors)
export FeatureCollection to Google Drive
Source code in src\rlcms\utils.py
206 207 208 209 210 211 212 213 214 215 216 |
|
export_image_to_drive(image, description='myExportImageTask', folder=None, fileNamePrefix=None, dimensions=None, region=None, scale=None, crs=None, crsTransform=None, maxPixels=None, shardSize=None, fileDimensions=None, skipEmptyTiles=None, fileFormat=None, formatOptions=None, **kwargs)
Creates a batch task to export an Image as a raster to Google Drive.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
image |
The image to be exported. |
required | |
description |
Human-readable name of the task. |
'myExportImageTask'
|
|
folder |
The name of a unique folder in your Drive account to export into. Defaults to the root of the drive. |
None
|
|
fileNamePrefix |
The Google Drive filename for the export. Defaults to the name of the task. |
None
|
|
dimensions |
The dimensions of the exported image. Takes either a single positive integer as the maximum dimension or "WIDTHxHEIGHT" where WIDTH and HEIGHT are each positive integers. |
None
|
|
region |
The lon,lat coordinates for a LinearRing or Polygon specifying the region to export. Can be specified as a nested lists of numbers or a serialized string. Defaults to the image's region. |
None
|
|
scale |
The resolution in meters per pixel. Defaults to the native resolution of the image assset unless a crsTransform is specified. |
None
|
|
crs |
The coordinate reference system of the exported image's projection. Defaults to the image's default projection. |
None
|
|
crsTransform |
A comma-separated string of 6 numbers describing the affine transform of the coordinate reference system of the exported image's projection, in the order: xScale, xShearing, xTranslation, yShearing, yScale and yTranslation. Defaults to the image's native CRS transform. |
None
|
|
maxPixels |
The maximum allowed number of pixels in the exported image. The task will fail if the exported region covers more pixels in the specified projection. Defaults to 100,000,000. |
None
|
|
shardSize |
Size in pixels of the tiles in which this image will be computed. Defaults to 256. |
None
|
|
fileDimensions |
The dimensions in pixels of each image file, if the image is too large to fit in a single file. May specify a single number to indicate a square shape, or a tuple of two dimensions to indicate (width,height). Note that the image will still be clipped to the overall image dimensions. Must be a multiple of shardSize. |
None
|
|
skipEmptyTiles |
If true, skip writing empty (i.e. fully-masked) image tiles. Defaults to false. |
None
|
|
fileFormat |
The string file format to which the image is exported. Currently only 'GeoTIFF' and 'TFRecord' are supported, defaults to 'GeoTIFF'. |
None
|
|
formatOptions |
A dictionary of string keys to format specific options. |
None
|
|
**kwargs |
Holds other keyword arguments that may have been deprecated such as 'crs_transform', 'driveFolder', and 'driveFileNamePrefix'. |
{}
|
Source code in src\rlcms\utils.py
28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 |
|
export_img_to_asset(image, description='myExportImageTask', assetId=None, pyramidingPolicy=None, dimensions=None, region=None, scale=None, crs=None, crsTransform=None, maxPixels=None, **kwargs)
Creates a task to export an EE Image to an EE Asset.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
image |
The image to be exported. |
required | |
description |
Human-readable name of the task. |
'myExportImageTask'
|
|
assetId |
The destination asset ID. |
None
|
|
pyramidingPolicy |
The pyramiding policy to apply to each band in the image, a dictionary keyed by band name. Values must be one of: "mean", "sample", "min", "max", or "mode". Defaults to "mean". A special key, ".default", may be used to change the default for all bands. |
None
|
|
dimensions |
The dimensions of the exported image. Takes either a single positive integer as the maximum dimension or "WIDTHxHEIGHT" where WIDTH and HEIGHT are each positive integers. |
None
|
|
region |
The lon,lat coordinates for a LinearRing or Polygon specifying the region to export. Can be specified as a nested lists of numbers or a serialized string. Defaults to the image's region. |
None
|
|
scale |
The resolution in meters per pixel. Defaults to the native resolution of the image assset unless a crsTransform is specified. |
None
|
|
crs |
The coordinate reference system of the exported image's projection. Defaults to the image's default projection. |
None
|
|
crsTransform |
A comma-separated string of 6 numbers describing the affine transform of the coordinate reference system of the exported image's projection, in the order: xScale, xShearing, xTranslation, yShearing, yScale and yTranslation. Defaults to the image's native CRS transform. |
None
|
|
maxPixels |
The maximum allowed number of pixels in the exported image. The task will fail if the exported region covers more pixels in the specified projection. Defaults to 100,000,000. |
None
|
|
**kwargs |
Holds other keyword arguments that may have been deprecated such as 'crs_transform'. |
{}
|
Source code in src\rlcms\utils.py
117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 |
|