본문 바로가기
작업/Linux, etc

Jupyter Notebook에 Kernel 추가

728x90

 

Python 개발 과정에서 사용하던 Interpreter를 Jupyter Notebook의 Kernel로 추가하여 사용할 수 있습니다.

 

1. Kernel로 추가할 Python.exe를 선택.

본 글에서는 "C:\Users\phant\anaconda3\python.exe"를 Kernel로 추가하겠습니다.

 

2. CMD 열기 후 Kernel 등록을 위한 패키지 설치.

"C:\Users\phant\anaconda3\python.exe" -m pip install ipykernel

 

3. Kernel 등록.

"C:\Users\phant\anaconda3\python.exe" -m ipykernel install --user --name anaconda3_python3 --display-name "Python3.12 (anaconda3)"

 

"C:\Users\phant\anaconda3\python.exe" -m : Kernel로 등록할 Python Interpreter에 명령을 수행.

ipykernel install : Jupyter에서 사용하는 Python Kernel module인 ipykernel 명령

--user : 현재 사용자 계정에만 Kernel을 설치.

--name : Jupyter 내부에서 사용하는 식별 목적의 이름 ('anaconda3_python3').

--display-name : Jupyter Notebook에서 사용(선택) 시 표시되는 이름 ('Python3.12 (anaconda3)').

 

 

4. Jupyter Notebook에서 Kernel 선택 확인.

Kernel 옵션 -> Change Kernel...

 

 

추가된 Interpreter 확인

 

728x90