Opened 9 years ago

Last modified 9 years ago

#1208 closed defect

WCPS2.0_Difference matrix values of bands calculation from WCPS 1.0 — at Version 2

Reported by: Bang Pham Huu Owned by:
Priority: major Milestone: 10.0
Component: petascope Version: development
Keywords: WCPS 2.0, matrix calculation, coverage bands Cc: Dimitar Misev, Alex Dumitru, Vlad Merticariu
Complexity: Medium

Description (last modified by Bang Pham Huu)

wcps test "04-vegetation_index.test.out" with WCPS query

for c in ( rgb ) return encode((unsigned char)
( ((c.0 / ((float)c.0 + c.1))-(c.1 / ((float)c.0 + c.1))) > 0.6 ) * 255, "png", "nodata=0" )

is translate in Rasql by WCPS 2.0

select encode((char)((((((((((c).0)/((float)((((c).0)+((c).1))))))-((((c).1)/((float)((((c).0)+((c).1))))))))>(0.6)))*(255))),
 "PNG", "nodata=0;xmin=0.0;xmax=399.0;ymin=0.0;ymax=343.0;crs=OGC:Index2D")
 from rgb AS c where oid(c)=45057

and Rasql by WCPS 1.0

SELECT encode((char)  
(  (  ( c.0 /  ( (float) c.0 + c.1 )  ) 
 -
  ( c.1 /  ( (float) c.0 + c.1 )  )  )  > 0.6 )  * 255,
 "png" , "nodata=0") FROM rgb AS c

the result is different, view here https://drive.google.com/a/fimo.edu.vn/folderview?id=0B_VL2-SVlKPHU1VMSi1iXzgzNTA&usp=drive_web (oracle is WCPS 1.0, output is WCPS 2.0)

due to the matrix calculation between coverage bands which is different between WCPS 1.0 and WCPS 2.0

Change History (2)

comment:1 by Dimitar Misev, 9 years ago

Did you make a mistake in copying the rasql queries? Because both queries seem to be exactly same, please check.

comment:2 by Bang Pham Huu, 9 years ago

Description: modified (diff)

Thanks Dimitar, I've posted wrong WCPS 2.0 Rasql query.

Note: See TracTickets for help on using tickets.