mirror of
https://github.com/easydiffusion/easydiffusion.git
synced 2025-04-03 13:20:35 +02:00
commit
16fcb4ed79
@ -174,16 +174,22 @@ const TASK_MAPPING = {
|
|||||||
name: "Use Face Correction",
|
name: "Use Face Correction",
|
||||||
setUI: (use_face_correction) => {
|
setUI: (use_face_correction) => {
|
||||||
const oldVal = gfpganModelField.value
|
const oldVal = gfpganModelField.value
|
||||||
gfpganModelField.value = getModelPath(use_face_correction, [".pth"])
|
console.log("use face correction", use_face_correction)
|
||||||
if (gfpganModelField.value) {
|
if (use_face_correction == null || use_face_correction == "None") {
|
||||||
// Is a valid value for the field.
|
|
||||||
useFaceCorrectionField.checked = true
|
|
||||||
gfpganModelField.disabled = false
|
|
||||||
} else {
|
|
||||||
// Not a valid value, restore the old value and disable the filter.
|
|
||||||
gfpganModelField.disabled = true
|
gfpganModelField.disabled = true
|
||||||
gfpganModelField.value = oldVal
|
|
||||||
useFaceCorrectionField.checked = false
|
useFaceCorrectionField.checked = false
|
||||||
|
} else {
|
||||||
|
gfpganModelField.value = getModelPath(use_face_correction, [".pth"])
|
||||||
|
if (gfpganModelField.value) {
|
||||||
|
// Is a valid value for the field.
|
||||||
|
useFaceCorrectionField.checked = true
|
||||||
|
gfpganModelField.disabled = false
|
||||||
|
} else {
|
||||||
|
// Not a valid value, restore the old value and disable the filter.
|
||||||
|
gfpganModelField.disabled = true
|
||||||
|
gfpganModelField.value = oldVal
|
||||||
|
useFaceCorrectionField.checked = false
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//useFaceCorrectionField.checked = parseBoolean(use_face_correction)
|
//useFaceCorrectionField.checked = parseBoolean(use_face_correction)
|
||||||
|
Loading…
Reference in New Issue
Block a user