Download - Viva city open smart city platform
VivaCity 2.0 Open Data Smart City Pla6orm
Marco Montanari
HI, I’M MARCO
@ingmmo [email protected] marco.montanari or sirmmo on facebook, slideshare, … hDp://ingmmo.com hDp://www.mmo.it hDps://github.com/sirmmo
HI, I’M MARCO
We <3 open data!!!
-‐ Almost everyone
Oh Open Data are so cool … • Lots of data collecPons (281*) • Lots of data sources • Growing movement (*) • More and more ciPes and regions
are giving out datasets
• Lots of geographic datasets • Lots of geologic datasets • Lots of public transportaPon
datasets * As of today (20.09.12), on census.okfn.org
… But There’s a catch
… But There’s a catch
NYC Parks (shp) ORGANIZATI STATUS TYPE GISPROPNUM OMPPROPID LOCATION JURISDICTI WATERFRONT MAPPED SIGNNAME BOROUGH Precinct
ACRES
Chicago Parks (csv) PARK NUMBER PARK NAME STREET ADDRESS ZIP ACRES WARD PARK CLASS LABEL WHEELCHAIR ACCESSIBLE BALL FIELDS ALFRED CALDWELL LILY POND ARCHERY RANGE ARTIFICIAL TURF FIELDS BAND SHELL BASEBALL BATTING CAGES BASKETBALL BACKBOARDS BASKETBALL COURTS BEACH BOAT LAUNCH (MOTORIZED) BOAT LAUNCH (NON-‐
MOTORIZED) BOAT SLIPS BOCCE COURT BOWLING GREEN CASTING AREA CHESS PAVILLION FOOTBALL SOCCER COMBO COMMUNITY GARDEN CONSERVATORY CULTURAL CENTER DOG-‐FRIENDLY FITNESS CENTER FITNESS COURSES GALLERY GARDEN GOLF COURSE GOLF DRIVING RANGE GOLF PUTTING GREENS GYMNASIUM GYMNASTIC CENTERS HANDBALL/RAQUETBALL COURT HANDBALL
HORSESHOE COURTS ICE SKATING POOL INDOOR BASEBALL JR/SOFTBALL/T-‐BALL MOUNTAIN BIKE TRAIL NATURE CENTER,POOL OUTDOOR PAVILLION ZOO PLAYGROUND PLAYGROUND PARK ROWING CLUB VOLLEYBALL SENIOR CENTER SHUFFLEBOARD SKATE PARK SLED HILL SPORT ROLLER COURTS SPRAY FEATURE BASEBALL SR TENNIS COURTS TRACK
VOLLEYBALL SAND WATER PLAYGROUND WATER SLIDE BOXING CENTER WETLAND AREA LAGOON CAROUSEL CROQUET GOLF COURSE MINIATURE MODEL TRAIN DISPLAY MODEL YACHT BASIN CRICKET FIELD LOCATION
Bologna Parks (shp) COD_UG NOME
… But There’s a (bunch of) catch(es)
NYC Parks (shp) ORGANIZATI STATUS TYPE GISPROPNUM OMPPROPID LOCATION JURISDICTI WATERFRONT MAPPED SIGNNAME BOROUGH Precinct
ACRES AREAS
Chicago Parks (csv) PARK NUMBER PARK NAME STREET ADDRESS ZIP ACRES WARD PARK CLASS LABEL WHEELCHAIR ACCESSIBLE BALL FIELDS ALFRED CALDWELL LILY POND ARCHERY RANGE ARTIFICIAL TURF FIELDS BAND SHELL BASEBALL BATTING CAGES BASKETBALL BACKBOARDS BASKETBALL COURTS BEACH BOAT LAUNCH (MOTORIZED) BOAT LAUNCH (NON-‐
MOTORIZED) BOAT SLIPS BOCCE COURT BOWLING GREEN CASTING AREA CHESS PAVILLION FOOTBALL SOCCER COMBO COMMUNITY GARDEN CONSERVATORY CULTURAL CENTER DOG-‐FRIENDLY FITNESS CENTER FITNESS COURSES GALLERY GARDEN GOLF COURSE GOLF DRIVING RANGE GOLF PUTTING GREENS GYMNASIUM GYMNASTIC CENTERS HANDBALL/RAQUETBALL COURT HANDBALL
HORSESHOE COURTS ICE SKATING POOL INDOOR BASEBALL JR/SOFTBALL/T-‐BALL MOUNTAIN BIKE TRAIL NATURE CENTER,POOL OUTDOOR PAVILLION ZOO PLAYGROUND PLAYGROUND PARK ROWING CLUB VOLLEYBALL SENIOR CENTER SHUFFLEBOARD SKATE PARK SLED HILL SPORT ROLLER COURTS SPRAY FEATURE BASEBALL SR TENNIS COURTS TRACK
VOLLEYBALL SAND WATER PLAYGROUND WATER SLIDE BOXING CENTER WETLAND AREA LAGOON CAROUSEL CROQUET GOLF COURSE MINIATURE MODEL TRAIN DISPLAY MODEL YACHT BASIN CRICKET FIELD LOCATION POINTS
Bologna Parks (shp) COD_UG NOME AREAS
It’s all about semanPcs
• Adding semanPcs to SHP (dbf), CSV – Easy but elaborate
• Adding a normalizaPon process to the CSV – Quite easy but quite elaborate
• We could define a meta-‐semanPc model…
It’s all about dimensions
Time • Date • Timestamp • Reference Period
Topic • PoliPcs • Finance • Social issues
Space • Coordinates • Areas • Regions and sub-‐regions
It’s all about dimensions
Time • Date • Timestamp • Reference Period
Topic • PoliPcs • Finance • Social issues
Space • Coordinates • Areas • Regions and sub-‐regions
It’s all about dimensions
Time • Date • Timestamp • Reference Period
Topic • PoliPcs • Finance • Social issues
Space • Coordinates • Areas • Regions and sub-‐regions
It’s all about dimensions
Time • Date • Timestamp • Reference Period
Topic • PoliPcs • Finance • Social issues
Space • Coordinates • Areas • Regions and sub-‐regions
It’s all about ontologies
• Lots of ontologies explainig the most various topics – DMTF è CIM ontology (useless? Why?) – INSPIRE – Dublin Core – Foaf – …
• Do we need more? – Sure! But projects are already ongoing (and if there is no standard, we can always try to become a de-‐facto standard)
But in the end it’s all about visualizing the data…
• Who likes a table? (besides developers)
…and puong it into context (generate informaPon)…
…and puong it into context (generate informaPon)…
…and puong it into context (generate informaPon)…
… and elaborate
• MDX queries and aggregaPons based on the various dimensions defined by the topic-‐based ontologies
• SPARQL queries to harness the graph-‐structure of the backend • SQL queries to enable access to table-‐like front-‐ends • WFS queries to enable access to GIS tools
VivaCity Park_name Ball fields Borough City Geometry
Margherita 3 Murri Bologna …
Montagnola 0 Porto Bologna …
Borough Phone Manager City Geometry
Murri +39051000000 Mario Rossi Bologna …
Porto +39051000001 Luigi Neri Bologna …
VivaCity PARK
TREE
SPECIES
SERVICE
PLAY FIELD
BALL FIELD
BASKET FIELD
MGMT
PHONE NUMBER
VivaCity Park_name Ball fields Borough City Geometry
Margherita 3 Murri Bologna …
Montagnola 0 Porto Bologna …
Borough Phone Manager City Geometry
Murri +39051000000 Mario Rossi Bologna …
Porto +39051000001 Luigi Neri Bologna …
PARK
TREE
SPECIES
SERVICE
PLAY FIELD
BALL FIELD
BASKET FIELD
MGMT
PHONE NUMBER
The semanPc is given to any meta-‐descripPon of a
dataset
At every change a new semanPc has
to be given
ETL is complex in many forms
Can be from filed
and APIs
Versioned
VivaCity
Ontology SemanPcs Raw Data VivaCity
VivaCity
• Not just a front end • Not just an uniforming tool
• A way to understand and help interprePng the data exposed as Open Data
• A pla6orm for the city to evolve from data producer to data integrator
The stack
VivaCity 1.0 • Openlayers 2
– Geojson where possible
• Django – Data manager – Exposed basic WFS
• Postgresql (PostGIS) – Neo4j was young and needed more evoluPon – Mongodb supported only points, had only
superficial support of queries – PostGIS is THE best for many cases – Not for graphs…
VivaCity 2.0 • Leaflet (with plugins) [maybe OL3.js soon]
– GeoJSON, TopoJSON where possible
• Django – With the role of data manager – Exposes the “data” APIs
• Fyzz for sparql interpretaPon • MDXParse (developed for this project) for MDX
interpretaPon • SQLParse for SQL interpretaPon
– Exposes the OGC APIs – Celery to manage the import of data
• Mongodb + Neo4j spaPal – Mongo for basic document queries and a document centric
approach – Neo4j for complex relaPonal queries and a relaPonship-‐
centric approach
It’s Open Source
Or beDer, it will be soon (end november)
Right now there is version 1.0 on github (for last year’s never-‐made FOSS4G12) -‐ hDps://github.com/ciPzennerd/VivaCity
IT’S A PROTOTYPE!!!
Thanks!
[email protected] , @ingmmo, ingmmo.com, hDps://github.com/sirmmo,