Opened 11 years ago

Closed 9 years ago

#598 closed defect (fixed)

WCPS1.5_domain metadata expression with subsetting

Reported by: Piero Campalani Owned by: Alex Dumitru
Priority: major Milestone: 10.0
Component: petascope Version: development
Keywords: domain subset Cc: Vlad Merticariu, Alex Dumitru, Peter Baumann
Complexity: Medium

Description

It seems that the parser only accepts coverage identifiers in a domain metadata expression.

Working query:

for c in (eobstest)
return domain( c , Lat, "http://localhost:8090/def/crs/EPSG/0/4326")
[1] (-40.5,75.5)

Trimming the coverage won't work:

for c in (eobstest)
return domain( c[Lat(0:10)] , Lat, "http://localhost:8090/def/crs/EPSG/0/4326")

Log:
...
 TRACE [13:03:46] RasUtil@245: Parsing abstract WCPS query...
line 2:16 mismatched input '[' expecting COMMA
...

This does not affect the imagecrsdomain function:

for c in (eobscov)
return imagecrsdomain( c[Lat(0:10)] , Lat)
[1] (131,151)

Change History (12)

comment:1 by Piero Campalani, 11 years ago

Cc: Vlad Merticariu Alex Dumitru added

comment:2 by Piero Campalani, 10 years ago

Owner: changed from Piero Campalani to uadhikari
Status: newassigned

comment:3 by uadhikari, 10 years ago

The feature that is wanted is not allowed in the WCPS 1.0 standard.

metaDataExpr: 
identifier ( coverageExpr ) 
| imageCrs ( coverageExpr ) 
| imageCrsDomain ( coverageExpr ) 
| imageCrsDomain ( coverageExpr , axisName ) 
| crsSet ( coverageExpr ) 
| domain ( coverageName , axisName , crsName ) 
| interpolationDefault ( coverageExpr , fieldName ) 
| interpolationSet ( coverageExpr , fieldName ) 
coverageName: name     /* coverage identifier as in WCS [OGC 07-067r5] */

The first argument of domain is coverageName (variable), and not the coverageExpr (which incudes trimExpr).

comment:4 by Piero Campalani, 10 years ago

Cc: Peter Baumann added

@Peter, how is WCPS 2.0 on this?
All other metadata expressions (even imageCrsDomain) take a coverage expression as argument: I'm not really sure why only the domain expression takes a coverage name.

comment:5 by uadhikari, 10 years ago

Owner: changed from uadhikari to Piero Campalani

@pcampalini Grammar fixed (will be effective after the patch is applied). Reassigning to you so that you can fix the query evaluation.

comment:6 by Dimitar Misev, 9 years ago

Owner: changed from Piero Campalani to Alex Dumitru

comment:7 by Bang Pham Huu, 9 years ago

Now, one can add interval to coverage name, but it will not has any effect and still returns the full domain of the axisName.

http://localhost:8080/rasdaman/ows?service=WCS&version=2.0.1&request=ProcessCoverages&
query=for c in (eobstest) return domain( c[Lat(0:8)] , Lat, "http://localhost:8080/def/crs/EPSG/0/4326")

returns (-40.50,75.50).

So maybe in WCPS 2.0, it can calculate the domain of axis in CRS also.

comment:8 by Piero Campalani, 9 years ago

Pham,
'now' means you submitted a patch for this or just tried it out?

Thanks for the update, let's just keep it open until it will be considered again for patching. !

in reply to:  8 comment:9 by Bang Pham Huu, 9 years ago

Replying to pcampalani:

Pham,
'now' means you submitted a patch for this or just tried it out?

Thanks for the update, let's just keep it open until it will be considered again for patching. !

Piero,

Now is just tried it out, as I could not do anything when it is not in WCPS 1 grammar (comment 3).

All of your tickets still open until it is validated (e.g pass some test cases). Thanks for your sharing.

comment:10 by Bang Pham Huu, 9 years ago

Cc: mantovani@… removed
Milestone: Future10.0
Summary: domain metadata expression with subsettingWCPS1.5_domain metadata expression with subsetting

comment:11 by Bang Pham Huu, 9 years ago

From WCPS1.0 specification document (OGC 08-068r1, page 16/75), domain(C, a, c) with C is coverage expression, a is dimension, c is crs

domain of the coverage, expressed in one of its CRSs, 
for a given (spatial, or temporal) dimension

then I think it was developed correctly, i.e

for c in (eobstest) return domain(c[Lat(0:8)], Lat, "http://localhost:8080/def/crs/EPSG/0/4326")

will return the domain of coverage: eobstest in dimesion: Lat with (-40.5:75.5)
instead of (0:8).

If no one has different idea, I will close this ticket soon.

comment:12 by Bang Pham Huu, 9 years ago

Resolution: fixed
Status: assignedclosed

So domain() operator will return the domain of one dimension of a coverage (not only coverage identifier) as in example:

 for c in (eobstest) 
 return domain(c[Lat(0:8)], Lat, "​http://localhost:8080/def/crs/EPSG/0/4326")

which returns domain of Lat of eobstest is -40.5:75.5 in WCPS1.5 also.

I will close this ticket here as it was fixed in WCPS1.0 and has been fixed in WCPS1.5

Note: See TracTickets for help on using tickets.