-
miniconda 및 jupyter 설치환경구축 2023. 10. 11. 01:02
1. conda vs miniconda
설치할때 약간 고민되는데
나의 경우는 내가 어떤 s/w를 설치해야하는지 알아야 하기도하고
버전에 따라서 안되는 경우도 존재해서 mini conda 가 좋은 것 같음.
그리고 용량도 작음.
https://docs.conda.io/projects/miniconda/en/latest/index.html
Miniconda — miniconda documentation
These three commands quickly and quietly install the latest 64-bit version of the installer and then clean up after themselves. To install a different version or architecture of Miniconda for Windows, change the name of the .exe installer in the curl comma
docs.conda.io
리눅스인 경우 아래 코드로 바로 설치할 수 있음.
mkdir -p ~/miniconda3 wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh -O ~/miniconda3/miniconda.sh bash ~/miniconda3/miniconda.sh -b -u -p ~/miniconda3 rm -rf ~/miniconda3/miniconda.sh
1.1 알아두면 좋은 conda 명령어
// 콘다 환경 확인
conda env list
// 설치된 파일 모듈 확인
conda list
// 콘다 새로운 환경 만들기
conda create -n [가상환경명] python=3.x -y
ex) conda create -n openmmlab python-3.8 -y
// bashrc 설정하기
conda init
치면 ~/.bashrc 에 아래 코드 자동으로 설정됨.
# >>> conda initialize >>> # !! Contents within this block are managed by 'conda init' !! __conda_setup="$('/home/joo/miniconda3/bin/conda' 'shell.bash' 'hook' 2> /dev/null)" if [ $? -eq 0 ]; then eval "$__conda_setup" else if [ -f "/home/joo/miniconda3/etc/profile.d/conda.sh" ]; then . "/home/joo/miniconda3/etc/profile.d/conda.sh" else export PATH="/home/joo/miniconda3/bin:$PATH" fi fi unset __conda_setup # <<< conda initialize <<<
2. jupyter notebook
jupyter notebook을 별로 좋아하지 않음. 그러나 요즘 많은 예제가 jupyter notebook형태로 제공되기 때문에 설치함.
conda activate openmmlab pip install jupyter notebook // python -m ipykernel install --user --name [가상환경명] python -m ipykernel install --user --name openmmlab
반응형'환경구축' 카테고리의 다른 글
pip install opencv-python 설치해도 잘 안될 때 (0) 2023.10.27 ubuntu22.04에서 화면캡쳐 side bar에 고정 시키기 (0) 2023.10.27 ubuntu 설치시 검은 화면이 나올때 (0) 2023.10.10 cuda 설치 및 pytorch 설치 (0) 2023.10.10 리눅스에서 MAC 키보드 사용할때 function키 기본으로 사용하기 (0) 2023.09.03