• Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below
  • Forum
  • Website
  • GitHub
  • Status
  • Translation
  • Features
  • Team
  • Rules
  • Help
  • Feeds
User Links
  • Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below

    Useful Links Forum Website GitHub Status Translation Features Team Rules Help Feeds
    Jellyfin Forum Support Troubleshooting SOLVED: HWA AMD VAAPI Stuttering

     
    • 0 Vote(s) - 0 Average

    SOLVED: HWA AMD VAAPI Stuttering

    Weird stuttering on some media but not all
    floppy
    Offline

    Junior Member

    Posts: 5
    Threads: 1
    Joined: 2023 Sep
    Reputation: 0
    #1
    2023-09-06, 05:25 PM (This post was last modified: 2023-09-06, 05:29 PM by floppy. Edited 2 times in total.)
    I have this weird stuttering that only happens on select media, I've not been able to pin point what actually differs from the media, I've attached some transcode log example and the stuttering result.

    The only thing I can see that differs is the bad transcode input stream uses bt709

    I'm using an RX580 with VAAPI in the latest linuxserver docker image



    Bad Transcode: 
    .txt   stuttertranscode.txt (Size: 70.44 KB / Downloads: 73)
    Good Transcode: 
    .txt   goodtranscode.txt (Size: 33.93 KB / Downloads: 61)

    Vainfo: 
    .txt   vainfo.txt (Size: 1.5 KB / Downloads: 81)
    OpenCL: 
    .txt   opencl.txt (Size: 2.05 KB / Downloads: 98)
    Vulcan
    .txt   vulcan.txt (Size: 3.83 KB / Downloads: 60)

    I can't upload an example video so hopefully a discord link will be okay Smiling-face  

    https://cdn.discordapp.com/attachments/3...36/bad.mp4
    https://streamable.com/za5c7g
    Go to solution
    bitmap
    Offline

    Community Moderator

    Posts: 821
    Threads: 9
    Joined: 2023 Jul
    Reputation: 27
    #2
    2023-09-06, 05:37 PM
    Quick look? This right here:

    Code:
    -filter_complex "[0:3]scale=s=1920x1080:flags=fast_bilinear[sub];[0:0]setparams=color_primaries=bt709:color_trc=bt709:colorspace=bt709,scale_vaapi=format=nv12:extra_hw_frames=24,hwdownload,format=nv12[main];[main][sub]overlay=eof_action=pass:shortest=1:repeatlast=0,hwupload_vaapi"

    You have more complex subs being burned in through a complex filter and the video is being scaled in the stuttering transcode. I'll look more in-depth in a bit when I have time...
    Jellyfin 10.10.7 LSIO Docker | Ubuntu 24.04 LTS | i7-13700K | Arc A380 6 GB | 64 GB RAM | 79 TB Storage

    [Image: AIL4fc84QG6uSnTDEZiCCtosg7uAA8x9j1myFaFs...qL0Q=w2400]
    1
    floppy
    Offline

    Junior Member

    Posts: 5
    Threads: 1
    Joined: 2023 Sep
    Reputation: 0
    #3
    2023-09-06, 06:06 PM (This post was last modified: 2023-09-06, 06:21 PM by floppy. Edited 2 times in total.)
    (2023-09-06, 05:37 PM)bitmap Wrote: Quick look? This right here:

    Code:
    -filter_complex "[0:3]scale=s=1920x1080:flags=fast_bilinear[sub];[0:0]setparams=color_primaries=bt709:color_trc=bt709:colorspace=bt709,scale_vaapi=format=nv12:extra_hw_frames=24,hwdownload,format=nv12[main];[main][sub]overlay=eof_action=pass:shortest=1:repeatlast=0,hwupload_vaapi"

    You have more complex subs being burned in through a complex filter and the video is being scaled in the stuttering transcode. I'll look more in-depth in a bit when I have time...

    This is it! Turning off burned in subtitles resolved the stuttering, but now there is no subtitles, quick find on the cause, hopefully there is a simple solution Smiling-face
    bitmap
    Offline

    Community Moderator

    Posts: 821
    Threads: 9
    Joined: 2023 Jul
    Reputation: 27
    #4
    2023-09-06, 07:13 PM
    Could you post a mediainfo or ffprobe of the file to provide more context on why the subs are being burned in? Guessing with anime the subs are too complex to display natively. If they're ASS/SSA and you're using a client that supports swapping players, you could try a different one (e.g., VLC might support more complex subs than ExoPlayer, built-in, or web). If they're PGS, DVD, VOB, etc... you'd want to find SRT subs. The down side for anime is you miss out on signs/songs translations. Personally, I don't care, but I've learned over time that I'm (in some cases literally) a heretic in a lot of the communities that I'm a part of so...
    Jellyfin 10.10.7 LSIO Docker | Ubuntu 24.04 LTS | i7-13700K | Arc A380 6 GB | 64 GB RAM | 79 TB Storage

    [Image: AIL4fc84QG6uSnTDEZiCCtosg7uAA8x9j1myFaFs...qL0Q=w2400]
    floppy
    Offline

    Junior Member

    Posts: 5
    Threads: 1
    Joined: 2023 Sep
    Reputation: 0
    #5
    2023-09-06, 08:15 PM (This post was last modified: 2023-09-06, 08:17 PM by floppy. Edited 2 times in total.)
    (2023-09-06, 07:13 PM)bitmap Wrote: Could you post a mediainfo or ffprobe of the file to provide more context on why the subs are being burned in? Guessing with anime the subs are too complex to display natively. If they're ASS/SSA and you're using a client that supports swapping players, you could try a different one (e.g., VLC might support more complex subs than ExoPlayer, built-in, or web). If they're PGS, DVD, VOB, etc... you'd want to find SRT subs. The down side for anime is you miss out on signs/songs translations. Personally, I don't care, but I've learned over time that I'm (in some cases literally) a heretic in a lot of the communities that I'm a part of so...

    ASS/Complex subs are preferable when working as it will overlay the subs in the correct place on the screen with good font/styling, it's a deal breaker for me personally without. I've been using CPU encoding as it works flawlessly however reduces the speed of encoding and strains the system much more

    FFprobe: 
    .txt   ffprobe.txt (Size: 4.89 KB / Downloads: 50)
    bitmap
    Offline

    Community Moderator

    Posts: 821
    Threads: 9
    Joined: 2023 Jul
    Reputation: 27
    #6
    2023-09-06, 09:26 PM
    Oh I'm well aware of why folks would prefer ASS over another format. My anime collection would make teenage me extremely jealous. If only adult me had time to watch it like teenage me did. Time makes fools of us all.
    Jellyfin 10.10.7 LSIO Docker | Ubuntu 24.04 LTS | i7-13700K | Arc A380 6 GB | 64 GB RAM | 79 TB Storage

    [Image: AIL4fc84QG6uSnTDEZiCCtosg7uAA8x9j1myFaFs...qL0Q=w2400]
    nyanmisaka
    Offline

    Team Member

    Posts: 244
    Threads: 0
    Joined: 2023 Jun
    Reputation: 9
    #7
    2023-09-06, 10:10 PM
    Upgrading to JF 10.9 should fix issue.
    floppy
    Offline

    Junior Member

    Posts: 5
    Threads: 1
    Joined: 2023 Sep
    Reputation: 0
    #8
    2023-09-06, 11:10 PM (This post was last modified: 2023-09-06, 11:10 PM by floppy. Edited 1 time in total.)
    (2023-09-06, 10:10 PM)nyanmisaka Wrote: Upgrading to JF 10.9 should fix issue.

    Nope, same issue: 
    .txt   transcode.txt (Size: 16.88 KB / Downloads: 65)

    Code:
    ujellyfin:
        image: jellyfin/jellyfin:unstable
        container_name: ujellyfin
        network_mode: 'host'
        group_add:
          - "109"
          - "44"
        volumes:
          - ./configs/ujellyfin/config:/config
          - ./configs/ujellyfin/cache:/cache
          - /storage/downloads:/downloads
        devices:
          - /dev/dri/card0:/dev/dri/card0
          - /dev/dri/renderD128:/dev/dri/renderD128
        restart: 'unless-stopped'

    Code:
    Server: mserv
    Version: 10.9.0
    Operating System:
    Architecture: X64
    floppy
    Offline

    Junior Member

    Posts: 5
    Threads: 1
    Joined: 2023 Sep
    Reputation: 0
    #9
    2023-09-06, 11:41 PM
    I solved it, upgrading to ffmpeg6 manually worked, I'll write a quick guide on how I did that in case anyone has the same issue in the future

    This assumes you're using docker

    Code:
    docker compose exec jellyfin /bin/bash;
    cd ~;
    curl -L https://github.com/jellyfin/jellyfin-ffmpeg/releases/download/v6.0-6/jellyfin-ffmpeg6_6.0-6-bullseye_amd64.deb --output ffmpeg.deb;
    dpkg -i ffmpeg.deb;

    That should get you up and running with ffmpeg6 and removed stuttering with subtitles Smiling-face
    bitmap
    Offline

    Community Moderator

    Posts: 821
    Threads: 9
    Joined: 2023 Jul
    Reputation: 27
    #10
    2023-09-07, 12:35 AM
    I don't know how other folks handle their containers, but you can set this up as a pre-launch step for your container. Put a startup script in your custom init scripts folder that does a wget or curl call for jellyfin-ffmpeg6 and forces the update over version 5. Makes it essentially invisible, but will add a few seconds to "boot" time for your container.
    Jellyfin 10.10.7 LSIO Docker | Ubuntu 24.04 LTS | i7-13700K | Arc A380 6 GB | 64 GB RAM | 79 TB Storage

    [Image: AIL4fc84QG6uSnTDEZiCCtosg7uAA8x9j1myFaFs...qL0Q=w2400]
    « Next Oldest | Next Newest »

    Users browsing this thread: 1 Guest(s)


    • View a Printable Version
    • Subscribe to this thread
    Forum Jump:

    Home · Team · Help · Contact
    © Designed by D&D - Powered by MyBB
    L


    Jellyfin

    The Free Software Media System

    Linear Mode
    Threaded Mode