Giter Club home page Giter Club logo

neuralnets.jl's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

neuralnets.jl's Issues

write @train_parameters

to take each setting in a vector of train parameters and output a Dict for use in TrainReport, possibly with another Dict to convert variable names to user friendly names. e.g. learning_rate -> "Learning rate".

Can't train on MNIST data

Sorry for the vague title, but I'm having a number of different issues. I'm trying to compare NeuralNets.jl to an implementation I wrote a few months ago using the MNIST data, and I have not yet been able to train a mlp.

The data:

julia> using MNIST

julia> x, yy = traindata();

julia> n = length(yy)
60000

julia> y = zeros(10, n);

julia> for i in 1:n
           yi = yy[i]
           if yi == 0.0
               y[10, i] = 1.0
           else
               y[yi, i] = 1.0
           end
       end

julia> #x is 784 x 60000
       #y is 10 x 60000

Training with :levenberg_marquardt results in a MemoryError:

julia> using NeuralNets

julia> layer_sizes = [size(x, 1), 30, size(y, 1)]
3-element Array{Int64,1}:
 784
  30
  10

julia> act = [logis, logis]
2-element Array{Function,1}:
 logis
 logis

julia> mlp = MLP(randn, layer_sizes, act);

julia> mlp1 = train(mlp, x, [], y, [], train_method=:levenberg_marquardt)
ERROR: MemoryError()
 in Array at base.jl:230
 in train at /home/sam/.julia/v0.3/NeuralNets/src/train.jl:66

Training with :gradient_descent results in all weights being NaN. Output not shown. Perhaps this is because I'm using logis instead of logissafe?

Training with gdmtrain:

julia> gdmtrain(mlp, x, y)
ERROR: `.+` has no method matching .+(::NNLayer{Float64}, ::Float64)
 in .+ at array.jl:758
 in gdmtrain at /home/sam/.julia/v0.3/NeuralNets/src/gradientdescent.jl:41

Any suggestions?

Can't use the train function

When I call train(nn, trainx, valx, traint, valt) I get the following message
julia> train
ERROR: UndefVarError: train not defined

The same doesn't happen when I call the gdmtrain (from the same package)
Am I doing anything wrong?

Thanks.

XOR example won't run with :gradient_descent

maxiters here should be maxiter, I think. But even if I fix that, I cannot run the XOR example with gradient descent.

I get

`setindex!` has no method matching setindex!(::ContiguousView{Float64,1,Array{Float64,1}}, ::Array{Float64,2}, ::UnitRange{Int64})

You might have used a 2d row vector where a 1d column vector was required.
Note the difference between 1d column vector [1,2,3] and 2d row vector [1 2 3].
You can convert to a column vector with the vec() function.
while loading In[8], in expression starting on line 21
 in backprop! at /home/sam/.julia/v0.3/NeuralNets/src/backprop.jl:39
 in backprop! at /home/sam/.julia/v0.3/NeuralNets/src/backprop.jl:35 (repeats 2 times)
 in g! at /home/sam/.julia/v0.3/NeuralNets/src/train.jl:93
 in fg! at /home/sam/.julia/v0.3/Optim/src/types.jl:150
 in gradient_descent at /home/sam/.julia/v0.3/Optim/src/gradient_descent.jl:56
 in optimize at /home/sam/.julia/v0.3/Optim/src/optimize.jl:328
 in train at /home/sam/.julia/v0.3/NeuralNets/src/train.jl:97

example fails

Hi,

the example provided in the release fails with

ERROR: `NNLayer{T}` has no method matching NNLayer{T}(::Array{Float64,2}, ::Array{Float64,1}, ::Function, ::Function, ::Bool, ::Float64, ::Float64, ::Array{Float64,1})
 in NNLayer at /home/davide/.julia/v0.3/NeuralNets/src/mlp.jl:19
 in MLP at /home/davide/.julia/v0.3/NeuralNets/src/mlp.jl:85
 in include_3B_215 at /usr/bin/../lib/julia/sys.so
 in include_from_node1 at loading.jl:128
 in process_options_3B_1728 at /usr/bin/../lib/julia/sys.so
 in _start_3B_1715 at /usr/bin/../lib/julia/sys.so (repeats 2 times)
while loading /home/davide/prova.jl, in expression starting on line 19

I am thus unable to use the MLP

Thanks,

Davide

example fails

Hi,

Thanks for the package.

Would you register it, so it is easier to install and it has more visibility?

Davide

register this package

Hi,

Thanks for the package.

Would you register it, so it is easier to install and it has more visibility?

Davide

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.