Browse Source

Don't send the "Random seed after every gen" field in the prompt.

pull/17/head
comfyanonymous 2 years ago
parent
commit
a37b41e84c
  1. 1
      script_examples/basic_api_example.py
  2. 10
      webshit/index.html

1
script_examples/basic_api_example.py

@ -30,7 +30,6 @@ prompt_text = """
"6",
0
],
"Random seed after every gen": true,
"sampler_name": "sample_euler",
"scheduler": "normal",
"seed": 8566257,

10
webshit/index.html

@ -350,10 +350,12 @@ function graphToPrompt() {
}
for (let y in n.widgets) {
if (n.widgets[y].dynamic_prompt && n.widgets[y].dynamic_prompt === true) {
input_[n.widgets[y].name] = n.widgets[y].value.replace("\\{", "{").replace("\\}", "}");
} else {
input_[n.widgets[y].name] = n.widgets[y].value;
if (!Object.hasOwn(n.widgets[y], 'to_randomize')) { //don't include "Random seed after every gen" in prompt.
if (n.widgets[y].dynamic_prompt && n.widgets[y].dynamic_prompt === true) {
input_[n.widgets[y].name] = n.widgets[y].value.replace("\\{", "{").replace("\\}", "}");
} else {
input_[n.widgets[y].name] = n.widgets[y].value;
}
}
}
for (let y in n.inputs) {

Loading…
Cancel
Save