Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
GeoSentinel
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Mario Chirinos Colunga
GeoSentinel
Commits
81d8c47c
Commit
81d8c47c
authored
May 09, 2018
by
Alfonso Ramire Pedraza
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
delete
parent
9694e82b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
54 deletions
+0
-54
download_images
examples/download_images
+0
-54
No files found.
examples/download_images
deleted
100644 → 0
View file @
9694e82b
#!/bin/python
# Copyright (C) 2018 Adan Salazar <asalazargaribay@gmail.com>
#
#
# This file is part of GeoSentinel
#
#
# GeoSentinel is free software you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# GeoSentinel is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with StereoVision. If not, see <http://www.gnu.org/licenses/>.
"""
Example of dowloading Sentinel images from the Copernicus Open Access Hub < https://scihub.copernicus.eu/dhus/#/home >
"""
from
sentinelsat.sentinel
import
read_geojson
,
geojson_to_wkt
from
argparse
import
ArgumentParser
from
geosentinel.ui_utils
import
(
download_sentinel_mages
)
from
geosentinel.arguments
import
SENTINEL_ARGUMENTS
def
main
():
"""
Download all Sentinel images from the Copernicus Hub and save them in the folder specified by the user.
Please run: python dowload_images --help before usage
First, parse arguments provided by the user. Then choose the images that are in the
dates and polygon provided by the user, then remove the images that do not overlap more than 30
%
of the input polygon and the polygon of the image. Finally, download the remaining images.
"""
parser
=
ArgumentParser
(
description
=
"Download Sentinel images from the Copernicus Hub"
,
parents
=
[
SENTINEL_ARGUMENTS
])
args
=
parser
.
parse_args
()
path_json
=
args
.
input_file
args
.
footprint
=
geojson_to_wkt
(
read_geojson
(
path_json
))
download_sentinel_mages
(
args
)
if
__name__
==
"__main__"
:
main
()
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment