Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
make sure the error isnt checked if sampling is disabled
Browse files
ui/src/app/.DS_Store
CHANGED
|
Binary files a/ui/src/app/.DS_Store and b/ui/src/app/.DS_Store differ
|
|
|
ui/src/components/HFJobsWorkflow.tsx
CHANGED
|
@@ -258,10 +258,12 @@ export default function HFJobsWorkflow({ jobConfig, onComplete, hackathonEligibl
|
|
| 258 |
throw new Error('Instruction models require a control dataset. Please select or upload a control dataset before continuing.');
|
| 259 |
}
|
| 260 |
|
| 261 |
-
|
| 262 |
-
|
| 263 |
-
|
| 264 |
-
|
|
|
|
|
|
|
| 265 |
}
|
| 266 |
}
|
| 267 |
|
|
|
|
| 258 |
throw new Error('Instruction models require a control dataset. Please select or upload a control dataset before continuing.');
|
| 259 |
}
|
| 260 |
|
| 261 |
+
if (!samplingDisabled) {
|
| 262 |
+
const samples = jobConfig?.config?.process?.[0]?.sample?.samples ?? [];
|
| 263 |
+
const missingCtrl = samples.filter((sample: any) => !sample?.ctrl_img || !String(sample.ctrl_img).trim());
|
| 264 |
+
if (missingCtrl.length > 0) {
|
| 265 |
+
throw new Error('Instruction models require a control image for every sample prompt. Please add control images before continuing.');
|
| 266 |
+
}
|
| 267 |
}
|
| 268 |
}
|
| 269 |
|