提交 5c148490 编写于 作者: A Abdullah Alfaraj

Added support for `noise_seed` as an alternative name for the seed field

上级 de6f73e4
......@@ -1130,6 +1130,11 @@ function loadWorkflow2(workflow: any) {
}
)
)
store.data.is_random_seed = Object.fromEntries(
Object.keys(toJS(store.data.current_prompt2)).map((node_id: string) => {
return [node_id, false]
})
)
// parse the output nodes
// Note: we can't modify the node directly in the prompt like we do for input nodes.
......
......@@ -467,9 +467,15 @@ function runRandomSeedScript() {
0n,
18446744073709552000n
)
store.data.current_prompt2[node_id].inputs['seed'] =
random_seed.toString()
// Usage
Object.keys(store.data.current_prompt2[node_id].inputs).forEach(
(name: string) => {
if (['seed', 'noise_seed'].includes(name)) {
store.data.current_prompt2[node_id].inputs[name] =
random_seed.toString()
// Usage
}
}
)
}
}
)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册