VideoHelp Forum




+ Reply to Thread
Results 1 to 14 of 14
  1. Member
    Join Date
    Aug 2023
    Location
    Germany
    Search PM
    Currently used Kubuntu 24.04. Wayland, ffmpeg 8.0

    Did compress the video :

    Video: h264, yuv420p(tv, bt709, progressive), 1280x720 [SAR 1:1 DAR 16:9], 11343 kb/s, 50 fps, 50 tbr, 90k tbn

    to :
    Video: hevc, yuv420p(tv, bt709, progressive), 1280x720 [SAR 1:1 DAR 16:9], 5075 kb/s, 50 fps, 50 tbr, 16k tbn

    h.264 video-file size= 9GB. h.265 video-file size 3.7GB

    VMAF score: 99.836461

    the respective ffmpeg command as a script :

    Code:
    #!/bin/sh
    
    for f in *.ts; do ffmpeg -y -i "$f" -map 0:v -map 0:a -vcodec libx265 -crf 16 -preset slow -vf nlmeans="1.6:7:5:3:3",unsharp="3:3:1.0" -c:a copy "$(basename "$f" .ts).mkv";done
    A short description :
    crf 16 = quality, less value higher quality
    nlmeans = filter to reduce grain
    unsharp = increase sharpness

    Without the filter unsharp. I got a file size of 2.4GB (same video) and a vmaf score 95.6 .

    For your information vmaf score of 100. no difference can be seen. 95.6, a good value.

    Never reached this high vmaf score without "unsharp". I did decrease crf until I got a compressed file size < 1/2 source file, but the vmaf score max was 96-97.

    Also I did compress with "unsharp" other videos with very equal results (vmaf score > 99.9)

    I have a restriction : If I can not reduce the file size with crf 16, unsharp as given above to 1/2 of the source file-size. I decide for no compression.

    Only to share my results.

    Others who would like to share their results ?
    Quote Quote  
  2. Mr. Computer Geek dannyboy48888's Avatar
    Join Date
    May 2007
    Location
    Texas, USA
    Search Comp PM
    Ah yes the fun metrics rabbit hole. Take them as a guide not concrete. I've gotten hight scores before but the background gradients etc were gone. And I've had home with a lower score (92) look fine visually as the gradients got preserved, just not exactly like the original.
    if all else fails read the manual
    Quote Quote  
  3. Member
    Join Date
    Aug 2023
    Location
    Germany
    Search PM
    @dannyboy48888, yes and no. I got bad vmaf scores e.g. 55 but acceptable results checked by vivictpp or via TV.

    But this case I can confirm e.g. by vivictpp, I did not see any differences in the pictures, frame by frame.
    And it does not depend on the background/foreground.

    And also as given by my example, I could see differences with vivictpp and the vmaf score 95, but not with a vmaf score of 99.
    Quote Quote  
  4. Member
    Join Date
    Aug 2023
    Location
    Germany
    Search PM
    But we have the possibility to check the "subjective" results with a respective upload :

    https://we.tl/t-R2sLFzDOX9ypuf2c

    The link will be for 3 days available.

    From my side of view, the given webpage should be checked before to download my files.
    Quote Quote  
  5. Member
    Join Date
    Aug 2023
    Location
    Germany
    Search PM
    An additional hint : vmaf developed by Netflix engineers + some US-Universities + ffmpeg community to get a metric for its own, the Netflix encoding results. And if a vmaf score of > 99 would be indicate not an on top result, the logic leads to : Neither Netflix engineers nor some US-Universities nor the ffmpeg community does not know what they speak about, I must confess, I can not believe it.
    Quote Quote  
  6. Member
    Join Date
    Aug 2018
    Location
    Wrocław
    Search PM
    Last edited by rgr; 6th Jun 2026 at 16:47.
    Quote Quote  
  7. Member
    Join Date
    Aug 2023
    Location
    Germany
    Search PM
    @rgr. I must confess, I have no eyes for cheap sharpening, did you see the context of the picture ?
    Better it would be, to send 2 pictures, the first you did send and the second, the cursor a bit to the right, then you can compare source/target, the context you have to accept all ways.
    But every body can do it, it does not depend on you (vivictpp a tool for free, WIN +Linux).

    But I must also confess, to indicate "sheap" sharpening, at a position where the light is totally different (left, right), has to explain its choice.

    Obviously you are also the opposite of Netflix engineers + some US-Universities + ffmpeg community ?!

    Are you also the opposite of tools for free ?
    Last edited by Gloster; 7th Jun 2026 at 23:58.
    Quote Quote  
  8. Member
    Join Date
    Aug 2023
    Location
    Germany
    Search PM
    And further results with vivictpp : https://we.tl/t-StWaSjJp3RkPmpYo
    Two pictures left and right of totally different light.
    But @rgr, if it is not the correct timestamp, give me the timestamp, I can give also for further investigations the respective pictures (refer to vivictpp : https://github.com/vivictorg/vivictpp).
    Quote Quote  
  9. Member
    Join Date
    Apr 2012
    Location
    Hungary
    Search PM
    Originally Posted by Gloster View Post
    Currently used Kubuntu 24.04. Wayland, ffmpeg 8.0

    Did compress the video :

    Video: h264, yuv420p(tv, bt709, progressive), 1280x720 [SAR 1:1 DAR 16:9], 11343 kb/s, 50 fps, 50 tbr, 90k tbn

    to :
    Video: hevc, yuv420p(tv, bt709, progressive), 1280x720 [SAR 1:1 DAR 16:9], 5075 kb/s, 50 fps, 50 tbr, 16k tbn

    h.264 video-file size= 9GB. h.265 video-file size 3.7GB

    VMAF score: 99.836461

    the respective ffmpeg command as a script :

    Code:
    #!/bin/sh
    
    for f in *.ts; do ffmpeg -y -i "$f" -map 0:v -map 0:a -vcodec libx265 -crf 16 -preset slow -vf nlmeans="1.6:7:5:3:3",unsharp="3:3:1.0" -c:a copy "$(basename "$f" .ts).mkv";done
    A short description :
    crf 16 = quality, less value higher quality
    nlmeans = filter to reduce grain
    unsharp = increase sharpness

    Without the filter unsharp. I got a file size of 2.4GB (same video) and a vmaf score 95.6 .

    For your information vmaf score of 100. no difference can be seen. 95.6, a good value.

    Never reached this high vmaf score without "unsharp". I did decrease crf until I got a compressed file size < 1/2 source file, but the vmaf score max was 96-97.

    Also I did compress with "unsharp" other videos with very equal results (vmaf score > 99.9)

    I have a restriction : If I can not reduce the file size with crf 16, unsharp as given above to 1/2 of the source file-size. I decide for no compression.

    Only to share my results.

    Others who would like to share their results ?
    Can I use ffmpeg 8.0 on Windows 7 running your script?
    Quote Quote  
  10. I usually do not use scripts.
    I used the code necessary for the command line in ffmpeg.

    Code:
    ffmpeg -y -i "input.mp4" -map 0:v -map 0:a -vcodec libx265 -crf 16 -preset slow -vf nlmeans="1.6:7:5:3:3",unsharp="3:3:1.0" -c:a copy "output.mkv"
    I'm using:
    ffmpeg version 8.1.2-WIN7 Copyright (c) 2000-2026 the FFmpeg developers built with gcc 16.1.0 (Rev5, Built by MSYS2 project)
    It is one of the ffmpeg that was posted in this thread:
    https://forum.videohelp.com/threads/414767-ffmpeg-7-0-1-and-Windows-7/page6
    The current version being posted is a version 9.
    A version 7 may still be posted but I'm not sure.
    autodidact the member creating the versions for Windows 7 is real cooperative & may be able to post a ffmpeg version you want.

    I have the 7zip for the version 8.1 still but it is for Windows 7 32-bit.
    Quote Quote  
  11. Member
    Join Date
    Aug 2023
    Location
    Germany
    Search PM
    given by @cholla :

    Code:
    ffmpeg -y -i "input.mp4" -map 0:v -map 0:a -vcodec libx265 -crf 16 -preset slow -vf nlmeans="1.6:7:5:3:3",unsharp="3:3:1.0" -c:a copy "output.mkv"
    additional hints :

    The map parameter can be deleted, if only one audio stream will be present :

    Code:
    ffmpeg -y -i "input.mp4" -vcodec libx265 -crf 16 -preset slow -vf nlmeans="1.6:7:5:3:3",unsharp="3:3:1.0" -c:a copy "output.mkv"
    the value of nlmeans="1.6:7:5:3:3"
    "1.6", first entry can be increased, it depends on the video resolution :

    "1.0 to 1.8 for 720p video and 1.0 to 4.0 for 1080p". I does not find the respective link, from where the values I have.

    With crf increased up to "crf 19", I also get vmaf values > 99 (sometimes >98), file size decreased to 1/3 - 1/2.

    But I must confess, the sources are all ways fps=50.
    Quote Quote  
  12. Member
    Join Date
    Apr 2012
    Location
    Hungary
    Search PM
    Originally Posted by cholla View Post
    I usually do not use scripts.
    I used the code necessary for the command line in ffmpeg.

    Code:
    ffmpeg -y -i "input.mp4" -map 0:v -map 0:a -vcodec libx265 -crf 16 -preset slow -vf nlmeans="1.6:7:5:3:3",unsharp="3:3:1.0" -c:a copy "output.mkv"
    I'm using:
    ffmpeg version 8.1.2-WIN7 Copyright (c) 2000-2026 the FFmpeg developers built with gcc 16.1.0 (Rev5, Built by MSYS2 project)
    It is one of the ffmpeg that was posted in this thread:
    https://forum.videohelp.com/threads/414767-ffmpeg-7-0-1-and-Windows-7/page6
    The current version being posted is a version 9.
    A version 7 may still be posted but I'm not sure.
    autodidact the member creating the versions for Windows 7 is real cooperative & may be able to post a ffmpeg version you want.

    I have the 7zip for the version 8.1 still but it is for Windows 7 32-bit.
    The code that you provided, it works like that with version 9 a well? No need for mods to the code?
    Quote Quote  
  13. Is the VMAF score that reliable?
    I just gave it a test run on two identical videos (I made a copy of a video and used it for the comparison) and the VMAF score was only around 98.24. It was animation, and 10 bit HEVC (1080p) if that makes a difference, but I fully expected the score to be 100.

    I used the following command line. Admittedly it was an older version of ffmpeg (version 7 something) because there was an error when I tried to build the latest version and I was too lazy to work out how to resolve it, so I downloaded a pre-built executable for linux, but I used the latest VMAF models.

    Code:
    /media/Drive1/Programs/VMAF/ffmpeg -i /media/Drive1/VideoA.mkv -an -sn -i /media/Drive1/VideoB.mkv -an -sn -lavfi libvmaf=log_path=/media/Drive1/Programs/VMAF/logs/output.xml:log_fmt=xml:n_threads=12 -f null -
    Quote Quote  
  14. Member
    Join Date
    Aug 2023
    Location
    Germany
    Search PM
    @hello_hello, obviously you have detect an vmaf error of -1.76. I can agree it for 8Bit : -1.31, one test.

    I can live with this error.

    Obviously there are a lot of numerical algorithms implemented, what else.
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!