PaintsChainer
PaintsChainer copied to clipboard
Simple Installation??
I am not a programmer. I am an artist who loved the results of the demo of this program, and I wanted to download it so I may use it as a base in my own works, to then work off of and create finalized art.
Unfortunately, the instructions might as well be in an ancient nordic language because I cannot for the life of me figure out how to install it. I feel as though I wasted several hours of my life downloading all these programs like the guide told me, only to be stumped at the last few lines that have no instructions, just coding (which means nothing to me as I have no idea what to do with them). So hours later, I am still incapable of using this program.
Is there no way for someone to package this into one install? Or at the very least, provide instructions that someone who is NOT a programmer may follow?
I see , current installation process is too difficult for non programmer. Currently we dont have 1 packaged version, its future work.
a programmer friend helped me local install, but now i need a bit of help. all images i upload say they're too big to colorize. is there a way to allow larger image sizes?
Wait, more issues.
I installed locally through python 3. The only way I've managed to get it to run is through a local server run through the command prompt. All other methods give various errors.
It opens perfectly with a local server, except uploading any image comes up with "UPLOAD ERROR". Any suggestions?
Having the same issue. managed to get it to lauch into localhost with
python -m http.server --cgi 8000 but I keep getting a code 501: can only post to CGI scripts error.
To colorize larger image, you have to change code itself. see also https://github.com/pfnet/PaintsChainer/issues/92
Did you booted the server.py ? is there any error in your console?
python -m http.server --cgi 8000
is not correct command.
Type python server.py
in your terminal at root PaintsChainer dir.
It's giving me the error "no module named http.server"
Which is odd because i'm using 3.6. I thought http.server was in python 3 :/
Oops, apologies. Forgot to input "python" >_>
Getting this instead:
C:\ProgramData\Anaconda3\lib\site-packages\chainer\cuda.py:88: UserWarning: cuDNN is not enabled.
Please reinstall chainer after you install cudnn
(see https://github.com/pfnet/chainer#installation).
'cuDNN is not enabled.\n'
Traceback (most recent call last):
File "server.py", line 167, in
Could have sworn i installed cudnn correctly :(
- Didn't tested in 3.6 but it fails to install in a month ago. Prefer 3.5 as stated in installation guide.
-
FileNotFoundError: [Errno 2] No such file or directory: './cgibin/paint_x2_unet/models/unet_128_standard'
Download the trained data. The network is nothing without trained data :)
For installation, due to license issues, we cannot include everything from the others. You must visit them all to get the "ingredients" legally. Here is just a recipe for making a roast chicken. (And this is why I created the guide to make it working in my personal notebook instead of big server)
ah, makes sense.
Sorry, having trouble understanding where to get the trained data and where to put it. I see the line, out, and ref folder in the images subfolder, but I'm unsure how to continue.
Visit http://paintschainer.preferred.tech/downloads/
Download all of them, put them into 'cgi-bin/paint_x2_unet/models/'
Create folder models
if you don't see it.
cgi-bin
should be in the same folder as server.py
Excellent! I can now upload images without upload error.
Unfortunately I'm now getting a "Server Error" after i upload and paint it. I don't think the image is too big, as I haven't received the 'Image is too large to colorize" error.
Any ideas? Hopefully it's not a python 3.6 error :/
You should see there are tons of logs in the console log. Try to copy and paste it here. If you can read it, try to paste the critical lines (Usually located in the bottom line).
Nothing in the command line:
python server.py GPU: 0 start load model serving at localhost : 8000
Try press F12 in browser... ? That could have a few lines about error.
load:./images/line/GK93M4X6RGJCLVQ88VR3DCF1X4R2FBG7.png True False
Exception happened during processing of request from ('127.0.0.1', 41234) Traceback (most recent call last): File "C:\Users\Kirsten\Anaconda3\lib\site-packages\cupy\cuda\compiler.py", line 49, in _run_nvcc return subprocess.check_output(cmd, cwd=cwd, stderr=subprocess.STDOUT) File "C:\Users\Kirsten\Anaconda3\lib\subprocess.py", line 336, in check_output **kwargs).stdout File "C:\Users\Kirsten\Anaconda3\lib\subprocess.py", line 418, in run output=stdout, stderr=stderr) subprocess.CalledProcessError: Command '['nvcc', '--preprocess', '-Xcompiler', '/wd 4819', '-m64', 'C:\Users\Kirsten\AppData\Local\Temp\tmpq9mct_d7\kern.cu']' returned non-zero exit status 1.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\Kirsten\Anaconda3\lib\socketserver.py", line 317, in _handle_request_noblock
self.process_request(request, client_address)
File "C:\Users\Kirsten\Anaconda3\lib\socketserver.py", line 348, in process_request
self.finish_request(request, client_address)
File "C:\Users\Kirsten\Anaconda3\lib\socketserver.py", line 361, in finish_request
self.RequestHandlerClass(request, client_address, self)
File "server.py", line 30, in init
self, req, client_addr, server)
File "C:\Users\Kirsten\Anaconda3\lib\socketserver.py", line 696, in init
self.handle()
File "C:\Users\Kirsten\Anaconda3\lib\http\server.py", line 418, in handle
self.handle_one_request()
File "C:\Users\Kirsten\Anaconda3\lib\http\server.py", line 406, in handle_one_request
method()
File "server.py", line 75, in do_POST
self.paint_process( form, id_str )
File "server.py", line 118, in paint_process
painter.colorize(id_str, form["step"][0].decode() if "step" in form else "C", blur=blur)
File "./cgi-bin/paint_x2_unet\cgi_exe.py", line 106, in colorize
image_conv2d_layer = cnn[step].calc(Variable(sample_container, volatile='on'), test=True)
File "./cgi-bin/paint_x2_unet\unet.py", line 61, in calc
e0 = F.relu(self.bnc0(self.c0(x), test=test), use_cudnn)
File "C:\Users\Kirsten\Anaconda3\lib\site-packages\chainer\links\normalization\batch_normalization.py", line 139, in call
x, gamma, beta, mean, var, self.eps, self.use_cudnn)
File "C:\Users\Kirsten\Anaconda3\lib\site-packages\chainer\functions\normalization\batch_normalization.py", line 347, in fixed_batch_normalization
use_cudnn)(x, gamma, beta, mean, var)
File "C:\Users\Kirsten\Anaconda3\lib\site-packages\chainer\function.py", line 199, in call
outputs = self.forward(in_data)
File "C:\Users\Kirsten\Anaconda3\lib\site-packages\chainer\functions\normalization\batch_normalization.py", line 167, in forward
self.std = xp.sqrt(var, dtype=var.dtype)
File "cupy/core/elementwise.pxi", line 774, in cupy.core.core.ufunc.call (cupy\core\core.cpp:42682)
File "cupy/util.pyx", line 37, in cupy.util.memoize.decorator.ret (cupy\util.cpp:1283)
File "cupy/core/elementwise.pxi", line 582, in cupy.core.core._get_ufunc_kernel (cupy\core\core.cpp:39296)
File "cupy/core/elementwise.pxi", line 32, in cupy.core.core._get_simple_elementwise_kernel (cupy\core\core.cpp:29818)
File "cupy/core/carray.pxi", line 87, in cupy.core.core.compile_with_cache (cupy\core\core.cpp:29505)
File "C:\Users\Kirsten\Anaconda3\lib\site-packages\cupy\cuda\compiler.py", line 131, in compile_with_cache
base = _empty_file_preprocess_cache[env] = preprocess('', options)
File "C:\Users\Kirsten\Anaconda3\lib\site-packages\cupy\cuda\compiler.py", line 94, in preprocess
pp_src = _run_nvcc(cmd, root_dir)
File "C:\Users\Kirsten\Anaconda3\lib\site-packages\cupy\cuda\compiler.py", line 56, in _run_nvcc
raise RuntimeError(msg)
RuntimeError: nvcc
command returns non-zero exit status.
command: ['nvcc', '--preprocess', '-Xcompiler', '/wd 4819', '-m64', 'C:\Users\Kirsten\AppData\Local\Temp\tmpq9mct_d7\kern.cu']
return-code: 1
stdout/stderr:
b"nvcc warning : The 'compute_20', 'sm_20', and 'sm_21' architectures are deprecated, and may be removed in a future release (Use -Wno-deprecated-gpu-targets to suppress warning).\r\nnvcc fatal : Cannot find compiler 'cl.exe' in PATH\r\n"
stdout/stderr: b"nvcc warning : The 'compute_20', 'sm_20', and 'sm_21' architectures are deprecated, and may be removed in a future release (Use -Wno-deprecated-gpu-targets to suppress warning).\r\nnvcc fatal : Cannot find compiler 'cl.exe' in PATH\r\n"
I have a bad news for you (chill it happens to me too). What GPU you're using?
EVGA Geforce GTX 970. Almost brand new card :/
Updating my driver real quick....
Strange. Deprecate architecture
occurs on GPU under 630... (Even 590 is included). That's may not your case. Ignore the warning.
But for cl.exe
See https://github.com/pfnet/PaintsChainer/wiki/Required-environment-variables
Hard to explain it, try go to My Computer
right click Properties
> Advanced system options
in the left > Environment variables
and set them all.
Make sure your VS stuffs are present.
I've tried adding D:\Program Files (x86)\Visual Studio\VC\bin to the environment path and tested a dozen or so times now and I still keep getting the same error.
Edit: is it a particular architecture it's looking for? I have amd64_arm, x86..etc. folders as well containing gl.exe, and i haven't been able to get it to work with any of them
Sorry for late reply.
As my case, all folders have cl.exe
, but /bin
only is good enough.
Go to the directory same as server.py
Try use python to run these code
import os
print(os.environ["PATH"])
See if your D:\Program Files (x86)\Visual Studio\VC\bin
exists there... If not, try make the environment variables not for your account but the system one. (there are 2 places to input them).
i tried to run it locally , but both firefox and chrome tabs crash or hang
Hi, guys! @taizan, @kanekirsten07, @Ulf3000, @6DammK9, @vhall413, could anyone please share the downloaded pretrained models (unet_128_standard & unet_512_standard)? I cannot download them since the provided link in the repo does not function properly :(