Instructions to use Pensioner/LightShift with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use Pensioner/LightShift 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("Pensioner/LightShift", 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
Add model card
Browse files
README.md
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: apache-2.0
|
| 3 |
+
library_name: diffusers
|
| 4 |
+
tags:
|
| 5 |
+
- relighting
|
| 6 |
+
- indoor
|
| 7 |
+
- video-diffusion
|
| 8 |
+
base_model: stabilityai/stable-video-diffusion-img2vid-xt
|
| 9 |
+
pipeline_tag: image-to-image
|
| 10 |
+
---
|
| 11 |
+
|
| 12 |
+
# LightShift
|
| 13 |
+
|
| 14 |
+
**LightShift: Controllable Indoor Relighting via Video Diffusion Priors**
|
| 15 |
+
|
| 16 |
+
This repository contains the fine-tuned UNet checkpoint for LightShift, a controllable indoor relighting method that repurposes Stable Video Diffusion for image-based relighting.
|
| 17 |
+
|
| 18 |
+
## Usage
|
| 19 |
+
|
| 20 |
+
This checkpoint is compatible with the [Diffusers](https://github.com/huggingface/diffusers) library. See the code and inference scripts at [Pensioner-11/LightShift](https://github.com/Pensioner-11/LightShift).
|
| 21 |
+
|
| 22 |
+
```python
|
| 23 |
+
from diffusers import StableVideoDiffusionPipeline
|
| 24 |
+
|
| 25 |
+
pipe = StableVideoDiffusionPipeline.from_pretrained(
|
| 26 |
+
"Pensioner/LightShift",
|
| 27 |
+
torch_dtype=torch.float16,
|
| 28 |
+
).to("cuda")
|
| 29 |
+
```
|
| 30 |
+
|
| 31 |
+
## Model Description
|
| 32 |
+
|
| 33 |
+
- **Base model:** [stabilityai/stable-video-diffusion-img2vid-xt](https://huggingface.co/stabilityai/stable-video-diffusion-img2vid-xt)
|
| 34 |
+
- **Fine-tuned component:** UNet
|
| 35 |
+
- **Training steps:** 200,000
|
| 36 |
+
|
| 37 |
+
## Citation
|
| 38 |
+
|
| 39 |
+
Citation information will be updated after publication.
|