title: Conda
date: 2023-12-23
status: DONE
tags:
- Conda
- NOTE
author:
- AllenYGY
created: 2023-12-23T02:12
updated: 2024-05-10T22:35
publish: True
Conda
conda config --add channels [url]
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main/
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud//pytorch/
conda config --set show_channel_urls yes
conda create -n [EnvName] python=[Version]
conda create -n TEST python=3.8
conda activate [EnvName]
conda deactivate
conda env list
conda env remove -n [EnvName]
Jupyter
环境conda install jupyter
# 创建数据分析环境
conda create -n data_analysis python=3.9
# 激活环境
conda activate data_analysis
# 安装常用的数据分析库
conda install numpy pandas matplotlib seaborn scikit-learn jupyter
# 安装其他有用的数据分析工具
conda install -c conda-forge jupyterlab ipython statsmodels
conda create -n Causality python -y
conda activate Causality
conda install numpy pandas matplotlib seaborn scikit-learn jupyter -y
conda install -c conda-forge dowhy -y
# 创建深度学习环境
conda create -n deep_learning python=3.9
# 激活环境
conda activate deep_learning
# 安装 TensorFlow
conda install tensorflow
# 安装 PyTorch
conda install pytorch torchvision torchaudio cpuonly -c pytorch
# 安装其他常用的深度学习库
conda install -c conda-forge keras matplotlib pandas scikit-learn jupyter
# 创建计算机视觉环境
conda create -n computer_vision python=3.9
# 激活环境
conda activate computer_vision
# 安装 OpenCV
conda install -c conda-forge opencv
# 安装其他常用的计算机视觉库
conda install numpy matplotlib scikit-learn jupyter
# 安装深度学习库(用于计算机视觉任务)
conda install tensorflow pytorch torchvision torchaudio cpuonly -c pytorch
# 安装图像处理库
conda install scikit-image pillow
# 创建 NLP 环境
conda create -n nlp python=3.9
# 激活环境
conda activate nlp
# 安装常用的 NLP 库
conda install -c conda-forge spacy nltk gensim
# 安装深度学习库
conda install snownlp tensorflow pytorch torchvision torchaudio cpuonly -c pytorch
# 安装其他有用的库
conda install pandas scikit-learn matplotlib
# 安装 transformers 库(用于预训练模型)
pip install transformers
# 安装 jupyter 和 jupyterlab
conda install -c conda-forge jupyter jupyterlab
# 下载和安装 spaCy 语言模型(例如 en_core_web_sm)
python -m spacy download en_core_web_sm
conda create -n bioinfo_r_env r-base r-essentials