Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Capturing and Editing Video > VapourSynth

Reply
 
Thread Tools Search this Thread Display Modes
Old 26th July 2015, 22:50   #21  |  Link
jose1711
Registered User
 
Join Date: Jul 2015
Posts: 11
hi, is this the correct place to report build issues for this plugin?
jose1711 is offline   Reply With Quote
Old 27th July 2015, 07:17   #22  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Quote:
Originally Posted by jose1711 View Post
hi, is this the correct place to report build issues for this plugin?
It is.
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 16th January 2016, 20:16   #23  |  Link
an3k
Registered User
 
an3k's Avatar
 
Join Date: Oct 2006
Location: Omicron Persei 8
Posts: 180
What's the difference between the included libtemporalsoften2 and jackoneills https://github.com/dubhater/vapoursynth-temporalsoften ? Do I get any interference when both are installed? If so which one should be used?
an3k is offline   Reply With Quote
Old 16th January 2016, 21:21   #24  |  Link
Myrsloik
Professional Code Monkey
 
Myrsloik's Avatar
 
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,547
Quote:
Originally Posted by an3k View Post
What's the difference between the included libtemporalsoften2 and jackoneills https://github.com/dubhater/vapoursynth-temporalsoften ? Do I get any interference when both are installed? If so which one should be used?
It's exactly the same
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet
Myrsloik is offline   Reply With Quote
Old 16th January 2016, 21:26   #25  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Quote:
Originally Posted by an3k View Post
What's the difference between the included libtemporalsoften2 and jackoneills https://github.com/dubhater/vapoursynth-temporalsoften ? Do I get any interference when both are installed? If so which one should be used?
There is no interference. Chikuzen's version should be faster. Maybe it has additional functionality as well. I don't remember.
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 8th August 2017, 03:18   #26  |  Link
lansing
Registered User
 
Join Date: Sep 2006
Posts: 1,657
How do I get all the frame numbers of the start of the scene change?
lansing is offline   Reply With Quote
Old 9th August 2017, 01:20   #27  |  Link
VS_Fan
Registered User
 
Join Date: Jan 2016
Posts: 98
Quote:
Originally Posted by lansing View Post
How do I get all the frame numbers of the start of the scene change?
This should do the trick:
Code:
import vapoursynth as vs
core = vs.get_core()

ret = core.ffms2.Source(source="video file name")

#ret = core.scd.Detect(clip=ret, thresh=40, log="SC_SCD.TXT")#, interval_h, interval_v)
ret = core.misc.SCDetect(clip=ret, threshold=0.15)

fstats = open ('SC.txt', 'w', encoding='utf-8', errors='strict')
fstats.write('frame_no\n')
for i in range (ret.num_frames):
    if ret.get_frame(i).props._SceneChangePrev == 1 :
        fstats.write('{}\n'.format(i))
fstats.close()

ret=core.text.FrameProps(clip=ret, alignment=3)#, props
ret.set_output()
It will scan the whole video, create the 'SC.txt' text file, write to it the list of frames detected by the misc.SCDetect filter as start of a scene change, then it will close the file when finished and only after that it will show any video if run from vsedit.

So give it a while, and when it finishes, rename or copy your new 'SC.txt' text file with the frame numbers to avoid rewritting it.
VS_Fan is offline   Reply With Quote
Old 9th August 2017, 15:18   #28  |  Link
lansing
Registered User
 
Join Date: Sep 2006
Posts: 1,657
What is the difference between this scene change detection filter and the one in the misc? Right now I'm using the loop from the documentation to loop through the video, which way is faster?

Code:
clip = core.scd.Detect(clip, thresh=25)

for frame in clip.frames():
    if frame.props._SceneChangePrev == 1 and frame.props._SceneChangeNext == 0:
        frame_num = round(frame.props._AbsoluteTime * clip.fps)
        #do stuff
lansing is offline   Reply With Quote
Old 9th August 2017, 15:33   #29  |  Link
Myrsloik
Professional Code Monkey
 
Myrsloik's Avatar
 
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,547
Quote:
Originally Posted by lansing View Post
What is the difference between this scene change detection filter and the one in the misc? Right now I'm using the loop from the documentation to loop through the video, which way is faster?

Code:
clip = core.scd.Detect(clip, thresh=25)

for frame in clip.frames():
    if frame.props._SceneChangePrev == 1 and frame.props._SceneChangeNext == 0:
        frame_num = round(frame.props._AbsoluteTime * clip.fps)
        #do stuff
The misc version is basically a faster replacement of the scd version. It should behave identically.

That's a really awkward way of writing things:
Code:
clip = ...

for n in range(length(clip)):
    frame = clip.get_frame(n)
    if frame.props['_SceneChangePrev'] == 1 and frame.props['_SceneChangeNext'] == 0:
        frame_num = n
        #do stuff
And another note about speed. Any script that can be run through vspipe will be faster due to multiple frame requests being possible at once.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet
Myrsloik is offline   Reply With Quote
Old 10th August 2017, 03:28   #30  |  Link
lansing
Registered User
 
Join Date: Sep 2006
Posts: 1,657
um both filters didn't do well on scene change in darker areas, I have to set threshold to 0.02 in order to see them.
lansing is offline   Reply With Quote
Old 10th August 2017, 15:12   #31  |  Link
Myrsloik
Professional Code Monkey
 
Myrsloik's Avatar
 
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,547
Quote:
Originally Posted by lansing View Post
um both filters didn't do well on scene change in darker areas, I have to set threshold to 0.02 in order to see them.
Of course not, they're based on a simple absolute difference. You need something fancier to get good results everywhere. Try scxvid?
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet
Myrsloik is offline   Reply With Quote
Old 10th August 2017, 17:11   #32  |  Link
lansing
Registered User
 
Join Date: Sep 2006
Posts: 1,657
Quote:
Originally Posted by Myrsloik View Post
Of course not, they're based on a simple absolute difference. You need something fancier to get good results everywhere. Try scxvid?
I just tried it, I clicked on preview in the editor, and after a minute or two of loading, the preview window popped up and the whole program frozed.
lansing is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 11:57.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.