I am trying to make gifs but when I try to encode video I get this error. not sure if I'm missing a plugin or something.
Failed to evaluate the script:
Python exception: lsmas: failed to construct index.
Traceback (most recent call last):
File "src/cython/vapoursynth.pyx", line 2244, in vapoursynth.vpy_evaluateScript
File "src/cython/vapoursynth.pyx", line 2245, in vapoursynth.vpy_evaluateScript
File "", line 19, in
File "src/cython/vapoursynth.pyx", line 2069, in vapoursynth.Function.__call__
vapoursynth.Error: lsmas: failed to construct index.
+ Reply to Thread
Results 1 to 8 of 8
-
-
Post your script
Possibly lsmash cannot read your source. What is your source ?
You can try another lsmash build , or another source filter such as ffms2 -
import vapoursynth as vs
core = vs.get_core()
import os
import vapoursynth as vs
import havsfunc as haf
import G41Fun as fun
import mvsfunc as mvs
import descale as descale
import kagefunc as kage
core = vs.get_core()
#core.max_cache_size = 1000 #Use this command to limit the RAM usage. 1000 or 2000 is fine.
script_dir = os.path.dirname(__file__)
rel_path = "video_cut/cut.mkv"
abs_file_path=os.path.join(script_dir, rel_path)
video = core.lsmas.LWLibavSource(source=abs_file_path)
#Trim returns a clip with only the frames between the arguments first and last, or a clip of length frames, starting at first. a = first frame, b = last frame
#video = core.std.Trim(video, a, b)
#Resizer content goes here
video = haf.QTGMC(video, Preset="Slower", TFF=True)
video = core.fmtc.resample(video, css="444")
video = descale.Debilinear(video, 272,483)
video = core.knlm.KNLMeansCL(video, 0, 6, 4, 4.39, channels="YUV")
video = fun.FineSharp(video, sstr=1.23)
video = core.std.CropRel(video, left=38, top=62, right=66, bottom=121)
video.set_output()
I just downloaded yesterday, but when you say source do you mean the video I am creating the gif from? -
ah, am I supposed to change that information? (the cut.mkv / directory / video_cut) that stuff was what I copy and pasted from the script.vpy document from the vapoursynth folder.
the video is an mp4 downloaded from YouTube using 4k video downloader. -
Yes, you need to enter the correct path and filename, otherwise it cannot find which video you're referring to
You probably want to change the script and filters; for example, a video downloaded from youtube will be progressive, so you wouldn't use QTGMC -
Until you decide what you want to do (how to process the video, which filters to use), I would comment out all those filter lines, or delete them. Those crop values are for a different video and chances are you're not going to use the same filters. They were just meant as an example script
#video = haf.QTGMC(video, Preset="Slower", TFF=True)
#video = core.fmtc.resample(video, css="444")
#video = descale.Debilinear(video, 272,483)
#video = core.knlm.KNLMeansCL(video, 0, 6, 4, 4.39, channels="YUV")
#video = fun.FineSharp(video, sstr=1.23)
#video = core.std.CropRel(video, left=38, top=62, right=66, bottom=121)
video.set_output()
Similar Threads
-
Vapoursynth error
By plshelpvapoursynth in forum Newbie / General discussionsReplies: 9Last Post: 23rd Aug 2020, 23:19 -
Vapoursynth colour issue
By ashateli in forum Video ConversionReplies: 8Last Post: 15th Jul 2020, 16:07 -
wmv Avisynth/Vapoursynth?
By Selur in forum Newbie / General discussionsReplies: 0Last Post: 5th Sep 2019, 13:59 -
encoding with vapoursynth.
By zanzar in forum Newbie / General discussionsReplies: 31Last Post: 7th Mar 2019, 14:57 -
StaxRip 1.7.0.0 with Vapoursynth ?
By locky in forum Video ConversionReplies: 6Last Post: 24th Jan 2018, 18:08