File size: 1,533 Bytes
d2bc429
 
 
 
 
 
b7480fc
fb42d13
ab56f94
f5c416e
fb42d13
8441a16
ab56f94
8441a16
ab56f94
fb42d13
8441a16
 
 
 
 
 
 
 
ab56f94
 
8441a16
ab56f94
 
 
8441a16
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
fb42d13
 
 
 
 
 
 
 
 
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
---
# For reference on model card metadata, see the spec: https://github.com/huggingface/hub-docs/blob/main/modelcard.md?plain=1
# Doc / guide: https://huggingface.co/docs/hub/model-cards
{}
---

# LoRA model of the Genshin Characters
## Data source
Manually captured 64 characters at different angles in the character directory of the Genshin game, 20 pictures for each character.

## Train
Training code: [lora-scripts](https://github.com/Akegarasu/lora-scripts).

Batch training code: [batch_train_loras](https://github.com/RobertLau666/batch_train_loras).

## Usage
prompt: 
```txt
1[Gender], solo, [EN_Name], [Arbitrary scene description]
```
For example:
```txt
"1girl, solo, Nahida, on the playground
```

Negative prompt (You can choose the following three ways):
```txt
1. \
2. (((NSFW))),poorly drawn, anatomical nonsense, bad anatomy, bad feet, bad hands, bad proportions, quality
3. (worst quality, low quality:1.4), (monochrome:1.1), turn pale, text, watermark
```

```python
from diffusers import StableDiffusionPipeline
import torch

model_id = "ckpt/anything-v3.0"
pipe = StableDiffusionPipeline.from_pretrained(model_id, torch_dtype=torch.float16)

lora_file = "Nahida.safetensors"
pipe.load_lora_weights(lora_file)
pipe = pipe.to("cuda")

prompt = "1girl, Nahida, solo, on the playground"
image = pipe(prompt).images[0]
image.save("./hatsune_miku.png")
```

## Result
```txt
Gender: girl
EN_Name: Nahida, YaeMiko, Ganyu
Arbitrary scene description: on the playground, in the classroom
```
![combined](combined.webp)