Luo-Yihong
commited on
Commit
•
b25d8b2
1
Parent(s):
7422ed6
Update README.md
Browse files
README.md
CHANGED
@@ -29,8 +29,9 @@ steps = 1
|
|
29 |
bs = 1
|
30 |
latents = ... # maybe some latent codes of real images or SD generation
|
31 |
latent_mean = latent.mean(dim=0)
|
|
|
32 |
noise = torch.randn([1,bs,64,64])
|
33 |
-
input_latent = pipeline.scheduler.add_noise(
|
34 |
imgs= pipeline(prompt="A photo of a dog",
|
35 |
num_inference_steps=steps,
|
36 |
num_images_per_prompt = 1,
|
|
|
29 |
bs = 1
|
30 |
latents = ... # maybe some latent codes of real images or SD generation
|
31 |
latent_mean = latent.mean(dim=0)
|
32 |
+
init_latent = latent_mean.repeat(bs,1,1,1) + latents.std()*torch.randn_like(latents)
|
33 |
noise = torch.randn([1,bs,64,64])
|
34 |
+
input_latent = pipeline.scheduler.add_noise(init_latent,noise,T)
|
35 |
imgs= pipeline(prompt="A photo of a dog",
|
36 |
num_inference_steps=steps,
|
37 |
num_images_per_prompt = 1,
|