digitalFAQ.com Forums [Archives]

digitalFAQ.com Forums [Archives] (http://www.digitalfaq.com/archives/)
-   Avisynth Scripting (http://www.digitalfaq.com/archives/avisynth/)
-   -   Avisynth: Optimal script now fully adaptive (http://www.digitalfaq.com/archives/avisynth/4230-avisynth-optimal-script.html)

kwag 06-30-2003 10:33 PM

Quote:

Originally Posted by ovg64

Yes i see a diference of 20mb in file size, but :?: is there a difference
in Quality between 62.58% n 62.95% :?:

Nah :!:, there's not :)
Quote:

i dont think so but it would be great to be closer to the target w fast prediction. :)
Let's see: A CD-R is approxmately $0.25 each. About a quarter. So 30 MB would be 3.75% of 800. Now 3.75% of a quarter is 0.0093 cents. Do we really want to find the correct CQ to fill the disk with no visual quality gained for less than one cent :?: I don't :mrgreen:

-kwag

J-Wo 06-30-2003 11:10 PM

I think we could just up our prediction factor by a smidge if doing fast prediction, no? Like say 1.01 or 1.02

audi2honda 06-30-2003 11:16 PM

I keep coming up 5 or 6% short even though as you guys said the CQ values are close. I'm going to keep trying, but I think 48 frame samples at 2 per minute will really slow down prediction time, but we'll see. I haven't tried yet.

kwag 06-30-2003 11:21 PM

Quote:

Originally Posted by J-Wo
I think we could just up our prediction factor by a smidge if doing fast prediction, no? Like say 1.01 or 1.02

We could, but what guarantee do we have that when ToK is using fast prediction, the 0.5% sample is not over instead of under the wanted size :!:
So you could end with -30MB or with +30MB, depending if the sampler was -0.5% or +0.5% from wanted file size. I rather do a full prediction with a factor of 1.0 just to be sure. I'm currently starting to encode a complete different movie I haven't tried with the latest settings. It's "Under Siege 2". We'll see tomorrow how it comes out :)

-kwag

bman 07-01-2003 03:07 AM

@ Kwag
I'm encoding "Foreigner" Pal version and have 2 problems
1 . Encoding with last script is taking 8hr 20 min and with script before
last changes 3hr 35 min
CQ = 61 in both cases and res=704x576
with last script quality is slightly better (less mosquitos around subs )
but encoding time ~3 times slower ???? 8O 8O 8O
What could be the problem ???
2 . Prediction with Tok 0.0.5.2 or 0.0.5.3 with fast mode always
results files 40-50mb smaller then whanted .

I tryed to play with param's but cant get constant results with different movies .
bman

Abond 07-01-2003 08:16 AM

Hi bman,
For me ToK never worked correctly, so I tried another procedure which gave me correct results for PAL, but it is not wide tested. I will give you a link to the post
http://www.kvcd.net/forum/viewtopic....=asc&start=128
Try it, if you want.

bman 07-01-2003 08:31 AM

Quote:

Originally Posted by Abond
Hi bman,
For me ToK never worked correctly, so I tried another procedure which gave me correct results for PAL, but it is not wide tested. I will give you a link to the post
http://www.kvcd.net/forum/viewtopic....=asc&start=128
Try it, if you want.

Thank's Abond !
I'll try that as soon as I'll arrive home :D :D :D
bman

Krassi 07-01-2003 08:43 AM

Quote:

Originally Posted by bman
2 . Prediction with Tok 0.0.5.2 or 0.0.5.3 with fast mode always
results files 40-50mb smaller then whanted .

I tryed to play with param's but cant get constant results with different movies .
bman

Hi bman,
have you tried ToK 0.0.5.2 with a Sampler length of 24 or 48 :?: My predictions are within 1% since i use these settings (doesn't matter if i use faster prediction or the older one). You could also try to go for a higher value at samples/minute.

bman 07-01-2003 09:32 AM

Quote:

Originally Posted by Krassi
Quote:

Originally Posted by bman
2 . Prediction with Tok 0.0.5.2 or 0.0.5.3 with fast mode always
results files 40-50mb smaller then whanted .

I tryed to play with param's but cant get constant results with different movies .
bman

Hi bman,
have you tried ToK 0.0.5.2 with a Sampler length of 24 or 48 :?: My predictions are within 1% since i use these settings (doesn't matter if i use faster prediction or the older one). You could also try to go for a higher value at samples/minute.

I'm using 24 as sampler length !
I've try 48 :D
Thank's Krassy
bman

kwag 07-01-2003 09:38 AM

Here's my result on "Under Siege 2":
Code:

=============================================================
ToK Log: F:\temp2\under.avs
=============================================================
 
Resolution (fps):528x480 (23.976 fps)
Total Frames: 143220
Total Time  : 01:39:33
-------------------------------------------------------------
 
Audio Size: 83,622,000
Required Video Size: 735,578,000
 
Factor: 59.940
Desired Sample Size: 12,271,906
 
-------------------------------------------------------------
Prediction: 1st Group of Passes
-------------------------------------------------------------
 
Next CQ: 64.740. Sample Size: 13,759,185
Next CQ: 57.742. Sample Size: 11,472,843
Next CQ: 60.714. Sample Size: 11,571,574
Next CQ: 62.365. Sample Size: 11,584,085
Next CQ: 63.334. Sample Size: 12,776,402
Next CQ: 62.887. Sample Size: 12,245,618

Exit Condition: 0.500 % reached ! yahoo !
Tries  : 6
 

Final CQ: 62.887
Total Time For Predicition: 00:33:24

 
-------------------------------------------------------------
Encoding F:\temp2\under.avs
-------------------------------------------------------------
 
Encoding... CQ : 62.887
Final Encoded Size: 713,747,819
Total Time (all operations): 05:16:25
 
Finished

For a difference of ~-21MB and an accuracy of ~2.96%.

-kwag

bman 07-01-2003 10:05 AM

Thank's Kwag !!!
I'm encoding with 704x576 and it takes ~8.5hr to encode .
U have encoded 528x480 and it took ~5.25hr to encode .
So 704x576 / 528x480 *5.25 = 8.4 hr
It's about the time that took me to encode "The Foreigner" with CQ 61 .
I'm happy that my system is tuned up and quality is great too but 8.5hr
encoding is too much time for me , on job that could be done in 3.5hr with previous script and hardly noticable difference :? :? :?
Correct me if I'm wrong :? :? :wink:
bman

kwag 07-01-2003 10:11 AM

Quote:

Originally Posted by bman
Correct me if I'm wrong :? :? :wink:
bman

There is a HUGE difference in quality from the old 2.0x script (non-adaptive) to the new Motion Adaptive script :)

-kwag

bman 07-01-2003 10:30 AM

Quote:

Originally Posted by kwag
Quote:

Originally Posted by bman
Correct me if I'm wrong :? :? :wink:
bman

There is a HUGE difference in quality from the old 2.0x script (non-adaptive) to the new Motion Adaptive script :)

-kwag

Absolutely right !!!
We just missunderstand one each other :D
I'm talking about MA script before the last changes u made (with conditionalfilter and without )
With NEWEST script If u are encoding 528x480 it could be a big difference but not with 704x576 .
Even on 34" TV it's hard to see difference cos TV is smoothing most of mosquitos .
That's just my opinion , That's what I see :wink: :wink:
bman

Sykes 07-01-2003 10:48 AM

Script Screwed ?
 
Somethins wrong with jul 1st script 2.52
(Keep gettin white writing on the screen along with my movie that i am encoding)

jorel 07-01-2003 11:42 AM

Re: Script Screwed ?
 
Quote:

Originally Posted by Sykes
Somethins wrong with jul 1st script 2.52
(Keep gettin white writing on the screen along with my movie that i am encoding)


Sykes,download temporalcleaner here:
http://www.avisynth.org/~warpenterprises/

i think that you don't have this filter for use in the new script!
:wink:

editing:
no need the filter no more,
temporalcleaner was changed for temporalSoften.
copy the script again!
:wink:

kwag 07-01-2003 11:54 AM

Re: Script Screwed ?
 
Quote:

Originally Posted by Sykes
Somethins wrong with jul 1st script 2.52
(Keep gettin white writing on the screen along with my movie that i am encoding)

You bet you are :!:
Change this line:

ScriptClip("nf = round(YDifferenceToNext()+1)"+chr(13)+ "nf > 2 ? \

Dialhot's line read:
ScriptClip("nf = round(YDifferenceToNext())"+chr(13)+ "nf > 2 ? \
and the value would go to zero, which causes "division by zero".

With the above fix, now it never goes below 1 ;)

-kwag

kwag 07-01-2003 12:04 PM

Looking at the changes by Dialhot, I overlooked something :!:
The values are integer now, but that throws OFF completely the boundary between the switching of blurring and temporal filter. Before, there was a floating point precision. And now it's sharp values that jump from 1 to 2, and that's NO good :!:
I'm revising the script again :!: :!:

Edit:
Ignore this post. I need sleep. The script is correct :oops:


-kwag

Sykes 07-01-2003 07:36 PM

:wink:

vhelp 07-01-2003 09:00 PM

hi Kwag.. :)

Quote:

Well what can I say , here's a sample from the last encode
I think this just can't get any better ( at least for the next 48 hours )
This looks almost like ( or like? ) my DVD
** www.kvcd.net/k-pax-fixed-adaptive.mpg
Comments always welcome

-kwag
Just finished D/L'ing your latest sample clip. And, I must say, looks VERY
good in PDVD v3.0 !!

Please keep it up :lol:

Hay, we're gonna have a LONG weekend this week. Our company is letting
us go Thur and Friday !! And, I've got things cooken for this week/end..
See you then..

..TGIW, almost here hehe..

Be well all.
-vhelp

andybno1 07-02-2003 01:41 AM

I'm seein blocky areas in my encode anyone suggest what I can change or add to the optimal script datetd 1 july?

jorel 07-03-2003 09:38 AM

Quote:

Originally Posted by jorel
8O

please,someone answer me:

did you see the image(colors) "breathing" in each second
after the changes to "adaptive in the TemporalSmoother filter" :?:

the colors seems that encrease and decrease each second...
like beating!
:?

hey,me again.

i see the same but less "breathing" in each second!
just a "little few" beating changing every second!
little blocky areas too like andybno1 posted.

only i see it?
nobody see?
:?:

Dialhot 07-03-2003 09:45 AM

Quote:

Originally Posted by jorel
only i see it?
nobody see?
:?:

Sorry, I use temporalcleaner now :-)

But yo can try round(2/nf) insteed of round(3/nf) in the third parameter of temporalsoften.

jorel 07-03-2003 09:55 AM

sorry?
why?

post how you use temporalcleaner,
i want to test it too!
:wink:

ovg64 07-03-2003 10:04 AM

I think this is what Dialhot uses Jorel. :idea:

Quote:

ScriptClip("nf = round(YDifferenceToNext())"+chr(13)+ "nf >= 2 ? \
unfilter( -(fmin(nf*2, 100)), -(fmin(nf*2, 100)) ) : \
temporalcleaner(fmin(3+nf,7),fmin(8+nf,15)) ")


jorel 07-03-2003 10:11 AM

thank you Osvaldo!
:wink:

what's your results testing with temporalcleaner?

jorel 07-03-2003 10:59 AM

Phil and Osvaldo:

with temporalcleaner the colors are draw...seems better,
the size with my sample encrease a little but
straight "breathing" yet...like pulsing,beating :!:

:(

ovg64 07-03-2003 12:34 PM

hi Jo, i haven't really try TemporalCleaner in the MAS yet, but that pulsing that you are talking about sounds maybe like your memory defrager setting is too high, just a guess dude. :wink:

jorel 07-03-2003 12:53 PM

yes,Osvaldo..maybe this is the problem of "beating".

send me recomendations...what i do?
:?

ovg64 07-03-2003 12:59 PM

Quote:

Originally Posted by jorel
yes,Osvaldo..maybe this is the problem of "beating".

send me recomendations...what i do?
:?

I would put a very low (2-3mb) optimise at a low auto defrag level (40-50mb) thats what i do.

jorel 07-03-2003 01:18 PM

8O

i don't know how to do it.
please Osvaldo pm to me,
i am "off topic".
:)

Jellygoose 07-03-2003 02:35 PM

You can PM that to me too, I think it's maybe off-topic, but still informative. 8)

ovg64 07-03-2003 02:45 PM

:idea: Maybe you Guys should just disable the software n encode a clip to
make sure thats your problem before you go crazy guessing, just left
click exit on the icon.

ozjeff99 07-03-2003 07:17 PM

Kwag

Thought you might be interested in the way that the KVCD method has stopped someone in their tracks 8O Check this 8)

http://forum.doom9.org/showthread.ph...0&pagenumber=2

ozjeff99

FredThompson 07-04-2003 01:12 AM

He already knows, I've started hanging out here.

Right now I'm trying to figure out what noise filtering I do pre-KVCD and how that might mess things up. I doubt SpotRemover as a way to fill dropouts and scratches would interfere. Things like DarkSmoother need to be tested.

I'm working on field-oriented filtering right now and have run into a couple of problems with the optimal script. AviSynth doesn't have a chr function so there's got to be more script.

kwag 07-04-2003 01:20 AM

Quote:

Originally Posted by FredThompson

Right now I'm trying to figure out what noise filtering I do pre-KVCD and how that might mess things up. I doubt SpotRemover as a way to fill dropouts and scratches would interfere.

How about a heavy spatial filter :idea:
Spatial filters work on a frame by frame basis, not on adjacent frames like temporal filters. So maybe a mix of spatial filters will do the job :idea:

-kwag

FredThompson 07-04-2003 01:30 AM

It's not as simple as that with old film or any analog tape. Look at the image at the bottom of this page: http://www.geocities.com/fredthompson6

This shows a number of things including:

1) scratch/dropout restoration must be done on a per-field basis.
2) spatial filtering must be done on a per-field basis
3) scratch/dropout filtering must be done before decombing
(believe me, it's a LOT harder otherwise)
4) chroma filtering needs to be done first

In this case, greyscale() or tweak() works for chroma but only because this is a B&W film captured from VHS tape.

I'm also looking at near-black swim on camcorder and satellite source. That's where DarkSmoother comes in.

Am also wondering how to get rid of the swimming near the edges of satellite MPEG and at the beginning of a scene change. Some of that source is pre-compressed so very good but hte streamed stuff is noisy as all getout.

Tried encapsulating the optimal script but AviSynth is choking on it.

The idea is to have global variable at the top of the script so Joe Sixpack can easily configure it. These are followed by media-specific cleaning then the field split like so:

GetParity() ? nop() : ReverseFieldDominance()
even=SelectEven(SeparateFields()).KVCD_Filter()
odd=SelectOdd(SeparateFields()).KVCD_Filter()
Interleave(even,odd).Weave()

(That first line is to ensure order because DV is reversed.)

Problem is, AviSynth doesn't like the encapsulation. I'm PMing you the script right now.

kwag 07-04-2003 02:39 AM

Script just updated.
Now TemporalSoften "radius" paramer is also adaptive ;)
Artifacts (Gibbs) are now buried deeper :)

-kwag

jorel 07-04-2003 06:10 AM

hey,
8O
few "seconds" out and tons news and tons posts to read!
:wink:


All times are GMT -5. The time now is 04:05 AM  —  vBulletin © Jelsoft Enterprises Ltd

Site design, images and content © 2002-2024 The Digital FAQ, www.digitalFAQ.com
Forum Software by vBulletin · Copyright © 2024 Jelsoft Enterprises Ltd.