Update use_cpu using UI on Redo and Double Size

This commit is contained in:
Marc-Andre Ferland 2022-10-14 12:08:22 -04:00
parent 8cb408bc6e
commit 4f5a352985

View File

@ -418,7 +418,10 @@ function getStartNewTaskHandler(reqBody, imageItemElem, mode) {
switch (mode) {
case 'img2img':
case 'img2img_X2':
newTaskRequest.reqBody = Object.assign({}, reqBody, { num_outputs: 1 })
newTaskRequest.reqBody = Object.assign({}, reqBody, {
num_outputs: 1,
use_cpu: useCPUField.checked,
})
if (!newTaskRequest.reqBody.init_image || mode === 'img2img_X2') {
newTaskRequest.reqBody.sampler = 'ddim'
newTaskRequest.reqBody.prompt_strength = '0.5'