Advertisement
DJATOM

Wrold Trigger script

Jan 28th, 2021
300
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.97 KB | None | 0 0
  1. import vapoursynth as vs
  2. from vapoursynth import core
  3. import atomchtools as at
  4. import cooldegrain as cd
  5.  
  6. import psutil
  7. p_handle = psutil.Process()
  8. p_handle.cpu_affinity([0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 22])
  9.  
  10. core.max_cache_size = 12000
  11.  
  12. def denoise_deband(clip):
  13.     clip16 = clip.fmtc.bitdepth(bits=16)
  14.     mask16 = at.retinex_edgemask(clip16, sigma=1.5).std.Expr('x 2.7 *')
  15.     pfclip = core.dfttest.DFTTest(clip16, tbsize=1, slocation=[0.0,0.4, 0.1,0.86, 0.3,2.4, 0.5,4.2, 0.7,6.5, 1.0,10.0], planes=0)
  16.     denc16 = cd.CoolDegrain(clip16, bits=16, tr=1, thsad=80, thsadc=80, blksize=8, pf=pfclip)
  17.     debc16 = core.f3kdb.Deband(denc16, range=7, y=44, cb=36, cr=36, grainy=64, grainc=42, output_depth=16)
  18.     return core.std.MaskedMerge(debc16, clip16, mask16, first_plane=True)
  19.  
  20. source = core.dgdecodenv.DGSource(r'N:\Encoding\World_Trigger\index\VOL17_01.dgi')
  21. source = core.std.Trim(source, 0, 32708)
  22. source.set_output(1)
  23. denoise_deband(source).set_output(2)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement