Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -87,9 +87,12 @@ def main():
|
|
87 |
# gaussian=gaussian_radius,
|
88 |
log_visual_freq=1000,
|
89 |
input='text',
|
90 |
-
))
|
91 |
device = th.device()
|
92 |
generator = create_generator("stylegan2-ffhq-config-f.pt","feng2022/Time-TravelRephotography_stylegan2-ffhq-config-f",args, device)
|
|
|
|
|
|
|
93 |
iface = gr.Interface(
|
94 |
fn=predict,
|
95 |
inputs='text',
|
|
|
87 |
# gaussian=gaussian_radius,
|
88 |
log_visual_freq=1000,
|
89 |
input='text',
|
90 |
+
))
|
91 |
device = th.device()
|
92 |
generator = create_generator("stylegan2-ffhq-config-f.pt","feng2022/Time-TravelRephotography_stylegan2-ffhq-config-f",args, device)
|
93 |
+
latent = torch.randn((1, 512), device=device)
|
94 |
+
img_out, _, _ = generator([latent])
|
95 |
+
imgs_arr = make_image(img_out)
|
96 |
iface = gr.Interface(
|
97 |
fn=predict,
|
98 |
inputs='text',
|