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. |
17th June 2022, 22:15 | #41 | Link | |
Registered User
Join Date: Oct 2001
Location: Germany
Posts: 7,419
|
I'm on Windows 11.
Quote:
I now opened the script in avsmod, changed the call to Code:
Exblend(mode=1, ExBfile="e:\Exbfile", debug=true, lv=5, dv=5) Tried to save the content of Debugview, but then Debugview, simple froze. -> took a screenshot and killed Debugview. Now E:\Exbfile_1.LOG was created, when I closed avspmod which contains: Code:
ExBlend: INFO, ExBlend: INFO, ExBlend() v1.04 - 18 Dec 2018 - (c) StainlessS. ExBlend: INFO, ExBlend: DEBUG, Limiting args to 'Mode 1' ExBlend: DEBUG, Checking Colorspace ExBlend: DEBUG, Checking valid 'mode' ExBlend: DEBUG, Checking valid 'pal' range ExBlend: DEBUG, Allocating fdat[] ExBlend: DEBUG, Allocating MetricsDat[] ExBlend: INFO, ------------------------------------ ExBlend: INFO, MODE = 1 ExBlend: INFO, PAL = 0 ExBlend: INFO, LOCKTHRESH = 1,00 ExBlend: INFO, ITHRESH = 3,00 ExBlend: INFO, SHOW = 5 ExBlend: INFO, EXBFILE = 'e:\Exbfile' ExBlend: INFO, VER = False ExBlend: INFO, REVIP = False ExBlend: INFO, OVERRIDE = NOT SET ExBlend: INFO, LV = 5 DEBUG ExBlend: INFO, DV = 5 DEBUG ExBlend: INFO, DISP = 1 EXBLEND [Default] ExBlend: INFO, DCLIP = NO ExBlend: INFO, COMPUB = 2 0=SSSS, 1=SDDS 2=DDDD [S=Source,D=DClip] ExBlend: INFO, DECIMATE = False ExBlend: INFO, DECOMPIX = 1 UNUSED ExBlend: INFO, DecClpIx = 1 ExBlend: INFO, DEBUG = True ExBlend: INFO, ------------------------------------ ExBlend: DEBUG, LOG Filename = e:\Exbfile_1.LOG ExBlend: DEBUG, LOG file Verbosity = 5 ExBlend: DEBUG, LOG DebugView Verbosity = 5 ExBlend: DEBUG, XBD Filename = e:\Exbfile.XBD ExBlend: DEBUG, FRAMES Filename = e:\Exbfile_Decimated.TXT ExBlend: DEBUG, ------------------------------------ ExBlend: DEBUG, Constructor, no Errors encountered. ExBlend: DEBUG, Constructor OUT >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ExBlend: INFO, [569] Lost Sequence: Detected=2 ExBlend: DEBUG, Destructor IN <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< ExBlend: DEBUG, Mode 1, checking if clip fully scanned. ExBlend: DEBUG, Mode 1, Buffer Incomplete ( 0,3 Percent) ExBlend: DEBUG, delete[] MetricsDat ExBlend: DEBUG, delete[] fdat ExBlend: DEBUG, Destructor OUT (CLOSING LOG) >>>>>>>>>>>>>>>>>>>> >>> Cu Selur Last edited by Selur; 18th June 2022 at 00:02. |
|
18th June 2022, 00:11 | #42 | Link | |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,992
|
OK, I think I twigged whats happening,
Quote:
I'm not on my compiler machine, and not even on windows at present, I'll see what I can do when I can. EDIT: I've never actually used avs2yuv. [or cant remember it if I have done] EDIT: I still doubt that it would do any good if it is to follow this Code:
TFM() # field match back to a film frames TDecimate() #remove duplicates
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? Last edited by StainlessS; 18th June 2022 at 00:18. |
|
18th June 2022, 00:42 | #43 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,992
|
Selur,
https://forum.doom9.org/showthread.p...53#post1846853 above linked RT_ForceProcess() will scan entire file and NOT return to frame 0 on completion. [if that is any good]
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? |
18th June 2022, 06:56 | #44 | Link |
Registered User
Join Date: Oct 2001
Location: Germany
Posts: 7,419
|
Thanks will look whether I get RT_ForceProcess working.
a. Okay, the link in that thread doesn't work, but I got the RT_Stats_25&26_x86_x64_dll_v2.00Beta13_20201229.zip from your MediaFire site. b. Looked at the source the TFM&Decimate isn't needed, source is wrongly flagged as interlaced while it's progressive (+ blended fields). -> okay, I got no idea how to use that properly. using: Code:
ClearAutoloadDirs() SetFilterMTMode("DEFAULT_MT_MODE", MT_MULTI_INSTANCE) LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\LSMASHSource.dll") Import("I:\Hybrid\64bit\Avisynth\avisynthPlugins\mtmodes.avsi") LoadPlugin("C:\Users\Selur\Desktop\ExBlend_x64.dll") LoadPlugin("C:\Users\Selur\Desktop\RT_Stats_x64.dll") LWLibavVideoSource("e:\clips\Courage the Cowardly Dog S02E17E18 SOURCE.mkv",cache=false,dr=true,format="YUV420P8", prefer_hw=0) org=last #Exblend(mode=1, ExBfile="e:\Exbfile", debug=true, lv=5, dv=5) RT_ForceProcess() #Exblend(mode=0,revip=true, show=0) #StackHorizontal(last, org) PreFetch(16) # output: color sampling YV12@10, matrix: bt709, scantyp: progressive, luminance scale: limited return last Cu Selur Ps.: Also uploaded the source to my GoogleDrive Last edited by Selur; 18th June 2022 at 07:20. |
18th June 2022, 14:25 | #45 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,992
|
Selur,
OK, Exblend only writes XBD file on exblend input clip [EDIT: ExBlend Filter] destructor, so we need to do a little hack for RT_ForceProcess thingy to work. Code:
VideoFileName ="E:\SELUR\Courage the Cowardly Dog S02E17E18 SOURCE.dgi" DGSource(VideoFileName) ORG=Last TMP=ORG TMP.Exblend(mode=1, ExBfile=".\Exbfile", debug=true, lv=5, dv=5) RT_ForceProcess() # Force PASS1 TMP=0 # Force Close ExBlend I/P clip [and so also destroy ExBlend Filter clip]. XBD file NOT written until ExBlend destructor is called. ORG Exblend(mode=2,ExBfile=".\Exbfile") # PASS2 Return last So, we had to kill input clip to Exblend instead of output clip. Making Last=0 [instead of "TMP=0"] after RT_ForceProcess() does not work, not sure why. EDIT: Above PASS2 is decimated result, so any StackHorizontal whatsit will be out-of-sync frames. EDIT: Metrics on last frame [single pass only] show 92.53% of maximum possible blend pair detections, I would only use ExBlend() if above about 95% or 96%. [EDIT: Although it is a short clip and does fluctuate about 92% -> 96%, longer clip would be better accuracy %]
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? Last edited by StainlessS; 18th June 2022 at 15:58. |
18th June 2022, 15:38 | #46 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,992
|
With stackhorizontal
Code:
VideoFileName ="E:\SELUR\Courage the Cowardly Dog S02E17E18 SOURCE.dgi" DGSource(VideoFileName) ORG=Last TMP=ORG TMP.Exblend(mode=1, ExBfile=".\Exbfile", debug=true, lv=5, dv=5) #return last Return Pass 1 RT_ForceProcess() TMP=0 # kill TMP clip and call ExBlend filter destructor ORG SHOW=1 Exblend(mode=2,ExBfile=".\Exbfile",Decimate=False,Disp=1,Show=SHOW) # Non decimated, Blend pair replaced with 2 x copies of ex-blended frame. Little colored block flags ex-Blended frame pair. #Exblend(mode=2,ExBfile=".\Exbfile") # Deblended & Decimated # Both below lines for Non Decimated ONLY. StackHorizontal(ORG,Last) #Subtract(ORG,Last) Return last
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? Last edited by StainlessS; 18th June 2022 at 16:02. |
20th June 2022, 14:27 | #47 | Link | |
Registered User
Join Date: Dec 2020
Posts: 94
|
Quote:
Code:
import vapoursynth as vs core = vs.core src = core.lsmas.LWLibavSource(r"C:\Users\conta\Videos\src\dog.mkv") decimate = src.std.SelectEvery(cycle=5, offsets=[0, 1, 2, 4]) decimate.set_output() |
|
20th June 2022, 16:58 | #48 | Link | |
Registered User
Join Date: Dec 2020
Posts: 94
|
Quote:
I will try to make a script to replace the damaged part using a mask. |
|
20th June 2022, 17:12 | #49 | Link | |
Registered User
Join Date: Oct 2001
Location: Germany
Posts: 7,419
|
Quote:
I'm looking for some way to automate this. |
|
6th August 2023, 22:04 | #51 | Link |
Registered User
Join Date: Jul 2023
Posts: 5
|
I have a video with a 29.97fps obtained using Telecine and already transcoded using progressive scan. The source material was not 24fps, but 25fps. That is using a sequence of 4 true frames and 2 mixed frames. The sequence of frames is constant throughout the video.
I tried using ExBlend plugin with PAL=1 flag. It generally does what I need, but automatic detection of mixed frames doesn't always work correctly. Sometimes the plugin falsely detects a 3/2 or 5/2 sequence probably because of poor video quality. Trying to change the values of some parameters and not getting the desired result, two questions arose: 1. Is it possible to hard specify the sequence 4/2? That out of every 6 frames of video the last two are always processed as mixed and no other frames are processed. 2. I noticed that deblended frames are visually different. They have more saturation and sharpness which makes them stand out a lot against the real frames. Is it possible any post-processing? Thank you! |
7th August 2023, 18:19 | #52 | Link | |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,992
|
In Mode=1,
Set PAL=1. Also, see "Override", https://forum.doom9.org/showthread.p...86#post1860486 Code:
ExBlend is intended to correct clips that do not stay in sequence, if you have a clip that does stay in sequence (and you are sure of that), you can force ExBlend to stay in sequence too using the manual override command file. If say the first, 1st blend index is at frame 2, you could create a text file containing the manual override command:- 2=*1000000 Thats it. (you would also need to set correct pal/film mode and such). Here we gave a command to set 1 million LONG BLEND PAIR's, it will cease when it comes to end of clip, and in the logs will tell you how many it actually set. This excessive repetition count will not be considered an error by the override command parser, however, trying to start a new command outside of clip range will be considered an error. Also, NOTE, all manual override commands MUST be in ascending order of frame number, you are NOT permitted to override previously set overrides, some sort of order has to be maintained. As an aid (and byproduct of this strict ordering) the parser can tell you (in logs) where the next permissable command may be set. If trying to set up a manual override command file, use the logs, they are your friend when trying to do this. 2) In old Exblend thread, there is a demo to show how is possible to process blended frames manually outside of Exblend, the demo uses a vertically blurred DCLip which you probably do not need. Anyway, can you at least have a play with it to see if you can figure out how to do it, I'm in pain with broken/dislocated ankle, and not in best mood nor able to think very straight [I'm on 6 different drugs, x number of times per day]. Thanks. [get back if problems and I'll try to assist as best I can]. https://forum.doom9.org/showthread.p...46#post1558846 Quote:
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? Last edited by StainlessS; 7th August 2023 at 18:48. |
|
7th August 2023, 19:06 | #53 | Link |
Registered User
Join Date: Feb 2002
Location: California
Posts: 2,706
|
Hah, I saw those stills in StainlessS' post and thought the OP was also working on 1971 Stanford campus protests. I then saw my name ...
I'd be happy to look at a clip of what the person is trying to fix, if one is available. |
7th August 2023, 19:42 | #54 | Link | |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,992
|
Quote:
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? |
|
25th September 2023, 19:23 | #55 | Link |
Registered User
Join Date: Aug 2016
Posts: 710
|
Thanks a lot for this filter! I am surprised to find it is even possible to do this in theory.
I am using it on this VHS transfer which looks like it was converted from 30i hard telecine to 30p using field blend deinterlacing, and ExBlend repairs it nicely and in realtime too (mode=0). Strangely it seems to work better and produce less "embossed" frames with lockthresh and ithresh both set to 100.0. I don't really know if I should be doing that or if it would create problems with other clips. I will need to gain some more experience with using it on various clips. For good frame pacing in mode 0 I seem to need to put in its own thread and preroll some frames, but that's probably specific to my system. Anyway the panning shot at 5:48 and 13:55 the actor's face are showing better results for me with those thresh settings set to 100.0 if that is of any interest to you. My script looks like this Code:
# source LWLibavVideoSource(source="Weeds (1987) VHSRip.mp4", stream_index=-1) # fix blended frames ExBlend(mode=0, show=0, lockthresh=100.0, ithresh=100.0).Prefetch(1).Preroll(8) TDecimate(mode=1, CycleR=1, Cycle=5).Prefetch(1) # smoothing QTGMC(InputType=2, TR2=3, EdiThreads=2).Prefetch(4) # fix black level blackLevel = -24.0 whiteLevel = 255.0/(255.0+blackLevel) z_ConvertFormat( \ pixel_type="RGBP8", \ colorspace_op="601:601:170m:limited=>rgb:601:170m:limited", \ dither_type="ordered").Prefetch(1) RGBAdjust( \ rb=blackLevel, bb=blackLevel, gb=blackLevel, \ r=whiteLevel, g=whiteLevel, b=whiteLevel, \ dither=true).Prefetch(1) z_ConvertFormat( \ pixel_type="YV12", \ colorspace_op="rgb:601:170m:limited=>601:601:170m:limited", \ dither_type="ordered").Prefetch(1) |
25th September 2023, 19:57 | #56 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,992
|
Sorry, cant get to it just yet, am messing with hardware and stuff, also
just tried and Avisynth aint working proper. Note, LSMashVideoSource is designed for mp4 container, does not need indexing and usually rock solid. I did down the mp4, I note, "Score by Angelo Badalamenti", the same guy who did Twin Peaks (also Blue Velvet and Mulholland drive, apparently). I'll havva look when I can.
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? |
26th September 2023, 04:25 | #57 | Link |
Registered User
Join Date: Aug 2016
Posts: 710
|
What a coincidence, I just saw Mulholland Drive last week and had read about that composer. The first thing that struck me about Weeds is how unusually good the soundtrack is. The VHS audio quality is strangely appealing with its wow and flutter. Strange that Nolte would make such an obscure little amateur film after the success of 48hrs.
|
26th September 2023, 12:48 | #58 | Link | |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,992
|
Posted elsewhere onsite
Quote:
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? |
|
4th October 2023, 07:44 | #59 | Link |
Registered User
Join Date: Jan 2018
Posts: 2,163
|
Hi, try your plugin, the result is good but I got wrong some frames, and I've no idea how to fix them, Do you have any suggestion values and parameters of Exblend to fix them???
Script: Code:
QTGMC(Preset="Very Slow", Sharpness=0).SelectEven() ORG=Last TMP=ORG TMP.Exblend(mode=1, ExBfile=".\Exbfile", debug=true, lv=5, dv=5) RT_ForceProcess() # Force PASS1 TMP=0 # Force Close ExBlend I/P clip [and so also destroy ExBlend Filter clip]. XBD file NOT written until ExBlend destructor is called. ORG Exblend(mode=2,ExBfile=".\Exbfile") # PASS2 Return last Frame 371 Frame 375 Frame 387 Frame 395 Frame 399 |
9th October 2023, 03:07 | #60 | Link | |
Registered User
Join Date: Aug 2016
Posts: 710
|
Quote:
So not even QTGMC deinterlacing will be able to produce clean progressive frames for ExBlend to work with, which is probably making it difficult for ExBlend to do its subtraction thing to pull out a clean unblended frame. The best I could manage was this: Code:
# reduce field structure problem nnedi3(field=-2).Prefetch(1) Merge(SelectEven(), SelectOdd()).Prefetch(1) # deblend to 24fps ExBlend(mode=0, show=0, lockthresh=100.0, ithresh=100.0).Prefetch(1).Preroll(8) TDecimate(mode=1, CycleR=1, Cycle=5).Prefetch(1) # final smoothing & sharpening QTGMC(InputType=0, preset="slow", TR2=1, FPSDivisor=2, EdiThreads=2).Prefetch(4) # to keep more resolution: InputType=2, FPSDivisor=1 There are still issues like on this sequence "embossed" frames and stutter: Perhaps you will get a better result using the prepass mode 1&2 -- I'll have a play around with that later. edit: tried it just now like your code example with mode1 followed by mode2 and got the same result as mode0 on those problematic sequences. Am I correct in hypothesising that the issue with embossed frames & stutter is occurring due to the source clip having cadence breaks in the GGGBBGGGBBGGGBB pattern causing deblend to subtract the wrong frame pair? Last edited by flossy_cake; 9th October 2023 at 05:15. |
|
Tags |
blending, unblending |
Thread Tools | Search this Thread |
Display Modes | |
|
|