Mercurial > hg > Members > aka > jupyter_CbC_kernel
annotate README.md @ 68:d20180912a98
Merge branch 'master' of github.com:brendan-rius/jupyter-c-kernel
author | Brendan Rius <brendan.rius@gmail.com> |
---|---|
date | Sun, 13 Aug 2017 16:04:05 +0200 |
parents | b5fd860bd157 |
children | 79199ce31269 |
rev | line source |
---|---|
0 | 1 # Minimal C kernel for Jupyter |
2 | |
16
63084d5da27c
Update README.md after #2 and to move the requirements to the correct section
Brendan Rius <brendan@omixy.com>
parents:
13
diff
changeset
|
3 ## Use with Docker (recommended) |
13 | 4 |
5 * `docker pull brendanrius/jupyter-c-kernel` | |
62 | 6 * `docker run -p 8888:8888 brendanrius/jupyter-c-kernel` |
64
37ded774d876
Update README typo and clarification
Jason B <jasonkingsley.brown@gmail.com>
parents:
63
diff
changeset
|
7 * Copy the given URL containing the token, and browse to it. For instance: |
37ded774d876
Update README typo and clarification
Jason B <jasonkingsley.brown@gmail.com>
parents:
63
diff
changeset
|
8 |
37ded774d876
Update README typo and clarification
Jason B <jasonkingsley.brown@gmail.com>
parents:
63
diff
changeset
|
9 ``` |
37ded774d876
Update README typo and clarification
Jason B <jasonkingsley.brown@gmail.com>
parents:
63
diff
changeset
|
10 Copy/paste this URL into your browser when you connect for the first time, |
37ded774d876
Update README typo and clarification
Jason B <jasonkingsley.brown@gmail.com>
parents:
63
diff
changeset
|
11 to login with a token: |
37ded774d876
Update README typo and clarification
Jason B <jasonkingsley.brown@gmail.com>
parents:
63
diff
changeset
|
12 http://localhost:8888/?token=66750c80bd0788f6ba15760aadz53beb9a9fb4cf8ac15ce8 |
37ded774d876
Update README typo and clarification
Jason B <jasonkingsley.brown@gmail.com>
parents:
63
diff
changeset
|
13 ``` |
13 | 14 |
16
63084d5da27c
Update README.md after #2 and to move the requirements to the correct section
Brendan Rius <brendan@omixy.com>
parents:
13
diff
changeset
|
15 ## Manual installation |
63084d5da27c
Update README.md after #2 and to move the requirements to the correct section
Brendan Rius <brendan@omixy.com>
parents:
13
diff
changeset
|
16 |
17 | 17 * Make sure you have the following requirements installed: |
18 * gcc | |
19 * jupyter | |
31 | 20 * python 3 |
17 | 21 * pip |
26
06e1c3c43532
Add alternative installation using wget and sh
Manoel Vilela <manoel_vilela@engineer.com>
parents:
18
diff
changeset
|
22 |
06e1c3c43532
Add alternative installation using wget and sh
Manoel Vilela <manoel_vilela@engineer.com>
parents:
18
diff
changeset
|
23 ### Step-by-step: |
10 | 24 * `pip install jupyter-c-kernel` |
58
8a8a9952c887
Change install procedure
Brendan Rius <brendan.rius@gmail.com>
parents:
47
diff
changeset
|
25 * `install_c_kernel` |
18 | 26 * `jupyter-notebook`. Enjoy! |
6 | 27 |
28 ## Example of notebook | |
29 | |
30 ![Example of notebook](example-notebook.png?raw=true "Example of notebook") | |
19 | 31 |
63 | 32 ## Custom compilation flags |
33 | |
34 You can use custom compilation flags like so: | |
35 | |
36 ![Custom compulation flag](custom_flags.png?raw=true "Example of notebook using custom compilation flags") | |
37 | |
38 Here, the `-lm` flag is passed so you can use the math library. | |
39 | |
32
fae3b8f7cbfb
Add contributing guidelines in README
Brendan Rius <brendan@omixy.com>
parents:
31
diff
changeset
|
40 ## Contributing |
fae3b8f7cbfb
Add contributing guidelines in README
Brendan Rius <brendan@omixy.com>
parents:
31
diff
changeset
|
41 |
46
59cf2351e933
Add instruction on how to live-edit the code
Brendan Rius <brendan@omixy.com>
parents:
42
diff
changeset
|
42 The docker image installs the kernel in editable mode, meaning that you can |
59cf2351e933
Add instruction on how to live-edit the code
Brendan Rius <brendan@omixy.com>
parents:
42
diff
changeset
|
43 change the code in real-time in Docker. For that, just run the docker box like |
59cf2351e933
Add instruction on how to live-edit the code
Brendan Rius <brendan@omixy.com>
parents:
42
diff
changeset
|
44 that: |
59cf2351e933
Add instruction on how to live-edit the code
Brendan Rius <brendan@omixy.com>
parents:
42
diff
changeset
|
45 |
59cf2351e933
Add instruction on how to live-edit the code
Brendan Rius <brendan@omixy.com>
parents:
42
diff
changeset
|
46 ```bash |
59cf2351e933
Add instruction on how to live-edit the code
Brendan Rius <brendan@omixy.com>
parents:
42
diff
changeset
|
47 git clone https://github.com/brendan-rius/jupyter-c-kernel.git |
59cf2351e933
Add instruction on how to live-edit the code
Brendan Rius <brendan@omixy.com>
parents:
42
diff
changeset
|
48 cd jupyter-c-kernel |
47 | 49 docker run -v $(pwd):/jupyter/jupyter_c_kernel/ -p 8888:8888 brendanrius/jupyter-c-kernel |
46
59cf2351e933
Add instruction on how to live-edit the code
Brendan Rius <brendan@omixy.com>
parents:
42
diff
changeset
|
50 ``` |
59cf2351e933
Add instruction on how to live-edit the code
Brendan Rius <brendan@omixy.com>
parents:
42
diff
changeset
|
51 |
59cf2351e933
Add instruction on how to live-edit the code
Brendan Rius <brendan@omixy.com>
parents:
42
diff
changeset
|
52 This clones the source, run the kernel, and binds the current folder (the one |
64
37ded774d876
Update README typo and clarification
Jason B <jasonkingsley.brown@gmail.com>
parents:
63
diff
changeset
|
53 you just cloned) to the corresponding folder in Docker. |
46
59cf2351e933
Add instruction on how to live-edit the code
Brendan Rius <brendan@omixy.com>
parents:
42
diff
changeset
|
54 Now, if you change the source, it will be reflected in [http://localhost:8888](http://localhost:8888) |
59cf2351e933
Add instruction on how to live-edit the code
Brendan Rius <brendan@omixy.com>
parents:
42
diff
changeset
|
55 instantly. Do not forget to click "restart" the kernel on the page as it does |
59cf2351e933
Add instruction on how to live-edit the code
Brendan Rius <brendan@omixy.com>
parents:
42
diff
changeset
|
56 not auto-restart. |
59cf2351e933
Add instruction on how to live-edit the code
Brendan Rius <brendan@omixy.com>
parents:
42
diff
changeset
|
57 |
19 | 58 ## License |
59 | |
41 | 60 [MIT](LICENSE.txt) |