Outils pour utilisateurs

Outils du site


tech:install-ipython3

Différences

Ci-dessous, les différences entre deux révisions de la page.

Lien vers cette vue comparative

Prochaine révision
Révision précédente
tech:install-ipython3 [2025/03/24 15:06] – créée - modification externe 127.0.0.1tech:install-ipython3 [2025/05/14 03:22] (Version actuelle) Jean-Baptiste
Ligne 1: Ligne 1:
-{{tag>Python Ipython Console}}+<!DOCTYPE markdown> 
 +{{tag>Python Ipython Console FIXME}}
  
-Install IPython+Install IPython
  
 Voir aussi : Voir aussi :
-* bpython +  * bpython 
-* ptpython +  * ptpython 
-* xonsh+  [[Notes xonsh - le shell Python]]
  
 +Voir aussi :
 +  * Scilab
 +  * SageMath
 +  * Matlab
  
  
-== Debian+## Debian
  
 Install Install
-<code bash>+~~~bash
 #python3 -m pip install --user ipython #python3 -m pip install --user ipython
 sudo apt-get install python3-ipython sudo apt-get install python3-ipython
-</code>+~~~
  
 Lancement Lancement
-<code bash>+~~~bash
 python3 -m IPython python3 -m IPython
-</code>+~~~
  
 ou ou
  
-<file python /usr/bin/ipython3>+''/usr/bin/ipython3'' 
 +~~~python
 #!/usr/bin/python3 #!/usr/bin/python3
 # -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
Ligne 34: Ligne 40:
     sys.argv[0] = re.sub(r"(-script\.pyw|\.exe)?$", "", sys.argv[0])     sys.argv[0] = re.sub(r"(-script\.pyw|\.exe)?$", "", sys.argv[0])
     sys.exit(start_ipython())     sys.exit(start_ipython())
-</file>+~~~
  
  
 Alias Alias
-<code bash ~/.bashrc>+ 
 +''~/.bashrc'' 
 +~~~bash
 #export PATH="$PATH:$HOME/.local/bin" #export PATH="$PATH:$HOME/.local/bin"
 alias ipython='python3 -m IPython' alias ipython='python3 -m IPython'
-</code>+~~~
  
  
  
  
-== Docker-compose 
  
-Password less. 
  
-<code yaml docker-compose.yml> 
-version: '3.7' 
-services: 
-  ipython: 
-    image: jupyter/base-notebook 
-    restart: unless-stopped 
-    # Warning : No password ! 
-    command: ["start-notebook.sh", "--NotebookApp.token=''","--NotebookApp.password=''"] 
-    environment: 
-      GRANT_SUDO: "no" 
-    user: root 
-    ports: 
-      - '127.0.0.1:8083:8888' 
-    volumes: 
-      - ipython_work:/home/jovyan/work 
-    networks: 
-      - ipython-net 
  
-networks: 
-  ipython-net: 
-    name: ipython-net 
  
-volumes: +## Old
-  ipython_work:+
  
-</code> +### Install de ipython sur Debian Wheezy :
- +
-== Install iPython sur Android Termux +
- +
-<code bash> +
-pkg update +
-pkg upgrade +
-pip install --user ipython +
-</code> +
- +
-== Old +
- +
-== 1) Install de ipython sur Debian Wheezy :+
  
 Install ''ipython3 --pylab'' Install ''ipython3 --pylab''
Ligne 95: Ligne 68:
 https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=690906 https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=690906
  
-<code bash>+~~~bash
 apt-get install python3-pip python3-numpy python3-scipy apt-get install python3-pip python3-numpy python3-scipy
 apt-get build-dep python-matplotlib apt-get build-dep python-matplotlib
-</code>+~~~
  
-Puis sous le compte de l'utilisateur voulant executer ''ipython3 --pylab'' 
  
-<code bash>+ 
 +Puis sous le compte de l'utilisateur voulant exécuter ''ipython3 --pylab'' 
 + 
 +~~~bash
 pip-3.2 install --user matplotlib pip-3.2 install --user matplotlib
-</code>+~~~ 
 + 
  
-== 2) Install de IPython3 Notebook 
  
-http://www.scipy.org/install.html+### Install de IPython3 Notebook
  
-http://ipython.org/ipython-doc/stable/install/install.html 
  
-http://www.math.univ-paris13.fr/~cuvelier/mainsu23.html+Voir : 
 +  * http://www.scipy.org/install.htm 
 +  * http://ipython.org/ipython-doc/stable/install/install.html 
 +  * http://www.math.univ-paris13.fr/~cuvelier/mainsu23.html
  
 En root : En root :
  
-<code bash>+~~~bash
 apt-get install ipython3 ipython-qtconsole ipython3-notebook  apt-get install ipython3 ipython-qtconsole ipython3-notebook 
 apt-get install python3-scipy python3-matplotlib python3-numpy apt-get install python3-scipy python3-matplotlib python3-numpy
 apt-get install pandoc python3-tk python3-pandas python3-pip python3-nose python3-zmq python-pygments python3-jinja2 fonts-mathjax libjs-mathjax apt-get install pandoc python3-tk python3-pandas python3-pip python3-nose python3-zmq python-pygments python3-jinja2 fonts-mathjax libjs-mathjax
 apt-get install python3-cairo python3-gi python3-gobject python3-pyqt4 python3-scipy python3-sip tix python3-tk-dbg apt-get install python3-cairo python3-gi python3-gobject python3-pyqt4 python3-scipy python3-sip tix python3-tk-dbg
-</code>+~~~
  
 Install de sympy Install de sympy
  
-<code bash>+~~~bash
 sudo apt-get install python3-mpmath sudo apt-get install python3-mpmath
 pip3 install --user sympy pip3 install --user sympy
-</code>+~~~
  
 Puis Puis
 ipython3 ipython3
  
-<code python>+~~~python
 from pylab import * from pylab import *
-</code>+~~~
  
-<code bash>+ 
 +~~~bash
 ipython3 notebook --pylab=inline --no-browser --profile=notebook ipython3 notebook --pylab=inline --no-browser --profile=notebook
-</code> +~~~
- +
- +
- +
- +
- +
-J'ai eu me même pb : +
-http://stackoverflow.com/questions/22665809/how-to-configure-ipython-behind-nginx-in-a-subpath +
- +
-<code nginx> +
-server { +
-        listen 80; +
-        root /usr/share/nginx/www; +
-        index index.html index.htm index.php ; +
- +
-        server_name notebook.mondomain.fr ; +
- +
-        error_log /var/log/nginx/error-notebook.log; +
- +
- +
-    location / { +
-        proxy_pass http://localhost:5001; +
- +
-        proxy_set_header X-Real-IP $remote_addr; +
-        proxy_set_header Host $host; +
-        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; +
- +
-        proxy_set_header X-NginX-Proxy true; +
- +
-        # WebSocket support +
-        proxy_http_version 1.1; +
-        proxy_set_header Upgrade $http_upgrade; +
-        proxy_set_header Connection "upgrade"; +
-        proxy_read_timeout 86400; +
-    } +
- +
-    location ^/static/ { +
-        alias /usr/share/ipython/notebook/static/; +
-    } +
-+
-</code> +
- +
-<code bash> +
-cd +
-mkdir books +
- +
- +
-$ vim ipython_notebook_config.py +
-</code> +
- +
-<code ini> +
-c = get_config() +
- +
-c.IPKernelApp.pylab = 'inline'  # if you want plotting support always +
-c.NotebookApp.open_browser = False +
-c.NotebookApp.port = 5001 +
-</code>+
  
  
-<code bash> 
-vi /etc/cron.allow 
-crontab -e 
-@reboot cd ${HOME}/books ; ipython3 notebook --pylab=inline --no-browser --profile=notebook >${HOME}/notebook.log 2>${HOME}/notebook.err 
-</code> 
  
  
tech/install-ipython3.1742825205.txt.gz · Dernière modification : de 127.0.0.1

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki