头像
mawen1250
核心会员
核心会员
帖子: 670
注册时间: 2011-07-24 20:33

mvsfunc-r8

Github | NMM

Examples:

代码: 全选

import mvsfunc as mvf

# Any input depth
clip = mvf.Depth(clip, depth=16)
# 16-bit integer output

# Any input depth
clip = mvf.Depth(clip, depth=32)
# 32-bit float output

# Any input format
clip = mvf.ToYUV(clip, css="420")
# YUV420P output

# Any input format
clip = mvf.ToRGB(clip, depth=8)
# RGB24 output (e.g. for previewing using vsedit)

# Faster way to preview with RGB24 output, for vsedit
clip = mvf.Preview(clip)

# Preview with CompatBGR32 output, for VirtualDub, AvsPmod, etc.
clip = mvf.Preview(clip, compat=True)

# Compare multiple clips, they will be interleaved into one clip
clip = mvf.Preview([clip1, clip2, clip3])

# Any input format
clip = mvf.BM3D(clip, sigma=[3,3,3], radius1=0) # radius1=0 for BM3D, radius1>0 for V-BM3D
# Same as input format
主要是一些wrap functions,方便某些功能、滤镜的使用,特别是BM3D
其实几个月前就写好了,本来想把nnedi3_resample给整合进来的,但因为太懒了不想碰那玩意儿所以……
上次由 mawen1250 在 2016-07-31 21:38,总共编辑 10 次。
头像
oribe
帖子: 8
注册时间: 2015-05-06 20:31

Re: mvsfunc-r1

py脚本是放在Python34的Lib\site-packages\vapoursynth位置吧
我什么也不知道——by 只知道抱姐姐们大腿的oribe
► 显示剧情透露 自助网盘
netsky123
帖子: 53
注册时间: 2015-01-26 14:18

Re: mvsfunc-r4

Failed to evaluate the script:
Python exception: nnedi3: plane index out of range
Traceback (most recent call last):
File "src\cython\vapoursynth.pyx", line 1484, in vapoursynth.vpy_evaluateScript (src\cython\vapoursynth.c:26808)
File "D:/Untitled.vpy", line 5, in <module>
clip = core.lsmas.LWLibavSource(source="D:\test.mp4")
File "C:\Users\LEGION\AppData\Local\Programs\Python\Python35\Lib\nnedi3_resample.py", line 242, in nnedi3_resample
Y = nnedi3_resample_kernel(Y, target_width, target_height, src_left, src_top, src_width, src_height, scale_thr, nsize, nns, qual, etype, pscrn, opt, fapprox, kernel, taps, a1, a2)
File "C:\Users\LEGION\AppData\Local\Programs\Python\Python35\Lib\nnedi3_resample.py", line 350, in nnedi3_resample_kernel
last = nnedi3_resample_kernel_vertical(last, target_width, src_left, src_width, scale_thr, nsize, nns, qual, etype, pscrn, opt, fapprox, kernel, taps, a1, a2, invks, invkstaps)
File "C:\Users\LEGION\AppData\Local\Programs\Python\Python35\Lib\nnedi3_resample.py", line 398, in nnedi3_resample_kernel_vertical
last = nnedi3_rpow2_vertical(input, eTimes, 1, nsize, nns, qual, etype, pscrn, opt, fapprox)
File "C:\Users\LEGION\AppData\Local\Programs\Python\Python35\Lib\nnedi3_resample.py", line 425, in nnedi3_rpow2_vertical
last = core.nnedi3.nnedi3(input, field, True, True, True, True, nsize, nns, qual, etype, pscrn, opt, fapprox)
File "src\cython\vapoursynth.pyx", line 1376, in vapoursynth.Function.__call__ (src\cython\vapoursynth.c:25123)
vapoursynth.Error: nnedi3: plane index out of range

请问这是什么问题呢?
为了测试,vs里写的就是git上的示例代码
clip = nnrs.nnedi3_resample(clip, clip.width * 2, clip.height * 2)
头像
Holy
核心会员
核心会员
帖子: 235
注册时间: 2010-09-24 9:28

Re: mvsfunc-r4

因為新版的 nnedi3 新增了 planes 參數,造成傳遞的引數位置錯了,把第 425 行改成這樣就行了。
► 显示剧情透露
图片

回到 “VapourSynth”