Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -34,13 +34,13 @@ def process(model_path ,prompt, num_samples, image_resolution, sample_steps, see
|
|
34 |
os.mkdir(output_path)
|
35 |
assert os.path.exists(output_path)
|
36 |
|
37 |
-
run_format = './bin/sd -m {} --sampling-method "dpm++2mv2" -o "{}/{}.png" -p "{}" --steps {} -H {} -W {}'
|
38 |
images = []
|
39 |
for i in range(num_samples):
|
40 |
uid = str(uuid1())
|
41 |
run_cmd = run_format.format(model_path, output_path,
|
42 |
uid, prompt, sample_steps, image_resolution,
|
43 |
-
image_resolution)
|
44 |
print("run cmd: {}".format(run_cmd))
|
45 |
os.system(run_cmd)
|
46 |
assert os.path.exists(os.path.join(output_path, "{}.png".format(uid)))
|
|
|
34 |
os.mkdir(output_path)
|
35 |
assert os.path.exists(output_path)
|
36 |
|
37 |
+
run_format = './bin/sd -m {} --sampling-method "dpm++2mv2" -o "{}/{}.png" -p "{}" --steps {} -H {} -W {} -s {}'
|
38 |
images = []
|
39 |
for i in range(num_samples):
|
40 |
uid = str(uuid1())
|
41 |
run_cmd = run_format.format(model_path, output_path,
|
42 |
uid, prompt, sample_steps, image_resolution,
|
43 |
+
image_resolution, seed + i)
|
44 |
print("run cmd: {}".format(run_cmd))
|
45 |
os.system(run_cmd)
|
46 |
assert os.path.exists(os.path.join(output_path, "{}.png".format(uid)))
|