Opened 4 years ago

Closed 4 years ago

#475 closed defect (fixed)

Coverage iterator over double/date intervals

Reported by: dmisev Owned by: dmisev
Priority: major Milestone: 9.0
Component: petascope Version: development
Keywords: Cc: pcampalani, dirk.daems@…, pbaumann
Complexity: Medium

Description

It would be very useful if the coverage iterator in a coverage constructor can iterate over double and date intervals, so that we can iterate over geo and time coordinates. This should be possible to implement fairly easily. E.g.

for c in (Cov)
return
  coverage newcov
  over px x(15.5:93.432)
       pt t(2013-09-10:2013-09-25)
  values ...

Change History (3)

comment:1 Changed 4 years ago by dmisev

  • Cc pcampalani dirk.daems@… pbaumann added
  • Owner changed from abeccati to dmisev
  • Status changed from new to accepted

Ok I take back the "fairly easy" remark.

It would be fairly easy if the over clause was bound to an existing coverage, otherwise it would be necessary to provide a resolution parameter as well for the iterator, and a CRS.

So something like this (0.5 is resolution)

  over px x:"../EPSG/0/4326"(15.5:93.432, 0.5)
       pt t...

but then there is the issue of translating that to rasql and relating it to coverages in the values clause..


All in all, quite complicated. I think for most purposes it would suffice to allow imageCrsDomain in the over, which would provide the binding to an existing coverage, i.e. something like

  over px x(imageCrsDomain(c[x(15.5:93.432)])
       pt t...

much like we made it possible to use imageCrsDomain in scale (cf. #387)

Thoughts?

comment:2 Changed 4 years ago by dmisev

I submitted patch to allow imageCrsDomain. An example test case in the systemtest is:

for c in (eobstest)
return encode(
  coverage newcov
  over $px x(imageCrsDomain(c[Lat(25:35)], Lat)),
       $pt t(imageCrsDomain(c, t))
  values avg(c[Lat($px),t($pt)])
, "csv")

comment:3 Changed 4 years ago by dmisev

  • Resolution set to fixed
  • Status changed from accepted to closed
Note: See TracTickets for help on using tickets.