com presentations: Slides for tonight's MongoDB UG.: mongo-tz-mug13.xml slides/mongodb/all-zones.png slides/mongodb/josm-tzshapefile2.png
slides/mongodb/location-to-tzid-method.xml slides/mongodb/resources.xml slides/mongodb/simplify1.png slides/mongodb/simplify2.png
slides/mongodb/simplify3.png slides/mongodb/simplify4.png slides/mongodb/tzid-convert-osm-file.xml slides/mongodb/tzid-convert-shapefiles.xml
slides/mongodb/tzid-fallback.xml slides/
| From: | Derick Rethans | Date: | Wed, 11 Sep 2013 17:11:09 +0000 |
| Subject: | com presentations: Slides for tonight's MongoDB UG.: mongo-tz-mug13.xml slides/mongodb/all-zones.png slides/mongodb/josm-tzshapefile2.png slides/mongodb/location-to-tzid-method.xml slides/mongodb/resources.xml slides/mongodb/simplify1.png slides/mongodb/simplify2.png slides/mongodb/simplify3.png slides/mongodb/simplify4.png slides/mongodb/tzid-convert-osm-file.xml slides/mongodb/tzid-convert-shapefiles.xml slides/mongodb/tzid-fallback.xml slides/ |
||
| Groups: | php.pres | ||
| Request: | Send a blank email to pres+get-1911@lists.php.net to get a copy of this message | ||
Commit: da951bf5f35428be99d15892c4d118f686af7ebc
Author: Derick Rethans <github@derickrethans.nl> Wed, 11 Sep 2013 18:11:09 +0100
Parents: b9f3cc6008c700bc70ce92f0e9e942fb610ce269
Branches: master
Link: http://git.php.net/?p=presentations.git;a=commitdiff;h=da951bf5f35428be99d15892c4d118f686af7ebc
Log:
Slides for tonight's MongoDB UG.
Changed paths:
A mongo-tz-mug13.xml
A slides/mongodb/all-zones.png
A slides/mongodb/josm-tzshapefile2.png
A slides/mongodb/location-to-tzid-method.xml
M slides/mongodb/resources.xml
A slides/mongodb/simplify1.png
A slides/mongodb/simplify2.png
A slides/mongodb/simplify3.png
A slides/mongodb/simplify4.png
A slides/mongodb/tzid-convert-osm-file.xml
A slides/mongodb/tzid-convert-shapefiles.xml
A slides/mongodb/tzid-fallback.xml
A slides/mongodb/tzid-import-osm-file.xml
A slides/mongodb/tzid-left-to-do.xml
A slides/mongodb/tzid-match-same-tzid.xml
A slides/mongodb/tzid-match.xml
A slides/mongodb/tzid-matched-show.xml
A slides/mongodb/tzid-nautical-border-ca-us.xml
A slides/mongodb/tzid-nautical-border.xml
A slides/mongodb/tzid-nautical-border2.xml
A slides/mongodb/tzid-nautical-what-it-is.xml
A slides/mongodb/tzid-shapefiles.xml
A slides/mongodb/tzid-simplify.xml
A slides/mongodb/tzid-simplify1.xml
A slides/mongodb/tzid-simplify2.xml
A slides/mongodb/tzid-simplify3.xml
A slides/mongodb/tzid-simplify4.xml
A slides/mongodb/uk-highres.png
A slides/mongodb/uk-nautical.png
A slides/mongodb/us-ca-nautical.png
A slides/mongodb/zone-utc.png
M slides/time/improvements-timezones.xml
A slides/time/location-to-tzid.xml
A slides/time/timezone-map.xml
A slides/time/worldclock.jpg
A slides/time/worldclock.xml
diff --git a/mongo-tz-mug13.xml b/mongo-tz-mug13.xml new file mode 100644 index 0000000..a505ff9 --- /dev/null +++ b/mongo-tz-mug13.xml @@ -0,0 +1,47 @@ +<?xml version="1.0" encoding="utf-8"?> +<presentation css="10gen-strict.css"> +<topic>MongoDB</topic> +<title>What time is it where?</title> +<event>MongoDB MUG #7</event> +<location>London, UK</location> +<lat>51.52348</lat><lon>-0.08350</lon> +<date>September 11th, 2013</date> +<speaker>Derick Rethans</speaker> +<email>derick@mongodb.com</email> +<twitter>derickr</twitter> +<joindin>http://derickrethans.nl/talks/mongo-tz-mug13</joindin> + +<slide>slides/mongodb/title.xml</slide> +<slide>slides/time/worldclock.xml</slide> +<slide>slides/time/problems-condensed.xml</slide> +<slide>slides/time/timezone-map.xml</slide> +<slide>slides/time/improvements-timezones.xml</slide> +<slide>slides/time/location-to-tzid.xml</slide> + +<slide>slides/mongodb/location-to-tzid-method.xml</slide> +<slide>slides/mongodb/tzid-shapefiles.xml</slide> +<slide>slides/mongodb/tzid-convert-shapefiles.xml</slide> +<slide>slides/mongodb/tzid-convert-osm-file.xml</slide> +<slide>slides/mongodb/tzid-import-osm-file.xml</slide> + +<slide>slides/mongodb/tzid-match.xml</slide> +<slide>slides/mongodb/tzid-match-same-tzid.xml</slide> + +<slide>slides/mongodb/tzid-simplify1.xml</slide> +<slide>slides/mongodb/tzid-simplify2.xml</slide> +<slide>slides/mongodb/tzid-simplify3.xml</slide> +<slide>slides/mongodb/tzid-simplify4.xml</slide> + +<slide>slides/mongodb/tzid-nautical-border.xml</slide> +<slide>slides/mongodb/tzid-nautical-border2.xml</slide> +<slide>slides/mongodb/tzid-nautical-border-ca-us.xml</slide> + +<slide>slides/mongodb/tzid-fallback.xml</slide> +<slide>slides/mongodb/tzid-nautical-what-it-is.xml</slide> +<slide>slides/mongodb/tzid-left-to-do.xml</slide> + +<slide>slides/mongodb/questions.xml</slide> + +<slide>slides/mongodb/resources.xml</slide> + +</presentation> diff --git a/slides/mongodb/all-zones.png b/slides/mongodb/all-zones.png new file mode 100644 index 0000000..75fe1c0 Binary files /dev/null and b/slides/mongodb/all-zones.png differ diff --git a/slides/mongodb/josm-tzshapefile2.png b/slides/mongodb/josm-tzshapefile2.png new file mode 100644 index 0000000..543eba6 Binary files /dev/null and b/slides/mongodb/josm-tzshapefile2.png differ diff --git a/slides/mongodb/location-to-tzid-method.xml b/slides/mongodb/location-to-tzid-method.xml new file mode 100644 index 0000000..8495842 --- /dev/null +++ b/slides/mongodb/location-to-tzid-method.xml @@ -0,0 +1,10 @@ +<slide> +<title>Approach</title> + +<list> + <bullet>Find shape files defining the Timezone Identifier boundaries</bullet> + <bullet>Convert shape files to GeoJSON</bullet> + <bullet>Import GeoJSON files into MongoDB</bullet> + <bullet>Match!</bullet> +</list> +</slide> diff --git a/slides/mongodb/resources.xml b/slides/mongodb/resources.xml index 1b86f88..3fd20cf 100644 --- a/slides/mongodb/resources.xml +++ b/slides/mongodb/resources.xml @@ -2,6 +2,6 @@ <break/> <qrcode>http://derickrethans.nl/talks/:-:talk_id:-:</qrcode> <break/> -<blurb class="pres-url-small">:-:joindin:-:</blurb> -<blurb class="pres-url-small">:-:email:-:—@:-:twitter:-:</blurb> +<blurb align="center" class="pres-url-small">:-:joindin:-:</blurb> +<blurb align="center" class="pres-url-small">:-:email:-:—@:-:twitter:-:</blurb> </slide> diff --git a/slides/mongodb/simplify1.png b/slides/mongodb/simplify1.png new file mode 100644 index 0000000..ee8652d Binary files /dev/null and b/slides/mongodb/simplify1.png differ diff --git a/slides/mongodb/simplify2.png b/slides/mongodb/simplify2.png new file mode 100644 index 0000000..1cd0c16 Binary files /dev/null and b/slides/mongodb/simplify2.png differ diff --git a/slides/mongodb/simplify3.png b/slides/mongodb/simplify3.png new file mode 100644 index 0000000..8c57f29 Binary files /dev/null and b/slides/mongodb/simplify3.png differ diff --git a/slides/mongodb/simplify4.png b/slides/mongodb/simplify4.png new file mode 100644 index 0000000..ba6dab5 Binary files /dev/null and b/slides/mongodb/simplify4.png differ diff --git a/slides/mongodb/tzid-convert-osm-file.xml b/slides/mongodb/tzid-convert-osm-file.xml new file mode 100644 index 0000000..d8380d1 --- /dev/null +++ b/slides/mongodb/tzid-convert-osm-file.xml @@ -0,0 +1,32 @@ +<slide> +<title>After saving...</title> + +<example><![CDATA[ +<?xml version='1.0' encoding='UTF-8'?> +<osm version='0.6' upload='false' generator='JOSM'> + <node id='-1754895' visible='true' lat='11.843674659729004' lon='-71.322021484375' /> + <node id='-1754894' visible='true' lat='11.844100952148438' lon='-71.31991577148438' /> + … + <node id='-8' visible='true' lat='15.542881011962892' lon='-61.29474258422852' /> + <way id='-1751536' visible='true'> + <nd ref='-774459' /> + … + <nd ref='-131' /> + </way> + <way id='-7' visible='true'> + <nd ref='-8' /> + … + <nd ref='-8' /> + <tag k='TZID' v='America/Dominica' /> + </way> + … + <relation id='-129' visible='true'> + <member type='way' ref='-130' role='outer' /> + <member type='way' ref='-137' role='outer' /> + … + <member type='way' ref='-283' role='outer' /> + <tag k='TZID' v='America/St_Vincent' /> + <tag k='type' v='multipolygon' /> + </relation> +</osm>]]></example> +</slide> diff --git a/slides/mongodb/tzid-convert-shapefiles.xml b/slides/mongodb/tzid-convert-shapefiles.xml new file mode 100644 index 0000000..85ecc8c --- /dev/null +++ b/slides/mongodb/tzid-convert-shapefiles.xml @@ -0,0 +1,15 @@ +<slide> +<title>Converting shapefiles</title> + +<image filename="josm-tzshapefile2.png" align="right"/> +<list> + <bullet>We need to import them into MongoDB</bullet> + <bullet>I have already written an OpenStreetMap to MongoDB importer</bullet> + <bullet>The OpenStreetMap editor JOSM can convert shapefiles: + <example> +wget http://efele.net/maps/tz/world/tz_world_mp.zip +unzip tz_world_mp.zip +josm world/tz_world_mp.shp</example> + </bullet> +</list> +</slide> diff --git a/slides/mongodb/tzid-fallback.xml b/slides/mongodb/tzid-fallback.xml new file mode 100644 index 0000000..c0705dc --- /dev/null +++ b/slides/mongodb/tzid-fallback.xml @@ -0,0 +1,10 @@ +<slide> +<title>Nautical Time</title> + +<blurb>Three different cases:</blurb> +<list> + <bullet>The location is within a land-polygon</bullet> + <bullet>The location is within 22km from a land-polygon</bullet> + <bullet>All others: Nautical time</bullet> +</list> +</slide> diff --git a/slides/mongodb/tzid-import-osm-file.xml b/slides/mongodb/tzid-import-osm-file.xml new file mode 100644 index 0000000..eb28cf8 --- /dev/null +++ b/slides/mongodb/tzid-import-osm-file.xml @@ -0,0 +1,27 @@ +<slide> +<title>Importing the OSM file</title> + +<blurb>Article describing imports:<br/>http://drck.me/mongosm-a7u</blurb> +<example>> db.timezone.stats(1024); +{ + "ns" : "demo.timezone", + "count" : 408, + "size" : 69841, + "avgObjSize" : 171.17892156862746, + "storageSize" : 142736, + "numExtents" : 9, + "nindexes" : 4, + "lastExtentSize" : 41340, + "paddingFactor" : 1, + "systemFlags" : 1, + "userFlags" : 0, + "totalIndexSize" : 2427, + "indexSizes" : { + "_id_" : 23, + "ty_1" : 23, + "l_2dsphere" : 2331, + "ts_1" : 47 + }, + "ok" : 1 +}</example> +</slide> diff --git a/slides/mongodb/tzid-left-to-do.xml b/slides/mongodb/tzid-left-to-do.xml new file mode 100644 index 0000000..52530a7 --- /dev/null +++ b/slides/mongodb/tzid-left-to-do.xml @@ -0,0 +1,11 @@ +<slide> +<title>What's next?</title> + +<image align="center" filename="all-zones.png"/> + +<list> + <bullet>Create shape files that include territorial waters</bullet> + <bullet>Improve simplification algorithm/implementation</bullet> +</list> + +</slide> diff --git a/slides/mongodb/tzid-match-same-tzid.xml b/slides/mongodb/tzid-match-same-tzid.xml new file mode 100644 index 0000000..5ca121c --- /dev/null +++ b/slides/mongodb/tzid-match-same-tzid.xml @@ -0,0 +1,9 @@ +<slide> +<title>Finding the TZID at a location</title> + +<blurb>All others with the same TZID:</blurb> +<example>db.timezone.find( { ts: "TZID=Europe/London" } );</example> + +<break lines="4"/> +<image filename="uk-highres.png"/> +</slide> diff --git a/slides/mongodb/tzid-match.xml b/slides/mongodb/tzid-match.xml new file mode 100644 index 0000000..58fd5af --- /dev/null +++ b/slides/mongodb/tzid-match.xml @@ -0,0 +1,26 @@ +<slide> +<title>Finding the TZID at a location</title> + +<blurb>Under the "cursor":</blurb> +<example>db.timezone.findOne( { + l: { + '$geoIntersects' : { + '$geometry' : { + type: 'Point', + coordinates: [ -0.08237, 51.52336 ] + } + } + } +}, { ts: 1 } );</example> + +<blurb>Result:</blurb> +<example> +{ + "_id" : "r-1403284", + "ts" : [ + "TZID=Europe/London", + "type=multipolygon" + ] +} +</example> +</slide> diff --git a/slides/mongodb/tzid-matched-show.xml b/slides/mongodb/tzid-matched-show.xml new file mode 100644 index 0000000..8221884 --- /dev/null +++ b/slides/mongodb/tzid-matched-show.xml @@ -0,0 +1,5 @@ +<slide> +<title>Finding the TZID at a location</title> + +<image filename="uk-highres.png"/> +</slide> diff --git a/slides/mongodb/tzid-nautical-border-ca-us.xml b/slides/mongodb/tzid-nautical-border-ca-us.xml new file mode 100644 index 0000000..4d094b8 --- /dev/null +++ b/slides/mongodb/tzid-nautical-border-ca-us.xml @@ -0,0 +1,7 @@ +<slide> +<title>Territorial Waters</title> + +<blurb>It does not always work...</blurb> + +<image filename="us-ca-nautical.png" align="center"/> +</slide> diff --git a/slides/mongodb/tzid-nautical-border.xml b/slides/mongodb/tzid-nautical-border.xml new file mode 100644 index 0000000..8b4e079 --- /dev/null +++ b/slides/mongodb/tzid-nautical-border.xml @@ -0,0 +1,11 @@ +<slide> +<title>Territorial waters</title> + +<list> + <bullet>Share the same timezone as the zone they belong to</bullet> + <bullet>Extend up to 22km from the coast</bullet> +</list> + +<break lines="2"/> +<image filename="uk-nautical.png" align="center"/> +</slide> diff --git a/slides/mongodb/tzid-nautical-border2.xml b/slides/mongodb/tzid-nautical-border2.xml new file mode 100644 index 0000000..6e5234f --- /dev/null +++ b/slides/mongodb/tzid-nautical-border2.xml @@ -0,0 +1,32 @@ +<slide> +<title>Territorial waters</title> + +<example> +db.timezone.aggregate( [ + { "$geoNear": { + near: { type: "Point", coordinates: [ 1.0375, 51.5809 ] }, + distanceField: "d", + distanceMultiplier: 1, + maxDistance: 22000, + spherical: true, + query: { "ty" : { $gte: 2 } }, + limit: 4 + } } +] ); +</example> + +<example>{ + "result" : [ + { + "_id" : "r-1403284", + "ty" : NumberLong(3), + "ts" : [ + "TZID=Europe/London", + "type=multipolygon" + ], + "l" : { … } + } + ] +} +</example> +</slide> diff --git a/slides/mongodb/tzid-nautical-what-it-is.xml b/slides/mongodb/tzid-nautical-what-it-is.xml new file mode 100644 index 0000000..08ec48d --- /dev/null +++ b/slides/mongodb/tzid-nautical-what-it-is.xml @@ -0,0 +1,11 @@ +<slide> +<title>Nautical Time</title> + +<list> + <bullet>Timezones from before timezones where invented</bullet> + <bullet>Simply divides the Earth into 24 zones</bullet> + <bullet>15° apart</bullet> +</list> +<break lines="2"/> +<image filename="zone-utc.png" align="center"/> +</slide> diff --git a/slides/mongodb/tzid-shapefiles.xml b/slides/mongodb/tzid-shapefiles.xml new file mode 100644 index 0000000..d4e8202 --- /dev/null +++ b/slides/mongodb/tzid-shapefiles.xml @@ -0,0 +1,9 @@ +<slide> +<title>Shapefiles</title> + +<list> + <bullet>Eric Muller provides shape files at:<br/>http://efele.net/maps/tz/world/</bullet> + <bullet>For each Timezone Identifier there are one or more polygons</bullet> + <bullet>Polygons can have holes in them</bullet> +</list> +</slide> diff --git a/slides/mongodb/tzid-simplify.xml b/slides/mongodb/tzid-simplify.xml new file mode 100644 index 0000000..d0a26c8 --- /dev/null +++ b/slides/mongodb/tzid-simplify.xml @@ -0,0 +1,15 @@ +<slide> +<title>Simplify ways</title> + +<image align="right" filename="simplify1.png"/> + +<list> + <bullet>Lots of points take a lot of rendering time</bullet> + <bullet>Simplifying ways to reduce rendering time</bullet> + <bullet>Ramer–Douglas–Peucker algorithm</bullet> + <bullet>Takes up time to run...</bullet> + <bullet>Part of MongoDB?</bullet> + <bullet>Store alternative polygons for rendering?</bullet> +</list> + +</slide> diff --git a/slides/mongodb/tzid-simplify1.xml b/slides/mongodb/tzid-simplify1.xml new file mode 100644 index 0000000..6c9361a --- /dev/null +++ b/slides/mongodb/tzid-simplify1.xml @@ -0,0 +1,10 @@ +<slide> +<title>Simplify ways</title> + +<image align="right" filename="simplify1.png"/> + +<list> + <bullet>Lots of points take a lot of rendering time</bullet> +</list> + +</slide> diff --git a/slides/mongodb/tzid-simplify2.xml b/slides/mongodb/tzid-simplify2.xml new file mode 100644 index 0000000..cdb430c --- /dev/null +++ b/slides/mongodb/tzid-simplify2.xml @@ -0,0 +1,12 @@ +<slide> +<title>Simplify ways</title> + +<image align="right" filename="simplify2.png"/> + +<list> + <bullet>Lots of points take a lot of rendering time</bullet> + <bullet>Simplifying ways to reduce rendering time</bullet> + <bullet>Ramer–Douglas–Peucker algorithm</bullet> +</list> + +</slide> diff --git a/slides/mongodb/tzid-simplify3.xml b/slides/mongodb/tzid-simplify3.xml new file mode 100644 index 0000000..5b55f50 --- /dev/null +++ b/slides/mongodb/tzid-simplify3.xml @@ -0,0 +1,12 @@ +<slide> +<title>Simplify ways</title> + +<image align="right" filename="simplify3.png"/> + +<list> + <bullet>Lots of points take a lot of rendering time</bullet> + <bullet>Simplifying ways to reduce rendering time</bullet> + <bullet>Ramer–Douglas–Peucker algorithm</bullet> +</list> + +</slide> diff --git a/slides/mongodb/tzid-simplify4.xml b/slides/mongodb/tzid-simplify4.xml new file mode 100644 index 0000000..ec99146 --- /dev/null +++ b/slides/mongodb/tzid-simplify4.xml @@ -0,0 +1,15 @@ +<slide> +<title>Simplify ways</title> + +<image align="right" filename="simplify4.png"/> + +<list> + <bullet>Lots of points take a lot of rendering time</bullet> + <bullet>Simplifying ways to reduce rendering time</bullet> + <bullet>Ramer–Douglas–Peucker algorithm</bullet> + <bullet>Takes up time to run...</bullet> + <bullet>Part of MongoDB?</bullet> + <bullet>Store alternative polygons for rendering?</bullet> +</list> + +</slide> diff --git a/slides/mongodb/uk-highres.png b/slides/mongodb/uk-highres.png new file mode 100644 index 0000000..214023d Binary files /dev/null and b/slides/mongodb/uk-highres.png differ diff --git a/slides/mongodb/uk-nautical.png b/slides/mongodb/uk-nautical.png new file mode 100644 index 0000000..c5d9cae Binary files /dev/null and b/slides/mongodb/uk-nautical.png differ diff --git a/slides/mongodb/us-ca-nautical.png b/slides/mongodb/us-ca-nautical.png new file mode 100644 index 0000000..ff0cfa6 Binary files /dev/null and b/slides/mongodb/us-ca-nautical.png differ diff --git a/slides/mongodb/zone-utc.png b/slides/mongodb/zone-utc.png new file mode 100644 index 0000000..6871bea Binary files /dev/null and b/slides/mongodb/zone-utc.png differ diff --git a/slides/time/improvements-timezones.xml b/slides/time/improvements-timezones.xml index 4366fd3..56be555 100644 --- a/slides/time/improvements-timezones.xml +++ b/slides/time/improvements-timezones.xml @@ -3,9 +3,9 @@ <title>Timezone Support</title> <list> - <bullet>Bundled timezone database with more than 500 zones</bullet> - <bullet>Not dependent on timezone abbreviations</bullet> - <bullet>Timezones have the format: Continent/Location or Continent/Location/Sublocation - Like: Europe/Amsterdam, America/Indiana/Knox</bullet> + <bullet>There are more than 500 zones</bullet> + <bullet>Do not dependend on timezone abbreviations</bullet> + <bullet>Use timezone IDs like %Europe/Amsterdam% or %America/Indiana/Knox%</bullet> </list> <image align="center" filename="zone-places.png" y-offset="6"/> diff --git a/slides/time/location-to-tzid.xml b/slides/time/location-to-tzid.xml new file mode 100644 index 0000000..0eca540 --- /dev/null +++ b/slides/time/location-to-tzid.xml @@ -0,0 +1,3 @@ +<slide type="section"> +<blurb class="quote">How to get to local time?</blurb> +</slide> diff --git a/slides/time/timezone-map.xml b/slides/time/timezone-map.xml new file mode 100644 index 0000000..552bd61 --- /dev/null +++ b/slides/time/timezone-map.xml @@ -0,0 +1,5 @@ +<slide> +<title>Map</title> + +<iframe width="1000" filename='http://127.0.1.4/?l=timezones&zoom=3;&lat=:-:lat:-:&lon=:-:lon:-:'/> +</slide> diff --git a/slides/time/worldclock.jpg b/slides/time/worldclock.jpg new file mode 100644 index 0000000..b76d3e2 Binary files /dev/null and b/slides/time/worldclock.jpg differ diff --git a/slides/time/worldclock.xml b/slides/time/worldclock.xml new file mode 100644 index 0000000..cfb055b --- /dev/null +++ b/slides/time/worldclock.xml @@ -0,0 +1,5 @@ +<slide> +<title>What time is it where?</title> + +<image filename="worldclock.jpg" attr="CC-by: http://www.flickr.com/photos/skippy/"/> +</slide>
diff --git a/mongo-tz-mug13.xml b/mongo-tz-mug13.xml new file mode 100644 index 0000000..a505ff9 --- /dev/null +++ b/mongo-tz-mug13.xml @@ -0,0 +1,47 @@ +<?xml version="1.0" encoding="utf-8"?> +<presentation css="10gen-strict.css"> +<topic>MongoDB</topic> +<title>What time is it where?</title> +<event>MongoDB MUG #7</event> +<location>London, UK</location> +<lat>51.52348</lat><lon>-0.08350</lon> +<date>September 11th, 2013</date> +<speaker>Derick Rethans</speaker> +<email>derick@mongodb.com</email> +<twitter>derickr</twitter> +<joindin>http://derickrethans.nl/talks/mongo-tz-mug13</joindin> + +<slide>slides/mongodb/title.xml</slide> +<slide>slides/time/worldclock.xml</slide> +<slide>slides/time/problems-condensed.xml</slide> +<slide>slides/time/timezone-map.xml</slide> +<slide>slides/time/improvements-timezones.xml</slide> +<slide>slides/time/location-to-tzid.xml</slide> + +<slide>slides/mongodb/location-to-tzid-method.xml</slide> +<slide>slides/mongodb/tzid-shapefiles.xml</slide> +<slide>slides/mongodb/tzid-convert-shapefiles.xml</slide> +<slide>slides/mongodb/tzid-convert-osm-file.xml</slide> +<slide>slides/mongodb/tzid-import-osm-file.xml</slide> + +<slide>slides/mongodb/tzid-match.xml</slide> +<slide>slides/mongodb/tzid-match-same-tzid.xml</slide> + +<slide>slides/mongodb/tzid-simplify1.xml</slide> +<slide>slides/mongodb/tzid-simplify2.xml</slide> +<slide>slides/mongodb/tzid-simplify3.xml</slide> +<slide>slides/mongodb/tzid-simplify4.xml</slide> + +<slide>slides/mongodb/tzid-nautical-border.xml</slide> +<slide>slides/mongodb/tzid-nautical-border2.xml</slide> +<slide>slides/mongodb/tzid-nautical-border-ca-us.xml</slide> + +<slide>slides/mongodb/tzid-fallback.xml</slide> +<slide>slides/mongodb/tzid-nautical-what-it-is.xml</slide> +<slide>slides/mongodb/tzid-left-to-do.xml</slide> + +<slide>slides/mongodb/questions.xml</slide> + +<slide>slides/mongodb/resources.xml</slide> + +</presentation> diff --git a/slides/mongodb/all-zones.png b/slides/mongodb/all-zones.png new file mode 100644 index 0000000..75fe1c0 Binary files /dev/null and b/slides/mongodb/all-zones.png differ diff --git a/slides/mongodb/josm-tzshapefile2.png b/slides/mongodb/josm-tzshapefile2.png new file mode 100644 index 0000000..543eba6 Binary files /dev/null and b/slides/mongodb/josm-tzshapefile2.png differ diff --git a/slides/mongodb/location-to-tzid-method.xml b/slides/mongodb/location-to-tzid-method.xml new file mode 100644 index 0000000..8495842 --- /dev/null +++ b/slides/mongodb/location-to-tzid-method.xml @@ -0,0 +1,10 @@ +<slide> +<title>Approach</title> + +<list> + <bullet>Find shape files defining the Timezone Identifier boundaries</bullet> + <bullet>Convert shape files to GeoJSON</bullet> + <bullet>Import GeoJSON files into MongoDB</bullet> + <bullet>Match!</bullet> +</list> +</slide> diff --git a/slides/mongodb/resources.xml b/slides/mongodb/resources.xml index 1b86f88..3fd20cf 100644 --- a/slides/mongodb/resources.xml +++ b/slides/mongodb/resources.xml @@ -2,6 +2,6 @@ <break/> <qrcode>http://derickrethans.nl/talks/:-:talk_id:-:</qrcode> <break/> -<blurb class="pres-url-small">:-:joindin:-:</blurb> -<blurb class="pres-url-small">:-:email:-:—@:-:twitter:-:</blurb> +<blurb align="center" class="pres-url-small">:-:joindin:-:</blurb> +<blurb align="center" class="pres-url-small">:-:email:-:—@:-:twitter:-:</blurb> </slide> diff --git a/slides/mongodb/simplify1.png b/slides/mongodb/simplify1.png new file mode 100644 index 0000000..ee8652d Binary files /dev/null and b/slides/mongodb/simplify1.png differ diff --git a/slides/mongodb/simplify2.png b/slides/mongodb/simplify2.png new file mode 100644 index 0000000..1cd0c16 Binary files /dev/null and b/slides/mongodb/simplify2.png differ diff --git a/slides/mongodb/simplify3.png b/slides/mongodb/simplify3.png new file mode 100644 index 0000000..8c57f29 Binary files /dev/null and b/slides/mongodb/simplify3.png differ diff --git a/slides/mongodb/simplify4.png b/slides/mongodb/simplify4.png new file mode 100644 index 0000000..ba6dab5 Binary files /dev/null and b/slides/mongodb/simplify4.png differ diff --git a/slides/mongodb/tzid-convert-osm-file.xml b/slides/mongodb/tzid-convert-osm-file.xml new file mode 100644 index 0000000..d8380d1 --- /dev/null +++ b/slides/mongodb/tzid-convert-osm-file.xml @@ -0,0 +1,32 @@ +<slide> +<title>After saving...</title> + +<example><![CDATA[ +<?xml version='1.0' encoding='UTF-8'?> +<osm version='0.6' upload='false' generator='JOSM'> + <node id='-1754895' visible='true' lat='11.843674659729004' lon='-71.322021484375' /> + <node id='-1754894' visible='true' lat='11.844100952148438' lon='-71.31991577148438' /> + … + <node id='-8' visible='true' lat='15.542881011962892' lon='-61.29474258422852' /> + <way id='-1751536' visible='true'> + <nd ref='-774459' /> + … + <nd ref='-131' /> + </way> + <way id='-7' visible='true'> + <nd ref='-8' /> + … + <nd ref='-8' /> + <tag k='TZID' v='America/Dominica' /> + </way> + … + <relation id='-129' visible='true'> + <member type='way' ref='-130' role='outer' /> + <member type='way' ref='-137' role='outer' /> + … + <member type='way' ref='-283' role='outer' /> + <tag k='TZID' v='America/St_Vincent' /> + <tag k='type' v='multipolygon' /> + </relation> +</osm>]]></example> +</slide> diff --git a/slides/mongodb/tzid-convert-shapefiles.xml b/slides/mongodb/tzid-convert-shapefiles.xml new file mode 100644 index 0000000..85ecc8c --- /dev/null +++ b/slides/mongodb/tzid-convert-shapefiles.xml @@ -0,0 +1,15 @@ +<slide> +<title>Converting shapefiles</title> + +<image filename="josm-tzshapefile2.png" align="right"/> +<list> + <bullet>We need to import them into MongoDB</bullet> + <bullet>I have already written an OpenStreetMap to MongoDB importer</bullet> + <bullet>The OpenStreetMap editor JOSM can convert shapefiles: + <example> +wget http://efele.net/maps/tz/world/tz_world_mp.zip +unzip tz_world_mp.zip +josm world/tz_world_mp.shp</example> + </bullet> +</list> +</slide> diff --git a/slides/mongodb/tzid-fallback.xml b/slides/mongodb/tzid-fallback.xml new file mode 100644 index 0000000..c0705dc --- /dev/null +++ b/slides/mongodb/tzid-fallback.xml @@ -0,0 +1,10 @@ +<slide> +<title>Nautical Time</title> + +<blurb>Three different cases:</blurb> +<list> + <bullet>The location is within a land-polygon</bullet> + <bullet>The location is within 22km from a land-polygon</bullet> + <bullet>All others: Nautical time</bullet> +</list> +</slide> diff --git a/slides/mongodb/tzid-import-osm-file.xml b/slides/mongodb/tzid-import-osm-file.xml new file mode 100644 index 0000000..eb28cf8 --- /dev/null +++ b/slides/mongodb/tzid-import-osm-file.xml @@ -0,0 +1,27 @@ +<slide> +<title>Importing the OSM file</title> + +<blurb>Article describing imports:<br/>http://drck.me/mongosm-a7u</blurb> +<example>> db.timezone.stats(1024); +{ + "ns" : "demo.timezone", + "count" : 408, + "size" : 69841, + "avgObjSize" : 171.17892156862746, + "storageSize" : 142736, + "numExtents" : 9, + "nindexes" : 4, + "lastExtentSize" : 41340, + "paddingFactor" : 1, + "systemFlags" : 1, + "userFlags" : 0, + "totalIndexSize" : 2427, + "indexSizes" : { + "_id_" : 23, + "ty_1" : 23, + "l_2dsphere" : 2331, + "ts_1" : 47 + }, + "ok" : 1 +}</example> +</slide> diff --git a/slides/mongodb/tzid-left-to-do.xml b/slides/mongodb/tzid-left-to-do.xml new file mode 100644 index 0000000..52530a7 --- /dev/null +++ b/slides/mongodb/tzid-left-to-do.xml @@ -0,0 +1,11 @@ +<slide> +<title>What's next?</title> + +<image align="center" filename="all-zones.png"/> + +<list> + <bullet>Create shape files that include territorial waters</bullet> + <bullet>Improve simplification algorithm/implementation</bullet> +</list> + +</slide> diff --git a/slides/mongodb/tzid-match-same-tzid.xml b/slides/mongodb/tzid-match-same-tzid.xml new file mode 100644 index 0000000..5ca121c --- /dev/null +++ b/slides/mongodb/tzid-match-same-tzid.xml @@ -0,0 +1,9 @@ +<slide> +<title>Finding the TZID at a location</title> + +<blurb>All others with the same TZID:</blurb> +<example>db.timezone.find( { ts: "TZID=Europe/London" } );</example> + +<break lines="4"/> +<image filename="uk-highres.png"/> +</slide> diff --git a/slides/mongodb/tzid-match.xml b/slides/mongodb/tzid-match.xml new file mode 100644 index 0000000..58fd5af --- /dev/null +++ b/slides/mongodb/tzid-match.xml @@ -0,0 +1,26 @@ +<slide> +<title>Finding the TZID at a location</title> + +<blurb>Under the "cursor":</blurb> +<example>db.timezone.findOne( { + l: { + '$geoIntersects' : { + '$geometry' : { + type: 'Point', + coordinates: [ -0.08237, 51.52336 ] + } + } + } +}, { ts: 1 } );</example> + +<blurb>Result:</blurb> +<example> +{ + "_id" : "r-1403284", + "ts" : [ + "TZID=Europe/London", + "type=multipolygon" + ] +} +</example> +</slide> diff --git a/slides/mongodb/tzid-matched-show.xml b/slides/mongodb/tzid-matched-show.xml new file mode 100644 index 0000000..8221884 --- /dev/null +++ b/slides/mongodb/tzid-matched-show.xml @@ -0,0 +1,5 @@ +<slide> +<title>Finding the TZID at a location</title> + +<image filename="uk-highres.png"/> +</slide> diff --git a/slides/mongodb/tzid-nautical-border-ca-us.xml b/slides/mongodb/tzid-nautical-border-ca-us.xml new file mode 100644 index 0000000..4d094b8 --- /dev/null +++ b/slides/mongodb/tzid-nautical-border-ca-us.xml @@ -0,0 +1,7 @@ +<slide> +<title>Territorial Waters</title> + +<blurb>It does not always work...</blurb> + +<image filename="us-ca-nautical.png" align="center"/> +</slide> diff --git a/slides/mongodb/tzid-nautical-border.xml b/slides/mongodb/tzid-nautical-border.xml new file mode 100644 index 0000000..8b4e079 --- /dev/null +++ b/slides/mongodb/tzid-nautical-border.xml @@ -0,0 +1,11 @@ +<slide> +<title>Territorial waters</title> + +<list> + <bullet>Share the same timezone as the zone they belong to</bullet> + <bullet>Extend up to 22km from the coast</bullet> +</list> + +<break lines="2"/> +<image filename="uk-nautical.png" align="center"/> +</slide> diff --git a/slides/mongodb/tzid-nautical-border2.xml b/slides/mongodb/tzid-nautical-border2.xml new file mode 100644 index 0000000..6e5234f --- /dev/null +++ b/slides/mongodb/tzid-nautical-border2.xml @@ -0,0 +1,32 @@ +<slide> +<title>Territorial waters</title> + +<example> +db.timezone.aggregate( [ + { "$geoNear": { + near: { type: "Point", coordinates: [ 1.0375, 51.5809 ] }, + distanceField: "d", + distanceMultiplier: 1, + maxDistance: 22000, + spherical: true, + query: { "ty" : { $gte: 2 } }, + limit: 4 + } } +] ); +</example> + +<example>{ + "result" : [ + { + "_id" : "r-1403284", + "ty" : NumberLong(3), + "ts" : [ + "TZID=Europe/London", + "type=multipolygon" + ], + "l" : { … } + } + ] +} +</example> +</slide> diff --git a/slides/mongodb/tzid-nautical-what-it-is.xml b/slides/mongodb/tzid-nautical-what-it-is.xml new file mode 100644 index 0000000..08ec48d --- /dev/null +++ b/slides/mongodb/tzid-nautical-what-it-is.xml @@ -0,0 +1,11 @@ +<slide> +<title>Nautical Time</title> + +<list> + <bullet>Timezones from before timezones where invented</bullet> + <bullet>Simply divides the Earth into 24 zones</bullet> + <bullet>15° apart</bullet> +</list> +<break lines="2"/> +<image filename="zone-utc.png" align="center"/> +</slide> diff --git a/slides/mongodb/tzid-shapefiles.xml b/slides/mongodb/tzid-shapefiles.xml new file mode 100644 index 0000000..d4e8202 --- /dev/null +++ b/slides/mongodb/tzid-shapefiles.xml @@ -0,0 +1,9 @@ +<slide> +<title>Shapefiles</title> + +<list> + <bullet>Eric Muller provides shape files at:<br/>http://efele.net/maps/tz/world/</bullet> + <bullet>For each Timezone Identifier there are one or more polygons</bullet> + <bullet>Polygons can have holes in them</bullet> +</list> +</slide> diff --git a/slides/mongodb/tzid-simplify.xml b/slides/mongodb/tzid-simplify.xml new file mode 100644 index 0000000..d0a26c8 --- /dev/null +++ b/slides/mongodb/tzid-simplify.xml @@ -0,0 +1,15 @@ +<slide> +<title>Simplify ways</title> + +<image align="right" filename="simplify1.png"/> + +<list> + <bullet>Lots of points take a lot of rendering time</bullet> + <bullet>Simplifying ways to reduce rendering time</bullet> + <bullet>Ramer–Douglas–Peucker algorithm</bullet> + <bullet>Takes up time to run...</bullet> + <bullet>Part of MongoDB?</bullet> + <bullet>Store alternative polygons for rendering?</bullet> +</list> + +</slide> diff --git a/slides/mongodb/tzid-simplify1.xml b/slides/mongodb/tzid-simplify1.xml new file mode 100644 index 0000000..6c9361a --- /dev/null +++ b/slides/mongodb/tzid-simplify1.xml @@ -0,0 +1,10 @@ +<slide> +<title>Simplify ways</title> + +<image align="right" filename="simplify1.png"/> + +<list> + <bullet>Lots of points take a lot of rendering time</bullet> +</list> + +</slide> diff --git a/slides/mongodb/tzid-simplify2.xml b/slides/mongodb/tzid-simplify2.xml new file mode 100644 index 0000000..cdb430c --- /dev/null +++ b/slides/mongodb/tzid-simplify2.xml @@ -0,0 +1,12 @@ +<slide> +<title>Simplify ways</title> + +<image align="right" filename="simplify2.png"/> + +<list> + <bullet>Lots of points take a lot of rendering time</bullet> + <bullet>Simplifying ways to reduce rendering time</bullet> + <bullet>Ramer–Douglas–Peucker algorithm</bullet> +</list> + +</slide> diff --git a/slides/mongodb/tzid-simplify3.xml b/slides/mongodb/tzid-simplify3.xml new file mode 100644 index 0000000..5b55f50 --- /dev/null +++ b/slides/mongodb/tzid-simplify3.xml @@ -0,0 +1,12 @@ +<slide> +<title>Simplify ways</title> + +<image align="right" filename="simplify3.png"/> + +<list> + <bullet>Lots of points take a lot of rendering time</bullet> + <bullet>Simplifying ways to reduce rendering time</bullet> + <bullet>Ramer–Douglas–Peucker algorithm</bullet> +</list> + +</slide> diff --git a/slides/mongodb/tzid-simplify4.xml b/slides/mongodb/tzid-simplify4.xml new file mode 100644 index 0000000..ec99146 --- /dev/null +++ b/slides/mongodb/tzid-simplify4.xml @@ -0,0 +1,15 @@ +<slide> +<title>Simplify ways</title> + +<image align="right" filename="simplify4.png"/> + +<list> + <bullet>Lots of points take a lot of rendering time</bullet> + <bullet>Simplifying ways to reduce rendering time</bullet> + <bullet>Ramer–Douglas–Peucker algorithm</bullet> + <bullet>Takes up time to run...</bullet> + <bullet>Part of MongoDB?</bullet> + <bullet>Store alternative polygons for rendering?</bullet> +</list> + +</slide> diff --git a/slides/mongodb/uk-highres.png b/slides/mongodb/uk-highres.png new file mode 100644 index 0000000..214023d Binary files /dev/null and b/slides/mongodb/uk-highres.png differ diff --git a/slides/mongodb/uk-nautical.png b/slides/mongodb/uk-nautical.png new file mode 100644 index 0000000..c5d9cae Binary files /dev/null and b/slides/mongodb/uk-nautical.png differ diff --git a/slides/mongodb/us-ca-nautical.png b/slides/mongodb/us-ca-nautical.png new file mode 100644 index 0000000..ff0cfa6 Binary files /dev/null and b/slides/mongodb/us-ca-nautical.png differ diff --git a/slides/mongodb/zone-utc.png b/slides/mongodb/zone-utc.png new file mode 100644 index 0000000..6871bea Binary files /dev/null and b/slides/mongodb/zone-utc.png differ diff --git a/slides/time/improvements-timezones.xml b/slides/time/improvements-timezones.xml index 4366fd3..56be555 100644 --- a/slides/time/improvements-timezones.xml +++ b/slides/time/improvements-timezones.xml @@ -3,9 +3,9 @@ <title>Timezone Support</title> <list> - <bullet>Bundled timezone database with more than 500 zones</bullet> - <bullet>Not dependent on timezone abbreviations</bullet> - <bullet>Timezones have the format: Continent/Location or Continent/Location/Sublocation - Like: Europe/Amsterdam, America/Indiana/Knox</bullet> + <bullet>There are more than 500 zones</bullet> + <bullet>Do not dependend on timezone abbreviations</bullet> + <bullet>Use timezone IDs like %Europe/Amsterdam% or %America/Indiana/Knox%</bullet> </list> <image align="center" filename="zone-places.png" y-offset="6"/> diff --git a/slides/time/location-to-tzid.xml b/slides/time/location-to-tzid.xml new file mode 100644 index 0000000..0eca540 --- /dev/null +++ b/slides/time/location-to-tzid.xml @@ -0,0 +1,3 @@ +<slide type="section"> +<blurb class="quote">How to get to local time?</blurb> +</slide> diff --git a/slides/time/timezone-map.xml b/slides/time/timezone-map.xml new file mode 100644 index 0000000..552bd61 --- /dev/null +++ b/slides/time/timezone-map.xml @@ -0,0 +1,5 @@ +<slide> +<title>Map</title> + +<iframe width="1000" filename='http://127.0.1.4/?l=timezones&zoom=3;&lat=:-:lat:-:&lon=:-:lon:-:'/> +</slide> diff --git a/slides/time/worldclock.jpg b/slides/time/worldclock.jpg new file mode 100644 index 0000000..b76d3e2 Binary files /dev/null and b/slides/time/worldclock.jpg differ diff --git a/slides/time/worldclock.xml b/slides/time/worldclock.xml new file mode 100644 index 0000000..cfb055b --- /dev/null +++ b/slides/time/worldclock.xml @@ -0,0 +1,5 @@ +<slide> +<title>What time is it where?</title> + +<image filename="worldclock.jpg" attr="CC-by: http://www.flickr.com/photos/skippy/"/> +</slide>