SlideShare ist ein Scribd-Unternehmen logo
1 von 28
Downloaden Sie, um offline zu lesen
PPaarraalllleellccoommppuuttiinnggiinnRR
Vivian Zhang, Yuan Huang, Tong He
SupStat Inc
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
1 of 28 6/12/14, 5:26 PM
OOuuttlliinnee
Introduction to Parallel computing
Implementation in R
Examples
·
·
Overview
Package: Foreach
-
-
·
2/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
2 of 28 6/12/14, 5:26 PM
Introduction to Parallel computing
3/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
3 of 28 6/12/14, 5:26 PM
SSeerriiaallvvssPPaarraalllleellCCoommppuuttaattiioonn
Serial Computation
Traditionally, software is written for serial computation, where tasks must be performed in sequence
on a single processor. Only one instruction may execute at any moment in time.
Illustration of Serial Computation
4/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
4 of 28 6/12/14, 5:26 PM
SSeerriiaallvvssPPaarraalllleellCCoommppuuttaattiioonn
Parallel Computation
Parallel computing aims to speed up the computation. In parallel computing,
Illustration of Parallel Computation
The problem is broken apart into discrete pieces of work.
Instructions from each part execute simultaneously on different processors.
·
·
5/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
5 of 28 6/12/14, 5:26 PM
PPaarraalllleellppaarraaddiiggmm
Master-worker paradigm
Master submits jobs to workers and collect results from workers.
No communications between workers
·
·
6/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
6 of 28 6/12/14, 5:26 PM
SStteeppssttoowwaarrddssPPaarraalllleellccoommppuuttiinngg
Hardware platforms1.
Whether the problem is parallelable ?2.
Tips to improve the parallel computing's effeciency.3.
Implementation in R.4.
7/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
7 of 28 6/12/14, 5:26 PM
HHaarrddwwaarreeppllaattffoorrmmss
Two representative Hardware platforms are multicore and cluster.
Multicore: Most of the PCs have multiple processors on a single chip, which enables the parallel
computing. CPU is subdivided into multiple "cores", each being a unique execution unit.
Cluster: A set of independent nodes that are connected by a certain network.
·
·
8/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
8 of 28 6/12/14, 5:26 PM
WWhheetthheerrtthheepprroobblleemmiissppaarraalllleellaabbllee??
Recap: parallel computing requires that
Example:
The problem can be broken apart into discrete pieces of work.
Instructions from each part can execute simultaneously on different processors.
·
·
vec <- runif(10)
# sum(vec): i-th itervation uses the result from (i-1)-th iteration.
sum.vec <- 0
for (i in seq(vec)) sum.vec <- sum.vec+vec[i]
# cumsum(vec): i-th itervation are independent from (i-1)-th iteration.
cumsum.vec <- 0*seq(vec)
for (i in seq(vec)) cumsum.vec[i] <- sum(vec[1:i])
9/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
9 of 28 6/12/14, 5:26 PM
IIsstthhiissaaggooooddppaarraalllleelliizzaattiioonnsscchheemmee??
For this cumsum example,
Scheme: Prepare 10 cores and let each core implement one sum(vec[1:i]).
Question: Is this a good parallel scheme?
vec <- runif(10)
# cumsum(vec): i-th itervation are independent from (i-1)-th iteration.
cumsum.vec <- 0*seq(vec)
for (i in seq(vec)) cumsum.vec[i] <- sum(vec[1:i])
10/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
10 of 28 6/12/14, 5:26 PM
IIsstthhiissaaggooooddppaarraalllleelliizzaattiioonnsscchheemmee??
No, because different i may have result in quite widely different computation time, which may bring in
a serious load balance issue.
Consider load balancing!
11/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
11 of 28 6/12/14, 5:26 PM
LLooaaddbbaallaanncciinngg
Load balancing aims to spread tasks evenly across processors.
When tasks and processors are not load balanced:
Some processes finish early and sit idle waiting
Global computation is finished when the slowest processor(s) completes its task.
·
·
12/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
12 of 28 6/12/14, 5:26 PM
PPaarraalllleelloovveerrhheeaadd
The amount of time required to coordinate parallel tasks, as opposed to doing useful work. Parallel
overhead can include factors such as:
Communication is much slower than computation; care should be taken to minimize unnecessary
data transfer to and from workers.
Assign the tasks in chunck help parallel overhead.
Task start-up time
Synchronizations
Data communications
Software overhead imposed by parallel languages, libraries, operating system, etc.
·
·
·
·
13/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
13 of 28 6/12/14, 5:26 PM
RRaannddoommnnuummbbeerrggeenneerraattoorrss
Random number generators require extra care. Random number streams on different nodes need to
be independent. It is important to avoid producing the same random number stream on each worker
and at the same time be able to facilitate reproducible research.
Special-purpose packages (rsprng, rlecuyer) are available; the snow package provides an integrated
interface to these packages.
In snow package, use the following code before the simulations.
clusterSetupSPRNG(cl)
14/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
14 of 28 6/12/14, 5:26 PM
AApppplliiccaattiioonnssoonnssttaattiissttiiccaallmmooddeelliinngg
Model selection
Data mining
Monte Carlo simulations
Boostrap (see examples)
Web Scrapper (see examples)
Subset selection
Tuning parameter selection (eg. tuning in regularized regression)
K-fold crossvalidation(see examples)
·
·
·
Random forest (see examples)
Clustering (see examples)
Principle component Analysis
·
·
·
15/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
15 of 28 6/12/14, 5:26 PM
Implementation in R
16/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
16 of 28 6/12/14, 5:26 PM
OOvveerrvviieeww::PPaacckkaaggeess
Use foreach + doSNOW.
Rmpi ( R interface to MPI; flexible; powerful, but more complex.)
Snow (will be used for backends with foreach package today)
multicore (work only on a single node and Linux-like machine)
parallel (hybrid package containing snow and multicore)
foreach (parallel backends doSNOW / doMPI / doMC)
·
·
·
·
·
17/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
17 of 28 6/12/14, 5:26 PM
ffoorreeaacchh::OOnneeRRiinnggttooRRuulleeTThheemmAAllll
foreach was written by Steve Weston (was in Revolution, now at Yale)
an elegant framework for parallel computing: loop construct + parallel execution
allows the user to specify the parallel environment. The parallel backends include:
·
·
·
doMC (multicore),
doSNOW (snow)
doMPI (Rmpi)
doParallel (parallel)
...
-
-
-
-
-
18/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
18 of 28 6/12/14, 5:26 PM
RReeggiisstteerrtthheeppaarraalllleellbbaacckkeennddss::
The doMC package acts as an interface between foreach and the multicore functionality.
The doSNOW package acts as an interface between foreach and the snow functionality.
# Register multicore as backend.
library(doMC)
registerDoMC(2)
foreach code
# Register snow as backend.
library(doSNOW)
cl <- makeCluster(2, type="SOCK")
registerDoSNOW(cl)
foreach code
stopCluster(cl)
19/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
19 of 28 6/12/14, 5:26 PM
PPaacckkaaggee::ssnnooww
Interfaces provided by snow package include:
MPI: Message Passing Interface, via Rmpi1.
NWS: NetWork Spaces via nws2.
PVM: Parallel Virtual Machine3.
Sockets: via the operating system4.
20/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
20 of 28 6/12/14, 5:26 PM
RReeggiisstteerrtthheeppaarraalllleellbbaacckkeennddss
Get the name of the currently registered backend:
Get the version of the currently registered backend:
Check how many workers foreach is going to use
getDoParName()
getDoParVersion()
getDoParWorkers()
21/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
21 of 28 6/12/14, 5:26 PM
ffoorreeaacchhccooddee::
Syntax
foreach object %do% expression1.
foreach object %dopar% expression2.
# here for(i=1:4) is the foreach object. we call i the iterator.
x <- foreach(i=1:4) %dopar% {exp(i)}
foreach object: Specify Looping sturcture, similar to for loop. (for -> foreach)
%do%, %dopar% : Specify excecution method.
expression: Specify how to excecute in each process.
·
·
%do% Execute the R expression sequentially
%dopar% Execute the R expression using the currently registered backend
-
-
·
22/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
22 of 28 6/12/14, 5:26 PM
ffoorreeaacchhccooddee::
Return is a list by default. Use .combine argument in foreach object to change.
library(doSNOW) # Register snow as backend.
cl <- makeCluster(2, type="SOCK")
registerDoSNOW(cl)
foreach(i=1:3) %dopar% {i^2} # foreach code
[[1]]
[1] 1
[[2]]
[1] 4
[[3]]
[1] 9
stopCluster(cl)
23/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
23 of 28 6/12/14, 5:26 PM
ffoorreeaacchhccooddee::
Set ".combine='c'" to obtain the return in vector.
# Register snow as backend.
library(doSNOW)
cl <- makeCluster(2, type="SOCK")
registerDoSNOW(cl)
# foreach code
foreach(i=1:3, .combine='c') %dopar% {i^2}
[1] 1 4 9
stopCluster(cl)
24/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
24 of 28 6/12/14, 5:26 PM
ffoorreeaacchhccooddee::ttwwooiitteerraattoorrss..
# Register snow as backend.
library(doSNOW)
cl <- makeCluster(2, type="SOCK")
registerDoSNOW(cl)
# foreach code: here we have two itrators, i and j.
foreach(i=1:3,j=4:6, .combine='c') %dopar% {i+j}
[1] 5 7 9
foreach(i=1:3,j=4:9, .combine='c') %dopar% {i+j}
[1] 5 7 9
stopCluster(cl)
25/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
25 of 28 6/12/14, 5:26 PM
NNeessttiinnggtthheellooooppss
Syntax
foreach object 1 %:%
foreach object 2 %dopar%
{ expression }
Example
# foreach code
bvec <- c(1,2,3)
avec <- c(-1,-2,-3)
x <-
foreach(b=bvec, .combine='c') %:%
foreach(a=avec, .combine='c') %dopar% {
a + b
}
26/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
26 of 28 6/12/14, 5:26 PM
NNeessttiinnggtthheellooooppss
library(doSNOW)
cl <- makeCluster(2, type="SOCK")
registerDoSNOW(cl)
# foreach code
bvec <- c(1,2,3)
avec <- c(-1,-2,-3)
x <-
foreach(b=bvec, .combine='c') %:%
foreach(a=avec, .combine='c') %dopar% {
a + b
}
stopCluster(cl)
27/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
27 of 28 6/12/14, 5:26 PM
RReeffeerreennccee
Good Overview: State of the Art in Parallel Computing with R, Journal of Statistical Software.1.
Hand-on tutorial:2.
Comprehensive textbook:3.
Package foreach, Steve Weston
Using The foreach Package,Steve Weston
Nesting Foreach Loops,Steve Weston
Getting Started with doMC and foreach,Steve Weston
·
·
·
·
Programming on Parallel Machines, Norm Matlof
Introduction to Parallel Computing, Blaise Barney
·
·
28/28
Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1
28 of 28 6/12/14, 5:26 PM

Weitere ähnliche Inhalte

Was ist angesagt?

Engineering fast indexes (Deepdive)
Engineering fast indexes (Deepdive)Engineering fast indexes (Deepdive)
Engineering fast indexes (Deepdive)Daniel Lemire
 
JVM Memory Model - Yoav Abrahami, Wix
JVM Memory Model - Yoav Abrahami, WixJVM Memory Model - Yoav Abrahami, Wix
JVM Memory Model - Yoav Abrahami, WixCodemotion Tel Aviv
 
Computational Techniques for the Statistical Analysis of Big Data in R
Computational Techniques for the Statistical Analysis of Big Data in RComputational Techniques for the Statistical Analysis of Big Data in R
Computational Techniques for the Statistical Analysis of Big Data in Rherbps10
 
Optimizing with persistent data structures (LLVM Cauldron 2016)
Optimizing with persistent data structures (LLVM Cauldron 2016)Optimizing with persistent data structures (LLVM Cauldron 2016)
Optimizing with persistent data structures (LLVM Cauldron 2016)Igalia
 
Конверсия управляемых языков в неуправляемые
Конверсия управляемых языков в неуправляемыеКонверсия управляемых языков в неуправляемые
Конверсия управляемых языков в неуправляемыеPlatonov Sergey
 
Good news, everybody! Guile 2.2 performance notes (FOSDEM 2016)
Good news, everybody! Guile 2.2 performance notes (FOSDEM 2016)Good news, everybody! Guile 2.2 performance notes (FOSDEM 2016)
Good news, everybody! Guile 2.2 performance notes (FOSDEM 2016)Igalia
 
OmpSs – improving the scalability of OpenMP
OmpSs – improving the scalability of OpenMPOmpSs – improving the scalability of OpenMP
OmpSs – improving the scalability of OpenMPIntel IT Center
 
Go and Uber’s time series database m3
Go and Uber’s time series database m3Go and Uber’s time series database m3
Go and Uber’s time series database m3Rob Skillington
 
Gor Nishanov, C++ Coroutines – a negative overhead abstraction
Gor Nishanov,  C++ Coroutines – a negative overhead abstractionGor Nishanov,  C++ Coroutines – a negative overhead abstraction
Gor Nishanov, C++ Coroutines – a negative overhead abstractionSergey Platonov
 
Knit, Chisel, Hack: Building Programs in Guile Scheme (Strange Loop 2016)
Knit, Chisel, Hack: Building Programs in Guile Scheme (Strange Loop 2016)Knit, Chisel, Hack: Building Programs in Guile Scheme (Strange Loop 2016)
Knit, Chisel, Hack: Building Programs in Guile Scheme (Strange Loop 2016)Igalia
 
Threaded Programming
Threaded ProgrammingThreaded Programming
Threaded ProgrammingSri Prasanna
 
A peek on numerical programming in perl and python e christopher dyken 2005
A peek on numerical programming in perl and python  e christopher dyken  2005A peek on numerical programming in perl and python  e christopher dyken  2005
A peek on numerical programming in perl and python e christopher dyken 2005Jules Krdenas
 
Flux and InfluxDB 2.0 by Paul Dix
Flux and InfluxDB 2.0 by Paul DixFlux and InfluxDB 2.0 by Paul Dix
Flux and InfluxDB 2.0 by Paul DixInfluxData
 
Code GPU with CUDA - Optimizing memory and control flow
Code GPU with CUDA - Optimizing memory and control flowCode GPU with CUDA - Optimizing memory and control flow
Code GPU with CUDA - Optimizing memory and control flowMarina Kolpakova
 
Tensorflow in practice by Engineer - donghwi cha
Tensorflow in practice by Engineer - donghwi chaTensorflow in practice by Engineer - donghwi cha
Tensorflow in practice by Engineer - donghwi chaDonghwi Cha
 
Dynamic Memory allocation
Dynamic Memory allocationDynamic Memory allocation
Dynamic Memory allocationGrishma Rajput
 
Yampa AFRP Introduction
Yampa AFRP IntroductionYampa AFRP Introduction
Yampa AFRP IntroductionChengHui Weng
 

Was ist angesagt? (20)

Engineering fast indexes (Deepdive)
Engineering fast indexes (Deepdive)Engineering fast indexes (Deepdive)
Engineering fast indexes (Deepdive)
 
JVM Memory Model - Yoav Abrahami, Wix
JVM Memory Model - Yoav Abrahami, WixJVM Memory Model - Yoav Abrahami, Wix
JVM Memory Model - Yoav Abrahami, Wix
 
Computational Techniques for the Statistical Analysis of Big Data in R
Computational Techniques for the Statistical Analysis of Big Data in RComputational Techniques for the Statistical Analysis of Big Data in R
Computational Techniques for the Statistical Analysis of Big Data in R
 
Optimizing with persistent data structures (LLVM Cauldron 2016)
Optimizing with persistent data structures (LLVM Cauldron 2016)Optimizing with persistent data structures (LLVM Cauldron 2016)
Optimizing with persistent data structures (LLVM Cauldron 2016)
 
Конверсия управляемых языков в неуправляемые
Конверсия управляемых языков в неуправляемыеКонверсия управляемых языков в неуправляемые
Конверсия управляемых языков в неуправляемые
 
Dma
DmaDma
Dma
 
Good news, everybody! Guile 2.2 performance notes (FOSDEM 2016)
Good news, everybody! Guile 2.2 performance notes (FOSDEM 2016)Good news, everybody! Guile 2.2 performance notes (FOSDEM 2016)
Good news, everybody! Guile 2.2 performance notes (FOSDEM 2016)
 
OmpSs – improving the scalability of OpenMP
OmpSs – improving the scalability of OpenMPOmpSs – improving the scalability of OpenMP
OmpSs – improving the scalability of OpenMP
 
Go and Uber’s time series database m3
Go and Uber’s time series database m3Go and Uber’s time series database m3
Go and Uber’s time series database m3
 
Gor Nishanov, C++ Coroutines – a negative overhead abstraction
Gor Nishanov,  C++ Coroutines – a negative overhead abstractionGor Nishanov,  C++ Coroutines – a negative overhead abstraction
Gor Nishanov, C++ Coroutines – a negative overhead abstraction
 
Knit, Chisel, Hack: Building Programs in Guile Scheme (Strange Loop 2016)
Knit, Chisel, Hack: Building Programs in Guile Scheme (Strange Loop 2016)Knit, Chisel, Hack: Building Programs in Guile Scheme (Strange Loop 2016)
Knit, Chisel, Hack: Building Programs in Guile Scheme (Strange Loop 2016)
 
C++ Coroutines
C++ CoroutinesC++ Coroutines
C++ Coroutines
 
Threaded Programming
Threaded ProgrammingThreaded Programming
Threaded Programming
 
A peek on numerical programming in perl and python e christopher dyken 2005
A peek on numerical programming in perl and python  e christopher dyken  2005A peek on numerical programming in perl and python  e christopher dyken  2005
A peek on numerical programming in perl and python e christopher dyken 2005
 
Flux and InfluxDB 2.0 by Paul Dix
Flux and InfluxDB 2.0 by Paul DixFlux and InfluxDB 2.0 by Paul Dix
Flux and InfluxDB 2.0 by Paul Dix
 
Code GPU with CUDA - Optimizing memory and control flow
Code GPU with CUDA - Optimizing memory and control flowCode GPU with CUDA - Optimizing memory and control flow
Code GPU with CUDA - Optimizing memory and control flow
 
Dynamic memory allocation
Dynamic memory allocationDynamic memory allocation
Dynamic memory allocation
 
Tensorflow in practice by Engineer - donghwi cha
Tensorflow in practice by Engineer - donghwi chaTensorflow in practice by Engineer - donghwi cha
Tensorflow in practice by Engineer - donghwi cha
 
Dynamic Memory allocation
Dynamic Memory allocationDynamic Memory allocation
Dynamic Memory allocation
 
Yampa AFRP Introduction
Yampa AFRP IntroductionYampa AFRP Introduction
Yampa AFRP Introduction
 

Andere mochten auch

Patterns For Parallel Computing
Patterns For Parallel ComputingPatterns For Parallel Computing
Patterns For Parallel ComputingDavid Chou
 
Scalable Parallel Computing on Clouds
Scalable Parallel Computing on CloudsScalable Parallel Computing on Clouds
Scalable Parallel Computing on CloudsThilina Gunarathne
 
Parallel computing in india
Parallel computing in indiaParallel computing in india
Parallel computing in indiaPreeti Chauhan
 
High Performance Parallel Computing with Clouds and Cloud Technologies
High Performance Parallel Computing with Clouds and Cloud TechnologiesHigh Performance Parallel Computing with Clouds and Cloud Technologies
High Performance Parallel Computing with Clouds and Cloud Technologiesjaliyae
 
network ram parallel computing
network ram parallel computingnetwork ram parallel computing
network ram parallel computingNiranjana Ambadi
 
Lessons from 2MM machine learning models
Lessons from 2MM machine learning modelsLessons from 2MM machine learning models
Lessons from 2MM machine learning modelsExtract Data Conference
 

Andere mochten auch (8)

Patterns For Parallel Computing
Patterns For Parallel ComputingPatterns For Parallel Computing
Patterns For Parallel Computing
 
Scalable Parallel Computing on Clouds
Scalable Parallel Computing on CloudsScalable Parallel Computing on Clouds
Scalable Parallel Computing on Clouds
 
Parallel computing in india
Parallel computing in indiaParallel computing in india
Parallel computing in india
 
High Performance Parallel Computing with Clouds and Cloud Technologies
High Performance Parallel Computing with Clouds and Cloud TechnologiesHigh Performance Parallel Computing with Clouds and Cloud Technologies
High Performance Parallel Computing with Clouds and Cloud Technologies
 
network ram parallel computing
network ram parallel computingnetwork ram parallel computing
network ram parallel computing
 
Lessons from 2MM machine learning models
Lessons from 2MM machine learning modelsLessons from 2MM machine learning models
Lessons from 2MM machine learning models
 
What is Big Data?
What is Big Data?What is Big Data?
What is Big Data?
 
Big data ppt
Big  data pptBig  data ppt
Big data ppt
 

Ähnlich wie R workshop xx -- Parallel Computing with R

NVIDIA HPC ソフトウエア斜め読み
NVIDIA HPC ソフトウエア斜め読みNVIDIA HPC ソフトウエア斜め読み
NVIDIA HPC ソフトウエア斜め読みNVIDIA Japan
 
RR & Docker @ MuensteR Meetup (Sep 2017)
RR & Docker @ MuensteR Meetup (Sep 2017)RR & Docker @ MuensteR Meetup (Sep 2017)
RR & Docker @ MuensteR Meetup (Sep 2017)Daniel Nüst
 
Porting a Streaming Pipeline from Scala to Rust
Porting a Streaming Pipeline from Scala to RustPorting a Streaming Pipeline from Scala to Rust
Porting a Streaming Pipeline from Scala to RustEvan Chan
 
Inter Task Communication On Volatile Nodes
Inter Task Communication On Volatile NodesInter Task Communication On Volatile Nodes
Inter Task Communication On Volatile Nodesnagarajan_ka
 
Parallelization of Graceful Labeling Using Open MP
Parallelization of Graceful Labeling Using Open MPParallelization of Graceful Labeling Using Open MP
Parallelization of Graceful Labeling Using Open MPIJSRED
 
Directive-based approach to Heterogeneous Computing
Directive-based approach to Heterogeneous ComputingDirective-based approach to Heterogeneous Computing
Directive-based approach to Heterogeneous ComputingRuymán Reyes
 
Using R on High Performance Computers
Using R on High Performance ComputersUsing R on High Performance Computers
Using R on High Performance ComputersDave Hiltbrand
 
IRJET- Latin Square Computation of Order-3 using Open CL
IRJET- Latin Square Computation of Order-3 using Open CLIRJET- Latin Square Computation of Order-3 using Open CL
IRJET- Latin Square Computation of Order-3 using Open CLIRJET Journal
 
Cooperative Task Execution for Apache Spark
Cooperative Task Execution for Apache SparkCooperative Task Execution for Apache Spark
Cooperative Task Execution for Apache SparkDatabricks
 
A Highly Parallel Semi-Dataflow FPGA Architecture for Large-Scale N-Body Simu...
A Highly Parallel Semi-Dataflow FPGA Architecture for Large-Scale N-Body Simu...A Highly Parallel Semi-Dataflow FPGA Architecture for Large-Scale N-Body Simu...
A Highly Parallel Semi-Dataflow FPGA Architecture for Large-Scale N-Body Simu...NECST Lab @ Politecnico di Milano
 
H2O Design and Infrastructure with Matt Dowle
H2O Design and Infrastructure with Matt DowleH2O Design and Infrastructure with Matt Dowle
H2O Design and Infrastructure with Matt DowleSri Ambati
 
Intermachine Parallelism
Intermachine ParallelismIntermachine Parallelism
Intermachine ParallelismSri Prasanna
 
Performance comparison of row per slave and rows set per slave method in pvm ...
Performance comparison of row per slave and rows set per slave method in pvm ...Performance comparison of row per slave and rows set per slave method in pvm ...
Performance comparison of row per slave and rows set per slave method in pvm ...eSAT Journals
 
Performance comparison of row per slave and rows set
Performance comparison of row per slave and rows setPerformance comparison of row per slave and rows set
Performance comparison of row per slave and rows seteSAT Publishing House
 
lecture_GPUArchCUDA04-OpenMPHOMP.pdf
lecture_GPUArchCUDA04-OpenMPHOMP.pdflecture_GPUArchCUDA04-OpenMPHOMP.pdf
lecture_GPUArchCUDA04-OpenMPHOMP.pdfTigabu Yaya
 
Migration To Multi Core - Parallel Programming Models
Migration To Multi Core - Parallel Programming ModelsMigration To Multi Core - Parallel Programming Models
Migration To Multi Core - Parallel Programming ModelsZvi Avraham
 
Speed up R with parallel programming in the Cloud
Speed up R with parallel programming in the CloudSpeed up R with parallel programming in the Cloud
Speed up R with parallel programming in the CloudRevolution Analytics
 
計算機性能の限界点とその考え方
計算機性能の限界点とその考え方計算機性能の限界点とその考え方
計算機性能の限界点とその考え方Naoto MATSUMOTO
 

Ähnlich wie R workshop xx -- Parallel Computing with R (20)

NVIDIA HPC ソフトウエア斜め読み
NVIDIA HPC ソフトウエア斜め読みNVIDIA HPC ソフトウエア斜め読み
NVIDIA HPC ソフトウエア斜め読み
 
RR & Docker @ MuensteR Meetup (Sep 2017)
RR & Docker @ MuensteR Meetup (Sep 2017)RR & Docker @ MuensteR Meetup (Sep 2017)
RR & Docker @ MuensteR Meetup (Sep 2017)
 
Porting a Streaming Pipeline from Scala to Rust
Porting a Streaming Pipeline from Scala to RustPorting a Streaming Pipeline from Scala to Rust
Porting a Streaming Pipeline from Scala to Rust
 
Inter Task Communication On Volatile Nodes
Inter Task Communication On Volatile NodesInter Task Communication On Volatile Nodes
Inter Task Communication On Volatile Nodes
 
Parallelization of Graceful Labeling Using Open MP
Parallelization of Graceful Labeling Using Open MPParallelization of Graceful Labeling Using Open MP
Parallelization of Graceful Labeling Using Open MP
 
Directive-based approach to Heterogeneous Computing
Directive-based approach to Heterogeneous ComputingDirective-based approach to Heterogeneous Computing
Directive-based approach to Heterogeneous Computing
 
Using R on High Performance Computers
Using R on High Performance ComputersUsing R on High Performance Computers
Using R on High Performance Computers
 
IRJET- Latin Square Computation of Order-3 using Open CL
IRJET- Latin Square Computation of Order-3 using Open CLIRJET- Latin Square Computation of Order-3 using Open CL
IRJET- Latin Square Computation of Order-3 using Open CL
 
Cooperative Task Execution for Apache Spark
Cooperative Task Execution for Apache SparkCooperative Task Execution for Apache Spark
Cooperative Task Execution for Apache Spark
 
A Highly Parallel Semi-Dataflow FPGA Architecture for Large-Scale N-Body Simu...
A Highly Parallel Semi-Dataflow FPGA Architecture for Large-Scale N-Body Simu...A Highly Parallel Semi-Dataflow FPGA Architecture for Large-Scale N-Body Simu...
A Highly Parallel Semi-Dataflow FPGA Architecture for Large-Scale N-Body Simu...
 
H2O Design and Infrastructure with Matt Dowle
H2O Design and Infrastructure with Matt DowleH2O Design and Infrastructure with Matt Dowle
H2O Design and Infrastructure with Matt Dowle
 
Intermachine Parallelism
Intermachine ParallelismIntermachine Parallelism
Intermachine Parallelism
 
Performance comparison of row per slave and rows set per slave method in pvm ...
Performance comparison of row per slave and rows set per slave method in pvm ...Performance comparison of row per slave and rows set per slave method in pvm ...
Performance comparison of row per slave and rows set per slave method in pvm ...
 
autoTVM
autoTVMautoTVM
autoTVM
 
6. Implementation
6. Implementation6. Implementation
6. Implementation
 
Performance comparison of row per slave and rows set
Performance comparison of row per slave and rows setPerformance comparison of row per slave and rows set
Performance comparison of row per slave and rows set
 
lecture_GPUArchCUDA04-OpenMPHOMP.pdf
lecture_GPUArchCUDA04-OpenMPHOMP.pdflecture_GPUArchCUDA04-OpenMPHOMP.pdf
lecture_GPUArchCUDA04-OpenMPHOMP.pdf
 
Migration To Multi Core - Parallel Programming Models
Migration To Multi Core - Parallel Programming ModelsMigration To Multi Core - Parallel Programming Models
Migration To Multi Core - Parallel Programming Models
 
Speed up R with parallel programming in the Cloud
Speed up R with parallel programming in the CloudSpeed up R with parallel programming in the Cloud
Speed up R with parallel programming in the Cloud
 
計算機性能の限界点とその考え方
計算機性能の限界点とその考え方計算機性能の限界点とその考え方
計算機性能の限界点とその考え方
 

Mehr von Vivian S. Zhang

Career services workshop- Roger Ren
Career services workshop- Roger RenCareer services workshop- Roger Ren
Career services workshop- Roger RenVivian S. Zhang
 
Nycdsa wordpress guide book
Nycdsa wordpress guide bookNycdsa wordpress guide book
Nycdsa wordpress guide bookVivian S. Zhang
 
We're so skewed_presentation
We're so skewed_presentationWe're so skewed_presentation
We're so skewed_presentationVivian S. Zhang
 
Wikipedia: Tuned Predictions on Big Data
Wikipedia: Tuned Predictions on Big DataWikipedia: Tuned Predictions on Big Data
Wikipedia: Tuned Predictions on Big DataVivian S. Zhang
 
A Hybrid Recommender with Yelp Challenge Data
A Hybrid Recommender with Yelp Challenge Data A Hybrid Recommender with Yelp Challenge Data
A Hybrid Recommender with Yelp Challenge Data Vivian S. Zhang
 
Kaggle Top1% Solution: Predicting Housing Prices in Moscow
Kaggle Top1% Solution: Predicting Housing Prices in Moscow Kaggle Top1% Solution: Predicting Housing Prices in Moscow
Kaggle Top1% Solution: Predicting Housing Prices in Moscow Vivian S. Zhang
 
Data mining with caret package
Data mining with caret packageData mining with caret package
Data mining with caret packageVivian S. Zhang
 
Streaming Python on Hadoop
Streaming Python on HadoopStreaming Python on Hadoop
Streaming Python on HadoopVivian S. Zhang
 
Kaggle Winning Solution Xgboost algorithm -- Let us learn from its author
Kaggle Winning Solution Xgboost algorithm -- Let us learn from its authorKaggle Winning Solution Xgboost algorithm -- Let us learn from its author
Kaggle Winning Solution Xgboost algorithm -- Let us learn from its authorVivian S. Zhang
 
Nyc open-data-2015-andvanced-sklearn-expanded
Nyc open-data-2015-andvanced-sklearn-expandedNyc open-data-2015-andvanced-sklearn-expanded
Nyc open-data-2015-andvanced-sklearn-expandedVivian S. Zhang
 
Nycdsa ml conference slides march 2015
Nycdsa ml conference slides march 2015 Nycdsa ml conference slides march 2015
Nycdsa ml conference slides march 2015 Vivian S. Zhang
 
THE HACK ON JERSEY CITY CONDO PRICES explore trends in public data
THE HACK ON JERSEY CITY CONDO PRICES explore trends in public dataTHE HACK ON JERSEY CITY CONDO PRICES explore trends in public data
THE HACK ON JERSEY CITY CONDO PRICES explore trends in public dataVivian S. Zhang
 
Max Kuhn's talk on R machine learning
Max Kuhn's talk on R machine learningMax Kuhn's talk on R machine learning
Max Kuhn's talk on R machine learningVivian S. Zhang
 
Winning data science competitions, presented by Owen Zhang
Winning data science competitions, presented by Owen ZhangWinning data science competitions, presented by Owen Zhang
Winning data science competitions, presented by Owen ZhangVivian S. Zhang
 
Using Machine Learning to aid Journalism at the New York Times
Using Machine Learning to aid Journalism at the New York TimesUsing Machine Learning to aid Journalism at the New York Times
Using Machine Learning to aid Journalism at the New York TimesVivian S. Zhang
 
Introducing natural language processing(NLP) with r
Introducing natural language processing(NLP) with rIntroducing natural language processing(NLP) with r
Introducing natural language processing(NLP) with rVivian S. Zhang
 

Mehr von Vivian S. Zhang (20)

Why NYC DSA.pdf
Why NYC DSA.pdfWhy NYC DSA.pdf
Why NYC DSA.pdf
 
Career services workshop- Roger Ren
Career services workshop- Roger RenCareer services workshop- Roger Ren
Career services workshop- Roger Ren
 
Nycdsa wordpress guide book
Nycdsa wordpress guide bookNycdsa wordpress guide book
Nycdsa wordpress guide book
 
We're so skewed_presentation
We're so skewed_presentationWe're so skewed_presentation
We're so skewed_presentation
 
Wikipedia: Tuned Predictions on Big Data
Wikipedia: Tuned Predictions on Big DataWikipedia: Tuned Predictions on Big Data
Wikipedia: Tuned Predictions on Big Data
 
A Hybrid Recommender with Yelp Challenge Data
A Hybrid Recommender with Yelp Challenge Data A Hybrid Recommender with Yelp Challenge Data
A Hybrid Recommender with Yelp Challenge Data
 
Kaggle Top1% Solution: Predicting Housing Prices in Moscow
Kaggle Top1% Solution: Predicting Housing Prices in Moscow Kaggle Top1% Solution: Predicting Housing Prices in Moscow
Kaggle Top1% Solution: Predicting Housing Prices in Moscow
 
Data mining with caret package
Data mining with caret packageData mining with caret package
Data mining with caret package
 
Xgboost
XgboostXgboost
Xgboost
 
Streaming Python on Hadoop
Streaming Python on HadoopStreaming Python on Hadoop
Streaming Python on Hadoop
 
Kaggle Winning Solution Xgboost algorithm -- Let us learn from its author
Kaggle Winning Solution Xgboost algorithm -- Let us learn from its authorKaggle Winning Solution Xgboost algorithm -- Let us learn from its author
Kaggle Winning Solution Xgboost algorithm -- Let us learn from its author
 
Xgboost
XgboostXgboost
Xgboost
 
Nyc open-data-2015-andvanced-sklearn-expanded
Nyc open-data-2015-andvanced-sklearn-expandedNyc open-data-2015-andvanced-sklearn-expanded
Nyc open-data-2015-andvanced-sklearn-expanded
 
Nycdsa ml conference slides march 2015
Nycdsa ml conference slides march 2015 Nycdsa ml conference slides march 2015
Nycdsa ml conference slides march 2015
 
THE HACK ON JERSEY CITY CONDO PRICES explore trends in public data
THE HACK ON JERSEY CITY CONDO PRICES explore trends in public dataTHE HACK ON JERSEY CITY CONDO PRICES explore trends in public data
THE HACK ON JERSEY CITY CONDO PRICES explore trends in public data
 
Max Kuhn's talk on R machine learning
Max Kuhn's talk on R machine learningMax Kuhn's talk on R machine learning
Max Kuhn's talk on R machine learning
 
Winning data science competitions, presented by Owen Zhang
Winning data science competitions, presented by Owen ZhangWinning data science competitions, presented by Owen Zhang
Winning data science competitions, presented by Owen Zhang
 
Using Machine Learning to aid Journalism at the New York Times
Using Machine Learning to aid Journalism at the New York TimesUsing Machine Learning to aid Journalism at the New York Times
Using Machine Learning to aid Journalism at the New York Times
 
Introducing natural language processing(NLP) with r
Introducing natural language processing(NLP) with rIntroducing natural language processing(NLP) with r
Introducing natural language processing(NLP) with r
 
Bayesian models in r
Bayesian models in rBayesian models in r
Bayesian models in r
 

Kürzlich hochgeladen

Introduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxIntroduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxupamatechverse
 
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICSHARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICSRajkumarAkumalla
 
Microscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptxMicroscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptxpurnimasatapathy1234
 
KubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlyKubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlysanyuktamishra911
 
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130Suhani Kapoor
 
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Call Girls in Nagpur High Profile
 
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINEMANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINESIVASHANKAR N
 
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSAPPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSKurinjimalarL3
 
AKTU Computer Networks notes --- Unit 3.pdf
AKTU Computer Networks notes ---  Unit 3.pdfAKTU Computer Networks notes ---  Unit 3.pdf
AKTU Computer Networks notes --- Unit 3.pdfankushspencer015
 
Processing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxProcessing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxpranjaldaimarysona
 
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escortsranjana rawat
 
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...ranjana rawat
 
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escortsranjana rawat
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxupamatechverse
 
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...ranjana rawat
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Christo Ananth
 
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSMANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSSIVASHANKAR N
 
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...roncy bisnoi
 

Kürzlich hochgeladen (20)

Introduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxIntroduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptx
 
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICSHARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
 
Microscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptxMicroscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptx
 
KubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlyKubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghly
 
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
 
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
 
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINEMANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
 
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSAPPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
 
AKTU Computer Networks notes --- Unit 3.pdf
AKTU Computer Networks notes ---  Unit 3.pdfAKTU Computer Networks notes ---  Unit 3.pdf
AKTU Computer Networks notes --- Unit 3.pdf
 
Processing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxProcessing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptx
 
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
 
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINEDJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
 
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
 
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
 
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptx
 
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
 
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSMANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
 
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
 

R workshop xx -- Parallel Computing with R

  • 1. PPaarraalllleellccoommppuuttiinnggiinnRR Vivian Zhang, Yuan Huang, Tong He SupStat Inc Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 1 of 28 6/12/14, 5:26 PM
  • 2. OOuuttlliinnee Introduction to Parallel computing Implementation in R Examples · · Overview Package: Foreach - - · 2/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 2 of 28 6/12/14, 5:26 PM
  • 3. Introduction to Parallel computing 3/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 3 of 28 6/12/14, 5:26 PM
  • 4. SSeerriiaallvvssPPaarraalllleellCCoommppuuttaattiioonn Serial Computation Traditionally, software is written for serial computation, where tasks must be performed in sequence on a single processor. Only one instruction may execute at any moment in time. Illustration of Serial Computation 4/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 4 of 28 6/12/14, 5:26 PM
  • 5. SSeerriiaallvvssPPaarraalllleellCCoommppuuttaattiioonn Parallel Computation Parallel computing aims to speed up the computation. In parallel computing, Illustration of Parallel Computation The problem is broken apart into discrete pieces of work. Instructions from each part execute simultaneously on different processors. · · 5/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 5 of 28 6/12/14, 5:26 PM
  • 6. PPaarraalllleellppaarraaddiiggmm Master-worker paradigm Master submits jobs to workers and collect results from workers. No communications between workers · · 6/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 6 of 28 6/12/14, 5:26 PM
  • 7. SStteeppssttoowwaarrddssPPaarraalllleellccoommppuuttiinngg Hardware platforms1. Whether the problem is parallelable ?2. Tips to improve the parallel computing's effeciency.3. Implementation in R.4. 7/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 7 of 28 6/12/14, 5:26 PM
  • 8. HHaarrddwwaarreeppllaattffoorrmmss Two representative Hardware platforms are multicore and cluster. Multicore: Most of the PCs have multiple processors on a single chip, which enables the parallel computing. CPU is subdivided into multiple "cores", each being a unique execution unit. Cluster: A set of independent nodes that are connected by a certain network. · · 8/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 8 of 28 6/12/14, 5:26 PM
  • 9. WWhheetthheerrtthheepprroobblleemmiissppaarraalllleellaabbllee?? Recap: parallel computing requires that Example: The problem can be broken apart into discrete pieces of work. Instructions from each part can execute simultaneously on different processors. · · vec <- runif(10) # sum(vec): i-th itervation uses the result from (i-1)-th iteration. sum.vec <- 0 for (i in seq(vec)) sum.vec <- sum.vec+vec[i] # cumsum(vec): i-th itervation are independent from (i-1)-th iteration. cumsum.vec <- 0*seq(vec) for (i in seq(vec)) cumsum.vec[i] <- sum(vec[1:i]) 9/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 9 of 28 6/12/14, 5:26 PM
  • 10. IIsstthhiissaaggooooddppaarraalllleelliizzaattiioonnsscchheemmee?? For this cumsum example, Scheme: Prepare 10 cores and let each core implement one sum(vec[1:i]). Question: Is this a good parallel scheme? vec <- runif(10) # cumsum(vec): i-th itervation are independent from (i-1)-th iteration. cumsum.vec <- 0*seq(vec) for (i in seq(vec)) cumsum.vec[i] <- sum(vec[1:i]) 10/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 10 of 28 6/12/14, 5:26 PM
  • 11. IIsstthhiissaaggooooddppaarraalllleelliizzaattiioonnsscchheemmee?? No, because different i may have result in quite widely different computation time, which may bring in a serious load balance issue. Consider load balancing! 11/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 11 of 28 6/12/14, 5:26 PM
  • 12. LLooaaddbbaallaanncciinngg Load balancing aims to spread tasks evenly across processors. When tasks and processors are not load balanced: Some processes finish early and sit idle waiting Global computation is finished when the slowest processor(s) completes its task. · · 12/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 12 of 28 6/12/14, 5:26 PM
  • 13. PPaarraalllleelloovveerrhheeaadd The amount of time required to coordinate parallel tasks, as opposed to doing useful work. Parallel overhead can include factors such as: Communication is much slower than computation; care should be taken to minimize unnecessary data transfer to and from workers. Assign the tasks in chunck help parallel overhead. Task start-up time Synchronizations Data communications Software overhead imposed by parallel languages, libraries, operating system, etc. · · · · 13/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 13 of 28 6/12/14, 5:26 PM
  • 14. RRaannddoommnnuummbbeerrggeenneerraattoorrss Random number generators require extra care. Random number streams on different nodes need to be independent. It is important to avoid producing the same random number stream on each worker and at the same time be able to facilitate reproducible research. Special-purpose packages (rsprng, rlecuyer) are available; the snow package provides an integrated interface to these packages. In snow package, use the following code before the simulations. clusterSetupSPRNG(cl) 14/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 14 of 28 6/12/14, 5:26 PM
  • 15. AApppplliiccaattiioonnssoonnssttaattiissttiiccaallmmooddeelliinngg Model selection Data mining Monte Carlo simulations Boostrap (see examples) Web Scrapper (see examples) Subset selection Tuning parameter selection (eg. tuning in regularized regression) K-fold crossvalidation(see examples) · · · Random forest (see examples) Clustering (see examples) Principle component Analysis · · · 15/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 15 of 28 6/12/14, 5:26 PM
  • 16. Implementation in R 16/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 16 of 28 6/12/14, 5:26 PM
  • 17. OOvveerrvviieeww::PPaacckkaaggeess Use foreach + doSNOW. Rmpi ( R interface to MPI; flexible; powerful, but more complex.) Snow (will be used for backends with foreach package today) multicore (work only on a single node and Linux-like machine) parallel (hybrid package containing snow and multicore) foreach (parallel backends doSNOW / doMPI / doMC) · · · · · 17/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 17 of 28 6/12/14, 5:26 PM
  • 18. ffoorreeaacchh::OOnneeRRiinnggttooRRuulleeTThheemmAAllll foreach was written by Steve Weston (was in Revolution, now at Yale) an elegant framework for parallel computing: loop construct + parallel execution allows the user to specify the parallel environment. The parallel backends include: · · · doMC (multicore), doSNOW (snow) doMPI (Rmpi) doParallel (parallel) ... - - - - - 18/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 18 of 28 6/12/14, 5:26 PM
  • 19. RReeggiisstteerrtthheeppaarraalllleellbbaacckkeennddss:: The doMC package acts as an interface between foreach and the multicore functionality. The doSNOW package acts as an interface between foreach and the snow functionality. # Register multicore as backend. library(doMC) registerDoMC(2) foreach code # Register snow as backend. library(doSNOW) cl <- makeCluster(2, type="SOCK") registerDoSNOW(cl) foreach code stopCluster(cl) 19/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 19 of 28 6/12/14, 5:26 PM
  • 20. PPaacckkaaggee::ssnnooww Interfaces provided by snow package include: MPI: Message Passing Interface, via Rmpi1. NWS: NetWork Spaces via nws2. PVM: Parallel Virtual Machine3. Sockets: via the operating system4. 20/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 20 of 28 6/12/14, 5:26 PM
  • 21. RReeggiisstteerrtthheeppaarraalllleellbbaacckkeennddss Get the name of the currently registered backend: Get the version of the currently registered backend: Check how many workers foreach is going to use getDoParName() getDoParVersion() getDoParWorkers() 21/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 21 of 28 6/12/14, 5:26 PM
  • 22. ffoorreeaacchhccooddee:: Syntax foreach object %do% expression1. foreach object %dopar% expression2. # here for(i=1:4) is the foreach object. we call i the iterator. x <- foreach(i=1:4) %dopar% {exp(i)} foreach object: Specify Looping sturcture, similar to for loop. (for -> foreach) %do%, %dopar% : Specify excecution method. expression: Specify how to excecute in each process. · · %do% Execute the R expression sequentially %dopar% Execute the R expression using the currently registered backend - - · 22/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 22 of 28 6/12/14, 5:26 PM
  • 23. ffoorreeaacchhccooddee:: Return is a list by default. Use .combine argument in foreach object to change. library(doSNOW) # Register snow as backend. cl <- makeCluster(2, type="SOCK") registerDoSNOW(cl) foreach(i=1:3) %dopar% {i^2} # foreach code [[1]] [1] 1 [[2]] [1] 4 [[3]] [1] 9 stopCluster(cl) 23/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 23 of 28 6/12/14, 5:26 PM
  • 24. ffoorreeaacchhccooddee:: Set ".combine='c'" to obtain the return in vector. # Register snow as backend. library(doSNOW) cl <- makeCluster(2, type="SOCK") registerDoSNOW(cl) # foreach code foreach(i=1:3, .combine='c') %dopar% {i^2} [1] 1 4 9 stopCluster(cl) 24/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 24 of 28 6/12/14, 5:26 PM
  • 25. ffoorreeaacchhccooddee::ttwwooiitteerraattoorrss.. # Register snow as backend. library(doSNOW) cl <- makeCluster(2, type="SOCK") registerDoSNOW(cl) # foreach code: here we have two itrators, i and j. foreach(i=1:3,j=4:6, .combine='c') %dopar% {i+j} [1] 5 7 9 foreach(i=1:3,j=4:9, .combine='c') %dopar% {i+j} [1] 5 7 9 stopCluster(cl) 25/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 25 of 28 6/12/14, 5:26 PM
  • 26. NNeessttiinnggtthheellooooppss Syntax foreach object 1 %:% foreach object 2 %dopar% { expression } Example # foreach code bvec <- c(1,2,3) avec <- c(-1,-2,-3) x <- foreach(b=bvec, .combine='c') %:% foreach(a=avec, .combine='c') %dopar% { a + b } 26/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 26 of 28 6/12/14, 5:26 PM
  • 27. NNeessttiinnggtthheellooooppss library(doSNOW) cl <- makeCluster(2, type="SOCK") registerDoSNOW(cl) # foreach code bvec <- c(1,2,3) avec <- c(-1,-2,-3) x <- foreach(b=bvec, .combine='c') %:% foreach(a=avec, .combine='c') %dopar% { a + b } stopCluster(cl) 27/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 27 of 28 6/12/14, 5:26 PM
  • 28. RReeffeerreennccee Good Overview: State of the Art in Parallel Computing with R, Journal of Statistical Software.1. Hand-on tutorial:2. Comprehensive textbook:3. Package foreach, Steve Weston Using The foreach Package,Steve Weston Nesting Foreach Loops,Steve Weston Getting Started with doMC and foreach,Steve Weston · · · · Programming on Parallel Machines, Norm Matlof Introduction to Parallel Computing, Blaise Barney · · 28/28 Parallel computing in R http://nycdatascience.com/slides/parallel_R/index.html#1 28 of 28 6/12/14, 5:26 PM