Code Monkey home page Code Monkey logo

Comments (10)

fyngyrz avatar fyngyrz commented on July 26, 2024 1

Same here. Dual 4-core Xeon.

from siggraph2016_colorization.

franverona avatar franverona commented on July 26, 2024

Yes, that's correct. As I said in issue #7, I have 8Gb RAM and Ubuntu 16.04 TLS (xenial).

The exact line where error appears is in line 23 of colorize.lua file:

local d = torch.load( 'colornet.t7' )

from siggraph2016_colorization.

bobbens avatar bobbens commented on July 26, 2024

Discarding model corruption and lack of RAM, the only thing I can think of is incompatibility between the torch version you guys are using and the torch version the model is saved in. You have done an install following the instructions on http://torch.ch/docs/getting-started.html recently right?

from siggraph2016_colorization.

franverona avatar franverona commented on July 26, 2024

Yes, I installed it yesterday following those instructions.

The trace (if helpful) is this:

franverona@fran-ubuntu:~/Downloads/siggraph2016_colorization-master$ th ansel_colorado_1941.png out.png
/home/franverona/torch/install/bin/luajit: /home/franverona/torch/install/share/lua/5.1/torch/File.lua:370: table index is nil
stack traceback:
    /home/franverona/torch/install/share/lua/5.1/torch/File.lua:370: in function 'readObject'
    /home/franverona/torch/install/share/lua/5.1/nn/Module.lua:158: in function 'read'
    /home/franverona/torch/install/share/lua/5.1/torch/File.lua:351: in function 'readObject'
    /home/franverona/torch/install/share/lua/5.1/torch/File.lua:369: in function 'readObject'
    /home/franverona/torch/install/share/lua/5.1/torch/File.lua:369: in function 'readObject'
    /home/franverona/torch/install/share/lua/5.1/torch/File.lua:369: in function 'readObject'
    /home/franverona/torch/install/share/lua/5.1/torch/File.lua:369: in function 'readObject'
    /home/franverona/torch/install/share/lua/5.1/torch/File.lua:353: in function 'readObject'
    /home/franverona/torch/install/share/lua/5.1/torch/File.lua:369: in function 'readObject'
    /home/franverona/torch/install/share/lua/5.1/torch/File.lua:369: in function 'readObject'
    /home/franverona/torch/install/share/lua/5.1/torch/File.lua:353: in function 'readObject'
    /home/franverona/torch/install/share/lua/5.1/torch/File.lua:369: in function 'readObject'
    ...anverona/torch/install/share/lua/5.1/nngraph/gmodule.lua:482: in function 'read'
    /home/franverona/torch/install/share/lua/5.1/torch/File.lua:351: in function 'readObject'
    /home/franverona/torch/install/share/lua/5.1/torch/File.lua:369: in function 'readObject'
    /home/franverona/torch/install/share/lua/5.1/torch/File.lua:409: in function 'load'
    colorize.lua:23: in main chunk
    [C]: in function 'dofile'
    ...rona/torch/install/lib/luarocks/rocks/trepl/scm-1/bin/th:145: in main chunk
    [C]: at 0x0804cbc0

from siggraph2016_colorization.

fyngyrz avatar fyngyrz commented on July 26, 2024

Same here - I installed Torch from the Torch page when, in issue number 6, you indicated in your first reply that it should be done, so the install is very fresh.

Perhaps a minimal test file or files that would tell you something?

It seems notable that the load of the data is so fragile. Perhaps that indicates something else that the lack of fine-grained diagnostics in Lua and Torch hides that might be remediated with some test files?

from siggraph2016_colorization.

bobbens avatar bobbens commented on July 26, 2024

The error indicates that it is failing to load, but it doesn't give any details on why.
Torch is research code and it wouldn't be surprising that there is some sort of compatibility issue. We are distributing the model in binary format due to size and it could be related to that. Are you by chance on a big-endian system?

from siggraph2016_colorization.

franverona avatar franverona commented on July 26, 2024

Nope, little endian in my case.

from siggraph2016_colorization.

bobbens avatar bobbens commented on July 26, 2024

I have converted it to ascii. Try download the model at http://hi.cs.waseda.ac.jp/~esimo//files/colornet_ascii.t7.bz2 , uncompressing it (bunzip colornet_ascii.t7.bz2) and running (in torch, "th" command)

require 'nngraph'
data = torch.load( 'colornet_ascii.t7', 'ascii' )

from siggraph2016_colorization.

franverona avatar franverona commented on July 26, 2024

It seems to work, but always breaks for my example images (1000x800) though.

Is there anything I can do to make it work? Maybe using GPU instead of pure CPU could do the job?

from siggraph2016_colorization.

bobbens avatar bobbens commented on July 26, 2024

If you want to do such large images, I recommend downscaling the input, running it through the model, then upscaling the output (chrominance) to match the original image (luminance) before fusing them together, as the current model was trained with rather small patches (dataset restriction). This will both give better results and take less time/memory than running directly on the large images. GPU is only faster than CPU, and usually runs out of memory.

from siggraph2016_colorization.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.