Instructions to use bardofcodes/pattern_analogies with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use bardofcodes/pattern_analogies with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline from diffusers.utils import load_image # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("bardofcodes/pattern_analogies", dtype=torch.bfloat16, device_map="cuda") prompt = "Turn this cat into a dog" input_image = load_image("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/cat.png") image = pipe(image=input_image, prompt=prompt).images[0] - Notebooks
- Google Colab
- Kaggle
Update README.md
Browse files
README.md
CHANGED
|
@@ -57,6 +57,8 @@ You can use the model with the [🧨Diffusers library](https://github.com/huggin
|
|
| 57 |
### PatternAnalogiesTrifuser
|
| 58 |
|
| 59 |
This repository contains example inputs to demonstrate the model's capabilities. Please change `EXAMPLE_ID` from 0-9 to check out the different examples.
|
|
|
|
|
|
|
| 60 |
|
| 61 |
```py
|
| 62 |
import requests
|
|
|
|
| 57 |
### PatternAnalogiesTrifuser
|
| 58 |
|
| 59 |
This repository contains example inputs to demonstrate the model's capabilities. Please change `EXAMPLE_ID` from 0-9 to check out the different examples.
|
| 60 |
+
Please first clone our repository: https://github.com/adobe-research/pattern-analogies and add it to the path path (as shown below).
|
| 61 |
+
This is a temporary fix until we figure out how to make diffusers custom pipeline with custom modules work directly.
|
| 62 |
|
| 63 |
```py
|
| 64 |
import requests
|