# 环境安装 **Repository Path**: BadeSummer/environmental-installation ## Basic Information - **Project Name**: 环境安装 - **Description**: No description available - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2024-04-23 - **Last Updated**: 2024-04-23 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README #### 安装`python=3.7.5`环境,-n后面的参数是名字,可以随意换 ```shell conda create -n py375 python=3.7.5 ``` #### 激活环境 ```shell conda activate py375 ``` #### 安装第三方库 ```shell pip install opencv-python==4.1.2.30 opencv-contrib-python==4.1.2.30 pillow==6.2.1 numpy==1.17.4 pytorch==1.2.0 matplotlib==3.1.2 jupyter -i https://pypi.tuna.tsinghua.edu.cn/simple ``` #### 根据需要安装pytorch,三选1即可(官网:https://pytorch.org/) ```shell # CUDA 10.0 pip install torch==1.2.0 torchvision==0.4.0 # CUDA 9.2 pip install torch==1.2.0+cu92 torchvision==0.4.0+cu92 -f https://download.pytorch.org/whl/torch_stable.html # CPU only pip install torch==1.2.0+cpu torchvision==0.4.0+cpu -f https://download.pytorch.org/whl/torch_stable.html ```