Alkl58 / NotEnoughAV1Encodes

GUI for AV1 (aomenc, rav1e & svt-av1)
MIT License
536 stars 24 forks source link

Progress does not correctly display after restart #134

Closed ThomasAunvik closed 1 year ago

ThomasAunvik commented 1 year ago

Describe the bug When initiating restarting the queue after closing the application / or crashing / or shutting down pc, the progress bar, % text and the estimated time is not shown correctly when a few video splits are already encoded.

The only way to see the actual progress would be to check the log files, and see what file it is currently working on.

2/17/2023 6:21:48 PM : INFO  - VideoEncode.Encode() => Chunk: F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Chunks\split000959.mkv
2/17/2023 6:21:48 PM : INFO  - VideoEncode.Encode() => Chunk: F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Chunks\split000960.mkv
2/17/2023 6:21:48 PM : INFO  - VideoEncode.Encode() => Chunk: F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Chunks\split000961.mkv
2/17/2023 6:21:48 PM : INFO  - VideoEncode.Encode() => Chunk: F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Chunks\split000962.mkv
2/17/2023 6:21:48 PM : INFO  - VideoEncode.Encode() => Chunk: F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Chunks\split000963.mkv
2/17/2023 6:21:48 PM : INFO  - VideoEncode.Encode() => Chunk: F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Chunks\split000964.mkv
2/17/2023 6:21:48 PM : INFO  - VideoEncode.Encode() => Chunk: F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Chunks\split000965.mkv
2/17/2023 6:21:48 PM : INFO  - VideoEncode.Encode() => Chunk: F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Chunks\split000966.mkv
2/17/2023 6:21:48 PM : INFO  - VideoEncode.Encode() => Chunk: F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Chunks\split000967.mkv
2/17/2023 6:21:48 PM : INFO  - VideoEncode.Encode() => Chunk: F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Chunks\split000968.mkv
2/17/2023 6:21:48 PM : INFO  - VideoEncode.Encode() => Chunk: F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Chunks\split000969.mkv
2/17/2023 6:21:48 PM : INFO  - VideoEncode.Encode() => Chunk: F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Chunks\split000970.mkv
2/17/2023 6:21:48 PM : INFO  - VideoEncode.Encode() => Chunk: F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Chunks\split000971.mkv
2/17/2023 6:21:48 PM : INFO  - VideoEncode.Encode() => Chunk: F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Chunks\split000972.mkv
2/17/2023 6:21:48 PM : INFO  - VideoEncode.Encode() => Command: /C ffmpeg.exe -y -i "F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Chunks\split000969.mkv"  -an -sn -map_metadata -1 -pix_fmt yuv420p  -c:v libaom-av1 -crf 25 -b:v 0 -cpu-used 4 -threads 4 -tile-columns 2 -tile-rows 1 -g 240 "F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Video\000969.webm"
2/17/2023 6:21:48 PM : INFO  - VideoEncode.Encode() => Command: /C ffmpeg.exe -y -i "F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Chunks\split000971.mkv"  -an -sn -map_metadata -1 -pix_fmt yuv420p  -c:v libaom-av1 -crf 25 -b:v 0 -cpu-used 4 -threads 4 -tile-columns 2 -tile-rows 1 -g 240 "F:\Video\Temp\NEAV1E\KAOnsdTKPrGCKXr\Video\000971.webm"

Notice that it skipped all the other ones, since the chunk file is already encoded, and now is on 0000969.webm, but my last file in the chunks folder is split001048.mkv

To Reproduce Steps to reproduce the behavior:

  1. Initiate an encoding job, long video (or multiple splits)

  2. Wait for it to it to progress be 50% or any.

  3. Shut down PC.

  4. Start up PC

  5. Run NEAV1E

  6. Go to Queue

  7. Hit Start

  8. See progress bar at 0%, and estimated time be the same as when you first started it.

Expected behavior Progress bar to reflect the encoding jobs already done.

Or

Correctly estimate the time from 0%.

Screenshots image

Log File https://gist.github.com/ThomasAunvik/9500bb19c2242ce557567c5834a59a41

Desktop:

Alkl58 commented 1 year ago

Should be fixed in the release v2.1.3