ShineChen1024 commited on
Commit
2128b98
1 Parent(s): 67658b2

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +5 -5
README.md CHANGED
@@ -9,12 +9,12 @@ This is the beta version of MiaoBi, a chinese text-to-image model, following the
9
  ## Diffusers
10
  ```py
11
  from diffusers import StableDiffusionPipeline
12
- import torch
13
- model_id = "AIXI-AIGC/miaobi"
14
- pipe = StableDiffusionPipeline.from_pretrained(model_id, torch_dtype=torch.float16)
15
- pipe = pipe.to("cuda")
16
  prompt = "一只穿着铠甲的猫"
17
- image = pipe(prompt).images[0]
18
  image.save("铠甲猫.png")
19
  ```
20
 
 
9
  ## Diffusers
10
  ```py
11
  from diffusers import StableDiffusionPipeline
12
+ from transformers import AutoTokenizer
13
+ tokenizer = AutoTokenizer.from_pretrained("checkpoints/miaobi_beta0.9/tokenizer", trust_remote_code=True)
14
+ pipe = StableDiffusionPipeline.from_pretrained("checkpoints/miaobi_beta0.9")
15
+ pipe.to("cuda")
16
  prompt = "一只穿着铠甲的猫"
17
+ image = pipe(prompt).images[0]
18
  image.save("铠甲猫.png")
19
  ```
20