Batch Processing fixes and improvements

This commit is contained in:
N00MKRAD
2021-05-30 15:03:24 +02:00
parent c53bf9166f
commit 2fda79aad7
6 changed files with 48 additions and 37 deletions

View File

@@ -29,10 +29,18 @@ namespace Flowframes.Main
{
if (!stopped && Program.batchQueue.Count > 0)
{
Logger.Log($"[Queue] Running queue task {i + 1}/{initTaskCount}, {Program.batchQueue.Count} tasks left.");
await RunEntry(Program.batchQueue.Peek());
if (currentBatchForm != null)
currentBatchForm.RefreshGui();
try
{
Logger.Log($"[Queue] Running queue task {i + 1}/{initTaskCount}, {Program.batchQueue.Count} tasks left.");
await RunEntry(Program.batchQueue.Peek());
if (currentBatchForm != null)
currentBatchForm.RefreshGui();
}
catch (Exception e)
{
Logger.Log($"Failed to run batch queue entry. If this happened after force stopping the queue, it's non-critical. {e.Message}", true);
}
}
await Task.Delay(1000);
}
@@ -55,6 +63,8 @@ namespace Flowframes.Main
return;
}
Logger.Log($"ENTRY DET FPS: " + entry.inFpsDetected);
string fname = Path.GetFileName(entry.inPath);
if (IOUtils.IsPathDirectory(entry.inPath)) fname = Path.GetDirectoryName(entry.inPath);
Logger.Log($"[Queue] Processing {fname} ({entry.interpFactor}x {entry.ai.aiNameShort}).");