Show More
@@ -1,434 +1,391 b'' | |||||
1 | IPython requires Python 2.7 or ≥ 3.3. |
|
1 | IPython requires Python 2.7 or ≥ 3.3. | |
2 |
|
2 | |||
3 | .. note:: |
|
3 | .. note:: | |
4 |
|
4 | |||
5 |
If you need to use Python 2.6 or 3.2, you can find IPython 1. |
|
5 | If you need to use Python 2.6 or 3.2, you can find IPython 1.x | |
6 |
`here <http://archive.ipython.org/release/>`__ |
|
6 | `here <http://archive.ipython.org/release/>`__, | |
|
7 | or get it with pip:: | |||
|
8 | ||||
|
9 | pip install 'ipython<2' | |||
|
10 | ||||
7 |
|
|
11 | ||
8 | Quickstart |
|
12 | Quickstart | |
9 | ========== |
|
13 | ========== | |
10 |
|
14 | |||
11 |
If you have :mod:` |
|
15 | If you have :mod:`pip`, | |
12 | the quickest way to get up and running with IPython is: |
|
16 | the quickest way to get up and running with IPython is: | |
13 |
|
17 | |||
14 | .. code-block:: bash |
|
18 | .. code-block:: bash | |
15 |
|
19 | |||
16 | $ pip install "ipython[all]" |
|
20 | $ pip install "ipython[all]" | |
17 |
|
21 | |||
18 |
This will download and install IPython and its main optional dependencies |
|
22 | This will download and install IPython and its main optional dependencies for the notebook, | |
19 |
|
23 | qtconsole, tests, and other functionality. | ||
20 | - jinja2, needed for the notebook |
|
24 | Some dependencies (Qt, PyQt for the QtConsole, pandoc for nbconvert) are not pip-installable, | |
21 | - sphinx, needed for nbconvert |
|
25 | and will not be pulled in by pip. | |
22 | - pyzmq, needed for IPython's parallel computing features, qt console and |
|
|||
23 | notebook |
|
|||
24 | - pygments, used by nbconvert and the Qt console for syntax highlighting |
|
|||
25 | - tornado, needed by the web-based notebook |
|
|||
26 | - nose, used by the test suite |
|
|||
27 | - readline (on OS X) or pyreadline (on Windows), needed for the terminal |
|
|||
28 |
|
26 | |||
29 | To run IPython's test suite, use the :command:`iptest` command: |
|
27 | To run IPython's test suite, use the :command:`iptest` command: | |
30 |
|
28 | |||
31 | .. code-block:: bash |
|
29 | .. code-block:: bash | |
32 |
|
30 | |||
33 | $ iptest |
|
31 | $ iptest | |
34 |
|
32 | |||
35 |
|
33 | |||
36 | Overview |
|
34 | Overview | |
37 | ======== |
|
35 | ======== | |
38 |
|
36 | |||
39 | This document describes in detail the steps required to install IPython, |
|
37 | This document describes in detail the steps required to install IPython, | |
40 | and its various optional dependencies. |
|
38 | and its various optional dependencies. | |
41 | For a few quick ways to get started with package managers or full Python distributions, |
|
39 | For a few quick ways to get started with package managers or full Python distributions, | |
42 | see `the install page <http://ipython.org/install.html>`_ of the IPython website. |
|
40 | see `the install page <http://ipython.org/install.html>`_ of the IPython website. | |
43 |
|
41 | |||
44 | IPython is organized into a number of subpackages, each of which has its own dependencies. |
|
42 | IPython is organized into a number of subpackages, each of which has its own dependencies. | |
45 | All of the subpackages come with IPython, so you don't need to download and |
|
43 | All of the subpackages come with IPython, so you don't need to download and | |
46 | install them separately. However, to use a given subpackage, you will need to |
|
44 | install them separately. However, to use a given subpackage, you will need to | |
47 | install all of its dependencies. |
|
45 | install all of its dependencies. | |
48 |
|
46 | |||
49 | Please let us know if you have problems installing IPython or any of its dependencies. |
|
47 | Please let us know if you have problems installing IPython or any of its dependencies. | |
50 |
|
48 | |||
51 | IPython and most dependencies can be installed via :command:`pip`. |
|
49 | IPython and most dependencies can be installed via :command:`pip`. | |
52 | In many scenarios, this is the simplest method of installing Python packages. |
|
50 | In many scenarios, this is the simplest method of installing Python packages. | |
53 | More information about :mod:`pip` can be found on |
|
51 | More information about :mod:`pip` can be found on | |
54 | `its PyPI page <http://pypi.python.org/pypi/pip>`__. |
|
52 | `its PyPI page <http://pypi.python.org/pypi/pip>`__. | |
55 |
|
53 | |||
56 | .. note:: |
|
|||
57 |
|
||||
58 | On Windows, IPython *requires* :mod:`setuptools`. We hope to |
|
|||
59 | change this in the future, but for now on Windows, you *must* install |
|
|||
60 | :mod:`setuptools` to use IPython. |
|
|||
61 |
|
54 | |||
62 | More general information about installing Python packages can be found in |
|
55 | More general information about installing Python packages can be found in | |
63 | `Python's documentation <http://docs.python.org>`_. |
|
56 | `Python's documentation <http://docs.python.org>`_. | |
64 |
|
57 | |||
65 |
|
58 | |||
66 | Installing IPython itself |
|
59 | Installing IPython itself | |
67 | ========================= |
|
60 | ========================= | |
68 |
|
61 | |||
69 | Given a properly built Python, the basic interactive IPython shell will work |
|
62 | Given a properly built Python, the basic interactive IPython shell will work | |
70 | with no external dependencies. However, some Python distributions |
|
63 | with no external dependencies. However, some Python distributions | |
71 | (particularly on Windows and OS X), don't come with a working :mod:`readline` |
|
64 | (particularly on Windows and OS X), don't come with a working :mod:`readline` | |
72 | module. The IPython shell will work without :mod:`readline`, but will lack |
|
65 | module. The IPython shell will work without :mod:`readline`, but will lack | |
73 | many features that users depend on, such as tab completion and command line |
|
66 | many features that users depend on, such as tab completion and command line | |
74 |
editing. If you install IPython with :mod:` |
|
67 | editing. If you install IPython with :mod:`pip`, | |
75 |
|
|
68 | then the appropriate :mod:`readline` for your platform will be installed. | |
76 |
|
|
69 | See below for details of how to make sure you have a working :mod:`readline`. | |
77 | :mod:`readline`. |
|
|||
78 |
|
70 | |||
79 | Installation using pip |
|
71 | Installation using pip | |
80 | ---------------------- |
|
72 | ---------------------- | |
81 |
|
73 | |||
82 |
If you have |
|
74 | If you have :mod:`pip`, the easiest way of getting IPython is | |
83 | to simply use :command:`pip`: |
|
75 | to simply use :command:`pip`: | |
84 |
|
76 | |||
85 | .. code-block:: bash |
|
77 | .. code-block:: bash | |
86 |
|
78 | |||
87 | $ pip install ipython |
|
79 | $ pip install ipython | |
88 |
|
80 | |||
89 | That's it. |
|
81 | That's it. | |
90 |
|
82 | |||
91 |
|
83 | |||
92 | Installation from source |
|
84 | Installation from source | |
93 | ------------------------ |
|
85 | ------------------------ | |
94 |
|
86 | |||
95 | If you don't want to use :command:`pip`, or don't have it installed, |
|
87 | If you don't want to use :command:`pip`, or don't have it installed, | |
96 |
|
|
88 | grab the latest stable build of IPython from `here | |
97 | <http://ipython.org/download.html>`_. Then do the following: |
|
89 | <http://ipython.org/download.html>`_. Then do the following: | |
98 |
|
90 | |||
99 | .. code-block:: bash |
|
91 | .. code-block:: bash | |
100 |
|
92 | |||
101 | $ tar -xzf ipython.tar.gz |
|
93 | $ tar -xzf ipython.tar.gz | |
102 | $ cd ipython |
|
94 | $ cd ipython | |
103 | $ python setup.py install |
|
95 | $ python setup.py install | |
104 |
|
96 | |||
105 | If you are installing to a location (like ``/usr/local``) that requires higher |
|
97 | If you are installing to a location (like ``/usr/local``) that requires higher | |
106 | permissions, you may need to run the last command with :command:`sudo`. |
|
98 | permissions, you may need to run the last command with :command:`sudo`. | |
107 |
|
99 | |||
108 | Windows |
|
100 | Windows | |
109 | ------- |
|
101 | ------- | |
110 |
|
102 | |||
111 | As mentioned above, on Windows, IPython requires :mod:`setuptools`, and it also |
|
103 | As mentioned above, terminal IPython requires the PyReadline library to properly support coloring and keyboard | |
112 | requires the PyReadline library to properly support coloring and keyboard |
|
|||
113 | management (features that the default windows console doesn't have). So on |
|
104 | management (features that the default windows console doesn't have). So on | |
114 | Windows, the installation procedure is: |
|
105 | Windows, the installation procedure is: | |
115 |
|
106 | |||
116 |
1. Install ` |
|
107 | 1. Install `pip <http://pypi.python.org/pypi/pip>`_, if you don't have it already. | |
117 |
|
108 | 2. Install IPython: ``pip install ipython``. | ||
118 | 2. Install `pyreadline <http://pypi.python.org/pypi/pyreadline>`_. You can use |
|
|||
119 | the command ``pip install pyreadline`` from a terminal, or the binary |
|
|||
120 | installer appropriate for your platform from the PyPI page. |
|
|||
121 |
|
||||
122 | 3. Install IPython itself, which you can download from `PyPI |
|
|||
123 | <http://pypi.python.org/pypi/ipython>`_ or from `our site |
|
|||
124 | <http://ipython.org/download.html>`_. Note that on Windows 7, you *must* |
|
|||
125 | right-click and 'Run as administrator' for the Start menu shortcuts to be |
|
|||
126 | created. |
|
|||
127 |
|
109 | |||
128 | IPython by default runs in a terminal window, but the normal terminal |
|
|||
129 | application supplied by Microsoft Windows is very primitive. You may want to |
|
|||
130 | download the excellent and free Console_ application instead, which is a far |
|
|||
131 | superior tool. You can even configure Console to give you by default an |
|
|||
132 | IPython tab, which is very convenient to create new IPython sessions directly |
|
|||
133 | from the working terminal. |
|
|||
134 |
|
110 | |||
135 | .. _Console: http://sourceforge.net/projects/console |
|
|||
136 |
|
||||
137 |
|
||||
138 | Installing the development version |
|
111 | Installing the development version | |
139 | ---------------------------------- |
|
112 | ---------------------------------- | |
140 |
|
113 | |||
141 | It is also possible to install the development version of IPython from our |
|
114 | It is also possible to install the development version of IPython from our | |
142 | `Git <http://git-scm.com/>`_ source code repository. To do this you will |
|
115 | `Git <http://git-scm.com/>`_ source code repository. To do this you will | |
143 |
need to have Git installed on your system. Then |
|
116 | need to have Git installed on your system. Then do: | |
144 |
|
117 | |||
145 | .. code-block:: bash |
|
118 | .. code-block:: bash | |
146 |
|
119 | |||
147 | $ git clone --recursive https://github.com/ipython/ipython.git |
|
120 | $ git clone --recursive https://github.com/ipython/ipython.git | |
148 | $ cd ipython |
|
121 | $ cd ipython | |
149 | $ python setup.py install |
|
122 | $ python setup.py install | |
150 |
|
123 | |||
151 | Some users want to be able to follow the development branch as it changes. If |
|
124 | Some users want to be able to follow the development branch as it changes. If | |
152 | you have :mod:`setuptools` installed, this is easy. Simply replace the last |
|
125 | you have :mod:`pip`, you can replace the last step by: | |
153 | step by: |
|
|||
154 |
|
126 | |||
155 | .. code-block:: bash |
|
127 | .. code-block:: bash | |
156 |
|
128 | |||
157 | $ python setupegg.py develop |
|
129 | $ pip install -e . | |
158 |
|
130 | |||
159 | This creates links in the right places and installs the command line script to |
|
131 | This creates links in the right places and installs the command line script to | |
160 | the appropriate places. |
|
132 | the appropriate places. | |
161 |
|
133 | |||
162 | Then, if you want to update your IPython at any time, |
|
134 | Then, if you want to update your IPython at any time, do: | |
163 | just do: |
|
|||
164 |
|
135 | |||
165 | .. code-block:: bash |
|
136 | .. code-block:: bash | |
166 |
|
137 | |||
167 | $ git pull |
|
138 | $ git pull | |
168 |
|
139 | |||
169 | IPython now uses git submodules to ship its javascript dependencies. If you run |
|
140 | IPython now uses git submodules to ship its javascript dependencies. If you run | |
170 | IPython from git master, you may need to update submodules once in a while with: |
|
141 | IPython from git master, you may need to update submodules once in a while with: | |
171 |
|
142 | |||
172 | .. code-block:: bash |
|
143 | .. code-block:: bash | |
173 |
|
144 | |||
174 | $ git submodule update |
|
145 | $ git submodule update | |
175 |
|
146 | |||
176 | or |
|
147 | or | |
177 |
|
148 | |||
178 | .. code-block:: bash |
|
149 | .. code-block:: bash | |
179 |
|
150 | |||
180 | $ python setup.py submodule |
|
151 | $ python setup.py submodule | |
181 |
|
152 | |||
182 | Another option is to copy `git hooks <https://github.com/ipython/ipython/tree/master/git-hooks>`_ |
|
153 | Another option is to copy `git hooks <https://github.com/ipython/ipython/tree/master/git-hooks>`_ | |
183 | to your ``./git/hooks/`` directory to ensure that your submodules are up to date on each pull. |
|
154 | to your ``./git/hooks/`` directory to ensure that your submodules are up to date on each pull. | |
184 |
|
155 | |||
185 |
|
156 | |||
186 | Basic optional dependencies |
|
157 | Basic optional dependencies | |
187 | =========================== |
|
158 | =========================== | |
188 |
|
159 | |||
189 | There are a number of basic optional dependencies that most users will want to |
|
160 | There are a number of basic optional dependencies that most users will want to | |
190 | get. These are: |
|
161 | get. These are: | |
191 |
|
162 | |||
192 | * readline (for command line editing, tab completion, etc.) |
|
163 | * readline (for command line editing, tab completion, etc.) | |
193 | * nose (to run the IPython test suite) |
|
164 | * nose (to run the IPython test suite) | |
|
165 | * mock (Python < 3, also for tests) | |||
194 |
|
166 | |||
195 | If you are comfortable installing these things yourself, have at it, otherwise |
|
167 | If you are comfortable installing these things yourself, have at it, otherwise | |
196 | read on for more details. |
|
168 | read on for more details. | |
197 |
|
169 | |||
198 | IPython uses several other modules, such as pexpect_ and path.py, if they are |
|
170 | IPython uses several other modules, such as pexpect_ and path.py, if they are | |
199 | installed on your system, but it can also use bundled versions from |
|
171 | installed on your system, but it can also use bundled versions from | |
200 | :mod:`IPython.external`, so there's no need to install them separately. |
|
172 | :mod:`IPython.external`, so there's no need to install them separately. | |
201 |
|
173 | |||
202 | readline |
|
174 | readline | |
203 | -------- |
|
175 | -------- | |
204 |
|
176 | |||
205 | As indicated above, on Windows, to get full functionality in the console |
|
177 | As indicated above, on Windows, to get full functionality in the console | |
206 | version of IPython, PyReadline is needed. |
|
178 | version of IPython, PyReadline is needed. | |
207 | PyReadline is a separate, Windows only implementation of readline that uses |
|
179 | PyReadline is a separate, Windows only implementation of readline that uses | |
208 | native Windows calls through :mod:`ctypes`. The easiest way of installing |
|
180 | native Windows calls through :mod:`ctypes`. The easiest way of installing | |
209 | PyReadline is you use the binary installer available `here |
|
181 | PyReadline is you use the binary installer available `here | |
210 | <http://pypi.python.org/pypi/pyreadline>`__. |
|
182 | <http://pypi.python.org/pypi/pyreadline>`__. | |
211 |
|
183 | |||
212 | On OSX, if you are using the built-in Python shipped by Apple, you will be |
|
184 | On OS X, if you are using the built-in Python shipped by Apple, you will be | |
213 | missing a proper readline implementation as Apple ships instead a library called |
|
185 | missing a proper readline implementation as Apple ships instead a library called | |
214 | ``libedit`` that provides only some of readline's functionality. While you may |
|
186 | ``libedit`` that provides only some of readline's functionality. While you may | |
215 | find libedit sufficient, we have occasional reports of bugs with it and several |
|
187 | find libedit sufficient, we have occasional reports of bugs with it and several | |
216 | developers who use OS X as their main environment consider libedit unacceptable |
|
188 | developers who use OS X as their main environment consider libedit unacceptable | |
217 | for productive, regular use with IPython. |
|
189 | for productive, regular use with IPython. | |
218 |
|
190 | |||
219 | Therefore, IPython on OS X depends on the :mod:`gnureadline` module. |
|
191 | Therefore, IPython on OS X depends on the :mod:`gnureadline` module. | |
220 | We will *not* consider completion/history problems to be bugs for IPython if you are using libedit. |
|
192 | We will *not* consider completion/history problems to be bugs for IPython if you are using libedit. | |
221 |
|
193 | |||
222 |
To get a working :mod:`readline` module on OS X, |
|
194 | To get a working :mod:`readline` module on OS X, do (with :mod:`pip` | |
223 | installed): |
|
195 | installed): | |
224 |
|
196 | |||
225 | .. code-block:: bash |
|
197 | .. code-block:: bash | |
226 |
|
198 | |||
227 | $ pip install gnureadline |
|
199 | $ pip install gnureadline | |
228 |
|
200 | |||
229 | .. note:: |
|
201 | .. note:: | |
230 |
|
202 | |||
231 | Other Python distributions on OS X (such as Anaconda, fink, MacPorts) |
|
203 | Other Python distributions on OS X (such as Anaconda, fink, MacPorts) | |
232 | already have proper readline so you likely don't have to do this step. |
|
204 | already have proper readline so you likely don't have to do this step. | |
233 |
|
205 | |||
234 |
When IPython is installed with :mod:` |
|
206 | When IPython is installed with :mod:`pip`, (e.g. using the | |
235 | ``pip`` command), the correct readline should be installed if you specify the `terminal` |
|
207 | ``pip`` command), the correct readline should be installed if you specify the `terminal` | |
236 | optional dependencies: |
|
208 | optional dependencies: | |
237 |
|
209 | |||
238 | .. code-block:: bash |
|
210 | .. code-block:: bash | |
239 |
|
211 | |||
240 | $ pip install "ipython[terminal]" |
|
212 | $ pip install "ipython[terminal]" | |
241 |
|
213 | |||
242 |
|
214 | |||
243 | nose |
|
215 | nose | |
244 | ---- |
|
216 | ---- | |
245 |
|
217 | |||
246 | To run the IPython test suite you will need the :mod:`nose` package. Nose |
|
218 | To run the IPython test suite you will need the :mod:`nose` package. Nose | |
247 | provides a great way of sniffing out and running all of the IPython tests. The |
|
219 | provides a great way of sniffing out and running all of the IPython tests. The | |
248 | simplest way of getting nose is to use :command:`pip`: |
|
220 | simplest way of getting nose is to use :command:`pip`: | |
249 |
|
221 | |||
250 | .. code-block:: bash |
|
222 | .. code-block:: bash | |
251 |
|
223 | |||
252 | $ pip install nose |
|
224 | $ pip install nose | |
253 |
|
225 | |||
254 | Another way of getting this is to do: |
|
226 | Another way of getting this is to do: | |
255 |
|
227 | |||
256 | .. code-block:: bash |
|
228 | .. code-block:: bash | |
257 |
|
229 | |||
258 | $ pip install "ipython[test]" |
|
230 | $ pip install "ipython[test]" | |
259 |
|
231 | |||
260 | For more installation options, see the `nose website |
|
232 | For more installation options, see the `nose website | |
261 | <http://somethingaboutorange.com/mrl/projects/nose/>`_. |
|
233 | <http://somethingaboutorange.com/mrl/projects/nose/>`_. | |
262 |
|
234 | |||
263 | Once you have nose installed, you can run IPython's test suite using the |
|
235 | Once you have nose installed, you can run IPython's test suite using the | |
264 | iptest command: |
|
236 | iptest command: | |
265 |
|
237 | |||
266 | .. code-block:: bash |
|
238 | .. code-block:: bash | |
267 |
|
239 | |||
268 | $ iptest |
|
240 | $ iptest | |
269 |
|
241 | |||
270 | Dependencies for IPython.parallel (parallel computing) |
|
242 | Dependencies for IPython.parallel (parallel computing) | |
271 | ====================================================== |
|
243 | ====================================================== | |
272 |
|
244 | |||
273 | IPython.parallel provides a nice architecture for parallel computing, with a |
|
245 | IPython's inter-process communication uses the PyZMQ_ bindings for the ZeroMQ_ messaging library. | |
274 | focus on fluid interactive workflows. These features require just one package: |
|
246 | This is the only dependency for :mod:`IPython.parallel`. | |
275 | PyZMQ. See the next section for PyZMQ details. |
|
|||
276 |
|
247 | |||
277 | On a Unix style platform (including OS X), if you want to use |
|
248 | Shortcut: | |
278 | :mod:`setuptools`, you can just do: |
|
|||
279 |
|
249 | |||
280 | .. code-block:: bash |
|
250 | .. code-block:: bash | |
281 |
|
251 | |||
282 | $ pip install "ipython[zmq]" # will include pyzmq |
|
252 | pip install "ipython[parallel]" | |
283 |
|
|
253 | ||
284 | Security in IPython.parallel is provided by SSH tunnels. By default, Linux |
|
254 | or manual | |
285 | and OSX clients will use the shell ssh command, but on Windows, we also |
|
|||
286 | support tunneling with paramiko_. |
|
|||
287 |
|
255 | |||
288 | Dependencies for IPython.kernel.zmq |
|
256 | .. code-block:: bash | |
289 | =================================== |
|
|||
290 |
|
|
257 | ||
291 | pyzmq |
|
258 | pip install pyzmq | |
292 | ----- |
|
|||
293 |
|
|
259 | ||
294 | IPython 0.11 introduced some new functionality, including a two-process |
|
260 | PyZMQ provides wheels for current Python on OS X and Windows, so installing pyzmq will typically not require compilation. | |
295 | execution model using ZeroMQ_ for communication. The Python bindings to ZeroMQ |
|
|||
296 | are found in the PyZMQ_ project, which is pip install-able. |
|
|||
297 | If you are on Python 2.7, 3.3, or 3.4 on OSX or Windows, |
|
|||
298 | pyzmq has eggs and wheels that include ZeroMQ itself. |
|
|||
299 |
|
261 | |||
300 | IPython.kernel.zmq depends on pyzmq >= 2.2. |
|
262 | IPython.parallel can use SSH tunnels, which require paramiko_ on Windows. | |
301 |
|
263 | |||
302 |
Dependencies for the IPython Q |
|
264 | Dependencies for the IPython Qt console | |
303 | ======================================= |
|
265 | ======================================= | |
304 |
|
266 | |||
305 | pyzmq |
|
267 | pyzmq_, pygments_, PyQt_ (or PySide_) | |
306 | ----- |
|
|||
307 |
|
268 | |||
308 | Like the :mod:`IPython.parallel` package, the QT Console requires ZeroMQ and |
|
269 | Shortcut: | |
309 | PyZMQ. |
|
|||
310 |
|
270 | |||
311 | Qt |
|
271 | .. code-block:: bash | |
312 | -- |
|
|||
313 |
|
|
272 | ||
314 | Also with 0.11, a new GUI was added using the work in :mod:`IPython.kernel.zmq`, which |
|
273 | pip install "ipython[qtconsole]" | |
315 | can be launched with ``ipython qtconsole``. The GUI is built on Qt, and works |
|
|||
316 | with either `PyQt <http://www.riverbankcomputing.co.uk/>`_, or `PySide |
|
|||
317 | <http://qt-project.org/wiki/PySide>`_. |
|
|||
318 |
|
|
274 | ||
319 | pygments |
|
275 | or manual | |
320 | -------- |
|
276 | ||
|
277 | .. code-block:: bash | |||
|
278 | ||||
|
279 | pip install pyzmq pygments | |||
321 |
|
|
280 | ||
322 | The syntax-highlighting in ``ipython qtconsole`` is done with the pygments_ |
|
281 | PyQt/PySide are not pip installable, so generally must be installed via system package managers (or conda). | |
323 | project, which is pip install-able. |
|
|||
324 |
|
282 | |||
325 | .. _installnotebook: |
|
283 | .. _installnotebook: | |
326 |
|
284 | |||
327 | Dependencies for the IPython HTML notebook |
|
285 | Dependencies for the IPython HTML notebook | |
328 | ========================================== |
|
286 | ========================================== | |
329 |
|
287 | |||
330 | The IPython notebook is a notebook-style web interface to IPython and can be |
|
288 | The HTML notebook is a complex web application with quite a few dependencies: | |
331 | started with the command ``ipython notebook``. |
|
|||
332 |
|
289 | |||
333 | pyzmq |
|
290 | pyzmq_, jinja2_, tornado_, mistune_, jsonschema_, pygments_, terminado_ | |
334 | ----- |
|
|||
335 |
|
291 | |||
336 | Like the :mod:`IPython.parallel` and :mod:`IPython.frontend.qt.console` |
|
292 | Shortcut: | |
337 | packages, the HTML notebook requires ZeroMQ and PyZMQ. |
|
|||
338 |
|
293 | |||
339 | Tornado |
|
294 | .. code-block:: bash | |
340 | ------- |
|
|||
341 |
|
|
295 | ||
342 | The IPython notebook uses the Tornado_ project for its HTTP server. Tornado 2.1 |
|
296 | pip install "ipython[notebook]" | |
343 | is required, in order to support current versions of browsers, due to an update |
|
|||
344 | to the websocket protocol. |
|
|||
345 |
|
|
297 | ||
346 | Jinja |
|
298 | or manual: | |
347 | ----- |
|
|||
348 |
|
299 | |||
349 | The IPython notebook uses the Jinja_ templating tool to render HTML pages. |
|
300 | .. code-block:: bash | |
350 |
|
|
301 | ||
|
302 | pip install pyzmq jinja2 tornado mistune jsonschema pygments terminado_ | |||
|
303 | ||||
|
304 | The IPython notebook is a notebook-style web interface to IPython and can be | |||
|
305 | started with the command ``ipython notebook``. | |||
351 |
|
306 | |||
352 | MathJax |
|
307 | MathJax | |
353 | ------- |
|
308 | ------- | |
354 |
|
309 | |||
355 | The IPython notebook uses the MathJax_ Javascript library for rendering LaTeX |
|
310 | The IPython notebook uses the MathJax_ Javascript library for rendering LaTeX | |
356 | in web browsers. Because MathJax is large, we don't include it with |
|
311 | in web browsers. Because MathJax is large, we don't include it with | |
357 | IPython. Normally IPython will load MathJax from a CDN, but if you have a slow |
|
312 | IPython. Normally IPython will load MathJax from a CDN, but if you have a slow | |
358 | network connection, or want to use LaTeX without an internet connection at all, |
|
313 | network connection, or want to use LaTeX without an internet connection at all, | |
359 | you can install MathJax locally. |
|
314 | you can install MathJax locally. | |
360 |
|
315 | |||
361 | A quick and easy method is to install it from a python session:: |
|
316 | A quick and easy method is to install it from a python session:: | |
362 |
|
317 | |||
363 |
|
|
318 | python -m IPython.external.mathjax | |
364 | install_mathjax() |
|
|||
365 |
|
319 | |||
366 | If you need tighter configuration control, you can download your own copy |
|
320 | If you need tighter configuration control, you can download your own copy | |
367 | of MathJax from http://www.mathjax.org/download/ - use the MathJax-2.0 link. |
|
321 | of MathJax from http://www.mathjax.org/download/ - use the MathJax-2.0 link. | |
368 | When you have the file stored locally, install it with:: |
|
322 | When you have the file stored locally, install it with:: | |
369 |
|
323 | |||
370 |
|
|
324 | python -m IPython.external.mathjax /path/to/source/mathjax-MathJax-v2.0-20-g07669ac.zip | |
371 |
|
325 | |||
372 | For unusual needs, IPython can tell you what directory it wants to find MathJax in:: |
|
326 | For unusual needs, IPython can tell you what directory it wants to find MathJax in:: | |
373 |
|
327 | |||
374 |
|
|
328 | python -m IPython.external.mathjax -d /some/other/mathjax | |
375 |
|
329 | |||
376 |
By default Mathjax will be installed in your ipython |
|
330 | By default Mathjax will be installed in your ipython directory, but you | |
377 | can make system wide install, please refer to the documentation and helper function |
|
331 | can make system wide install, please refer to the documentation and helper function | |
378 | of :mod:`IPython.external.mathjax` |
|
332 | of :mod:`IPython.external.mathjax` | |
379 |
|
333 | |||
380 | Browser Compatibility |
|
334 | Browser Compatibility | |
381 | --------------------- |
|
335 | --------------------- | |
382 |
|
336 | |||
383 | The IPython notebook is officially supported on the following browsers: |
|
337 | The IPython notebook is officially supported on the following browsers: | |
384 |
|
338 | |||
385 | * Chrome ≥ 13 |
|
339 | * Chrome ≥ 13 | |
386 | * Safari ≥ 5 |
|
340 | * Safari ≥ 5 | |
387 | * Firefox ≥ 6 |
|
341 | * Firefox ≥ 6 | |
388 |
|
342 | |||
389 | The is mainly due to the notebook's usage of WebSockets and the flexible box model. |
|
343 | The is mainly due to the notebook's usage of WebSockets and the flexible box model. | |
390 |
|
344 | |||
391 | The following browsers are unsupported: |
|
345 | The following browsers are unsupported: | |
392 |
|
346 | |||
393 | * Safari < 5 |
|
347 | * Safari < 5 | |
394 | * Firefox < 6 |
|
348 | * Firefox < 6 | |
395 | * Chrome < 13 |
|
349 | * Chrome < 13 | |
396 | * Opera (any): CSS issues, but execution might work |
|
350 | * Opera (any): CSS issues, but execution might work | |
397 | * Internet Explorer < 10 |
|
351 | * Internet Explorer < 10 | |
|
352 | * Internet Explorer ≥ 10 (same as Opera) | |||
398 |
|
353 | |||
399 | The following specific combinations are known **NOT** to work: |
|
354 | The following specific combinations are known **NOT** to work: | |
400 |
|
355 | |||
401 | * Safari, IPython 0.12, tornado ≥ 2.2.0 |
|
356 | * Safari, IPython 0.12, tornado ≥ 2.2.0 | |
402 | * Safari with HTTPS connection to notebook and an untrusted certificate (websockets will fail) |
|
357 | * Safari with HTTPS connection to notebook and an untrusted certificate (websockets will fail) | |
403 | * The `diigo Chrome extension <http://help.diigo.com/tools/chrome-extension>`_ seems to interfere with scrolling |
|
358 | * The `diigo Chrome extension <http://help.diigo.com/tools/chrome-extension>`_ seems to interfere with scrolling | |
404 |
|
359 | |||
405 | There are some early reports that the Notebook works on Internet Explorer 10, but we |
|
360 | There are some early reports that the Notebook works on Internet Explorer 10, but we | |
406 | expect there will be some CSS issues related to the flexible box model. |
|
361 | expect there will be some CSS issues related to the flexible box model. | |
407 |
|
362 | |||
408 |
|
363 | |||
409 | Dependencies for nbconvert (converting notebooks to various formats) |
|
364 | Dependencies for nbconvert (converting notebooks to various formats) | |
410 | ==================================================================== |
|
365 | ==================================================================== | |
411 |
|
366 | |||
412 | pandoc |
|
367 | For converting markdown to formats other than HTML, nbconvert uses Pandoc_ (1.12.1 or later). | |
413 | ------ |
|
|||
414 |
|
||||
415 | The most important dependency of nbconvert is Pandoc_ 1.10 or later, a document format translation program. |
|
|||
416 | This is not a Python package, so it cannot be expressed as a regular IPython dependency with setuptools. |
|
|||
417 |
|
368 | |||
418 | To install pandoc on Linux, you can generally use your package manager:: |
|
369 | To install pandoc on Linux, you can generally use your package manager:: | |
419 |
|
370 | |||
420 | sudo apt-get install pandoc |
|
371 | sudo apt-get install pandoc | |
421 |
|
372 | |||
422 | On other platforms, you can get pandoc from `their website <http://johnmacfarlane.net/pandoc/installing.html>`_. |
|
373 | On other platforms, you can get pandoc from `their website <http://johnmacfarlane.net/pandoc/installing.html>`_. | |
423 |
|
374 | |||
424 |
|
375 | |||
425 | .. _ZeroMQ: http://www.zeromq.org |
|
376 | .. _ZeroMQ: http://www.zeromq.org | |
426 | .. _PyZMQ: https://github.com/zeromq/pyzmq |
|
377 | .. _PyZMQ: https://github.com/zeromq/pyzmq | |
427 | .. _paramiko: https://github.com/robey/paramiko |
|
378 | .. _paramiko: https://github.com/robey/paramiko | |
428 | .. _pygments: http://pygments.org |
|
379 | .. _pygments: http://pygments.org | |
429 | .. _pexpect: http://pexpect.readthedocs.org/en/latest/ |
|
380 | .. _pexpect: http://pexpect.readthedocs.org/en/latest/ | |
430 | .. _Jinja: http://jinja.pocoo.org |
|
381 | .. _Jinja: http://jinja.pocoo.org | |
431 | .. _Sphinx: http://sphinx-doc.org |
|
382 | .. _Sphinx: http://sphinx-doc.org | |
432 | .. _pandoc: http://johnmacfarlane.net/pandoc |
|
383 | .. _pandoc: http://johnmacfarlane.net/pandoc | |
433 | .. _Tornado: http://www.tornadoweb.org |
|
384 | .. _Tornado: http://www.tornadoweb.org | |
434 | .. _MathJax: http://www.mathjax.org |
|
385 | .. _MathJax: http://www.mathjax.org | |
|
386 | .. _PyQt: http://www.riverbankcomputing.com/software/pyqt/intro | |||
|
387 | .. _PySide: http://qt-project.org/wiki/PySide | |||
|
388 | .. _jinja2: http://jinja.pocoo.org/ | |||
|
389 | .. _mistune: https://github.com/lepture/mistune | |||
|
390 | .. _jsonschema: https://github.com/Julian/jsonschema | |||
|
391 | .. _terminado: https://github.com/takluyver/terminado No newline at end of file |
General Comments 0
You need to be logged in to leave comments.
Login now