logo Sign In

Info Wanted: Averaging the various versions of the 2004 master? — Page 2

Author
Time

I’d actually be pretty interested to hear your results of using a median script on these various sources. I do think it runs the risk of basically selecting pixels from the same source all the time, due to slight color differences between the sources. That might be ok, if you rig it so the best source is likely to have the median pixel values, except in the case of encoding error, etc.

On another note, did you happen to see any other HDTV rips of Episode I? The Blu Rays of TPM and AOTC are so different as to make them unusable for this process, and you need three sources to do a median. I have the Premiere, SKY and Cinemax sources for AOTC, but only the first two for TPM.

Also, I know it’s somewhere else, but could you post your motion compensation script? I’d like to see how it works with these.

If I had some gum, I’d chew a hole into the sun…

Author
Time

I was going to write a Npassaverage function but it seemed much easier to write a 3 and 5 pass average separately. I don’t think we’ll ever see a need for a 7passaverage and it has to be an odd number greater than 1 so it kind of narrows it down to 3 and 5. The middle clip is the output clip in both functions so pass3 for the 5pa and pass2 for the 3pa.

Function FivePassAverage(clip pass1,clip pass2,clip pass3, clip pass4, clip pass5)
{
interleave=interleave(pass1,pass2,pass3,pass4,pass5)
super=msuper(interleave,pel=2,mt=true)
multivectors=manalyse(super,multi=true,delta=2,mt=true)
multiclip=mcompensate(interleave,super,multivectors,mt=true,tr=2,center=true)
average=temporalsoften(multiclip,2,255,255,50,2).selectevery(25,12)
return(average)
}

Function ThreePassAverage(clip pass1,clip pass2,clip pass3)
{
interleave=interleave(pass1,pass2,pass3)
super=msuper(interleave,pel=2,mt=true)
multivectors=manalyse(super,multi=true,delta=1,mt=true)
multiclip=mcompensate(interleave,super,multivectors,mt=true,tr=1,center=true)
average=temporalsoften(multiclip,1,255,255,50,2).selectevery(9,4)
return(average)
}

I believe the math is right. This should only use the motion compensated frames when temporalsoften compares surrounding frames instead of the actual clip frames. This is set by default to 255 for the luma and chroma threshold so it will hard blend everything.

So far testing of the hdtv caps has not really been beneficial that I can tell. The good news is that, as far as I can tell, the hdtv caps and blu-ray are perfectly registered against one another after doing a quick x/y adjustment. I guess that’s no big surprise since they all came from the same digital master assumedly.

Luke threw twice…maybe.

Author
Time
 (Edited)

There are some scenes in the HDTV versions, where the compression is downright awful - well at least in Schorman’s version but with his attention to detail and the huge bitrate of those releases, I have to assume that it is present even in the best available sources and I was hoping that maybe that could be helped a little by averaging the different sources but I don’t know enough about the process - I just assumed the program would compare the three or more sources and only keep what they all have in common, thus eliminating some artifacts.

In the scene, where Leia meets the Ewok in ROTJ, I actually ended up rotoscoping the original eyes into the BD footage, rather than using the full HDTV shots, because the difference in compression was stupendous.

Author
Time

That can be done where it only keeps pixels that are close to each other and discards the rest. The functions above are set to 255 threshold but if you turned it down to say 7 or 10 it would only keep things that are very alike. I’ve just not found a scene yet where it seems to really benefit from it.

I’ve noticed the sky hdtv cap has really bad artifacting when there is high motion vs the premiere cap. So far it seems like it’s just better to go with the premiere cap in these situations rather than trying to blend them.

Luke threw twice…maybe.

Author
Time

Yes this would work, if you had enough sources and can align them correctly you will potentially get rid of some of the compression artefacts and potentially recover some lost detail etc.
We do this all the time in astronomy, lately we have been stacking images from different sources, and it works well, but the alignment is really the problem, if you get that right then median stacking should improve things.

Donations welcome: paypal.me/poit
bitcoin:13QDjXjt7w7BFiQc4Q7wpRGPtYKYchnm8x
Help get The Original Trilogy preserved!

Author
Time
 (Edited)

These are all from the same source, so registration shouldn’t really be a problem. And yeah, I guess you’d need a lot of sources for things to really improve but maybe if we could get the digital releases from iTunes and Hulu and such, we could eventually get closer to the source files.