Strabon
view scripts/archive/v2.1/TimePersistence.sparql @ 1277:92b90ac06d39
[maven-release-plugin] prepare release v3.2.9
author | Babis Nikolaou <charnik@di.uoa.gr> |
---|---|
date | Sat Oct 19 23:37:23 2013 +0300 (2013-10-19) |
parents | 7b42dd5d908b |
children |
line source
1 PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
2 PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
3 PREFIX strdf: <http://strdf.di.uoa.gr/ontology#>
4 PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
6 INSERT {
7 ?newHotspot rdf:type noa:Hotspot ;
8 noa:hasConfidence ?hConfidence ;
9 noa:hasGeometry ?hGeometry1 ;
10 noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime ;
11 noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
12 noa:hasConfirmation noa:unknown ;
13 noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string ;
14 noa:isProducedBy noa:noa ;
15 noa:isDerivedFromSatellite "SAT"^^xsd:string .
17 }
18 WHERE {
19 SELECT (BNODE() AS ?newHotspot)
20 (SUM(?hConfidence1)/ACQUISITIONS_IN_HALF_AN_HOUR AS ?hConfidence)
21 ?hGeometry1
22 WHERE {
23 ?H1 noa:hasConfidence ?hConfidence1 .
24 ?H1 noa:hasGeometry ?hGeometry1 .
25 ?H1 noa:hasAcquisitionTime ?hAcquisitionTime1 .
26 ?H1 noa:isDerivedFromSensor "SENSOR"^^xsd:string .
27 ?H1 noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string .
28 OPTIONAL { ?H1 noa:isDiscarded ?z } .
29 FILTER (!BOUND(?z)) .
30 FILTER( "MIN_ACQUISITION_TIME"^^xsd:dateTime <= ?hAcquisitionTime1 && ?hAcquisitionTime1 < "TIMESTAMP"^^xsd:dateTime ) .
31 OPTIONAL {
32 ?H2 noa:hasGeometry ?HGEO2 .
33 ?H2 noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime .
34 ?H2 noa:isDerivedFromSensor "SENSOR"^^xsd:string .
35 ?H2 noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string .
36 FILTER(("PROCESSING_CHAIN"^^xsd:string = ?hProcessingChain2)||("PROCESSING_CHAIN-TimePersistence"^^xsd:string = ?hProcessingChain2)).
37 FILTER( strdf:equals(?hGeometry1, ?HGEO2) ) .
38 }
39 FILTER( !BOUND(?H2) ) .
40 }
41 GROUP BY ?hGeometry1
42 HAVING(SUM(?hConfidence1)>0.0)
43 }