save changes

This commit is contained in:
2025-09-22 22:22:57 +02:00
parent e5a65114d1
commit 78584ce1b6
3 changed files with 28 additions and 4 deletions

View File

@ -406,7 +406,9 @@ async function generateImageForItem(item: PipelineItem, server: { baseUrl: strin
videoFileName,
server.baseUrl,
server.outputDir,
{ width: 1280, height: 720 }
{ width: 1280, height: 720 },
true,
false
);
if (videoPath) {

View File

@ -97,7 +97,7 @@
},
"52": {
"inputs": {
"image": "AG9782s.webp"
"image": "zagreb_musicspot_s14_c1_v1.png"
},
"class_type": "LoadImage",
"_meta": {
@ -340,7 +340,7 @@
"inputs": {
"resize_to": "4k",
"images": [
"8",
"76",
0
],
"upscaler_trt_model": [
@ -355,12 +355,24 @@
},
"75": {
"inputs": {
"model": "4xNomos2_otf_esrgan",
"model": "4x-UltraSharp",
"precision": "fp16"
},
"class_type": "LoadUpscalerTensorrtModel",
"_meta": {
"title": "Load Upscale Tensorrt Model"
}
},
"76": {
"inputs": {
"anything": [
"8",
0
]
},
"class_type": "easy cleanGpuUsed",
"_meta": {
"title": "Clean VRAM Used"
}
}
}

View File

@ -41,6 +41,11 @@ async function callOpenAI(prompt: string): Promise<any> {
const jsonMatch = content.match(/\{[\s\S]*\}/);
if (jsonMatch) {
return JSON.parse(jsonMatch[0]);
} else {
const arrayMatch = content.match(/\[[\s\S]*\]/);
if (arrayMatch) {
return JSON.parse(arrayMatch[0]);
}
}
} else {
logger.error('Unexpected API response:', data);
@ -94,6 +99,11 @@ async function callOpenAIWithFile(imagePath: string, prompt: string): Promise<an
const jsonMatch = content.match(/\{[\s\S]*\}/);
if (jsonMatch) {
return JSON.parse(jsonMatch[0]);
} else {
const arrayMatch = content.match(/\[[\s\S]*\]/);
if (arrayMatch) {
return JSON.parse(arrayMatch[0]);
}
}
} else {
logger.error('Unexpected API response:', data);