Cov txheej txheem:

Koj puas tuaj yeem pip nruab hauv Jupyter phau ntawv?
Koj puas tuaj yeem pip nruab hauv Jupyter phau ntawv?

Video: Koj puas tuaj yeem pip nruab hauv Jupyter phau ntawv?

Video: Koj puas tuaj yeem pip nruab hauv Jupyter phau ntawv?
Video: Installing Jupyter Notebook on Ubuntu! 2024, Kaum ib hlis
Anonim

Cov! qhia cov phau ntawv mus tua lub cell raws li lub plhaub hais kom ua. Hauv IPython ( jupyter 7.3 thiab tom qab ntawd, muaj cov khawv koob % pib thiab %conda hais kom ua yuav nruab nyob rau hauv lub kernel tam sim no (tsis yog rau hauv piv txwv ntawm Python uas launched lub phau ntawv ).

Ib yam li ntawd, koj tuaj yeem nug, Kuv puas tuaj yeem siv PIP hauv Jupyter phau ntawv?

Yog tias conda qhia koj lub pob koj xav tau tsis muaj, ces siv pip (los yog sim conda-forge, uas muaj ntau pob khoom muaj tshaj li qhov default conda channel). Yog tias koj tau teeb tsa Python lwm txoj hauv kev (los ntawm qhov chaw, siv pyenv, virtualenv, etc.), ces siv pip rau nruab Python tej pob khoom.

Tsis tas li ntawd, kuv yuav import cov ntaub ntawv.ipynb rau hauv Jupyter phau ntawv li cas? Hauv qab no cov kauj ruam koj tuaj yeem sim, Kuv kuj tau sim thiab nws ua haujlwm:

  1. Rub tawm cov ntaub ntawv ntawd los ntawm koj phau ntawv sau hauv PY cov ntaub ntawv (Koj tuaj yeem pom qhov kev xaiv ntawd hauv File tab).
  2. Tam sim no luam cov ntaub ntawv rub tawm mus rau hauv phau ntawv ua haujlwm ntawm Jupyter Notebook.
  3. Tam sim no koj npaj siv nws. Tsuas yog import. PY File rau hauv cov ntaub ntawv ipynb.

Ua li no, kuv yuav hloov kho PIP li cas hauv Jupyter phau ntawv?

Siv pip nruab phau ntawv -- upgrade lub conda upgrade phau ntawv rau upgrade mus rau qhov tseeb tso tawm. Peb pom zoo kom koj upgrade pib mus rau version 9+ ntawm pib ua ntej hloov kho phau ntawv . Siv pib install pip -- upgrade rau upgrade pib . Tshawb xyuas pib version nrog pib --version.

Kuv yuav nruab Jupyter phau ntawv li cas?

Siv cov kauj ruam hauv qab no installation:

  1. Download tau Anaconda. Peb pom zoo kom rub tawm Anaconda qhov tseeb Python 3 version (tam sim no Python 3.7).
  2. Nruab lub version ntawm Anaconda uas koj rub tawm, ua raws cov lus qhia ntawm nplooj ntawv rub tawm.
  3. Nrog koj zoo siab, koj tau nruab Jupyter Notebook. Txhawm rau khiav lub phau ntawv:

Pom zoo: