Update README.md

This commit is contained in:
boba_and_beer 2021-01-27 01:11:41 +11:00 committed by GitHub
parent ab1686a681
commit d960552677
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 4 deletions

View File

@ -17,11 +17,12 @@ CLIP (Contrastive Language-Image Pre-Training) is a neural network trained on a
First, [install PyTorch 1.7.1](https://pytorch.org/get-started/locally/) and torchvision, as well as small additional dependencies. On a CUDA GPU machine, the following will do the trick:
```bash
$ conda install --yes -c pytorch pytorch=1.7.1 torchvision cudatoolkit=11.0
$ pip install ftfy regex tqdm
$ pip install clip-by-openai
```
Or if you want cuda installation:
```bash
$ pip install clip-by-openai[cuda]
```
Replace `cudatoolkit=11.0` above with the appropriate CUDA version on your machine or `cpuonly` when installing on a machine without a GPU.
```python
import torch