open-meta.com

SVG Open 2008


        SVG Open 2008

The text of  my presentation submitted for SVG Open 2008 follows , after that is the text of my Workshop also submitted for SVG Open 2008:
(following both of those are some SVG files which are used to help illustrate some of the ideas)



SVG, GML, KML Understanding Using Ontologies & Logic

This presentation is about the SVG Metadata element and the SVG Desc element usage in the topic areas of Accessibility of SVG, Location-based Services, Making Graphics Accessible. The Open-Meta Computing OMC name space used by the SVG Desc element is shown to be able to provide a schematized scene graph (using OpenSceneGraph OSG) and a semi-structured detailed description machine-usable beyond what a simple character-string description provides. The example SVG file which I wrote, shown in the SVG 1 spec, SVG meta data element, shows a simple example of this detail and the value of the structuring, such as including scene descriptors and Dublin Core in the meta data. The OMC name space scene graph is PCS-mappibly interoperable with RDF / OWL items in the SVG meta data section of an SVG file which depict spatial and other semantic relationships / descriptions of the component SVG items which constitute the SVG file. You can see examples of this RDF semantic representation of the spatial relationships of SVG items in the file containing the SVG
meta data item, in OMC's barchart.svg file (OMC website), and in Chapter 11 and 16 of my book WROX Professional XML Meta data. The OMC name space schematized scene graph capability enhances semantic knowledge of the SVG file content by maintaining such information as item location and attribute descriptions. External logic can use or give XML ID information on the SVG items comprising a file and incorporate those ID 'names' in both the scene graph and the meta data in the SVG meta data element of the file.Shown in this presentation is how geo-spatial data sets using GML and KML representation, accessed
through the SVG meta data element, are mapped into SVG graphics elements using meta-programming which implements aspect oriented programming technology. This external (to the SVG file) logic intelligently maps GML and KML items into visual form via SVG code generated via the mapping. The means to this intelligent meta-programming is explained in the presentation. Standardized symbols / geo-styles can be produced via the generated SVG based on the GML and KML content. KML is used in Google Maps and Earth. XML meta data (XML, RDF, RDFS, OWL, GML, KML) may be either embedded in the SVG Meta data element in the file or it may be external and referenced in the SVG Meta data element. URI, RDF:seeAlso and RDF:usedBy are used to reference external meta data, as can XML annotation and OMC PCS, the SVG meta data element is processed by parseType literal. Additionally it is shown how the twelve NASA JPL Semantic Web for Earth and Environmental Terminology (SWEET) ontologies, in conjunction with an ontology of SVG (*), are used to permit PELLET, a description logic reasoner, to not only understand the semantics of the SVG components constituting an SVG picture but also to understand the total ensemble of those elements. An (SVG) bargraph, pie-graph, and SVG-based geographic map are provided as focus examples. Embedded RDF and
OWL show spatial relationships etc and provide semantics to backup info in the scene graph content.

(*) The SVG ontology is a multiple ontology merging comprised of specific items from the SWEET set and mapped using the OMC Processing Connection Service PCS. It performs a topic map-like mapping of select items from multiple ontologies to comprise a new 'virtual' merged-ontology. In this case that ontology provides a semantic view of SVG in terms of SWEET. In this way SVG illustrations and XML material in GML and KML data sets 'have meaning' or are 'understood'. Schemas can not provide this, ontologies can. Named groups of SVG elements which draw standardized-stylized visual symbols, such as those used in cartography, are shown to be semantically understandable by this system using the ontologies and Description Logic reasoning. SVG can be mapped into GML / KML and vice-versa. SVG files can be mapped into natural language descriptions and vice-versa. This permits text-based query of SVG pictures including SVG geospatial illustrations.Because of the semantic understanding of the spatial-aspects of a GML, KML data set the external logic, with help from the ontologies, can map a 2 ½ D input or a 3D (X3D) input into a picture which 2D SVG can display by using perspective / projection performed in part by POV-ray.

David Dodds 
SVG Open 2008



Workshop

Workshop: SVG, GML, KML Understanding Using Ontologies & Logic

In this workshop participants will have hands on opportunity to see how to:

* use Notepad++ to look at SVG Desc element in an SVG file containing a schematized scene graph (using OpenSceneGraph OSG) and (B) relate items in the scene graph to SVG element items in the SVG picture

* use Notepad++ to look at a semi-structured data set in an SVG Desc element and (B) relate such contents to the SVG picture that that data set is in

* use Notepad++ to embed GML and KML data into the SVG meta data element of an SVG file

* view the SVG, GML, KML data with Firefox and with Notepad++, including SVG files barchart.svg, piechart.svg and SVG-based geographic map (each with meta data) .

* view the NASA JPL Semantic Web for Earth and Environmental Terminology (SWEET) ontologies with Notepad++ (Notepad++ does XML coloring nicely)

* edit the ontologies with Notepad++

* view OMC PCS with Notepad++ and (B) edit an instance of it and (C) see how to make a merged virtual ontology from a collection of other ontologies

* run Stanford Protege/OWL to view the SWEET ontologies, and (B) run PELLET to perform semantic processing of GML and KML geospatial data to produce SVG picture output from it the workshop shows hands-on how the SVG DESC and SVG META DATA elements may be used to provide an SVG system which not only can display geospatial (data) 'pictures' but also can 'understand' the SVG picture itself. (Understand in the sense of identifying the semantics (as expressed in ontologies) which relate the SVG which occurs in an SVG file (instance).)


Some examples: the SVG-based map that is part of the workshop uses SVG PATH to illustrate 'roadways' and 'waterways', and a circle to represent the location of cities. The NASA ontologies are seen to describe semantically what roads and waterways are and also what lines, and paths are (they are geometries) and the computer is able to “perceive” (via the ontologies and the semantic processing) that the SVG PATH elements in the geo-map picture represent the concepts (and descriptions of) roadways and waterways. (The color defined in the SVG elements is important too (obviously) but the computer doesn't know any intrinsic meaning of red or blue lines or paths). Well, the ontologies have other associated knowledge that goes with roadways and waterways concepts, and THAT gets associated with the SVG PATH elements in the picture. While you as a human see all this as obvious and trivial, remember that we're dealing with a computer and there is no one home in there.The other example was circles for cities on the map. By virtue of the ontologies the computer is able to 'see' that cities have names, locations, and areas or boundaries. Separate part of the SVG map has city names and point location to display the name on the map. The computer can infer that the name which has such a display origin-point closest to the the center of the circle having some ID in the SVG file, IS the name of that city. And because the ontology says that cities have names the computer can then 'know' to hunt around in the SVG file to find them. Also it can 'see' that the circles represent both an area for/of a city and also its 'location'. None of this information is EXPLICITLY present in the SVG map. So it wasnt just a table lookup or something braindead simple to do with a program-script.the following text should help develop a framework about what the hands on workshop shows and is
about:


SVG, GML, KML Understanding Using Ontologies & Logic

This presentation is about the SVG Metadata element and the SVG Desc element usage in the topic areas of Accessibility of SVG, Location-based Services, Making Graphics Accessible. The Open-Meta Computing OMC name space used by the SVG Desc element is shown to be able to provide a schematized scene graph (using OpenSceneGraph OSG) and a semi-structured detailed description machine-usable beyond what a simple character-string description provides. The example SVG file which I wrote, shown in the SVG 1 spec, SVG meta data element, shows a simple example of this detail and the value of the structuring, such as including scene descriptors and Dublin Core in the meta data. The OMC name space scene graph is PCS-mappibly interoperable with RDF / OWL items in the SVG meta data section of an SVG file which depict spatial and other semantic relationships / descriptions of the component SVG items which constitute the SVG file. You can see examples of this RDF semantic representation of the spatial relationships of SVG items in the file containing the SVG
meta data item, in OMC's barchart.svg file (OMC website), and in Chapter 11 and 16 of my book WROX Professional XML Meta data. The OMC name space schematized scene graph capability enhances semantic knowledge of the SVG file content by maintaining such information as item location and attribute descriptions. External logic can use or give XML ID information on the SVG items comprising a file and incorporate those ID 'names' in both the scene graph and the meta data in the SVG meta data element of the file. Shown in this presentation is how geo-spatial data sets using GML and KML representation, accessed
through the SVG meta data element, are mapped into SVG graphics elements using meta-programming which implements aspect oriented programming technology. This external (to the SVG file) logic intelligently maps GML and KML items into visual form via SVG code generated via the mapping. The means to this intelligent meta-programming is explained in the presentation. Standardized symbols / geo-styles can be produced via the generated SVG based on the GML and KML content. KML is used in Google Maps and Earth. XML meta data (XML, RDF, RDFS, OWL, GML, KML) may be either embedded in the SVG Meta data element in the file or it may be external and referenced  in the SVG Meta data element. URI, RDF:seeAlso and RDF:usedBy are used to reference external meta data, as can XML annotation and OMC PCS, the SVG meta data element is processed by parseType literal. Additionally it is shown how the twelve NASA JPL Semantic Web for Earth and Environmental Terminology (SWEET) ontologies, in conjunction with an ontology of SVG (*), are used to permit PELLET, a description logic reasoner, to not only understand the semantics of the SVG components constituting an SVG picture but also to understand the total ensemble of those elements. An (SVG) bargraph, pie-graph, and SVG-based geographic map are provided as focus examples. Embedded RDF and
OWL show spatial relationships etc and provide semantics to backup info in the scene graph content. (*) The SVG ontology is a multiple ontology merging comprised of specific items from the SWEET set and mapped using the OMC Processing Connection Service PCS. It performs a topic map-like mapping
of select items from multiple ontologies to comprise a new 'virtual' merged-ontology. In this case that ontology provides a semantic view of SVG in terms of SWEET. In this way SVG illustrations and XML material in GML and KML data sets 'have meaning' or are 'understood'. Schemas can not provide this, ontologies can.


David Dodds   SVG Open 2008


The following SVG code is Copyrighted. Copyright David Dodds 2008

myfoo_barchart.xml
Example of spatially related SVG components and metadata
<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
<!--Copyright 2008 David Dodds All Rights Reserved code copyright owner-->
<svg xmlns:xlink="http://www.w3.org/1999/xlink" xmlns="http://www.w3.org/2000/svg">
<desc xmlns:myfoo="http://example.org/myfoo">
<myfoo:title>This is a financial report</myfoo:title>
<myfoo:descr>The global description uses markup from the
<myfoo:emph>myfoo</myfoo:emph>namespace.
</myfoo:descr>
<myfoo:scene>
<myfoo:what>widget growth</myfoo:what>
<myfoo:contains>thirteen graph-bar</myfoo:contains>
<myfoo:when>1987 through 1999</myfoo:when>
</myfoo:scene>
</desc>
<metadata xmlns:rdfs="http://www.w3.org/TR/. ..-schema#" xmlns:omcsvg="http://www.openmeta.com/omcschema/"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description about="#text1">
<omcsvg:Below resource="#xbaseline"/>
</rdf:Description>
<rdfs:comment rdf:datatype="http://www.w3.org/2001/XMLSchema#string">XSLT2 Parse can translate &quot;id text1 is below id xbaseline&quot;
</rdfs:comment>
<rdf:Description about="#text1">
<omcsvg:IsNear resource="#xbaseline"/>
</rdf:Description>
<rdf:Description about="#text2">
<omcsvg:Below resource="#text1"/>
</rdf:Description>
<rdf:Description about="#text2">
<omcsvg:IsNear resource="#text1"/>
</rdf:Description>
<rdf:Description about="#endlineleft">
<omcsvg:AtRight resource="#bar1"/>
</rdf:Description>
<rdf:Description about="#endlineleft">
<omcsvg:IsNear resource="#bar1"/>
</rdf:Description>
<rdf:Description about="#endlineright">
<omcsvg:AtLeft resource="#bar13"/>
</rdf:Description>
<rdf:Description about="#endlineright">
<omcsvg:IsNear resource="#bar13"/>
</rdf:Description>
<rdf:Description about="#bar1">
<omcsvg:AtRight resource="#bar2"/>
</rdf:Description>
<rdf:Description about="#bar2">
<omcsvg:AtRight resource="#bar3"/>
</rdf:Description>
<rdf:Description about="#bar3">
<omcsvg:AtRight resource="#bar4"/>
</rdf:Description>
<rdf:Description about="#bar4">
<omcsvg:AtRight resource="#bar5"/>
</rdf:Description>
<rdf:Description about="#bar5">
<omcsvg:AtRight resource="#bar6"/>
</rdf:Description>
<rdf:Description about="#bar6">
<omcsvg:AtRight resource="#bar7"/>
</rdf:Description>
<rdf:Description about="#bar7">
<omcsvg:AtRight resource="#bar8"/>
</rdf:Description>
<rdf:Description about="#bar8">
<omcsvg:AtRight resource="#bar9"/>
</rdf:Description>
<rdf:Description about="#bar9">
<omcsvg:AtRight resource="#bar10"/>
</rdf:Description>
<rdf:Description about="#bar10">
<omcsvg:AtRight resource="#bar11"/>
</rdf:Description>
<rdfs:comment>SWRL SPARQL Jena RuleML XSLT can be used to examine the metadata and
ontology info to &quot;see&quot; that this is an SVG bar chart
</rdfs:comment>
<rdfs:seeAlso rdf:resource="http://www.open-meta.com/omcschema#AtRight"/>
<rdfs:isDefinedBy rdf:resource="http://www.open-meta.com/majic"/>
<rdf:Description about="#bar11">
<omcsvg:AtRight resource="#bar12"/>
</rdf:Description>
</metadata>
<text x="1" id="originlabel" y="12" style="font-family:Verdana; font-size:12.333;fill:lightblue"> * origin x=0, y=0</text>
<text x="340" id="uplabel" y="20" style="font-family:Verdana; font-size:12.333; fill:black">UP</text>
<text x="340" id="downlabel" y="230" style="font-family:Verdana; font-size:12.333;fill:black">DOWN</text>
<rect x="37" y="190" width="280" style="stroke:black; stroke-width:1" height="1"id="xbaseline"/>
<text x="317" id="text3" y="194" style="font-family:Verdana; font-size:12.333;fill:indigo">18</text>
<rect x="333" y="96" width="1" style="stroke:black; stroke-width:1" height="104" id="endlineright"/>
<rect x="37" y="96" width="1" style="stroke:black; stroke-width:1" height="104" id="endlineleft"/>
<rect x="40" y="160" width="20" style="stroke:green; fill:green; stroke-width:0" height="40" id="bar1"/>
<rect x="60" y="140" width="20" style="stroke:yellow; fill:yellow; stroke-width:0" height="60" id="bar2"/>
<rect x="80" y="111" width="20" style="stroke:blue; fill:orange; stroke-width:0" height="89" id="bar3"/>
<rect x="100" y="130" width="20" style="stroke:yellow; fill:yellow; stroke-width:0" height="70" id="bar4"/>
<rect x="120" y="173" width="20" style="stroke:green; fill:lightgreen; stroke-width:0" height="27" id="bar5"/>
<rect x="140" y="191" width="20" style="stroke:green; fill:green; stroke-width:0" height="09" id="bar6"/>
<rect x="160" y="140" width="20" style="stroke:yellow; fill:yellow; stroke-width:0" height="60" id="bar7"/>
<rect x="180" y="167" width="20" style="stroke:green; fill:green; stroke-width:0" height="33" id="bar8"/>
<rect x="200" y="175" width="20" style="stroke:green; fill:green; stroke-width:0" height="25" id="bar9"/>
<rect x="220" y="129" width="20" style="stroke:yellow; fill:yellow; stroke-width:0" height="71" id="bar10"/>
<rect x="240" y="150" width="20" style="stroke:green; fill:green; stroke-width:0" height="50" id="bar11"/>
<rect x="260" y="139" width="20" style="stroke:yellow; fill:yellow; stroke-width:0" height="61" id="bar12"/>
<rect x="280" y="125" width="20" style="stroke:yellow; fill:yellow; stroke-width:0" height="75" id="bar13"/>
<text x="37" id="text1" y="210" style="font-family:Verdana; font-size:25.;fill:black">95969798990001020304050607</text>
<text x="37" id="text2" y="230" style="font-family:Verdana; font-size:12.333; fill:blue">Mean High Ratings August 2007</text>
</svg>