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
ff386a56
Commit
ff386a56
authored
Jul 26, 2018
by
Mario Chirinos Colunga
💬
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wkt to shape
parent
99b2a0ca
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
10 deletions
+4
-10
myshape.dbf
geosentinel/myshape.dbf
+0
-0
wktToShape.py
geosentinel/wktToShape.py
+2
-2
L2AproductListToRGB.sh
tools/L2AproductListToRGB.sh
+2
-8
No files found.
geosentinel/myshape.dbf
0 → 100644
View file @
ff386a56
File added
geosentinel/wktToShape.py
View file @
ff386a56
...
@@ -5,7 +5,7 @@ import osgeo.ogr as ogr
...
@@ -5,7 +5,7 @@ import osgeo.ogr as ogr
import
osgeo.osr
as
osr
import
osgeo.osr
as
osr
import
sys
import
sys
def
wktToShape
(
wkt
,
shapefileName
):
def
wktToShape
(
wkt
,
shapefileName
,
layerName
=
"wkt"
):
'''!
'''!
'''
'''
# set up the shapefile driver
# set up the shapefile driver
...
@@ -17,7 +17,7 @@ def wktToShape(wkt, shapefileName):
...
@@ -17,7 +17,7 @@ def wktToShape(wkt, shapefileName):
# create the spatial reference, WGS84
# create the spatial reference, WGS84
srs
=
osr
.
SpatialReference
()
srs
=
osr
.
SpatialReference
()
srs
.
ImportFromEPSG
(
4326
)
srs
.
ImportFromEPSG
(
4326
)
layer
=
data_source
.
CreateLayer
(
"layer"
,
srs
,
ogr
.
wkbPolygon
)
layer
=
data_source
.
CreateLayer
(
layerName
,
srs
,
ogr
.
wkbPolygon
)
# Create the point from the Well Known Text
# Create the point from the Well Known Text
geometry
=
ogr
.
CreateGeometryFromWkt
(
wkt
)
geometry
=
ogr
.
CreateGeometryFromWkt
(
wkt
)
...
...
tools/L2AproductListToRGB.sh
View file @
ff386a56
...
@@ -24,7 +24,6 @@ do
...
@@ -24,7 +24,6 @@ do
echo
PASS
$f
echo
PASS
$f
fi
fi
RGBCROPED
=
$JP2DIR
"rgbCroped/"
RGBCROPED
=
$JP2DIR
"rgbCroped/"
if
[
!
-d
$RGBCROPED
]
;
then
if
[
!
-d
$RGBCROPED
]
;
then
mkdir
$RGBCROPED
mkdir
$RGBCROPED
...
@@ -33,12 +32,6 @@ do
...
@@ -33,12 +32,6 @@ do
fileout1
=
$(
echo
$filepattern
|
cut
-d
"_"
-f1
)
fileout1
=
$(
echo
$filepattern
|
cut
-d
"_"
-f1
)
fileout2
=
$(
echo
$filepattern
|
cut
-d
"_"
-f2
)
fileout2
=
$(
echo
$filepattern
|
cut
-d
"_"
-f2
)
#
# if [ ! -e rgb/$fileout2"_"$fileout1".tiff" ]; then
# gdal_merge.py -separate -co PHOTOMETRIC=RGB -o rgb/$fileout2"_"$fileout1".tiff" $filepattern"04.jp2" $filepattern"03.jp2" $filepattern"02.jp2"
# fi
if
[
!
-d
$RGBCROPED$fileout1
]
;
then
if
[
!
-d
$RGBCROPED$fileout1
]
;
then
mkdir
$RGBCROPED$fileout1
mkdir
$RGBCROPED$fileout1
fi
fi
...
@@ -50,8 +43,9 @@ do
...
@@ -50,8 +43,9 @@ do
## rm rgb/$fileout1/$fileout2"_"$fileout1"_t.jpg"
## rm rgb/$fileout1/$fileout2"_"$fileout1"_t.jpg"
fi
fi
cd
$PRODCUTSDIR
#
cd $PRODCUTSDIR
done
done
rm
*
.xml
## if [ ! -d "video" ]; then
## if [ ! -d "video" ]; then
## mkdir video
## mkdir video
## fi
## fi
...
...
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