Lots of skipped frames in LE 10.0.4

  • Hi

    I am using LE 10.0.4 on a Rpi4.

    I use it only to view recorded videos and since I basically only record one program, the video file is always the same

    When I play it, I see tons of skipped frames (if I activate the debug info, I see that number increasing every second or so). It looks to me that CPU spikes a bit when the frame is lost. Of course, final result is jerkyness of the video especially during pans or scrolling titles.

    I believe 10.0.3 was fixing it greatly but I am not fully sure. I for sure noticed it way more in 10.0.2 and 10.0.4

    Is there anything I can set in the debug log to show you where the problem is? I have activated ffmpeg debug but I am not sure all that info is relevant.

    For sure it's not a media problem as I stream from an USB3, locally plugged, and I tested r/w speed with dd

    Code
    LibreELEC:~ # dd if=/var/media/DVR/RegistrazioniTV/CLV/TestSppedFile of=/dev/zero bs=1G count=5
    5+0 records in
    5+0 records out
    5368709120 bytes (5.0GB) copied, 54.167245 seconds, 94.5MB/s

    I played the recorded video on my Mac and I didn't see any lost frames (I don't know if there a way with ffmpeg to check this).

    I have recorded a small video, actually with slow-motion but YouTube doesn't seem to care: LE10_DroppingFrames

    HD Version should be ready in 30 minutes from now (it's xx:43)

  • Go to Best Answer
  • Please post a short sample and a full debug log.

    Please provide a full debug log.

    How to post a log (wiki)

    1. Enable debugging in Settings>System Settings>Logging
    2. Restart Kodi
    3. Replicate the problem
    4. Generate a log URL (do not post/upload logs to the forum)

    use "Settings > LibreELEC > System > Paste system logs" or run "pastekodi" over SSH, then post the URL link
  • You can zip the file you got from "pastekodi -c" and attach it to a post here.

    But it'd be better to reproduce the issue immediately after kodi start, stop playing a few seconds after the issue happened and then create the log - that should be small enough for standard pastekodi upload (if you get an error, retry a few time with some 30-60 seconds between retries, ix.io might be busy and thus fail to accept the paste).

    so long,

    Hias

  • OK I have done what you have suggested, still pastebin complains about the maximum size reached.

    So I am attaching it here. It should be a .gz file as I have used gzip but since this extension is not accepted, I have renamed it to .zip

    kodi.log.zip

    Thanks

  • Please uninstall the vpn manager addon. It seems to be having severe issues, constantly generating log entries, spamming the logs and that might be the cause of your issues.

    Once you removed it please upload a pastekodi log as requested - kodi log alone isn't enough.

    so long,

    Hias

  • force_turbo will boost all clocks (including ARM CPU) which can help with general performance but likely result in higher temperatures. core_freq_min will only raise clocks needed for HW decoding so temperatures will be a bit lower.

    You have to check yourself, it also depends on how well your RPi is cooled - a too high boost can have quite negative effect without proper cooling, then it will start throttling after a while if temps get too high and have worse performance than without clock boosting.

    so long,

    Hias

  • I have a shim fan which gets activated whenever temperature is higher than a threshold and stops when another lower threshold is reached. However, since I have HW decoding issues, I will start with core_freq_min and will report back.

    This was a very valuable piece of info you gave me!!!

    Thanks again

    Luca

  • So, I have tested both options and none of them is bringin any valuable results.

    I also have a Fire TV 4K stick which I use to play videos (I use LE to record TV programs).

    I have seen the following:

    - FireTV can perfectly decode the TV recording and I don't see any skipped / dropped frame, but the HW Decoder is not Prime.

    - I tried to stream some films from LE, and tested MP4 SD/HD and H264 SD/HD. In all the cases, I didn't get any skipped / dropped frames, so the problem is not the H264 HW decoder but the DEINTERLACER. As soon as I have interlaced videos, I get jerkyness. I tried disabling Prime decoder but rpi4 is not powerful enough. But as soon as I disable deinterlacing in the player, no frames are skipped (of course, video experience is not nice); I re-enable it, and frames start to be skipped.

    So I think there is nothing I can do, at the moment....

    Edited once, last by ciclista71 (February 8, 2023 at 11:01 AM).

  • Uhm, no further comments, so I really understand the issue is within LE and I need to wait for LE11?

    Yes, the "famous" deinterlacer in the LE10 and LE11.

    Was added in the LE 11 nightly, to the ffmpeg, some kind of patch for better handling the deinterlace (the LE11 beta 10.95.0 don't have it, don't know if in the LE10 nightly was added or not). Make a backup (or better use another sd-card) and try the latest LE11 nightly, maybe you will see some improvement.

    I'm using 3 RPi3's, one with LE 10.0.4, two with LE11 nightly. For FHD live TV streams (h264, tvheadend), in case of LE10, sometimes appears some green artefacts, only for milliseconds, at the bottom of pictures. With the LE11 nightly, instead of green artefacts, some pixelation appear sometimes, mostly when major changes in the picture. L11 nightly with HD ready display (720p, the third RPi3) works better. I still have some SD channels, with mpeg2, works always without issues (RPi3, no HW decoding for mpeg2).

  • Sorry for missing the part about the sample.

    I would have sent it earlier. I have two clips, one starts from the beginning and the other shows some rolling titles which clearly show skipped frames

    Clip1

    Clip2


    This LE11 thing is rather interesting.... Have to check if I have some spare SD cards somewhere!

    Thanks

    Luca