Spaces:
Runtime error
Runtime error
yupeng.zhou
commited on
Commit
•
4005d74
1
Parent(s):
14f69c4
fix
Browse files
app.py
CHANGED
@@ -110,7 +110,7 @@ class SpatialAttnProcessor2_0(torch.nn.Module):
|
|
110 |
encoder_hidden_states = torch.cat((self.id_bank[cur_step][0].to(self.device),hidden_states[:1],self.id_bank[cur_step][1].to(self.device),hidden_states[1:]))
|
111 |
# 判断随机数是否大于0.5
|
112 |
if cur_step <5:
|
113 |
-
hidden_states = self.__call2__(attn, hidden_states,
|
114 |
else: # 256 1024 4096
|
115 |
random_number = random.random()
|
116 |
if cur_step <20:
|
@@ -672,9 +672,9 @@ with gr.Blocks(css=css) as demo:
|
|
672 |
num_steps = gr.Slider(
|
673 |
label="Number of sample steps",
|
674 |
minimum=20,
|
675 |
-
maximum=
|
676 |
step=1,
|
677 |
-
value=
|
678 |
)
|
679 |
G_height = gr.Slider(
|
680 |
label="height",
|
|
|
110 |
encoder_hidden_states = torch.cat((self.id_bank[cur_step][0].to(self.device),hidden_states[:1],self.id_bank[cur_step][1].to(self.device),hidden_states[1:]))
|
111 |
# 判断随机数是否大于0.5
|
112 |
if cur_step <5:
|
113 |
+
hidden_states = self.__call2__(attn, hidden_states,encoder_hidden_states,attention_mask,temb)
|
114 |
else: # 256 1024 4096
|
115 |
random_number = random.random()
|
116 |
if cur_step <20:
|
|
|
672 |
num_steps = gr.Slider(
|
673 |
label="Number of sample steps",
|
674 |
minimum=20,
|
675 |
+
maximum=50,
|
676 |
step=1,
|
677 |
+
value=25,
|
678 |
)
|
679 |
G_height = gr.Slider(
|
680 |
label="height",
|