International Archives of the Photogrammetry, Remote Sensing and Spatial Information Sciences, Volume XXXIX-B4, 2012
XXII ISPRS Congress, 25 August — 01 September 2012, Melbourne, Australia
generally called (soil) brightness, (vegetation) greenness, (soil
and canopy) wetness, haze, TCS, and TC6. Each or a
combination of them is useful for different applications,
including crop growth monitoring and analysis, biomass study,
agriculture planning, to name a few. In this test, we used a full
scene Landsat 5 TM image and the Landsat 5 Tasseled Cap
Transformation coefficients for DN Data (Crist and Cicone,
1986). The following script takes a TM image as input,
automatically generates the TCT expression based on the
coefficient matrix, execute the expression, and create a new
image holding the results.
declare
type array type is varray(6) of binary. double;
type array array type is varray(6) of array type;
tct coeffarray array type :- array array type(
array type( 0.3561, 0.3972, 0.3904, 0.6966, 0.2286, 0.1596),
array type(-0.3344, -0.3544, -0.4556, 0.6966, -0.0242, -0.2630),
array type( 0.2626, 0.2141, 0.0926, 0.0656, -0.7629, -0.5388),
array type( 0.0805, -0.0498, 0.1950, -0.1327, 0.5752, -0.7775),
array type(-0.7252, -0.0202, 0.6683, 0.0631, -0.1494, -0.0274),
array type( 0.4000, -0.8172, 0.3832, 0.0602, -0.1095, 0.0985);
i integer;
grl sdo georaster;
gr2 sdo georaster;
stmt varchar2(5024);
begin
select georaster into grl from georaster table where georid = 2;
select georaster into gr2 from georaster_table where georid = 4 for update;
stmt:=";
i=l;
-- the following code generates the TCT expression
LOOP
stmt:=stmt||
"(l|trim(to char(tct coeff(i)(1),0.9999^)|| )*{0}+ ||
'([trim(to_char(tct_coeff(i)(2),'0.9999'))|| ')*{1}+' ||
‘(|[trim(to_char(tet_coeff(i)(3),'0.9999"))}| ")*{2}+ ||
'(|[trim(to_char(tet_coeff(i)(4),'0.9999"))}| ")*{3}+ ||
'('lltrim(to_char(tct_coeff(i)(5),'0.9999")|| ')* {4} + ||
'([trim(to_char(tet_coeff(i)(6),'0.9999"))|| ")*{6}" ;
IF(i<6) THEN
stmt:=stmt||',";
END if;
1=i+l;
IF i> 6 THEN
EXIT;
END IF;
END LOOP;
stmt := 'call sdo_geor_ra.rasterMathOp(: l,SDO STRING2 ARRA Y('|stmt||),'|
"celldepth-32BIT REAL",:2)'
execute immediate stmt using grl,in out gr2;
update georaster_table set georaster = gr2 where georid = 4;
commit;
end;
The actual raster algebra expression and command, i.c., the
“stmt”, generated by the above script is as follows (reformatted
a bit for readability). Note that you can also directly apply this
expression to make the above script look even simpler.
sdo_geor_ra.rasterMathOp(:1, SDO STRING2 ARRAY(
((0.3561)* (0) -(0.3972)*(15-(0.3904)* (2) -(0.6966)* (3)--(0.2286)* (4]--(0.1596)* 6Y',
'(-0.3344)* {0} +(-0.3544)* { 1} +(-0.4556)* {2} +(0.6966)* {3} +(-0.0242)* {4} +(-0.2630)* {6}',
'(0.2626)*{0}+(0.2141)*{1}+(0.0926)*{2}+(0.0656)*{3} +(-0.7629)*{4}+(-0.5388)*{6}",
'(0.0805)* {0} +(-0.0498)* {1} +(0.1950)* {2}+(-0.1327)* {3}+(0.5752)* {4} +(-0.7775)* {6},
(-0.7252)*{0}+(-0.0202)* {1} +(0.6683)* {2} +(0.0631)* {3} +(-0.1494)* {4} +(-0.0274)* {6},
'(0.4000)* {0} +(-0.8172)* {1}+(0.3832)*{2}+(0.0602)* {3} +(-0.1095)* {4} +(0.0985)* {6} "),
'celldepth-32Bit REAL', :2)
The source image (the file name is L5044034 034201 10918.tif,
available from the U.S. Geological Survey) covers the San
Francisco Bay arca and is 377MB (7091 rows, 7961 columns, 7
bands and 8bit integer) in size. The result image is 1.26GB
(7091 rows, 7961 columns, 6 bands, and 32bit float) in size. In
repeated tests on a low-end commodity linux machine, the total
92
execution time (without parallelism) is only 3 minutes or less.
Figure 2 shows a small subset of the source image, and the
brightness, greenness and wetness resulted from the TCT.
Using the same raster algebra language, users can also very
easily add some additional scripts in the above PL/SQL block
to convert the 32bit floating number image into 8 bit integer
image and in the mean time apply image stretching (simply
another map algebra expression) on the TCT image to generate
a new GeoRaster object for visualization and analysis purposes.
Figure 2. TM 123 Color Image (upper left), Brightness (upper right),
Greenness (lower left) and Wetness (lower right). TM Image Courtesy
of the U.S. Geological Survey
As shown in the syntax and the above examples, the PL/SQL
language and the map algebra expressions are powerful and
flexible for users to easily implement numerous processing and
analytical applications. In addition to the optimized
implementation of raster algebra algorithms and the embedded
parallel processing, users can further leverage the power of
Oracle Enterprise GRID Computing infrastructure to quickly
process and analyze thousands of images and rasters stored in
the GeoRaster database concurrently and on a global basis (Xie,
20082).
6. CONCLUSIONS
Satellite imagery, airborne photographs and other geospatial
raster data are complex data types that require specialized
database management systems and analysis solutions.
Unprecedented data volume plus real time or near-real time
archiving and processing requirements of such data dictate
extreme scalability and performance of such systems and
solutions. Oracle Spatial GeoRaster takes an enterprise
database-centric approach by enhancing Oracle database server
to solve the database management challenges and achieve
virtually unlimited scalability and great performance. The in-
database raster analytics engine proposed in this paper enhances
Oracle Spatial GeoRaster database management system by
embedding some analytical algorithms inside the database
allowing data to be processed where the data is stored. This
approach coupled with parallel processing capabilities offers
great performance benefits for many basic and commonly used
NS) LA a P mM ome
Pt hd fp
r*3 2) 1 (SN (NN ef ef — pd poy sn f Cn o5 om
€ "^. (NN
Ph Cp,