LoginSignup
6
8

More than 5 years have passed since last update.

[メモ] Jupyter - Kernel追加(C, nodejs)

Last updated at Posted at 2016-08-31

 ちょいメモ

  • 前々前回からの続き
  • Rは、v3.1(Raspbian jessieのパッケージのやつ)だとうごかない。3.2か、3.3にしないといけない。
  • ホントに必要になったら、検証して、更新する。

C

sudo pip install jupyter-c-kernel
git clone https://github.com/brendan-rius/jupyter-c-kernel.git
cd jupyter-c-kernel
sudo jupyter-kernelspec install c_spec/

nodejs

sudo apt-get install npm nodejs-legacy libzmq-dev

git clone https://github.com/notablemind/jupyter-nodejs.git
cd jupyter-nodejs
mkdir -p ~/.ipython/kernels/nodejs/
npm install && node install.js
make
ipython console --kernel nodejs

REPLACE_INVALID_UTF8がないとかいうエラーの回避

# Raspbianのパッケージのような古いnodejs(v0.10?)の場合。

  • REPLACE_INVALID_UTF8 = 0を追加(一行前に , 入れる)
/usr/include/nodejs/deps/v8/include/v8.h
...
  enum WriteOptions {
    NO_OPTIONS = 0,
    HINT_MANY_WRITES_EXPECTED = 1,
    NO_NULL_TERMINATION = 2,
    PRESERVE_ASCII_NULL = 4,
    REPLACE_INVALID_UTF8 = 0
  };
...
6
8
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
6
8