Skip to content

Instantly share code, notes, and snippets.

@sebble
Last active August 29, 2015 14:15
Show Gist options
  • Save sebble/ece456957574182d9d0b to your computer and use it in GitHub Desktop.
Save sebble/ece456957574182d9d0b to your computer and use it in GitHub Desktop.
Jupyter Kernels
# http://jupyter.cs.brynmawr.edu/hub/dblank/public/Jupyter%20Help.ipynb#1.4.2-Enable-Python-3-kernel
# https://nbviewer.jupyter.org/github/ellisonbg/talk-2014-summer/blob/cfa/Multilanguage.ipynb
## Python 2
sudo apt-get install python-pip libzmq3-dev
sudo pip install -U pip
sudo pip install ipython pyzmq matplotlib
#sudo pip install -I ipython==3.* # force v3
## Python 3
sudo apt-get install python3-pip libzmq3-dev
sudo pip3 install -U pip
sudo pip3 install ipython pyzmq matplotlib
mkdir -p ~/.ipython/kernels/python3
cp kernels_python3_* ~/.ipython/kernels/python3/
## Julia (https://github.com/JuliaLang/IJulia.jl)
sudo apt-add-repository ppa:staticfloat/juliareleases
sudo apt-get update
sudo apt-get install julia
julia -e 'Pkg.add("IJulia")'
mkdir -p ~/.ipython/kernels/julia
cp kernels_julia_* ~/.ipython/kernels/julia/
## R (https://github.com/takluyver/IRkernel)
sudo sh -c "echo 'deb http://star-www.st-andrews.ac.uk/cran/bin/linux/ubuntu trusty/' > /etc/apt/sources.list.d/R.list"
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E084DAB9
sudo apt-get update
sudo apt-get install r-base libzmq3-dev libcurl4-openssl-dev
sudo R -e '
install.packages("devtools")
# Need RCurl for install_github
install.packages('RCurl')
library(devtools)
install_github('armstrtw/rzmq')
install_github("takluyver/IRdisplay")
install_github("takluyver/IRkernel")
# Only if you have IPython 3 or above installed:
IRkernel::installspec()
'
{"argv": ["R","-e","IRkernel::main()","--args","{connection_file}"],
"display_name":"R"
}
{
"display_name": "Julia",
"language": "julia",
"argv": ["/usr/bin/julia",
"-F", "/home/sebastian/.julia/v0.3/IJulia/src/kernel.jl", "{connection_file}"
]
}
{
"display_name": "Python 3",
"language": "python",
"argv": [
"python3",
"-c", "from IPython.kernel.zmq.kernelapp import main; main()",
"-f", "{connection_file}"
],
"codemirror_mode": {
"_version": 2,
"name": "ipython"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment