Strabon

changeset 565:8251379cab30

renamed the file extensions of NOA refinement queries from ".sparql" to the standard ".rq"
author Babis Nikolaou <charnik@di.uoa.gr>
date Thu Sep 27 19:53:36 2012 +0300 (2012-09-27)
parents 41246f8ce66e
children 81ac0fc6733e
files examples/teleios/deleteSeaHotspots.rq examples/teleios/deleteSeaHotspots.sparql examples/teleios/discover.rq examples/teleios/discover.sparql examples/teleios/insertMunicipalities.rq examples/teleios/insertMunicipalities.sparql examples/teleios/landUseInvalidForFires.rq examples/teleios/landUseInvalidForFires.sparql examples/teleios/refinePartialSeaHotspots.rq examples/teleios/refinePartialSeaHotspots.sparql examples/teleios/refineTimePersistence.rq examples/teleios/refineTimePersistence.sparql
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/examples/teleios/deleteSeaHotspots.rq	Thu Sep 27 19:53:36 2012 +0300
     1.3 @@ -0,0 +1,18 @@
     1.4 +PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
     1.5 +PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
     1.6 +PREFIX strdf: <http://strdf.di.uoa.gr/ontology#>
     1.7 +PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
     1.8 +PREFIX gag: <http://geo.linkedopendata.gr/greekadministrativeregion/ontology#>
     1.9 +
    1.10 +INSERT {?h noa:isDiscarded "1"^^xsd:int ;
    1.11 +           noa:refinedBy noa:seaInconsistency .
    1.12 +} 
    1.13 +WHERE {
    1.14 +?h   noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime ;
    1.15 +     noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string ;
    1.16 +     noa:isDerivedFromSensor "SENSOR"^^xsd:string .
    1.17 +       OPTIONAL {
    1.18 +    ?h	gag:hasMunicipality ?muni .
    1.19 +  } 
    1.20 +  FILTER(!bound(?muni)) .
    1.21 +}
     2.1 --- a/examples/teleios/deleteSeaHotspots.sparql	Thu Sep 27 19:12:21 2012 +0300
     2.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     2.3 @@ -1,18 +0,0 @@
     2.4 -PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
     2.5 -PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
     2.6 -PREFIX strdf: <http://strdf.di.uoa.gr/ontology#>
     2.7 -PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
     2.8 -PREFIX gag: <http://geo.linkedopendata.gr/greekadministrativeregion/ontology#>
     2.9 -
    2.10 -INSERT {?h noa:isDiscarded "1"^^xsd:int ;
    2.11 -           noa:refinedBy noa:seaInconsistency .
    2.12 -} 
    2.13 -WHERE {
    2.14 -?h   noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime ;
    2.15 -     noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string ;
    2.16 -     noa:isDerivedFromSensor "SENSOR"^^xsd:string .
    2.17 -       OPTIONAL {
    2.18 -    ?h	gag:hasMunicipality ?muni .
    2.19 -  } 
    2.20 -  FILTER(!bound(?muni)) .
    2.21 -}
     3.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     3.2 +++ b/examples/teleios/discover.rq	Thu Sep 27 19:53:36 2012 +0300
     3.3 @@ -0,0 +1,20 @@
     3.4 +PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#> 
     3.5 +PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> 
     3.6 +PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#> 
     3.7 +PREFIX strdf: <http://strdf.di.uoa.gr/ontology#> 
     3.8 +PREFIX xsd: <http://www.w3.org/2001/XMLSchema#> 
     3.9 +PREFIX gag: <http://geo.linkedopendata.gr/greekadministrativeregion/ontology#>
    3.10 +
    3.11 +SELECT ?h  (strdf:transform(?hGeo, <http://www.opengis.net/def/crs/EPSG/0/4326>) AS ?geo) ?conf ?muni
    3.12 +WHERE { 
    3.13 +?h   noa:hasGeometry ?hGeo ;
    3.14 +     noa:hasAcquisitionTime ?hAcquisitionTime ; 
    3.15 +     noa:producedFromProcessingChain ?hProcessingChain ; 
    3.16 +     noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
    3.17 +     noa:hasConfidence ?conf ;
    3.18 +     gag:hasMunicipality ?muni .
    3.19 +     FILTER(?hProcessingChain = "PROCESSING_CHAIN" || ?hProcessingChain = "PROCESSING_CHAIN-TimePersistence") .
    3.20 +     FILTER("MIN_ACQUISITION_TIME"^^xsd:dateTime <= ?hAcquisitionTime && ?hAcquisitionTime <= "MAX_ACQUISITION_TIME"^^xsd:dateTime ) .
    3.21 +     OPTIONAL {?h noa:isDiscarded ?disc }.
    3.22 +     FILTER (!bound(?disc)) .
    3.23 +}
     4.1 --- a/examples/teleios/discover.sparql	Thu Sep 27 19:12:21 2012 +0300
     4.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     4.3 @@ -1,20 +0,0 @@
     4.4 -PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#> 
     4.5 -PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> 
     4.6 -PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#> 
     4.7 -PREFIX strdf: <http://strdf.di.uoa.gr/ontology#> 
     4.8 -PREFIX xsd: <http://www.w3.org/2001/XMLSchema#> 
     4.9 -PREFIX gag: <http://geo.linkedopendata.gr/greekadministrativeregion/ontology#>
    4.10 -
    4.11 -SELECT ?h  (strdf:transform(?hGeo, <http://www.opengis.net/def/crs/EPSG/0/4326>) AS ?geo) ?conf ?muni
    4.12 -WHERE { 
    4.13 -?h   noa:hasGeometry ?hGeo ;
    4.14 -     noa:hasAcquisitionTime ?hAcquisitionTime ; 
    4.15 -     noa:producedFromProcessingChain ?hProcessingChain ; 
    4.16 -     noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
    4.17 -     noa:hasConfidence ?conf ;
    4.18 -     gag:hasMunicipality ?muni .
    4.19 -     FILTER(?hProcessingChain = "PROCESSING_CHAIN" || ?hProcessingChain = "PROCESSING_CHAIN-TimePersistence") .
    4.20 -     FILTER("MIN_ACQUISITION_TIME"^^xsd:dateTime <= ?hAcquisitionTime && ?hAcquisitionTime <= "MAX_ACQUISITION_TIME"^^xsd:dateTime ) .
    4.21 -     OPTIONAL {?h noa:isDiscarded ?disc }.
    4.22 -     FILTER (!bound(?disc)) .
    4.23 -}
     5.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     5.2 +++ b/examples/teleios/insertMunicipalities.rq	Thu Sep 27 19:53:36 2012 +0300
     5.3 @@ -0,0 +1,23 @@
     5.4 +PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
     5.5 +PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
     5.6 +PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
     5.7 +PREFIX strdf: <http://strdf.di.uoa.gr/ontology#>
     5.8 +PREFIX gag: <http://geo.linkedopendata.gr/greekadministrativeregion/ontology#>
     5.9 +PREFIX xsd: <http://www.w3.org/2001/XMLSchema#> 
    5.10 +
    5.11 +INSERT { ?h gag:hasMunicipality ?muni }
    5.12 +WHERE { 
    5.13 +SELECT ?h (SAMPLE(?mLabel) AS ?muni)
    5.14 +  WHERE {
    5.15 +	?h  rdf:type noa:Hotspot ;
    5.16 +		noa:hasGeometry ?hGeo ;
    5.17 +		noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
    5.18 +		noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string ;
    5.19 +        noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime.
    5.20 +	?m	rdf:type gag:Dhmos ;
    5.21 +		rdfs:label ?mLabel ;
    5.22 +		gag:hasGeometry ?mGeo .
    5.23 +	FILTER(strdf:intersects(?hGeo, ?mGeo)) .
    5.24 +  }  
    5.25 +  GROUP BY ?h
    5.26 +}
     6.1 --- a/examples/teleios/insertMunicipalities.sparql	Thu Sep 27 19:12:21 2012 +0300
     6.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     6.3 @@ -1,23 +0,0 @@
     6.4 -PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#>
     6.5 -PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
     6.6 -PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
     6.7 -PREFIX strdf: <http://strdf.di.uoa.gr/ontology#>
     6.8 -PREFIX gag: <http://geo.linkedopendata.gr/greekadministrativeregion/ontology#>
     6.9 -PREFIX xsd: <http://www.w3.org/2001/XMLSchema#> 
    6.10 -
    6.11 -INSERT { ?h gag:hasMunicipality ?muni }
    6.12 -WHERE { 
    6.13 -SELECT ?h (SAMPLE(?mLabel) AS ?muni)
    6.14 -  WHERE {
    6.15 -	?h  rdf:type noa:Hotspot ;
    6.16 -		noa:hasGeometry ?hGeo ;
    6.17 -		noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
    6.18 -		noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string ;
    6.19 -        noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime.
    6.20 -	?m	rdf:type gag:Dhmos ;
    6.21 -		rdfs:label ?mLabel ;
    6.22 -		gag:hasGeometry ?mGeo .
    6.23 -	FILTER(strdf:intersects(?hGeo, ?mGeo)) .
    6.24 -  }  
    6.25 -  GROUP BY ?h
    6.26 -}
     7.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     7.2 +++ b/examples/teleios/landUseInvalidForFires.rq	Thu Sep 27 19:53:36 2012 +0300
     7.3 @@ -0,0 +1,23 @@
     7.4 +PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#> 
     7.5 +PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> 
     7.6 +PREFIX strdf: <http://strdf.di.uoa.gr/ontology#> 
     7.7 +PREFIX xsd: <http://www.w3.org/2001/XMLSchema#> 
     7.8 +PREFIX clc: <http://geo.linkedopendata.gr/corine/ontology#>
     7.9 +
    7.10 +INSERT {?h noa:isDiscarded "1"^^xsd:int ;
    7.11 +           noa:refinedBy noa:clcInconsistency .
    7.12 +} 
    7.13 +WHERE {
    7.14 +	SELECT ?h WHERE 
    7.15 +	{
    7.16 +		?h  noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime ;
    7.17 +			noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string ;
    7.18 +			noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
    7.19 +			noa:hasGeometry ?hGeo.
    7.20 +		?a  rdf:type   clc:ExcludeArea;
    7.21 +			clc:hasGeometry ?aGeo.
    7.22 +		FILTER(strdf:mbbIntersects(?hGeo,?aGeo)).
    7.23 +	} 
    7.24 +	GROUP BY ?h ?hGeo
    7.25 +	HAVING strdf:contains(strdf:union(?aGeo),?hGeo)
    7.26 +}
     8.1 --- a/examples/teleios/landUseInvalidForFires.sparql	Thu Sep 27 19:12:21 2012 +0300
     8.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     8.3 @@ -1,23 +0,0 @@
     8.4 -PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#> 
     8.5 -PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> 
     8.6 -PREFIX strdf: <http://strdf.di.uoa.gr/ontology#> 
     8.7 -PREFIX xsd: <http://www.w3.org/2001/XMLSchema#> 
     8.8 -PREFIX clc: <http://geo.linkedopendata.gr/corine/ontology#>
     8.9 -
    8.10 -INSERT {?h noa:isDiscarded "1"^^xsd:int ;
    8.11 -           noa:refinedBy noa:clcInconsistency .
    8.12 -} 
    8.13 -WHERE {
    8.14 -	SELECT ?h WHERE 
    8.15 -	{
    8.16 -		?h  noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime ;
    8.17 -			noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string ;
    8.18 -			noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
    8.19 -			noa:hasGeometry ?hGeo.
    8.20 -		?a  rdf:type   clc:ExcludeArea;
    8.21 -			clc:hasGeometry ?aGeo.
    8.22 -		FILTER(strdf:mbbIntersects(?hGeo,?aGeo)).
    8.23 -	} 
    8.24 -	GROUP BY ?h ?hGeo
    8.25 -	HAVING strdf:contains(strdf:union(?aGeo),?hGeo)
    8.26 -}
     9.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     9.2 +++ b/examples/teleios/refinePartialSeaHotspots.rq	Thu Sep 27 19:53:36 2012 +0300
     9.3 @@ -0,0 +1,38 @@
     9.4 +PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#> 
     9.5 +PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> 
     9.6 +PREFIX strdf: <http://strdf.di.uoa.gr/ontology#> 
     9.7 +PREFIX xsd: <http://www.w3.org/2001/XMLSchema#> 
     9.8 +PREFIX gag: <http://geo.linkedopendata.gr/greekadministrativeregion/ontology#>
     9.9 +
    9.10 +
    9.11 +INSERT { ?h noa:isDiscarded "1"^^xsd:int . 
    9.12 +	    ?valid rdf:type noa:Hotspot ;
    9.13 +	    noa:hasConfidence ?conf ;
    9.14 +	    noa:hasGeometry ?dif ;
    9.15 +	    gag:hasMunicipality ?muni ;
    9.16 +	    noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime ; 
    9.17 +	    noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
    9.18 +	    noa:hasConfirmation noa:unknown ;
    9.19 +	    noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string ; 
    9.20 +	    noa:isProducedBy noa:noa ;
    9.21 +	    noa:isDerivedFromSatellite "SAT"^^xsd:string ;
    9.22 +            noa:refinedBy noa:coastlineRefinement ;
    9.23 +            noa:refinedBy ?refined .
    9.24 +}
    9.25 +WHERE { 
    9.26 +  SELECT ?h  (strdf:intersection(?hGeo, strdf:union(?cGeo)) AS ?dif) (URI(CONCAT(STR(?h),"/refined")) AS ?valid) ?conf ?muni
    9.27 +  WHERE { 
    9.28 +	 ?h     noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime; 
    9.29 +       		noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string ; 
    9.30 +       		noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
    9.31 +		noa:hasGeometry ?hGeo ;
    9.32 +       		gag:hasMunicipality ?muni ;
    9.33 +       		noa:hasConfidence ?conf .
    9.34 +	 ?c     rdf:type gag:GeometryPart ;
    9.35 +       		gag:hasGeometry ?cGeo .
    9.36 +       	FILTER(strdf:mbbIntersects(?hGeo, ?cGeo)) . 
    9.37 +	OPTIONAL { ?h noa:refinedBy ?refined } .
    9.38 +  }
    9.39 +  GROUP BY ?h ?hGeo ?conf ?muni
    9.40 +  HAVING strdf:overlap(?hGeo, strdf:union(?cGeo))
    9.41 +}
    10.1 --- a/examples/teleios/refinePartialSeaHotspots.sparql	Thu Sep 27 19:12:21 2012 +0300
    10.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
    10.3 @@ -1,38 +0,0 @@
    10.4 -PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#> 
    10.5 -PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> 
    10.6 -PREFIX strdf: <http://strdf.di.uoa.gr/ontology#> 
    10.7 -PREFIX xsd: <http://www.w3.org/2001/XMLSchema#> 
    10.8 -PREFIX gag: <http://geo.linkedopendata.gr/greekadministrativeregion/ontology#>
    10.9 -
   10.10 -
   10.11 -INSERT { ?h noa:isDiscarded "1"^^xsd:int . 
   10.12 -	    ?valid rdf:type noa:Hotspot ;
   10.13 -	    noa:hasConfidence ?conf ;
   10.14 -	    noa:hasGeometry ?dif ;
   10.15 -	    gag:hasMunicipality ?muni ;
   10.16 -	    noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime ; 
   10.17 -	    noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
   10.18 -	    noa:hasConfirmation noa:unknown ;
   10.19 -	    noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string ; 
   10.20 -	    noa:isProducedBy noa:noa ;
   10.21 -	    noa:isDerivedFromSatellite "SAT"^^xsd:string ;
   10.22 -            noa:refinedBy noa:coastlineRefinement ;
   10.23 -            noa:refinedBy ?refined .
   10.24 -}
   10.25 -WHERE { 
   10.26 -  SELECT ?h  (strdf:intersection(?hGeo, strdf:union(?cGeo)) AS ?dif) (URI(CONCAT(STR(?h),"/refined")) AS ?valid) ?conf ?muni
   10.27 -  WHERE { 
   10.28 -	 ?h     noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime; 
   10.29 -       		noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string ; 
   10.30 -       		noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
   10.31 -		noa:hasGeometry ?hGeo ;
   10.32 -       		gag:hasMunicipality ?muni ;
   10.33 -       		noa:hasConfidence ?conf .
   10.34 -	 ?c     rdf:type gag:GeometryPart ;
   10.35 -       		gag:hasGeometry ?cGeo .
   10.36 -       	FILTER(strdf:mbbIntersects(?hGeo, ?cGeo)) . 
   10.37 -	OPTIONAL { ?h noa:refinedBy ?refined } .
   10.38 -  }
   10.39 -  GROUP BY ?h ?hGeo ?conf ?muni
   10.40 -  HAVING strdf:overlap(?hGeo, strdf:union(?cGeo))
   10.41 -}
    11.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
    11.2 +++ b/examples/teleios/refineTimePersistence.rq	Thu Sep 27 19:53:36 2012 +0300
    11.3 @@ -0,0 +1,47 @@
    11.4 +PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#> 
    11.5 +PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> 
    11.6 +PREFIX strdf: <http://strdf.di.uoa.gr/ontology#> 
    11.7 +PREFIX xsd: <http://www.w3.org/2001/XMLSchema#> 
    11.8 +PREFIX gag: <http://geo.linkedopendata.gr/greekadministrativeregion/ontology#>
    11.9 +
   11.10 +INSERT {?newHotspot rdf:type noa:Hotspot ;
   11.11 +		    noa:hasConfidence ?hConfidence ;
   11.12 +		    noa:hasGeometry ?hGeometry1 ;
   11.13 +		    noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime ; 
   11.14 +		    noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
   11.15 +		    noa:hasConfirmation noa:unknown ;
   11.16 +		    noa:producedFromProcessingChain "PROCESSING_CHAIN-TimePersistence"^^xsd:string ; 
   11.17 +		    noa:isProducedBy noa:noa ;
   11.18 +		    gag:hasMunicipality ?hMunicipality1 ;
   11.19 +		    noa:isDerivedFromSatellite "SAT"^^xsd:string ;
   11.20 +                    noa:refinedBy noa:temporalPersistence ;
   11.21 +                    noa:refinedBy ?refined .
   11.22 +}
   11.23 +WHERE {
   11.24 +	SELECT  (URI(CONCAT(STR(MAX(?h1)),"/virtual/NEW_HOTSPOT")) AS ?newHotspot)
   11.25 +			(SUM(?hConfidence1)/ACQUISITIONS_IN_HALF_AN_HOUR AS ?hConfidence)
   11.26 +			?hGeometry1 ?hMunicipality1
   11.27 +  WHERE {
   11.28 +    ?h1 noa:hasConfidence ?hConfidence1 ;
   11.29 +        noa:hasGeometry ?hGeometry1 ;
   11.30 +        gag:hasMunicipality ?hMunicipality1 ;
   11.31 +        noa:hasAcquisitionTime ?hAcquisitionTime1 ;
   11.32 +        noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
   11.33 +        noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string .
   11.34 +    OPTIONAL { ?h1 noa:isDiscarded ?z } .
   11.35 +    FILTER (!BOUND(?z)) .
   11.36 +    OPTIONAL { ?h1 noa:refinedBy ?refined } .
   11.37 +    FILTER( "MIN_ACQUISITION_TIME"^^xsd:dateTime <= ?hAcquisitionTime1 && ?hAcquisitionTime1 < "TIMESTAMP"^^xsd:dateTime ) .
   11.38 +    OPTIONAL {
   11.39 +      ?h2 noa:hasGeometry ?hGeometry2 ;
   11.40 +          noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime ;
   11.41 +          noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
   11.42 +          noa:producedFromProcessingChain ?hProcessingChain2 .
   11.43 +      FILTER(("PROCESSING_CHAIN"^^xsd:string = ?hProcessingChain2)||("PROCESSING_CHAIN-TimePersistence"^^xsd:string = ?hProcessingChain2)).
   11.44 +      FILTER( strdf:mbbEquals(?hGeometry1, ?hGeometry2) ) .
   11.45 +    }
   11.46 +    FILTER( !BOUND(?h2) ) .
   11.47 +  }
   11.48 +  GROUP BY ?hGeometry1 ?hMunicipality1
   11.49 +  HAVING(SUM(?hConfidence1)>0.0)
   11.50 +}
    12.1 --- a/examples/teleios/refineTimePersistence.sparql	Thu Sep 27 19:12:21 2012 +0300
    12.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
    12.3 @@ -1,47 +0,0 @@
    12.4 -PREFIX noa: <http://teleios.di.uoa.gr/ontologies/noaOntology.owl#> 
    12.5 -PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> 
    12.6 -PREFIX strdf: <http://strdf.di.uoa.gr/ontology#> 
    12.7 -PREFIX xsd: <http://www.w3.org/2001/XMLSchema#> 
    12.8 -PREFIX gag: <http://geo.linkedopendata.gr/greekadministrativeregion/ontology#>
    12.9 -
   12.10 -INSERT {?newHotspot rdf:type noa:Hotspot ;
   12.11 -		    noa:hasConfidence ?hConfidence ;
   12.12 -		    noa:hasGeometry ?hGeometry1 ;
   12.13 -		    noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime ; 
   12.14 -		    noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
   12.15 -		    noa:hasConfirmation noa:unknown ;
   12.16 -		    noa:producedFromProcessingChain "PROCESSING_CHAIN-TimePersistence"^^xsd:string ; 
   12.17 -		    noa:isProducedBy noa:noa ;
   12.18 -		    gag:hasMunicipality ?hMunicipality1 ;
   12.19 -		    noa:isDerivedFromSatellite "SAT"^^xsd:string ;
   12.20 -                    noa:refinedBy noa:temporalPersistence ;
   12.21 -                    noa:refinedBy ?refined .
   12.22 -}
   12.23 -WHERE {
   12.24 -	SELECT  (URI(CONCAT(STR(MAX(?h1)),"/virtual/NEW_HOTSPOT")) AS ?newHotspot)
   12.25 -			(SUM(?hConfidence1)/ACQUISITIONS_IN_HALF_AN_HOUR AS ?hConfidence)
   12.26 -			?hGeometry1 ?hMunicipality1
   12.27 -  WHERE {
   12.28 -    ?h1 noa:hasConfidence ?hConfidence1 ;
   12.29 -        noa:hasGeometry ?hGeometry1 ;
   12.30 -        gag:hasMunicipality ?hMunicipality1 ;
   12.31 -        noa:hasAcquisitionTime ?hAcquisitionTime1 ;
   12.32 -        noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
   12.33 -        noa:producedFromProcessingChain "PROCESSING_CHAIN"^^xsd:string .
   12.34 -    OPTIONAL { ?h1 noa:isDiscarded ?z } .
   12.35 -    FILTER (!BOUND(?z)) .
   12.36 -    OPTIONAL { ?h1 noa:refinedBy ?refined } .
   12.37 -    FILTER( "MIN_ACQUISITION_TIME"^^xsd:dateTime <= ?hAcquisitionTime1 && ?hAcquisitionTime1 < "TIMESTAMP"^^xsd:dateTime ) .
   12.38 -    OPTIONAL {
   12.39 -      ?h2 noa:hasGeometry ?hGeometry2 ;
   12.40 -          noa:hasAcquisitionTime "TIMESTAMP"^^xsd:dateTime ;
   12.41 -          noa:isDerivedFromSensor "SENSOR"^^xsd:string ;
   12.42 -          noa:producedFromProcessingChain ?hProcessingChain2 .
   12.43 -      FILTER(("PROCESSING_CHAIN"^^xsd:string = ?hProcessingChain2)||("PROCESSING_CHAIN-TimePersistence"^^xsd:string = ?hProcessingChain2)).
   12.44 -      FILTER( strdf:mbbEquals(?hGeometry1, ?hGeometry2) ) .
   12.45 -    }
   12.46 -    FILTER( !BOUND(?h2) ) .
   12.47 -  }
   12.48 -  GROUP BY ?hGeometry1 ?hMunicipality1
   12.49 -  HAVING(SUM(?hConfidence1)>0.0)
   12.50 -}