CPUs - why do we have more than one?

Writing Efficient R Code

Colin Gillespie

Jumping Rivers & Newcastle University

CPUs

  • CPU: brains of the computer
    • Speed has slowly stabilized
      • CPUs were getting too hot
    • Multi-core CPUs
    • But R only uses 1 core :(

Writing Efficient R Code

Your CPU

library("parallel")
detectCores()
8
library("benchmarkme")
get_cpu()
$vendor_id
"GenuineIntel"

$model_name
"Intel(R) Core(TM) i7-4702HQ CPU

$no_of_cores
8
Writing Efficient R Code

Let's practice!

Writing Efficient R Code

Preparing Video For Download...