File size: 4,455 Bytes
f603dd5
 
 
 
 
ba68075
f603dd5
 
 
ba68075
f603dd5
ba68075
f603dd5
 
ba68075
 
 
 
 
 
f603dd5
 
 
 
 
 
 
 
 
 
 
 
 
ba68075
f603dd5
 
 
ba68075
f603dd5
 
 
 
8af7efa
7ef3ec7
 
f2533a6
 
 
 
 
 
7ef3ec7
 
f2533a6
 
 
 
 
 
 
7ef3ec7
f2533a6
 
 
 
f603dd5
 
 
 
 
 
 
 
 
 
 
ba68075
f603dd5
ba68075
f603dd5
 
 
 
ba68075
 
f603dd5
 
 
 
 
 
 
 
 
 
 
ba68075
564f574
 
 
 
f603dd5
 
 
 
564f574
 
 
 
723717b
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
---
library_name: diffusers
license: apache-2.0
language:
- ja
pipeline_tag: image-to-image
tags:
- stable-diffusion
---
# ๐ŸŸ Evo-Nishikie-v1

๐Ÿค— [Models](https://huggingface.co/SakanaAI) | ๐Ÿ“ [Blog](https://sakana.ai/evo-ukiyoe/) | ๐Ÿฆ [Twitter](https://twitter.com/SakanaAILabs)


**Evo-Nishikie-v1** is an experimental education-purpose Ukiyoe colorization model. The model is a ControlNet trained with [Evo-Ukiyoe](https://huggingface.co/SakanaAI/Evo-Ukiyoe-v1/). 
The dataset used to train the model came from Ukiyoe images belonged to [Ritsumeikan University, Art Research Center](https://www.arc.ritsumei.ac.jp/). The sample data is belonged to the [Pre-Modern Japanese Text dataset](http://codh.rois.ac.jp/pmjt/), 
owned by [National Institute of Japanese Literature](https://www.nijl.ac.jp/en/) and curated by [ROIS-DS Center for Open Data in the Humanities](http://codh.rois.ac.jp/).


Please refer to our [blog](https://sakana.ai/evo-ukiyoe/) for more details. 



## Usage

Use the code below to get started with the model.


<details>
<summary> Click to expand </summary>

1. Git clone this model card
   ```
   git clone https://huggingface.co/SakanaAI/Evo-Nishikie-v1
   ```
2. Install packages
   ```
   cd Evo-Nishikie-v1
   pip install -r requirements.txt
   ```
3. Run
   ```python
   from io import BytesIO
   from PIL import Image
   import requests
   from evo_nishikie_v1 import load_evo_nishikie
   
   url = "https://huggingface.co/spaces/SakanaAI/Evo-Nishikie/resolve/main/sample2.jpg"
   original_image = Image.open(BytesIO(requests.get(url).content))

   # Generate
   device = "cuda"
   pipe, processor = load_evo_nishikie(device)
   images = pipe(
        prompt="็€็‰ฉใ‚’็€ใŸๅฅณๆ€งใŒใ€่ตคใ‚“ๅŠใ‚’ๆŠฑใˆใ€ใ‚‚ใ†ไธ€ไบบใฎๅญใฉใ‚‚ใŒๆ‰‹ๆŠผใ—่ปŠใ‚’ๅผ•ใ„ใฆใ„ใพใ™ใ€‚่ƒŒๆ™ฏใซใฏๆœจใŒใ‚ใ‚Šใพใ™ใ€‚ๆœ€้ซ˜ๅ“่ณชใฎ่ผปใฎๆตฎไธ–็ตตใ€‚่ถ…่ฉณ็ดฐใ€‚",
        negative_prompt="ๆš—ใ„",
        image=processor(original_image),
        guidance_scale=7.0,
        controlnet_conditioning_scale=0.8,
        num_inference_steps=50,
        generator=torch.Generator(device).manual_seed(0),
        num_images_per_prompt=1,
        output_type="pil",
   ).images
   images[0].save("out.png")
   ```

</details>


 
## Model Details

<!-- Provide a longer summary of what this model is. -->

- **Developed by:** [Sakana AI](https://sakana.ai/)
- **Model type:** Diffusion-based image-to-image generative model
- **Language(s):** Japanese
- **Blog:** https://sakana.ai/evo-ukiyoe


## License
The Python script included in this repository is licensed under the [Apache License 2.0](https://www.apache.org/licenses/LICENSE-2.0).
Please note that the license for the model/pipeline generated by this script is inherited from the source models. 
The sample images used in the code has CC BY SA 4.0 license and is belonged to the Pre-Modern Japanese Text dataset, owned by National Institute of Japanese Literature and curated by ROIS-DS Center for Open Data in the Humanities.

## Uses
This model is provided for research and development purposes only and should be considered as an experimental prototype. 
It is not intended for commercial use or deployment in mission-critical environments. 
Use of this model is at the user's own risk, and its performance and outcomes are not guaranteed. 
Sakana AI shall not be liable for any direct, indirect, special, incidental, or consequential damages, or any loss arising from the use of this model, regardless of the results obtained. 
Users must fully understand the risks associated with the use of this model and use it at their own discretion.


## Acknowledgement

Evo-Nishikie was trained based on Evo-Ukiyoe and Evo-Ukiyoe was trained based on Evo-SDXL-JP. We would like to thank the developers of Evo-SDXL-JP source models for their contributions and for making their work available.
- [SDXL](https://huggingface.co/stabilityai/stable-diffusion-xl-base-1.0)
- [Juggernaut-XL-v9](https://huggingface.co/RunDiffusion/Juggernaut-XL-v9)
- [SDXL-DPO](https://huggingface.co/mhdang/dpo-sdxl-text2image-v1)
- [JSDXL](https://huggingface.co/stabilityai/japanese-stable-diffusion-xl)


## Citation

    @misc{Evo-Ukiyoe, 
    url    = {[https://huggingface.co/SakanaAI/Evo-Nishikie-v1](https://huggingface.co/SakanaAI/Evo-Nishikie-v1)}, 
    title  = {Evo-Nishikie}, 
    author = {Clanuwat, Tarin and Shing, Makoto and Imajuku, Yuki and Kitamoto, Asanobu and Akama, Ryo}
    }