This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

bad FPS with SelectEvery()
#1
Hello!

When I use the SelectEvery plugin, it drops the output FPS to something that looks wrong to me. Ex: going from 29.97 to 23.976 gives a resulting 5.994 fps.

Here's the script generated by Hybrid:

# Imports
import vapoursynth as vs
# getting Vapoursynth core
core = vs.core
# source: '/Users/admin/Desktop/in.mp4'
# current color space: YUV420P8, bit depth: 8, resolution: 656x480, fps: 29.97, color matrix: 470bg, yuv luminance scale: limited, scanorder: progressive
# Loading /Users/admin/Desktop/in.mp4 using LibavSMASHSource
clip = core.lsmas.LibavSMASHSource(source="/Users/admin/Desktop/in.mp4")
# Setting color matrix to 470bg.
clip = core.std.SetFrameProps(clip, _Matrix=5)
clip = clip if not core.text.FrameProps(clip,'_Transfer') else core.std.SetFrameProps(clip, _Transfer=5)
clip = clip if not core.text.FrameProps(clip,'_Primaries') else core.std.SetFrameProps(clip, _Primaries=5)
# Setting color range to TV (limited) range.
clip = core.std.SetFrameProp(clip=clip, prop="_ColorRange", intval=1)
# making sure frame rate is set to 29.970
clip = core.std.AssumeFPS(clip=clip, fpsnum=30000, fpsden=1001)
# adjusting frame with SelectEvery
clip = core.std.SelectEvery(clip=clip, cycle=5, offsets=[0,1,2,3])
clip = core.std.AssumeFPS(clip=clip,fpsnum=2997, fpsden=500)# new fps: 5.994
# adjusting output color from: YUV420P8 to YUV422P10 for ProResModel
clip = core.resize.Bicubic(clip=clip, format=vs.YUV422P10, range_s="limited")
# Output
clip.set_output()

The problem seems to be with the line:
clip = core.std.AssumeFPS(clip=clip,fpsnum=2997, fpsden=500)# new fps: 5.994

If I change it to fpsnum=24000 and fpsden=1001, I get a good 23.976 fps output.

I'm on mac (latest version 2022.03.20.1).

Is this a bug or do I miss something?

Thanks!!
Reply


Messages In This Thread
bad FPS with SelectEvery() - by annael - 16.09.2022, 21:19
RE: bad FPS with SelectEvery() - by Selur - 16.09.2022, 21:24
RE: bad FPS with SelectEvery() - by Selur - 17.09.2022, 07:24

Forum Jump:


Users browsing this thread: 1 Guest(s)