SlideShare a Scribd company logo
USING DOCKER FOR DATA 
SCIENCE
WHY DOCKER 
Portable environment 
Isolated between projects 
Stateless 
Fast local file access 
Hetrogenous
GET DOCKER 
https://docs.docker.com/installation/ 
boot2docker .dmg or .exe 
apt-get install docker.io ...
RUN SCIPYSERVER 
$ docker run -d -e "PASSWORD=YourPassword?" ipython/scipyserver 
$ docker run  
-d  
-e "PASSWORD=YourPassword?"  
--name dev_notebook  
-p 443:8888  
ipython/scipyserver 
https://localhost:443 
https://{boot2docker ip}:443
CREATE DATA-ONLY CONTAINERS 
$ docker run  
-d  
-v ~/notebooks:/notebooks  
--name notebooks_container  
ubuntu 
echo notebooks 
$ docker run -d -v ~/data:/data --name data_container ubuntu echo data
MOUNT DATA-ONLY CONTAINERS 
$ docker stop dev_notebook 
$ docker rm dev_notebook 
$ docker run  
-d  
-e "PASSWORD=YourPassword?"  
--name dev_notebook  
-p 443:8888  
--volumes-from data_container  
--volumes-from notebooks_container  
ipython/scipyserver
CREATE A DOCKERFILE 
FROM ipython/scipyserver 
MAINTAINER Calvin Giles <calvin.giles@gmail.com> 
COPY requirements.txt /requirements.txt 
RUN pip2 install -r /requirements.txt 
RUN pip3 install -r /requirements.txt 
$ docker build  
-t calvingiles/ds-notebook  
. 
$ docker run  
-d  
-e "PASSWORD=YourPassword?"  
--name dev_notebook  
-p 443:8888  
--volumes-from data_container  
--volumes-from notebooks_container  
calvingiles/ds-notebook
NEXT TIME 
Connecting to local database containers 
Tweaking the boot2docker vm memory from 2GB to 8 (or 
more...) 
Linking to private git repositories 
Automated builds with github linking
MORE? 
Docker User Guide: 
http://docs.docker.com/userguide/ 
Docker Reference: 
http://docs.docker.com/reference/commandline/cli/ 
ipython docker images: 
https://registry.hub.docker.com/repos/ipython/ 
my docker image: 
https://github.com/calvingiles/ds-notebook 
https://registry.hub.docker.com/u/calvingiles/ds-notebook/
ABOUT ME 
Calvin Giles 
Data Scientist at Adthena 
PyData Meetup Organiser 
untangleconsulting.io 
calvin.giles@gmail.com 
@calvingiles on twitter, github, docker hub (and many more)

More Related Content

What's hot (18)

PDF
Shared Object images in Docker: What you need is what you want.
Workhorse Computing
ย 
PPTX
2009 cluster user training
Chris Dwan
ย 
DOCX
Hadoop installation
habeebulla g
ย 
PDF
Drupal Camp Brighton 2015: Ansible Drupal Medicine show
George Boobyer
ย 
PDF
Ops for everyone - John Britton
Devopsdays
ย 
PDF
rake puppetexpert:create - Puppet Camp Silicon Valley 2014
nvpuppet
ย 
PPTX
Drupal from scratch
Rovic Honrado
ย 
PDF
Medicine show2 Drupal Bristol Camp 2015
George Boobyer
ย 
PDF
JDD 2017: Nginx + Lua = OpenResty (Marcin Stoลผek)
PROIDEA
ย 
PDF
Ansible - Swiss Army Knife Orchestration
bcoca
ย 
PDF
Ansible, Simplicity, and the Zen of Python
toddmowen
ย 
PDF
Top Node.js Metrics to Watch
Sematext Group, Inc.
ย 
PDF
PuppetCamp SEA 1 - Use of Puppet
Walter Heck
ย 
PDF
The Puppet Debugging Kit: Building Blocks for Exploration and Problem Solving...
Puppet
ย 
PDF
Puppet Camp Phoenix 2015: Managing Files via Puppet: Let Me Count The Ways (B...
Puppet
ย 
PDF
Docker & FieldAware
Jakub Jarosz
ย 
PDF
Configuration surgery with Augeas (OggCamp 12)
Dominic Cleal
ย 
PDF
AnsibleFest 2014 - Role Tips and Tricks
jimi-c
ย 
Shared Object images in Docker: What you need is what you want.
Workhorse Computing
ย 
2009 cluster user training
Chris Dwan
ย 
Hadoop installation
habeebulla g
ย 
Drupal Camp Brighton 2015: Ansible Drupal Medicine show
George Boobyer
ย 
Ops for everyone - John Britton
Devopsdays
ย 
rake puppetexpert:create - Puppet Camp Silicon Valley 2014
nvpuppet
ย 
Drupal from scratch
Rovic Honrado
ย 
Medicine show2 Drupal Bristol Camp 2015
George Boobyer
ย 
JDD 2017: Nginx + Lua = OpenResty (Marcin Stoลผek)
PROIDEA
ย 
Ansible - Swiss Army Knife Orchestration
bcoca
ย 
Ansible, Simplicity, and the Zen of Python
toddmowen
ย 
Top Node.js Metrics to Watch
Sematext Group, Inc.
ย 
PuppetCamp SEA 1 - Use of Puppet
Walter Heck
ย 
The Puppet Debugging Kit: Building Blocks for Exploration and Problem Solving...
Puppet
ย 
Puppet Camp Phoenix 2015: Managing Files via Puppet: Let Me Count The Ways (B...
Puppet
ย 
Docker & FieldAware
Jakub Jarosz
ย 
Configuration surgery with Augeas (OggCamp 12)
Dominic Cleal
ย 
AnsibleFest 2014 - Role Tips and Tricks
jimi-c
ย 

Viewers also liked (8)

PDF
Using docker for data science - part 2
Calvin Giles
ย 
PPTX
Using Docker for GPU Accelerated Applications
NVIDIA
ย 
PDF
Using Docker Containers to Improve Reproducibility in Software and Web Engine...
Vincenzo Ferme
ย 
PDF
Deploying Data Science with Docker and AWS
Matt McDonnell
ย 
PDF
Running Docker clusters on AWS (November 2016)
Julien SIMON
ย 
PDF
Deep Learning with AWS (November 2016)
Julien SIMON
ย 
PPT
Reproducible bioinformatics pipelines with Docker and Anduril
Christian Frech
ย 
PDF
Agile deployment predictive analytics on hadoop
DataWorks Summit
ย 
Using docker for data science - part 2
Calvin Giles
ย 
Using Docker for GPU Accelerated Applications
NVIDIA
ย 
Using Docker Containers to Improve Reproducibility in Software and Web Engine...
Vincenzo Ferme
ย 
Deploying Data Science with Docker and AWS
Matt McDonnell
ย 
Running Docker clusters on AWS (November 2016)
Julien SIMON
ย 
Deep Learning with AWS (November 2016)
Julien SIMON
ย 
Reproducible bioinformatics pipelines with Docker and Anduril
Christian Frech
ย 
Agile deployment predictive analytics on hadoop
DataWorks Summit
ย 
Ad

Similar to Using python and docker for data science (6)

PDF
Supercharge ml using docker
Sho Fola Soboyejo
ย 
PDF
Docker Containers- Data Engineers' Arsenal.pdf
gr6336192
ย 
PPTX
Docker training
Kiran Kumar
ย 
PDF
ieee cloud 2015 keynote talk
Microsoft Azure for Research
ย 
PDF
Data Science Workflows using Docker Containers
Aly Sivji
ย 
PDF
Deploy Deep Learning Application with Azure Container Instance - Devdays2018
Mia Chang
ย 
Supercharge ml using docker
Sho Fola Soboyejo
ย 
Docker Containers- Data Engineers' Arsenal.pdf
gr6336192
ย 
Docker training
Kiran Kumar
ย 
ieee cloud 2015 keynote talk
Microsoft Azure for Research
ย 
Data Science Workflows using Docker Containers
Aly Sivji
ย 
Deploy Deep Learning Application with Azure Container Instance - Devdays2018
Mia Chang
ย 
Ad

Recently uploaded (20)

PPTX
IObit Driver Booster Pro Crack Download Latest Version
chaudhryakashoo065
ย 
PDF
>Nitro Pro Crack 14.36.1.0 + Keygen Free Download [Latest]
utfefguu
ย 
PPTX
IObit Driver Booster Pro 12.4-12.5 license keys 2025-2026
chaudhryakashoo065
ย 
PPTX
ERP - FICO Presentation BY BSL BOKARO STEEL LIMITED.pptx
ravisranjan
ย 
PPTX
declaration of Variables and constants.pptx
meemee7378
ย 
PDF
WholeClear Split vCard Software for Split large vCard file
markwillsonmw004
ย 
PPTX
Iobit Driver Booster Pro 12 Crack Free Download
chaudhryakashoo065
ย 
PDF
capitulando la keynote de GrafanaCON 2025 - Madrid
Imma Valls Bernaus
ย 
PDF
>Wondershare Filmora Crack Free Download 2025
utfefguu
ย 
PDF
TEASMA: A Practical Methodology for Test Adequacy Assessment of Deep Neural N...
Lionel Briand
ย 
PPTX
For my supp to finally picking supp that work
necas19388
ย 
PDF
Rewards and Recognition (2).pdf
ethan Talor
ย 
PDF
IDM Crack with Internet Download Manager 6.42 Build 41
utfefguu
ย 
PDF
Automated Testing and Safety Analysis of Deep Neural Networks
Lionel Briand
ย 
PPTX
CONCEPT OF PROGRAMMING in language .pptx
tamim41
ย 
PDF
LPS25 - Operationalizing MLOps in GEP - Terradue.pdf
terradue
ย 
PPT
Information Communication Technology Concepts
LOIDAALMAZAN3
ย 
PPTX
B2C EXTRANET | EXTRANET WEBSITE | EXTRANET INTEGRATION
philipnathen82
ย 
PDF
Code Once; Run Everywhere - A Beginnerโ€™s Journey with React Native
Hasitha Walpola
ย 
PDF
AI Software Development Process, Strategies and Challenges
Net-Craft.com
ย 
IObit Driver Booster Pro Crack Download Latest Version
chaudhryakashoo065
ย 
>Nitro Pro Crack 14.36.1.0 + Keygen Free Download [Latest]
utfefguu
ย 
IObit Driver Booster Pro 12.4-12.5 license keys 2025-2026
chaudhryakashoo065
ย 
ERP - FICO Presentation BY BSL BOKARO STEEL LIMITED.pptx
ravisranjan
ย 
declaration of Variables and constants.pptx
meemee7378
ย 
WholeClear Split vCard Software for Split large vCard file
markwillsonmw004
ย 
Iobit Driver Booster Pro 12 Crack Free Download
chaudhryakashoo065
ย 
capitulando la keynote de GrafanaCON 2025 - Madrid
Imma Valls Bernaus
ย 
>Wondershare Filmora Crack Free Download 2025
utfefguu
ย 
TEASMA: A Practical Methodology for Test Adequacy Assessment of Deep Neural N...
Lionel Briand
ย 
For my supp to finally picking supp that work
necas19388
ย 
Rewards and Recognition (2).pdf
ethan Talor
ย 
IDM Crack with Internet Download Manager 6.42 Build 41
utfefguu
ย 
Automated Testing and Safety Analysis of Deep Neural Networks
Lionel Briand
ย 
CONCEPT OF PROGRAMMING in language .pptx
tamim41
ย 
LPS25 - Operationalizing MLOps in GEP - Terradue.pdf
terradue
ย 
Information Communication Technology Concepts
LOIDAALMAZAN3
ย 
B2C EXTRANET | EXTRANET WEBSITE | EXTRANET INTEGRATION
philipnathen82
ย 
Code Once; Run Everywhere - A Beginnerโ€™s Journey with React Native
Hasitha Walpola
ย 
AI Software Development Process, Strategies and Challenges
Net-Craft.com
ย 

Using python and docker for data science

  • 1. USING DOCKER FOR DATA SCIENCE
  • 2. WHY DOCKER Portable environment Isolated between projects Stateless Fast local file access Hetrogenous
  • 3. GET DOCKER https://docs.docker.com/installation/ boot2docker .dmg or .exe apt-get install docker.io ...
  • 4. RUN SCIPYSERVER $ docker run -d -e "PASSWORD=YourPassword?" ipython/scipyserver $ docker run -d -e "PASSWORD=YourPassword?" --name dev_notebook -p 443:8888 ipython/scipyserver https://localhost:443 https://{boot2docker ip}:443
  • 5. CREATE DATA-ONLY CONTAINERS $ docker run -d -v ~/notebooks:/notebooks --name notebooks_container ubuntu echo notebooks $ docker run -d -v ~/data:/data --name data_container ubuntu echo data
  • 6. MOUNT DATA-ONLY CONTAINERS $ docker stop dev_notebook $ docker rm dev_notebook $ docker run -d -e "PASSWORD=YourPassword?" --name dev_notebook -p 443:8888 --volumes-from data_container --volumes-from notebooks_container ipython/scipyserver
  • 7. CREATE A DOCKERFILE FROM ipython/scipyserver MAINTAINER Calvin Giles <[email protected]> COPY requirements.txt /requirements.txt RUN pip2 install -r /requirements.txt RUN pip3 install -r /requirements.txt $ docker build -t calvingiles/ds-notebook . $ docker run -d -e "PASSWORD=YourPassword?" --name dev_notebook -p 443:8888 --volumes-from data_container --volumes-from notebooks_container calvingiles/ds-notebook
  • 8. NEXT TIME Connecting to local database containers Tweaking the boot2docker vm memory from 2GB to 8 (or more...) Linking to private git repositories Automated builds with github linking
  • 9. MORE? Docker User Guide: http://docs.docker.com/userguide/ Docker Reference: http://docs.docker.com/reference/commandline/cli/ ipython docker images: https://registry.hub.docker.com/repos/ipython/ my docker image: https://github.com/calvingiles/ds-notebook https://registry.hub.docker.com/u/calvingiles/ds-notebook/
  • 10. ABOUT ME Calvin Giles Data Scientist at Adthena PyData Meetup Organiser untangleconsulting.io [email protected] @calvingiles on twitter, github, docker hub (and many more)