所有选项默认安装了python3.9.7(64bit)和VapourSynth R55(64bit)后,打开vsedit编辑:
import vapoursynth as vs
import sys
import havsfunc as haf
import mvsfunc as mvf
core = vs.get_core()
core.max_cache_size = 2000
a="1.mkv"
src = core.lsmas.LWLibavSource(a,threads=1)
src = core.std.SetFrameProp(src, prop="_FieldBased", intval=0)
src = mvf.ToRGB(src)
src.set_output()
按F5测试时出现了这样的错误:
Failed to evaluate the script:
Python exception: No module named 'havsfunc'
Traceback (most recent call last):
File "src\cython\vapoursynth.pyx", line 2728, in vapoursynth._vpy_evaluate
File "src\cython\vapoursynth.pyx", line 2729, in vapoursynth._vpy_evaluate
File "D:/Downloads/ANIME/Untitled.vpy", line 3, in
import havsfunc as haf
ModuleNotFoundError: No module named 'havsfunc'
在python命令行输入以下指令确认版本号:
import vapoursynth as vs
core = vs.get_core()
print(core.version())
出现以下错误:
>>> import vapoursynth as vs
>>> core = vs.get_core()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: module 'vapoursynth' has no attribute 'get_core'
>>> print(core.version())
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
NameError: name 'core' is not defined
>>>
在python module docs里面找到vapoursynth,并没有“get_core”的function也没有“havsfunc”的module
求解