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
7dc7f8fb
Commit
7dc7f8fb
authored
Apr 23, 2018
by
Pedro Alfonso Ramirez
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Unzip sentinel files
parent
697495a2
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
9 deletions
+11
-9
ui_utils.py
geosentinel/ui_utils.py
+11
-9
No files found.
geosentinel/ui_utils.py
View file @
7dc7f8fb
...
...
@@ -65,22 +65,24 @@ def check_existing_productType(product,flag):
def
find_files_Sentinel
(
args
):
check_existing_directory
(
args
.
folder
,
2
)
check_existing_productType
(
args
.
satellite
,
1
)
check_existing_productType
(
args
.
plattform
,
1
)
check_existing_productType
(
args
.
product_type
,
2
)
files
=
os
.
listdir
(
folder
)
files
=
os
.
listdir
(
args
.
folder
)
if
(
args
.
product_type
==
"all"
):
if
args
.
satellite
==
'Sentinel-1'
or
args
.
satellite
==
'sentinel-1'
:
if
args
.
plattform
==
'Sentinel-1'
or
args
.
plattform
==
'sentinel-1'
:
namfil1
=
'S1A_'
namfil2
=
'S1B_'
if
args
.
satellite
==
'Sentinel-2'
or
args
.
satellite
==
'sentinel-2'
:
namfil3
=
'S2A_'
namfil4
=
'S2B_'
files
=
[
f
for
f
in
files
if
f
.
startswith
(
namfil1
)
or
f
.
startswith
(
namfil2
)
or
f
.
startswith
(
namfil3
)
or
f
.
startswith
(
namfil4
)]
if
args
.
plattform
==
'Sentinel-2'
or
args
.
plattform
==
'sentinel-2'
:
namfil1
=
'S2A_'
namfil2
=
'S2B_'
files
=
[
f
for
f
in
files
if
f
.
startswith
(
namfil1
)
or
f
.
startswith
(
namfil2
)]
if
(
len
(
files
)
==
0
):
print
"Files not found..."
else
:
if
args
.
satellite
==
"Sentinel-1"
or
args
.
satellite
==
"sentinel-1"
:
if
args
.
plattform
==
"Sentinel-1"
or
args
.
plattform
==
"sentinel-1"
:
namfil1
=
'S1A_'
+
args
.
product_type
namfil2
=
'S1B_'
+
args
.
product_type
if
args
.
satellite
==
"Sentinel-2"
or
args
.
satellite
==
"sentinel-2"
:
if
args
.
plattform
==
"Sentinel-2"
or
args
.
plattform
==
"sentinel-2"
:
namfil1
=
'S2A_'
+
args
.
product_type
namfil2
=
'S2B_'
+
args
.
product_type
files
=
[
f
for
f
in
files
if
f
.
startswith
(
namfil1
)
or
f
.
startswith
(
namfil2
)]
...
...
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