-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathchip-from-vrt.json
115 lines (114 loc) · 5.19 KB
/
chip-from-vrt.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
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
{
"name": "chip-from-vrt",
"version": "0.2.11",
"taskOwnerEmail": "[email protected]",
"description": "A GBDX task for generating AOI chips from a group of images on S3 using the GDAL virtual format. The images can be individual strips or the tiles of a FLAME mosaic.",
"properties": {
"isPublic": true,
"timeout": 36000
},
"inputPortDescriptors": [
{
"name": "geojson",
"type": "directory",
"description": "Contains one geojson file containing AOIs to extract from the mosaic. If chips are to be used for training each feature must have a class_name property. Features will be saved as feature_id.tif in the output directory. If no feature_id property is present, ids will be generated and saved to the reference gejoson in the output directory.",
"required": true
},
{
"name": "images",
"type": "string",
"description": "S3 image locations. Note that if the bucket is private you must enter valid AWS keys and a token to access the imagery. If using a FLAME mosaic this should be the location of the project directory as follows: bucket_name/path/to/project_name/. This directory must contain the a subdirectory with the mosaic tiles and a wms/ subdirectory with a shapefile specified in the shapefile_name input port. Otherwise, this should be the exact S3 location of any image strips being used. Different strips should be separated by a comma as follows: 'bucket_name/path/to/image1.tif, bucket_name/path/to.image2.tif', ...",
"required": true
},
{
"name": "mosaic",
"type": "string",
"description": "True if the images comprise a FLAME mosaic; else False. Defaults to False.",
"required": false
},
{
"name": "shapefile_location",
"type": "string",
"description": "Location of the shapefile pointing to image raster location within the mosaic directory. Only relevant if using a flame mosaic. This file must be in the project directory. Defaults to wms/vsitindex_z12.shp.",
"required": false
},
{
"name": "aws_access_key",
"type": "string",
"description": "AWS access key. The account associated with this key should have read access to the bucket containing the mosaic.",
"required": false
},
{
"name": "aws_secret_key",
"type": "string",
"description": "AWS secret access key. The account associated with this key should have read access to the bucket containing the mosaic.",
"required": false
},
{
"name": "aws_session_token",
"type": "string",
"description": "AWS session token. This is necessary if the images input uses IAM credentials such as is in the gbd_customer_data bucket.",
"required": false
},
{
"name": "mask",
"type": "string",
"description": "If True, blackfill pixels outside the polygon. Otherwise entire bounding box will be included in the output chip. Defaults to False.",
"required": false
},
{
"name": "bit_depth",
"type": "string",
"description": "Bit depth to set the output chips to if larger than 8. Defaults to 8.",
"required": false
},
{
"name": "bands",
"type": "string",
"description": "List of bands to include in the chips, each separated by a comma. Note that indexing starts at 1. For example, to use the first three bands use input '1,2,3'. Defaults to all bands.",
"required": false
},
{
"name": "tar",
"type": "string",
"description": "If True, outputs chips directory as a tar file. Defaults to False.",
"required": false
},
{
"name": "filter_black",
"type": "string",
"description": "If True, will remove all black chips. Defaults to False.",
"required": false
},
{
"name": "jpg",
"type": "string",
"description": "If True, will save chips as JPEGs. Defaults to False.",
"required": false
},
{
"name": "reproject_to",
"type": "string",
"description": "If True, will reproject chips to the specified projection (ex EPSG:4326). Defaults to no reprojecting (None).",
"required": false
}
],
"outputPortDescriptors": [
{
"name": "chips",
"type": "directory",
"description": "Contains chipped AOIs from input geojson in tif format. Each chip is named after its feature_id value. A reference geojson file with feature ids for each geometry is also saved in this directory."
}
],
"containerDescriptors": [
{
"type": "DOCKER",
"properties": {
"image": "platformstories/chip-from-vrt",
"domain": "default"
},
"command": "python /chip-from-vrt.py",
"isPublic": true
}
]
}