make open clip available for use with dalle2 pytorch

This commit is contained in:
Phil Wang
2022-07-30 09:02:31 -07:00
parent 87432e93ad
commit f22e8c8741
3 changed files with 82 additions and 1 deletions

View File

@@ -627,6 +627,18 @@ images = dalle2(
# save your image (in this example, of size 256x256)
```
Alternatively, you can also use <a href="https://github.com/mlfoundations/open_clip">Open Clip</a>
```bash
$ pip install open-clip-torch
```
```python
from dalle2_pytorch import OpenClipAdapter
clip = OpenClipAdapter()
```
Now you'll just have to worry about training the Prior and the Decoder!
## Inpainting