Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Capturing and Editing Video > VapourSynth

Reply
 
Thread Tools Search this Thread Display Modes
Old 18th June 2015, 17:06   #1581  |  Link
jeremy33
Registered User
 
Join Date: Jun 2009
Posts: 172
Quote:
Originally Posted by sl1pkn07 View Post
install in the python3 sites-package

python -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())" for get the path

example for Arch https://aur4.archlinux.org/cgit/aur....-finesharp-git
I tried to install them in python3 dist-package and I have this error : "Instruction not allowed".
Do you know why ?

Quote:
Originally Posted by sl1pkn07 View Post
Thank you, I hope it will be add.
jeremy33 is offline   Reply With Quote
Old 18th June 2015, 17:32   #1582  |  Link
sl1pkn07
Pajas Mentales...
 
Join Date: Dec 2004
Location: Spanishtán
Posts: 497
Quote:
Originally Posted by jeremy33 View Post
I tried to install them in python3 dist-package and I have this error : "Instruction not allowed".
Do you know why ?
when install? when load (in vpy script)? when?

Code:
└───╼  python -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())"
/usr/lib/python3.4/site-packages
└───╼  ls $(python -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")/fine*
-rw-r--r-- 1 root root 6927 jun 16 19:30 /usr/lib/python3.4/site-packages/finesharp.py
testcase
Code:
import vapoursynth as vs
core = vs.get_core()
import finesharp
clip = core.std.BlankClip(format=vs.YUV420P8)
clip = finesharp.sharpen(clip)
clip.set_output()
Code:
└───╼  vspipe prueba.vpy -y --info -
Width: 640
Height: 480
Frames: 240
FPS: 24/1 (24.000 fps)
Format Name: YUV444P8
Color Family: YUV
Bits: 8
SubSampling W: 0
SubSampling H: 0
EDITED: do'h, i'm still noob

Last edited by sl1pkn07; 19th June 2015 at 05:46.
sl1pkn07 is offline   Reply With Quote
Old 18th June 2015, 21:30   #1583  |  Link
jeremy33
Registered User
 
Join Date: Jun 2009
Posts: 172
Code:
python3 -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())"
/usr/lib/python3/dist-packages
Code:
ls $(python3 -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")/fine*
/usr/lib/python3/dist-packages/finesharp.py
I have the error when I play a movie with mpv and, of course, vapoursynth :

Code:
mpv --vf-add=vapoursynth=/media/Data/vapoursynth.py "big buck bunny 480p h264.mkv"
Playing: big buck bunny 480p h264.mkv
 (+) Video --vid=1 (h264)
Opening video filter: [vapoursynth file=/media/Data/vapoursynth.py]
Instruction non permise
"Instruction non permise" = "Instruction not allowed"
jeremy33 is offline   Reply With Quote
Old 18th June 2015, 22:53   #1584  |  Link
foxyshadis
Angel of Night
 
foxyshadis's Avatar
 
Join Date: Nov 2004
Location: Tangled in the silks
Posts: 9,561
So what's in your vapoursynth.py? Have you tested it (replacing video_in with an actual source filter) in vsedit? Have you asked for help from mpv devs?
foxyshadis is offline   Reply With Quote
Old 19th June 2015, 00:13   #1585  |  Link
jeremy33
Registered User
 
Join Date: Jun 2009
Posts: 172
MPV and Vapoursynth work perfectly if I use these config files after the installation of MPV and Vapoursynth from the ppa :

Code:
$ mkdir -p "${HOME}/.config/vapoursynth"
$ tee "${HOME}/.config/vapoursynth/vapoursynth.conf" << 'EOF'
UserPluginDir=/Path/To/filters/
EOF
- add to ~/.profile
export PYTHONPATH=$PYTHONPATH:/Path/To/filters/
I tested with a simple vapoursynth.py script like this one from sl1pkn07 but I have the same error

Code:
import vapoursynth as vs
core = vs.get_core()
import finesharp
clip = core.std.BlankClip()
clip = core.fmtc.matrix(clip, mat="709", col_fam=vs.YUV)
clip = finesharp.sharpen(clip)
clip.set_output()
I don't asked for help from MPV devs because it's a Vapoursynth "problem". I just want to use Vapoursynth with the python scripts like finesharp right after the install without the need of some config files after the install.
They manage to do it on Arch so it can be possible on Ubuntu.

Last edited by jeremy33; 19th June 2015 at 00:18.
jeremy33 is offline   Reply With Quote
Old 19th June 2015, 05:51   #1586  |  Link
sl1pkn07
Pajas Mentales...
 
Join Date: Dec 2004
Location: Spanishtán
Posts: 497
works for me (edited my last post)

input.vpy
Code:
import vapoursynth as vs
core = vs.get_core()
clip = core.std.BlankClip(format=vs.YUV420P8)
clip.set_output()
filter.vpy
Code:
import vapoursynth as vs
import finesharp
core = vs.get_core()
clip = video_in
clip = finesharp.sharpen(clip)
clip.set_output()
sl1pkn07 is offline   Reply With Quote
Old 19th June 2015, 10:59   #1587  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Quote:
Originally Posted by jeremy33 View Post
Code:
python3 -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())"
/usr/lib/python3/dist-packages
Code:
ls $(python3 -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")/fine*
/usr/lib/python3/dist-packages/finesharp.py
I have the error when I play a movie with mpv and, of course, vapoursynth :

Code:
mpv --vf-add=vapoursynth=/media/Data/vapoursynth.py "big buck bunny 480p h264.mkv"
Playing: big buck bunny 480p h264.mkv
 (+) Video --vid=1 (h264)
Opening video filter: [vapoursynth file=/media/Data/vapoursynth.py]
Instruction non permise
"Instruction non permise" = "Instruction not allowed"
Last time I tried to use one of the plugins from that PPA (fmtconv), it was compiled incorrectly. It was not suitable for distribution due to the use of AVX instructions in some code path that is supposed to run on any old CPU with SSE2, not just those that have AVX. The result is exactly the error message you got.

Here is how to check:
Code:
gdb --args mpv etc
run
[prints "Instruction non permise"]
set disassembly-flavor intel
disassemble
[hit enter until you see "=>" on the left next to the illegal instruction]
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 19th June 2015, 11:29   #1588  |  Link
jeremy33
Registered User
 
Join Date: Jun 2009
Posts: 172
Quote:
Originally Posted by sl1pkn07 View Post
works for me (edited my last post)
Ok, little mistake so I tried that and that works ! Thank you.

Code:
import vapoursynth as vs
import finesharp
core = vs.get_core()
clip = video_in
clip = finesharp.sharpen(clip)
clip.set_output()
Now if I use my script that still don't work and I think jackoneill is probably right.

Quote:
Originally Posted by jackoneill View Post
Last time I tried to use one of the plugins from that PPA (fmtconv), it was compiled incorrectly. It was not suitable for distribution due to the use of AVX instructions in some code path that is supposed to run on any old CPU with SSE2, not just those that have AVX. The result is exactly the error message you got.
I run the gdb command and this is the error :

Code:
Program received signal SIGILL, Illegal instruction.
0x00007fffaeb57750 in vsutl::compute_fmt_mac_cst(double&, double&, VSFormat const&, bool, VSFormat const&, bool, int) () from /usr/lib/x86_64-linux-gnu/vapoursynth/libfmtconv.so
That's weird because Vapoursynth works if I use the config files after the install (mkdir -p "${HOME}/.config/vapoursynth" ...)

Last edited by jeremy33; 19th June 2015 at 11:35.
jeremy33 is offline   Reply With Quote
Old 19th June 2015, 12:40   #1589  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Maybe you have more than one copy of fmtconv.
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 19th June 2015, 12:53   #1590  |  Link
jeremy33
Registered User
 
Join Date: Jun 2009
Posts: 172
That don't seem to be the case. I search on my entire drive and I only found one copy of fmtconv.
jeremy33 is offline   Reply With Quote
Old 20th June 2015, 21:58   #1591  |  Link
jeremy33
Registered User
 
Join Date: Jun 2009
Posts: 172
That works !

djcj now use the original Makefiles from "https://github.com/EleonoreMizo/fmtc...ter/build/unix" to build fmtconv on the PPA.

Thank you very much
jeremy33 is offline   Reply With Quote
Old 24th June 2015, 10:22   #1592  |  Link
feisty2
I'm Siri
 
feisty2's Avatar
 
Join Date: Oct 2012
Location: void
Posts: 2,633

dunno why but vspipe failed to ouput "GrayS" clips, and preview in vseditor works good, so the vaporsynth core gotta be alright, guess it's a vspipe problem
did this on r28 test1
feisty2 is offline   Reply With Quote
Old 24th June 2015, 11:34   #1593  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Quote:
Originally Posted by feisty2 View Post

dunno why but vspipe failed to ouput "GrayS" clips, and preview in vseditor works good, so the vaporsynth core gotta be alright, guess it's a vspipe problem
did this on r28 test1
What is the script?
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 24th June 2015, 13:04   #1594  |  Link
feisty2
I'm Siri
 
feisty2's Avatar
 
Join Date: Oct 2012
Location: void
Posts: 2,633
now it's freaking me out...
I removed my modified RGVS.dll and FLT.dll from plugin folder, and it just works, like suddenly, I mean, I didn't even call things from RGVS.dll or FLT.dll in the python script, that doesn't make any sense at all, how's that even possible? and even if I just call things from RGVS.dll/FLT.dll, preview in vseditor works perfectly without any problem, why?
anyways, script
Code:
import vapoursynth as vs
core = vs.get_core()

def nlmcleansef (src, local=2.4, nlocal=0.8):
    core    = vs.get_core ()
    lflt    = core.knlm.KNLMeansCL (src, d=0, a=24, s=1, h=local).knlm.KNLMeansCL (d=0, a=24, s=0, h=local)
    ldif    = core.std.MakeDiff (src, lflt).knlm.KNLMeansCL (d=0, a=2, s=4, h=local)
    clip    = core.std.MergeDiff (lflt, ldif).knlm.KNLMeansCL (d=0, a=24, s=4, h=nlocal)
    return clip

clp = core.raws.Source("Y.rgb", 736, 480, src_fmt="GRAYS")
clp = nlmcleansef (clp)
clp.set_output ()
feisty2 is offline   Reply With Quote
Old 24th June 2015, 13:51   #1595  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Quote:
Originally Posted by feisty2 View Post
now it's freaking me out...
I removed my modified RGVS.dll and FLT.dll from plugin folder, and it just works, like suddenly, I mean, I didn't even call things from RGVS.dll or FLT.dll in the python script, that doesn't make any sense at all, how's that even possible? and even if I just call things from RGVS.dll/FLT.dll, preview in vseditor works perfectly without any problem, why?
anyways, script
Code:
import vapoursynth as vs
core = vs.get_core()

def nlmcleansef (src, local=2.4, nlocal=0.8):
    core    = vs.get_core ()
    lflt    = core.knlm.KNLMeansCL (src, d=0, a=24, s=1, h=local).knlm.KNLMeansCL (d=0, a=24, s=0, h=local)
    ldif    = core.std.MakeDiff (src, lflt).knlm.KNLMeansCL (d=0, a=2, s=4, h=local)
    clip    = core.std.MergeDiff (lflt, ldif).knlm.KNLMeansCL (d=0, a=24, s=4, h=nlocal)
    return clip

clp = core.raws.Source("Y.rgb", 736, 480, src_fmt="GRAYS")
clp = nlmcleansef (clp)
clp.set_output ()
Memory corruption is funny like that. See if Visual Studio can tell you where it happens.
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 25th June 2015, 04:22   #1596  |  Link
foxyshadis
Angel of Night
 
foxyshadis's Avatar
 
Join Date: Nov 2004
Location: Tangled in the silks
Posts: 9,561
Build everything in debug, especially VS. You'll find the culprit quickly enough.
foxyshadis is offline   Reply With Quote
Old 25th June 2015, 07:58   #1597  |  Link
feisty2
I'm Siri
 
feisty2's Avatar
 
Join Date: Oct 2012
Location: void
Posts: 2,633
after failed to trace any error down in the code
I tried to compile the original removegrain code from the vaporsynth master branch
and the same vspipe crash showed it fucking unwanted self again..
so the error actually comes from wrong compiling settings, what kind of special compiling parameter I gotta add to keep it from crashing?
feisty2 is offline   Reply With Quote
Old 25th June 2015, 17:49   #1598  |  Link
feisty2
I'm Siri
 
feisty2's Avatar
 
Join Date: Oct 2012
Location: void
Posts: 2,633
@Myrsloik
to find out what went wrong in float nnedi3 exactly, I decide to do something similar but somehow easier, adding 16bits support to eedi3
lucky me, I got the same problem here just like nnedi3
here are the differences between the original version and the incorrect 16bits version
https://github.com/IFeelBloated/eedi...f729b7358694fa
some guide about what I did wrong, plz?
it might help me figure out what's the float nnedi3 problem and we'll have a high bitdepth eedi3 also
feisty2 is offline   Reply With Quote
Old 25th June 2015, 18:16   #1599  |  Link
Myrsloik
Professional Code Monkey
 
Myrsloik's Avatar
 
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,588
Quote:
Originally Posted by feisty2 View Post
@Myrsloik
to find out what went wrong in float nnedi3 exactly, I decide to do something similar but somehow easier, adding 16bits support to eedi3
lucky me, I got the same problem here just like nnedi3
here are the differences between the original version and the incorrect 16bits version
https://github.com/IFeelBloated/eedi...f729b7358694fa
some guide about what I did wrong, plz?
it might help me figure out what's the float nnedi3 problem and we'll have a high bitdepth eedi3 also
I don't see anything obviously wrong in the code. You'll just have to step through it and see if something weird happens somewhere. Compare the behavior to the 8 bit version.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet
Myrsloik is offline   Reply With Quote
Old 26th June 2015, 05:34   #1600  |  Link
feisty2
I'm Siri
 
feisty2's Avatar
 
Join Date: Oct 2012
Location: void
Posts: 2,633
aside from eedi3, I uninstalled r28 test1 and rolled back to r27, and vspipe crash is gone, it's somehow compatible to plugins compiled by vs2015 rc again...
feisty2 is offline   Reply With Quote
Reply

Tags
speed, vaporware, vapoursynth

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 03:57.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.