Mercurial > repos > ecology > sentinel_2
comparison preprocess_S2.xml @ 0:fbffdeefb146 draft
Uploaded
author | ecology |
---|---|
date | Sun, 08 Jan 2023 23:03:35 +0000 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:fbffdeefb146 |
---|---|
1 <tool id="srs_preprocess_s2" name="Preprocess sentinel 2 data" version="@VERSION@" profile="20.01"> | |
2 <description>read, crop, resample and write it as a raster stack</description> | |
3 <macros> | |
4 <import>macro.xml</import> | |
5 </macros> | |
6 <requirements> | |
7 <requirement type="package" version="4.2.2">r-base</requirement> | |
8 <requirement type="package" version="1.0_7">r-sf</requirement> | |
9 <requirement type="package" version="0.6_1">r-rgeos</requirement> | |
10 <requirement type="package" version="0.5_5">r-stars</requirement> | |
11 <requirement type="package" version="1.5.0">r-stringr</requirement> | |
12 <requirement type="package" version="1.2.3">r-jqr</requirement> | |
13 <requirement type="package" version="2.1.3">r-protolite</requirement> | |
14 <requirement type="package" version="1.5.3">r-sen2r</requirement> | |
15 <requirement type="package" version="1.2.2">r-progress</requirement> | |
16 <requirement type="package" version="2.0.3">r-gdalutils</requirement> | |
17 <requirement type="package" version="1.0.4">r-fasterize</requirement> | |
18 <requirement type="package" version="3.99_0.13">r-xml</requirement> | |
19 <requirement type="package" version="1.3.3">r-xml2</requirement> | |
20 <requirement type="package" version="2.2.2">r-zip</requirement> | |
21 </requirements> | |
22 <command detect_errors="exit_code"><![CDATA[ | |
23 Rscript | |
24 '$__tool_directory__/preprocess_S2.r' | |
25 '$input' | |
26 '$__tool_directory__/Lib_preprocess_S2.r' | |
27 '$source_s2' | |
28 '$type_s2' | |
29 '$output' | |
30 '$output_refl' | |
31 '$output_cloud' | |
32 ]]> | |
33 </command> | |
34 <inputs> | |
35 <param name="input" type="data" format="zip" multiple="true" label="Input data"/> | |
36 <param name="source_s2" type="select" label="Where does your data come from ?"> | |
37 <option value="SAFE">From Scihub or Peps</option> | |
38 <option value="THEIA">From Theia</option> | |
39 </param> | |
40 <param name="type_s2" type="select" label="From which satellite are the data ?"> | |
41 <option value="2A">Sentinel 2A</option> | |
42 <option value="2B">Sentinel 2B</option> | |
43 </param> | |
44 </inputs> | |
45 <outputs> | |
46 <data name="output" from_work_dir="Mission.csv" format="csv" label="Mission source"/> | |
47 <data name="output_refl" from_work_dir="Refl.zip" format="zip" label="Reflectance"/> | |
48 <data name="output_cloud" from_work_dir="Cloud.zip" format="zip" label="Cloud Mask"/> | |
49 </outputs> | |
50 <tests> | |
51 <test> | |
52 <param name="input" value="S2A_MSIL2A_20200306T015621_N0214_R117_T51JXN_20200306T034744.zip"/> | |
53 <param name="source_s2" value="SAFE"/> | |
54 <param name="type_s2" value="2A"/> | |
55 <output name="output" value="Mission.csv"/> | |
56 <output name="output_refl"> | |
57 <assert_contents> | |
58 <has_size value="12923807" delta="100"/> | |
59 </assert_contents> | |
60 </output> | |
61 <output name="output_cloud"> | |
62 <assert_contents> | |
63 <has_size value="235912" delta="100"/> | |
64 </assert_contents> | |
65 </output> | |
66 </test> | |
67 </tests> | |
68 <help><![CDATA[ | |
69 ========================== | |
70 Preprocess Sentinel 2 data | |
71 ========================== | |
72 | |
73 | |
74 **What it does** | |
75 | |
76 The goal of this tool (using the package preprocS2) is to provide a common framework for the preprocessing of Level-2A Sentinel-2 images (does not work yet for Level 1C). | |
77 Sentinel-2 L2A images can be produced or obtained from various data hubs or atmospheric correction methods. PreprocS2 provides a unique function to read, crop, resample the original image directory, and write it as a raster stack. | |
78 | |
79 **Input description** | |
80 | |
81 A zip folder with Sentinel 2 data. | |
82 These data can be dowloaded on 3 different platforms: | |
83 | |
84 - Copernicus Open Access Hub, Scihub, which provides complete, free and open access to Sentinel-2 data : https://scihub.copernicus.eu/dhus/#/home | |
85 | |
86 - PEPS, la 'Plateforme d'Exploitation de Produits Sentinel' : https://peps.cnes.fr/rocket/#/search | |
87 | |
88 - Theia : https://theia.cnes.fr/atdistrib/rocket/#/search | |
89 | |
90 For each of those 3 platforms you will need to create an account. | |
91 | |
92 You need to select from where you dowloaded your data in order for the tool to know the format of the folder once it unzips it. | |
93 | |
94 +----------+----------+ | |
95 | ZIP | Source | | |
96 +==========+==========+ | |
97 |folder.zip|Character | | |
98 +----------+----------+ | |
99 | ... | ... | | |
100 +----------+----------+ | |
101 | |
102 **Output** | |
103 | |
104 A zip folder containing the refelctance data with a raster stack pile in BIL format (no extension), a header with the metadata (.hdr extension) and 2 other files in .xml. | |
105 | |
106 A zip folder containing the cloud mask with the 2 files for the raw data (.RAW) and 2 files containing the metadata (.hdr). | |
107 ]]> </help> | |
108 <expand macro="SRS_S2ref"/> | |
109 </tool> |