nagadomi / waifu2x

Image Super-Resolution for Anime-Style Art
http://waifu2x.udp.jp/
MIT License
27.56k stars 2.71k forks source link

Failure to work on my HP z400 & HP z820 #87

Open alijose opened 8 years ago

alijose commented 8 years ago

Hello nagadomi,

first let me congratulate you with this incredible upscaling masterpiece, im saying that since I am a technical engineer that works in the media domain and I realized after experimenting and trying your waifu application on hosted on your g2.8xlarge(what a fine peace of art) server and compared its result to many other upscaling hardware & software tools, congrats again for your distinguished software :)

I tried to install your waifu2x on my ubuntu 14.04 HP Z820 & Z400, but unfortunately met the same error on both machines. Although on the HP Z820, it successfully ran using the application on WINDOWS 7, but for both machines it didnt work on UBUNTU 14.04. I followed the steps posted by you, installed cuda > installed torch> installed luarocks packages > got wifu from github > validate: unfortunately failed. I met same error on both machines after running the "th waifu2x.lua" which is

/home/jose/torch/install/bin/luajit: cannot open waifu2x.lua: No such file or directory stack traceback: [C]: in function 'dofile' ...jose/torch/install/lib/luarocks/rocks/trepl/scm-1/bin/th:145: in main chunk [C]: at 0x00406670 I almost sure luarocks libraries & the torch are just working fine, my doubts are regarding the CUDA software. In my HP Z820 i have HP Z400 i have an nvidia Quadro FX 3800 , the CUDA-Z app clearly states that the it "found 1 CUDA device" and give me clear specs of the device (I ran it only one the HP Z400).

Do you have any suggestion? your help would be greatly valued and appreciated as I always look further into study and experiment everything related to video codecs and upscaling, it was my master's thesis research topic and I still can't move on its a fascinating world

CharAznableLoNZ commented 8 years ago

Works fine on my 14.04 Z400 workstation using a 550ti. Go into the BIOS and make sure VGA Snooping is disabled. Also, make sure you're launching the lua from the the Waifu2x folder that has all the other files in it. Solved another issue of mine. I can try to look through mine and dump some configs so you can compare if you want.

nagadomi commented 8 years ago

/home/jose/torch/install/bin/luajit: cannot open waifu2x.lua: No such file or directory

Does waifu2x.lua exist in your working directory?

git clone --depth 1 https://github.com/nagadomi/waifu2x.git
cd waifu2x
ls -la waifu2x.lua
th waifu2x.lua
alijose commented 8 years ago

Yes it does exist in my home folder ~/waifu2xa On Feb 27, 2016 8:53 AM, "nagadomi" notifications@github.com wrote:

/home/jose/torch/install/bin/luajit: cannot open waifu2x.lua: No such file or directory

Does waifu2x.lua exist in your working directory?

git clone --depth 1 https://github.com/nagadomi/waifu2x.git cd waifu2x ls -la waifu2x.lua th waifu2x.lua

— Reply to this email directly or view it on GitHub https://github.com/nagadomi/waifu2x/issues/87#issuecomment-189587764.

nagadomi commented 8 years ago

And, did you get this error?

/home/jose/torch/install/bin/luajit: cannot open waifu2x.lua: No such file or directory

Can the file be read?

cat ./waifu2x.lua
th ./waifu2x.lua
alijose commented 8 years ago

Ok i didnt try the cat ./waifu2x.lua command but i did try to double click on the waifu2x.lua in the ~/waifu2x directory and it opened and i could read the lines. As for the "th ./waifu2x.lua" i also didnt try this command and unfortunately i cannot try it as Saturdays & Sundays are weekend holiday and our office is locked till Monday (this is embarrassing you are dedicating from your time to help me but i am not able to reach my computer) On Feb 27, 2016 9:10 AM, "nagadomi" notifications@github.com wrote:

And, did you get this error?

/home/jose/torch/install/bin/luajit: cannot open waifu2x.lua: No such file or directory

Can the file be read?

cat ./waifu2x.lua th ./waifu2x.lua

— Reply to this email directly or view it on GitHub https://github.com/nagadomi/waifu2x/issues/87#issuecomment-189598097.

nagadomi commented 8 years ago

If you get an error when trying to execute the following command, it maybe a CUDA issue.

th -e "require 'cunn'"

But I don't know why you got "waifu2x.lua: No such file or directory".

alijose commented 8 years ago

Ok i will make sure to try that first thing on Monday and will get back to you soonest On Feb 27, 2016 9:28 AM, "nagadomi" notifications@github.com wrote:

If you get an error when trying to execute the following command, it maybe a CUDA issue.

th -e "require 'cunn'"

But I don't know why you got "waifu2x.lua: No such file or directory".

— Reply to this email directly or view it on GitHub https://github.com/nagadomi/waifu2x/issues/87#issuecomment-189599950.

alijose commented 8 years ago

ok, 1- cat ./waifu2x.lua works fine 2- th ./waifu2x.lua still same error /home/jose/torch/install/bin/luajit: /home/jose/torch/install/share/lua/5.1/trepl/init.lua:384: /home/jose/torch/install/share/lua/5.1/trepl/init.lua:384: /home/jose/torch/install/share/lua/5.1/torch/init.lua:102: bad argument #2 (invalid parent class name nn.Module) stack traceback: [C]: in function 'error' /home/jose/torch/install/share/lua/5.1/trepl/init.lua:384: in function 'require' ./waifu2x.lua:5: in main chunk [C]: in function 'dofile' ...jose/torch/install/lib/luarocks/rocks/trepl/scm-1/bin/th:145: in main chunk [C]: at 0x00406670

3- th -e "require 'cunn'" first was giving an erro, then I used to command "luarcoks install cunn" and cunn was installed, when running the (th -e "require 'cunn'") again its giving me this error: THCudaCheck FAIL file=/tmp/luarocks_cutorch-scm-1-3216/cutorch/lib/THC/THCGeneral.c line=16 error=35 : CUDA driver version is insufficient for CUDA runtime version /home/jose/torch/install/share/lua/5.1/trepl/init.lua:384: /home/jose/torch/install/share/lua/5.1/trepl/init.lua:384: cuda runtime error (35) : CUDA driver version is insufficient for CUDA runtime version at /tmp/luarocks_cutorch-scm-1-3216/cutorch/lib/THC/THCGeneral.c:16

nagadomi commented 8 years ago

It's seems to be CUDA installation issue. You need to update nvidia graphics driver. See http://docs.nvidia.com/cuda/cuda-getting-started-guide-for-linux/index.html

alijose commented 8 years ago

Ok i will first thing tomorrow and come back to you. On Feb 29, 2016 8:54 PM, "nagadomi" notifications@github.com wrote:

It's seems to be CUDA installation issue. You need to update nvidia graphics driver. See http://docs.nvidia.com/cuda/cuda-getting-started-guide-for-linux/index.html

— Reply to this email directly or view it on GitHub https://github.com/nagadomi/waifu2x/issues/87#issuecomment-190331349.

alijose commented 8 years ago

ok sorry for the late reply.

I tried everything you said but just didnt work fine on my pc apparently a software issue with that cuda!

around a week ago, I rented from amazon the the ec2 8x-large video processign server as I previously read that this the server you are currently using on your web hosting the "waifu2x.udp.jp". I followed the instruction step by step but dont know why it just didnt work, it gave me some errors, tried to troubleshoot it but no matter what I solve another error pops up again! So i solved the problem by using an image with pre-installed of ubuntu 14.04 & Cuda & torch, but i had to alter something with the torch by uninstalling the i-torch then installing the normal torch, then everything worked fine.

I used the server for approximately 6 hours, you know it is rented per hour, I did several tests, it gave pretty nice results. But there is something just confused me; when I ran the command to upscale and de-noise sequence of images, the first couple outputted images were nicely up-scaled and de-noised, but everything after that was really distorted even worse than the original image up-scaled by the normal photo viewer. However if I upscale the same image on your web or on that server in a single order, it gives a clean up-scaled de-noised output.

Just felt like sharing the experience maybe it would be helpful for the future.

Again, great work(Y)

nagadomi commented 8 years ago

I relesed public AMI

Region: us-east-1 (N.Virginia)
AMI ID: ami-568f823c
AMI NAME: waifu2x-server
Instance Type: g2.2xlarge
OS: Ubuntu 14.04
User: ubuntu
Created at: 2016-03-22

See ~/README.md