logo Sign In

althor1138

User Group
Members
Join date
12-Feb-2011
Last activity
20-Aug-2023
Posts
637

Post History

Post
#592433
Topic
Info: cleaning up dirty frames for scenes
Time

RemoveDirtMC2  is used in the script I posted in post 2 or 3.  The workflow for the script is:

Stabilization (Depanestimate/Depanstabilize)

Dirt Removal (RemovedirtMC or RemovedirtMC2 depending on version)

Degraining (Mvanalysemulti/MVdegrainmulti)

optional interpolation(Manalyse/Mflowfps)

optional color adjustments (Coloryuv/autolevels/levels)

 

There are other parameters for sharpening and blurring but that's the basic gist of things.

 

Here's a page that has collected a lot of the motion comepensated dirt removers.  You'll notice removedirtmc is now up to version 4 and even removedirthq.  Each one uses the prior version to build upon, I think. So you can't call removedirtmc4 without also having 1,2, and 3.

EDIT:  Looks like Removespots is the one that is dependent on the earlier versions and Removedirt is only up to removedirtmc2 and removedirthq.  I was looking at the wrong functions lol.

Post
#588440
Topic
Info: cleaning up dirty frames for scenes
Time

I've also been playing with capturing the optical audio tracks on that 1 sec clip I posted the other day.  I've managed to capture it by cropping each channel with avisynth and saving it as a 24bit bitmap and opening the waveform image in a program called imagetosound.  I've managed to capture it at 32400 samples per second with 8bits per channel(limited by the resolution).  I'm wondering how you guys are going about capturing it and what kind of quality it achieves? The 1 second I got sounds pretty awesome lol.

 

EDIT:  Little off topic but I didn't know where else to put it.

Post
#587911
Topic
Info: cleaning up dirty frames for scenes
Time

Ha. No I was talking about a 576p clip.  Well I could show a few of the stills but it wouldn't demonstrate much in the way of the stabilization. 

Perhaps I can just tell the process how I did it.  I flipped it and then used something called centertracker to focus on the sprockets on the side and then it feeds adjustment parameters to avisynth.  It works very well and since it is only looking at the holes there is never a chance that it will lock onto "bad" motion in different scenes.

Post
#587616
Topic
Idea & Info: Star Wars Deleted Scenes - Reincorporated?
Time

pittrek said:

Althor - is that what you achieved with this script ? http://originaltrilogy.com/forum/topic.cfm/cleaning-up-dirty-frames-for-scenes/post/571455/#TopicPost571455

It's been awhile since I encoded these but yes I believe those are the parameters I used.

Edit:  Keep in mind that these were 720p sources and not the higher resolution and bitrate that the blu's would offer.

Post
#587592
Topic
Idea & Info: Star Wars Deleted Scenes - Reincorporated?
Time

pittrek said:

althor1138 said:

Fox sent me a nastygram over the youtube videos so I took them down just to avoid any trouble.  Just in case anybody was wondering why the links I posted don't work.

Any chance to upload it somewhere else ? Like mediafire etc. ?

I've put some of them on Vimeo as well.  We'll see how long those last.

 

3PO Speeder

Blue Milk

Tosche

Luke Biggs

Luke Leia Hoth

PW=OT

Post
#586447
Topic
Info Wanted: Color Matching? - most accurate pre-97 ANH home video release?
Time

DISCLAIMER:  I know very little about what I'm about to say :).

I was thinking about this and I'm wondering if better results could be had by cropping the frames to 2 wide rows of horizontal or vertical lines of pixels and then running Colourlike on each row and then pasting them back together to make the entire image.

It should keep the filter from applying values to the entire image and limit it to a certain area.  I'd imagine both images would have to be aligned fairly well. 

Maybe something like the line below could be used instead of Colourlike.

ScriptClip(clip1,"ColorYUV(off_y(averageluma(clip2)-averageluma(clip1)),off_u(averagechromau(clip2)-averagechromau(clip1)),off_v(averagechromav(clip2)-averagechromav(clip1)))")

I'm not sure if it's any faster or more accurate but I've had some good results with it before.

 

Edit:  After playing around with this idea for a little bit I now realize it was probably a stupid idea. 

Post
#574991
Topic
Idea & Info: Star Wars Deleted Scenes - Reincorporated?
Time

SS4DarthPayne said:

I legally own the bonus disc, but have no idea how to Avisynth. Is it hard to learn? I am currently engulfed by school, but at some point in the future I would definitely like to take a crack at the deleted scenes restoration myself, if no one else has done it and shared it with others. 

Sounds like N1 is using this coupled with some other software that should produce some good results. 

Avisynth has a learning curve and it's sometimes hard to find the right plugin for the job but other than that it's quite fun.  I have to say it is probably the best freeware I've ever downloaded.

  If you have any knowledge of scripting it will maybe come naturally to you.  I started learning it at avisynth.org using just the base package of plugins that comes with it and after i had figured out how to make some easy scripts I started looking through all of the available external plugins.  Definitely download the latest avsp mod so you can have a gui with video preview.  Otherwise you'll be using virtualdub to open the scripts for a preview.

Post
#573601
Topic
Idea & Info: Star Wars Deleted Scenes - Reincorporated?
Time

Yes it is an "off-the-shelf" avisynth script used for 8mm restoration.  It's just had a few of the parameters tweaked.

Making the clips available without the original comparison is something I could do but...

I don't own the blu-rays and so these are from a re-encoded 720p source grabbed from the innernets so I think it would be best if someone interested in doing a restoration of these took a look here and recreated the results themself with a higher quality source clip.

Post
#573449
Topic
Idea & Info: Star Wars Deleted Scenes - Reincorporated?
Time

Sluggo said:

althor1138 said:

Here's the clip.  I think as far as dirt removal it worked pretty good.  It's not perfect and the tape splices,horizontal lines, and vertical lines are still present. 

Perhaps this script would speed up the process of bringing these scenes up to a presentable standard? They are gonna need a little more TLC than just this script but it certainly helps with dirt removal and sharpening. I've turned the sharpening way down to where it's just a bit sharper than the original scene.  It might be better with less or a bit more.  I'm not an expert at this by any means.

EDIT:

Here's another from ESB.

That is some smooth work.  I hope it works just as well in the hi-def.

After playing around with the script for awhile now I'd say it works just as good or even better in HD.  Of course some of the parameters have to be adjusted for higher resolution. The downside really is that it is pretty slow.

 

EDIT:

here's some more scenes.

Beru's blue milk.

Luke and Biggs.

Luke and 3-PO.

Post
#571455
Topic
Info: cleaning up dirty frames for scenes
Time

3PO Speeder

Blue Milk

Tosche

Luke Biggs

Luke Leia Hoth

PW=OT

Here's the changes to the script that I made.  I'm only posting the parameter variables as the rest of the script shouldn't be messed with except to trim the clip to whatever frames you want to process. Obviously if you want a different resolution for the end product you'll have to change it from 720x576 to whatever you want.

 

 

# film restoration script by videoFred.
# version with frame interpolation
# modified 30 august 2010
# added removedirtMC() as suggested by John Meyer
# cleaning, degraining, resizing, stabilizing, sharpening, auto-levels and auto-white balance.
#=============================================================================================

film="PATH TO FILM" # source clip, please specify the full path here

#PARAMETERS
#----------------------------------------------------------------------------------------------------------------------------
result="results4" # specify the wanted output here

trim_begin=0  play_speed=24  #trim frames and play speed (PAL: 16.6666 or 18.75)

numerator= 24  #numerator for the interpolator (final frame rate)
denumerator= 1 #denumerator  example: 60000/1001= 59.94fps


#COLOR AND LEVELS PARAMATERS
#----------------------------------------------------------------------------------------------------------------------------
saturation=1.2   #for all outputs

gamma= 1.1 # for all outputs

blue= -0  red= -0  #manual color adjustment, when returning result3 or result4. Values can be positive or negative


black_level=0  white_level=255 output_black=0  output_white=255 # manual levels, when returning result4
 

#SIZE, CROP AND BORDERS PARAMETERS
#----------------------------------------------------------------------------------------------------------------------------
CLeft=0  CTop=0  CRight=0  CBottom=0  #crop values after Depan and before final resizing

W=720  H=576  #final size after cropping

bord_left=0  bord_top=0  bord_right=0  bord_bot=0  #720p= borders 150


#STABILISING PARAMETERS
#----------------------------------------------------------------------------------------------------------------------------
maxstabH=0
maxstabV=0 #maximum values for the stabiliser (in pixels) 20 is a good start value

est_left=40   est_top=40  est_right=40  est_bottom=40  est_cont=1.4  #crop and contast values for special Estimate clip


#CLEANING PARAMETERS
#--------------------------------------------------------------------------------------------------------------

dirt_blur= 0.1 # some blur before cleaning to avoid pixel artifacts
dirt_strength=80 # set this lower for clean films.


#DENOISING PARAMETERS
#----------------------------------------------------------------------------------------------------------------------------


denoising_strength= 2000  #denoising level of second denoiser: MVDegrainMulti()
denoising_frames= 3  #number of frames for averaging (forwards and backwards) 3 is a good start value
block_size= 16  #block size of MVDegrainMulti()
block_size_v= 16
block_over= 8  #block overlapping of MVDegrainMulti()




# FOUR STEP SHARPENING PARAMETERS
#--------------------------------------------------------------------------------------------------------------------------------

USM_sharp_ness1= 60   USM_radi_us1= 3  #first sharpening (UnsharpMask) after cleaning with removedirtMC()

USM_sharp_ness2= 30    USM_radi_us2=2   #second harpening (UnsharpMask) after cleaning with removedirtMC()

USM_sharp_ness3= 20    USM_radi_us3=1   #third sharpening (UnsharpMask) after degraining with MVDegrainMulti()


last_sharp= 0.4 #final sharpening step after interpolation

last_blur= 0.2 #this smooths out the heavy sharpening effects



#AUTO LEVELS PARAMETER
#--------------------------------------------------------------------------------------------------------------------------------
X=2   # X is a special parameter for reducing the autolevels effect on the whites
X2=2  # X2 is a special parameter for reducing the autolevels effect on the blacks




# END VARIABLES, BEGIN SCRIPT
#=================================================================================================================================

Post
#571449
Topic
Idea & Info: Star Wars Deleted Scenes - Reincorporated?
Time

Here's the clip.  I think as far as dirt removal it worked pretty good.  It's not perfect and the tape splices,horizontal lines, and vertical lines are still present. 

Perhaps this script would speed up the process of bringing these scenes up to a presentable standard? They are gonna need a little more TLC than just this script but it certainly helps with dirt removal and sharpening. I've turned the sharpening way down to where it's just a bit sharper than the original scene.  It might be better with less or a bit more.  I'm not an expert at this by any means.

EDIT:

Here's another from ESB.