Image-to-Image
Diffusers
krea-2
krea2
anypaint
lora
inpainting
outpainting
arbitrary-mask
image-editing
Instructions to use yijunwang2/krea2-anypaint with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use yijunwang2/krea2-anypaint 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("krea/Krea-2-Turbo", dtype=torch.bfloat16, device_map="cuda") pipe.load_lora_weights("yijunwang2/krea2-anypaint") 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
- Local Apps Settings
- Draw Things
|
Download showcase/README.md from yijunwang2/krea2-anypaint: direct link, hf CLI and curl.
- Browser
- Download file 6.51 kB
-
https://huggingface.co/yijunwang2/krea2-anypaint/resolve/main/showcase/README.md
- Command line
-
hf download hf://yijunwang2/krea2-anypaint/showcase/README.md
-
curl -L -o README.md https://huggingface.co/yijunwang2/krea2-anypaint/resolve/main/showcase/README.md
6.51 kB
| # AnyPaint Showcase | |
| All sources are synthetic and use original, non-IP prompts. Every result is the first | |
| 8-step output for its recorded prompt and fixed seed; no rerolls were removed. | |
| ## 01_photo_internal - Photographic internal edit | |
| | Source | Generated mask | Result | | |
| |:---:|:---:|:---:| | |
| |  |  |  | | |
| **Prompt:** a sunlit modern kitchen interior with a handmade ceramic bowl of fresh lemons on the center island, coherent morning light, complete architectural photograph | |
| ## 02_watercolor_outpaint - Watercolor downward outpainting | |
| | Source | Generated mask | Result | | |
| |:---:|:---:|:---:| | |
| |  |  |  | | |
| **Prompt:** an original watercolor greenhouse and coastal garden, the path and flowering plants continuing naturally downward, airy washes, complete vertical composition | |
| ## 03_3d_outpaint - Stylized 3D horizontal outpainting | |
| | Source | Generated mask | Result | | |
| |:---:|:---:|:---:| | |
| |  |  |  | | |
| **Prompt:** an original retro-futuristic exploration rover crossing a colorful alien desert, distant mineral formations extending to the right, stylized 3D cinematic render | |
| ## 04_portrait_mixed - Original-character mixed edit | |
| | Source | Generated mask | Result | | |
| |:---:|:---:|:---:| | |
| |  |  |  | | |
| **Prompt:** an original adult woman with short silver hair wearing a richly textured coral coat in a spacious contemporary gallery, complete full-body fashion photograph | |
| ## 05_botanical_disconnected - Disconnected honeybee insertion | |
| | Source | Generated mask | Result | | |
| |:---:|:---:|:---:| | |
| |  |  |  | | |
| **Prompt:** an original botanical field illustration of blue and white meadow flowers with three small honeybees hovering naturally between the blossoms, delicate wings, fine paper texture, naturalistic painted details | |
| ## 07_product_narrow - Narrow cable recolor | |
| | Source | Generated mask | Result | | |
| |:---:|:---:|:---:| | |
| |  |  |  | | |
| **Prompt:** an original sculptural brushed aluminum desk lamp with a vivid orange braided power cable extending from the lamp across the tabletop, premium neutral product photography | |
| ## 08_landscape_complex - Complex semantic landscape edit | |
| | Source | Generated mask | Result | | |
| |:---:|:---:|:---:| | |
| |  |  |  | | |
| **Prompt:** an original alpine valley after rain with clusters of luminous rainbow-colored fantasy mushrooms growing along the winding riverbanks and foreground rocks, subtle magical glow reflected in wet stone, coherent wide cinematic landscape photograph | |
| ## 09_male_accessories - Male portrait accessories | |
| | Source | Generated mask | Result | | |
| |:---:|:---:|:---:| | |
| |  |  |  | | |
| **Prompt:** a realistic editorial portrait of an adult man with short dark hair wearing thin rectangular silver eyeglasses and a small silver ear cuff, plain navy shirt, coherent soft daylight and neutral studio background | |
| ## 10_female_accessories - Female disconnected accessories | |
| | Source | Generated mask | Result | | |
| |:---:|:---:|:---:| | |
| |  |  |  | | |
| **Prompt:** a polished portrait of an adult woman with shoulder-length auburn hair, a dark green enamel hair clip above her left ear and matching small geometric earrings, simple cream blouse, coherent natural daylight and pale gray studio background | |
| ## 11_product_restyle - Shoes and bag local redesign | |
| | Source | Generated mask | Result | | |
| |:---:|:---:|:---:| | |
| |  |  |  | | |
| **Prompt:** an overhead catalog photograph with a pair of deep forest-green suede sneakers on the left and a cobalt-blue structured leather shoulder bag on the right, refined minimal hardware, balanced composition, coherent soft studio shadows | |
| ## 12_desk_objects - Two desktop object insertions | |
| | Source | Generated mask | Result | | |
| |:---:|:---:|:---:| | |
| |  |  |  | | |
| **Prompt:** a clean oak writing desk in a softly lit home office with a handmade dark green ceramic mug on the left side and a small potted succulent in a matte white planter on the right, coherent restrained contemporary interior photograph | |
| ## 13_living_room_objects - Living-room multi-region insertion | |
| | Source | Generated mask | Result | | |
| |:---:|:---:|:---:| | |
| |  |  |  | | |
| **Prompt:** a bright neutral living room with a tall brushed-brass floor lamp beside the left end of the cream sofa and a round woven storage basket beside the right end, simple coffee table, coherent warm daylight and understated architectural photography | |
| ## 14_window_view - Complete window-view replacement | |
| | Source | Generated mask | Result | | |
| |:---:|:---:|:---:| | |
| |  |  |  | | |
| **Prompt:** a quiet contemporary reading room whose large central picture window overlooks a snowy mountain lake beneath a clear pale-blue winter sky, armchair in the foreground, coherent daylight, reflections and realistic interior photography | |
| ## 15_person_boundary - Boundary completion of an adult man | |
| | Source | Generated mask | Result | | |
| |:---:|:---:|:---:| | |
| |  |  |  | | |
| **Prompt:** a complete full-body photograph of an adult man wearing a charcoal field jacket, gray shirt, straight dark trousers and practical brown boots, standing naturally on a quiet railway platform in coherent soft cloudy daylight | |
| See `manifest.json` for prompts, seeds, placement, and timings. | |