21
IBM Cloud Data Services open crime data making pokémon go a safer space Raj Singh, PhD Developer Advocate: Geo | Open Data [email protected] http://ibm.biz/ rajrsingh twitter: @rajrsingh

Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

Embed Size (px)

Citation preview

Page 1: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

IBM Cloud Data Services

open crime datamaking pokémon go a safer spaceRaj Singh, PhDDeveloper Advocate: Geo | Open [email protected]://ibm.biz/rajrsingh twitter: @rajrsingh

Page 2: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

Read my newsletter on open data!http://opendatamag.rajsingh.org

Some background

Developer Advocate, Geo + open dataIBM Analytics

MCP, Ph.D.Urban Studies & Planning

Page 3: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

Agenda

• Finding and harvesting open crime data• Data wrangling & schema reconciliation• Products

• data service• safety app

Page 4: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

Architecture

Page 5: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

Harvesting CrimeData

Page 6: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

Open data is on the rise

open data?

Technology maturity curve

Page 7: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

Where to find data

https://data.cityofboston.gov/Public-Safety/Crime-Incident-Reports-August-2015-To-Date-Source-/fqn4-4qap

Page 8: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

The Socrata API

Page 9: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

DataWrangling

Gaucho Data Wrangler. Picture by Dave Werkley, http://compendiumofcountries.org/wiki/index.php?title=File:Data_Wrangler_-_Gaucho.png

Page 10: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

Data wrangling crime codes

Page 11: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

Querying Socrata for Boston Crimes

• https://data.cityofboston.gov/resource/29yf-ye7n.json?

$where=occurred_on_date>=“2016-08-23”

AND occurred_on_date<“2016-08-24”

• Then run it every day…

Page 12: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

Boston crime data query response

Page 13: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

Crime reconciliation

• CDSNV: non-violent• CDSDV: domestic

violence• CDSSTREET: street

crime

Page 14: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

DataProducts & Offerings

By Patrick Denker from Athens, GA - DSC04878, CC BY 2.0, https://commons.wikimedia.org/w/index.php?curid=37301184

Page 15: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

REST API & Mapping

Page 16: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

Cloudant / CouchDB replication

Page 17: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

Then this happened…

Page 18: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

The danger zone

Page 19: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

Safety app architecture

1.Built using Ionic framework

2.Cloudant -> mobile replication

3.Safety rating decision

4.Notification

https://github.com/ibm-cds-labs/crionic | by Jason Smith

Page 20: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

@rajrsinghIBM Cloud Data Services

Safety app phase 2

• Add Census demographics• Population: crimes per capita• Housing quality

• Add Points of Interest• Commercial activity: busy areas are safer

Page 21: Safety-enabled apps: using Boston crime data to make Pokemon Go a safer space

IBM Cloud Data Services

Raj SinghDeveloper Advocate: Geo | Open [email protected] http://ibm.biz/rajrsingh

Twitter: @rajrsinghLinkedIn: rajrsingh

Thanks• REST API

• http://ibm.biz/opencrimes

• Crime code reconciliation tables• https://github.com/ibm-cds-labs/open-data/tree/master/crime

• Harvesting service code• https://github.com/ibm-cds-labs/crimeharvest

• IBM Cloud Data Services on GitHub• https://ibm-cds-labs.github.io/

• IBM Cloud Data Services on Bluemix• http://www.ibm.com/cloud-computing/bluemix/solutions/data-analytics/