fluxml / fluxjs.jl Goto Github PK
View Code? Open in Web Editor NEWI heard you like compile times
License: Other
I heard you like compile times
License: Other
m = Chain(Dense(2, 2))
@code_js m(rand(2))
ERROR: MethodError: no method matching shape(::TrackedArray{…,Array{Float64,2}})
Closest candidates are:
shape(::Base.#*, ::FluxJS.Shape{T,2}, ::FluxJS.Shape{T,1}) where T at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/lib.jl:30
shape(::Base.#*, ::FluxJS.Shape{T,2}, ::FluxJS.Shape{T,2}) where T at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/lib.jl:33
shape(::FluxJS.#matVecMul, ::Any...) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/lib.jl:38
Would people be open to splitting the js portion into a new repository, converting it to ES6 and adding it to npm? This would simplify the process of using it with webpack, managing dependencies, etc.
FluxJS.compile()
doesn't seem to work when Convolution layers are involved:
>>> using Flux
>>> using FluxJS
>>> m = Chain(
Conv((2,2), 1=>16, relu),
x -> maxpool(x, (2,2)),
Conv((2,2), 16=>8, relu),
x -> maxpool(x, (2,2)),
x -> reshape(x, :, size(x, 4)),
Dense(288, 10), softmax)
>>> FLuxJS.compile("mnist",m, rand(10))
Error: StackOverflow
The error message is too big.
This example from Flux documentation gives an error
julia> model2 = Chain(
Dense(10, 5, σ),
Dense(5, 2),
softmax)
julia> @code_js model2(rand(10))
typeof(f) = Base.#one
one
Tuple{FluxJS.StagedArray{Real,1}}
ERROR: no method found for the specified argument types
Stacktrace:
[1] which(::Any, ::Any) at ./reflection.jl:823
[2] #determine_method_for_expr#23(::Bool, ::Function, ::Expr) at /Users/joyp.isahac/.julia/v0.6/ASTInterpreter2/src/ASTInterpreter2.jl:321
[3] (::ASTInterpreter2.#kw##determine_method_for_expr)(::Array{Any,1}, ::ASTInterpreter2.#determine_method_for_expr, ::Expr) at ./<missing>:0
[4] #enter_call_expr#26(::Bool, ::Function, ::Expr) at /Users/joyp.isahac/.julia/v0.6/ASTInterpreter2/src/ASTInterpreter2.jl:406
[5] (::ASTInterpreter2.#kw##enter_call_expr)(::Array{Any,1}, ::ASTInterpreter2.#enter_call_expr, ::Expr) at ./<missing>:0
[6] execute_command(::DebuggerFramework.DebuggerState, ::ASTInterpreter2.JuliaStackFrame, ::Val{:s}, ::String) at /Users/joyp.isahac/.julia/v0.6/ASTInterpreter2/src/commands.jl:80
[7] runall(::FluxJS.BTrace, ::DebuggerFramework.DebuggerState) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:41
[8] overdub(::FluxJS.BTrace, ::Function) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:53
[9] primitive(::FluxJS.Trace, ::Base.#broadcast, ::Function, ::FluxJS.StagedArray{Real,1}, ::TrackedArray{…,Array{Float64,1}}, ::Vararg{TrackedArray{…,Array{Float64,1}},N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/hooks.jl:24
[10] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:37
[11] overdub(::FluxJS.Trace, ::Flux.Dense{NNlib.#σ,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:53
[12] #trace#6(::FluxJS.Trace, ::Function, ::Flux.Dense{NNlib.#σ,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:30
[13] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Flux.Dense{NNlib.#σ,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at ./<missing>:0
[14] #_traceλ#9(::FluxJS.Trace, ::Function, ::Flux.Dense{NNlib.#σ,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:39
[15] (::FluxJS.#kw##_traceλ)(::Array{Any,1}, ::FluxJS.#_traceλ, ::Flux.Dense{NNlib.#σ,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at ./<missing>:0
[16] #tracecall#13(::FluxJS.Trace, ::Function, ::Flux.Dense{NNlib.#σ,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:50
[17] (::FluxJS.#kw##tracecall)(::Array{Any,1}, ::FluxJS.#tracecall, ::Flux.Dense{NNlib.#σ,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at ./<missing>:0
[18] macro expansion at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[19] primitive(::FluxJS.Trace, ::Flux.Dense{NNlib.#σ,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/hooks.jl:24
[20] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:37
[21] overdub(::FluxJS.Trace, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:53
[22] #trace#6(::FluxJS.Trace, ::Function, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:30
[23] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at ./<missing>:0
[24] macro expansion at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[25] primitive(::FluxJS.Trace, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Flux.Dense{NNlib.#σ,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/hooks.jl:24
[26] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:37
[27] overdub(::FluxJS.Trace, ::Function, ::Function, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:53
[28] #trace#6(::FluxJS.Trace, ::Function, ::Function, ::Function, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:30
[29] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Function, ::Function, ::Vararg{Any,N} where N) at ./<missing>:0
[30] macro expansion at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[31] primitive(::FluxJS.Trace, ::Function, ::Function, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/hooks.jl:24
[32] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:37
[33] overdub(::FluxJS.Trace, ::Function, ::Function, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:53
[34] #trace#6(::FluxJS.Trace, ::Function, ::Function, ::Function, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:30
[35] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Function, ::Function, ::Vararg{Any,N} where N) at ./<missing>:0
[36] macro expansion at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[37] primitive(::FluxJS.Trace, ::Function, ::Function, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/hooks.jl:24
[38] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:37
[39] overdub(::FluxJS.Trace, ::Function, ::Function, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:53
[40] #trace#6(::FluxJS.Trace, ::Function, ::Function, ::Function, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:30
[41] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Function, ::Function, ::Vararg{Any,N} where N) at ./<missing>:0
[42] macro expansion at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[43] primitive(::FluxJS.Trace, ::Function, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Array{Any,1}, ::Vararg{Array{Any,1},N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/hooks.jl:24
[44] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:37
[45] overdub(::FluxJS.Trace, ::Flux.Chain, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:53
[46] #trace#6(::FluxJS.Trace, ::Function, ::Flux.Chain, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:30
[47] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Flux.Chain, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at ./<missing>:0
[48] #_traceλ#9(::FluxJS.Trace, ::Function, ::Flux.Chain, ::Type{T} where T, ::Vararg{Type{T} where T,N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:39
[49] (::FluxJS.#kw##_traceλ)(::Array{Any,1}, ::FluxJS.#_traceλ, ::Flux.Chain, ::DataType, ::Vararg{DataType,N} where N) at ./<missing>:0
[50] #traceλ#10(::FluxJS.Trace, ::Function, ::Flux.Chain, ::Type{T} where T, ::Vararg{Type{T} where T,N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:44
[51] (::FluxJS.#kw##traceλ)(::Array{Any,1}, ::FluxJS.#traceλ, ::Flux.Chain, ::Type{T} where T, ::Vararg{Type{T} where T,N} where N) at ./<missing>:0
[52] #compile#42 at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/compile.jl:102 [inlined]
[53] compile(::Flux.Chain, ::Array{Float64,1}) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/compile.jl:101
I tried using FluxJS
/src/jit of Flux.jl was deleted in this commit
It seems like FluxJS.jl is not compatible with Julia v1.0 using pkg.
https://deeplearnjs.org/ is apparently no longer being updated. The tensorflow.js API is a bit more complicated but all the same stuff is there, so it should be possible to migrate.
@MikeInnes Given that this is currently WIP, I'd like to start contributing by working on writing the tests and docs for now. However, I think it would be better if I get your take on this before I actually start writing the tests. What do you think?
I'm on Flux 0.5.1 and FluxJS 0.1. I'm getting lots of UndefRefError: access to undefined reference
except for the most trivial uses. This seems to be working for others on the same so I'm not sure what's going on.
# Works
x = rand(10)
@code_js identity(x)
let model = (function () {
let math = dl.ENV.math;
function model(owl) {
return owl;
};
model.weights = [];
return model;
})();
flux.fetchWeights("model.bson").then((function (ws) {
return model.weights = ws;
}));
# From the readme but doesn't work
x = rand(10)
m = Chain(Dense(10,5,relu),Dense(5,2),softmax)
@code_js m(x)
UndefRefError: access to undefined reference
Stacktrace:
[1] lookup_var_if_var at /home/alex/.julia/v0.6/ASTInterpreter2/src/ASTInterpreter2.jl:147 [inlined]
[2] lookup(::ASTInterpreter2.JuliaStackFrame, ::SSAValue) at /home/alex/.julia/v0.6/Vinyl/src/interpret.jl:21
[3] broadcast_t(::Function, ::Type{Any}, ::Tuple{Base.OneTo{Int64}}, ::CartesianRange{CartesianIndex{1}}, ::ASTInterpreter2.JuliaStackFrame, ::Array{Any,1}) at ./broadcast.jl:256
[4] broadcast_c at ./broadcast.jl:319 [inlined]
[5] broadcast(::Function, ::ASTInterpreter2.JuliaStackFrame, ::Array{Any,1}) at ./broadcast.jl:434
[6] callargs(::DebuggerFramework.DebuggerState) at /home/alex/.julia/v0.6/Vinyl/src/interpret.jl:29
[7] runall(::FluxJS.BTrace, ::DebuggerFramework.DebuggerState) at /home/alex/.julia/v0.6/Vinyl/src/interpret.jl:34
[8] overdub(::FluxJS.BTrace, ::Function) at /home/alex/.julia/v0.6/Vinyl/src/interpret.jl:53
[9] primitive(::FluxJS.Trace, ::Base.#broadcast, ::Function, ::Tuple{TrackedArray{…,Array{Float64,1}}}) at /home/alex/.julia/v0.6/Vinyl/src/hooks.jl:24
[10] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /home/alex/.julia/v0.6/Vinyl/src/interpret.jl:37
[11] overdub(::FluxJS.Trace, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /home/alex/.julia/v0.6/Vinyl/src/interpret.jl:53
[12] #trace#6(::FluxJS.Trace, ::Function, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /home/alex/.julia/v0.6/FluxJS/src/trace.jl:30
[13] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at ./<missing>:0
[14] #_traceλ#9(::FluxJS.Trace, ::Function, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /home/alex/.julia/v0.6/FluxJS/src/trace.jl:39
[15] (::FluxJS.#kw##_traceλ)(::Array{Any,1}, ::FluxJS.#_traceλ, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at ./<missing>:0
[16] #tracecall#13(::FluxJS.Trace, ::Function, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /home/alex/.julia/v0.6/FluxJS/src/trace.jl:50
[17] (::FluxJS.#kw##tracecall)(::Array{Any,1}, ::FluxJS.#tracecall, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at ./<missing>:0
[18] macro expansion at /home/alex/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[19] primitive(::FluxJS.Trace, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}) at /home/alex/.julia/v0.6/Vinyl/src/hooks.jl:24
[20] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /home/alex/.julia/v0.6/Vinyl/src/interpret.jl:37
[21] overdub(::FluxJS.Trace, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at /home/alex/.julia/v0.6/Vinyl/src/interpret.jl:53
[22] #trace#6(::FluxJS.Trace, ::Function, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at /home/alex/.julia/v0.6/FluxJS/src/trace.jl:30
[23] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at ./<missing>:0
[24] macro expansion at /home/alex/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[25] primitive(::FluxJS.Trace, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}) at /home/alex/.julia/v0.6/Vinyl/src/hooks.jl:24
[26] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /home/alex/.julia/v0.6/Vinyl/src/interpret.jl:37
[27] overdub(::FluxJS.Trace, ::Function, ::Function, ::Vararg{Any,N} where N) at /home/alex/.julia/v0.6/Vinyl/src/interpret.jl:53
[28] #trace#6(::FluxJS.Trace, ::Function, ::Function, ::Function, ::Vararg{Any,N} where N) at /home/alex/.julia/v0.6/FluxJS/src/trace.jl:30
[29] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Function, ::Function, ::Vararg{Any,N} where N) at ./<missing>:0
[30] macro expansion at /home/alex/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[31] primitive(::FluxJS.Trace, ::Function, ::Function, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at /home/alex/.julia/v0.6/Vinyl/src/hooks.jl:24
[32] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /home/alex/.julia/v0.6/Vinyl/src/interpret.jl:37
[33] overdub(::FluxJS.Trace, ::Function, ::Function, ::Vararg{Any,N} where N) at /home/alex/.julia/v0.6/Vinyl/src/interpret.jl:53
[34] #trace#6(::FluxJS.Trace, ::Function, ::Function, ::Function, ::Vararg{Any,N} where N) at /home/alex/.julia/v0.6/FluxJS/src/trace.jl:30
[35] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Function, ::Function, ::Vararg{Any,N} where N) at ./<missing>:0
[36] macro expansion at /home/alex/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[37] primitive(::FluxJS.Trace, ::Function, ::Function, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at /home/alex/.julia/v0.6/Vinyl/src/hooks.jl:24
[38] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /home/alex/.julia/v0.6/Vinyl/src/interpret.jl:37
[39] overdub(::FluxJS.Trace, ::Function, ::Function, ::Vararg{Any,N} where N) at /home/alex/.julia/v0.6/Vinyl/src/interpret.jl:53
[40] #trace#6(::FluxJS.Trace, ::Function, ::Function, ::Function, ::Vararg{Any,N} where N) at /home/alex/.julia/v0.6/FluxJS/src/trace.jl:30
[41] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Function, ::Function, ::Vararg{Any,N} where N) at ./<missing>:0
[42] macro expansion at /home/alex/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[43] primitive(::FluxJS.Trace, ::Function, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Array{Any,1}, ::Vararg{Array{Any,1},N} where N) at /home/alex/.julia/v0.6/Vinyl/src/hooks.jl:24
[44] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /home/alex/.julia/v0.6/Vinyl/src/interpret.jl:37
[45] overdub(::FluxJS.Trace, ::Flux.Chain, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /home/alex/.julia/v0.6/Vinyl/src/interpret.jl:53
[46] #trace#6(::FluxJS.Trace, ::Function, ::Flux.Chain, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /home/alex/.julia/v0.6/FluxJS/src/trace.jl:30
[47] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Flux.Chain, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at ./<missing>:0
[48] #_traceλ#9(::FluxJS.Trace, ::Function, ::Flux.Chain, ::Type{T} where T, ::Vararg{Type{T} where T,N} where N) at /home/alex/.julia/v0.6/FluxJS/src/trace.jl:39
[49] (::FluxJS.#kw##_traceλ)(::Array{Any,1}, ::FluxJS.#_traceλ, ::Flux.Chain, ::DataType, ::Vararg{DataType,N} where N) at ./<missing>:0
[50] #traceλ#10(::FluxJS.Trace, ::Function, ::Flux.Chain, ::Type{T} where T, ::Vararg{Type{T} where T,N} where N) at /home/alex/.julia/v0.6/FluxJS/src/trace.jl:44
[51] (::FluxJS.#kw##traceλ)(::Array{Any,1}, ::FluxJS.#traceλ, ::Flux.Chain, ::Type{T} where T, ::Vararg{Type{T} where T,N} where N) at ./<missing>:0
[52] #compile#42 at /home/alex/.julia/v0.6/FluxJS/src/compile.jl:102 [inlined]
[53] compile(::Flux.Chain, ::Array{Float64,1}) at /home/alex/.julia/v0.6/FluxJS/src/compile.jl:101
[54] include_string(::String, ::String) at ./loading.jl:522
I tried the code in README and got following error
julia> using Flux, FluxJS
x = rand(10)
julia> x = rand(10)
10-element Array{Float64,1}:
0.435232
0.723494
0.159166
0.862539
0.263976
0.833034
0.0607865
0.989334
0.4656
0.115211
julia> m = Chain(Dense(10,5,relu),Dense(5,2),softmax)
Chain(Dense(10, 5, NNlib.relu), Dense(5, 2), NNlib.softmax)
julia> @code_js m(x)
ERROR: UndefRefError: access to undefined reference
Stacktrace:
[1] lookup_var_if_var at /home/lokesh/.julia/v0.6/ASTInterpreter2/src/ASTInterpreter2.jl:147 [inlined]
[2] lookup(::ASTInterpreter2.JuliaStackFrame, ::SSAValue) at /home/lokesh/.julia/v0.6/Vinyl/src/interpret.jl:21
[3] broadcast_t(::Function, ::Type{Any}, ::Tuple{Base.OneTo{Int64}}, ::CartesianRange{CartesianIndex{1}}, ::ASTInterpreter2.JuliaStackFrame, ::Array{Any,1}) at ./broadcast.jl:258
[4] broadcast_c at ./broadcast.jl:321 [inlined]
[5] broadcast(::Function, ::ASTInterpreter2.JuliaStackFrame, ::Array{Any,1}) at ./broadcast.jl:455
[6] callargs(::DebuggerFramework.DebuggerState) at /home/lokesh/.julia/v0.6/Vinyl/src/interpret.jl:29
[7] runall(::FluxJS.BTrace, ::DebuggerFramework.DebuggerState) at /home/lokesh/.julia/v0.6/Vinyl/src/interpret.jl:34
[8] overdub(::FluxJS.BTrace, ::Function) at /home/lokesh/.julia/v0.6/Vinyl/src/interpret.jl:53
[9] primitive(::FluxJS.Trace, ::Base.#broadcast, ::Function, ::Tuple{TrackedArray{…,Array{Float64,1}}}) at /home/lokesh/.julia/v0.6/Vinyl/src/hooks.jl:24
[10] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /home/lokesh/.julia/v0.6/Vinyl/src/interpret.jl:37
[11] overdub(::FluxJS.Trace, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /home/lokesh/.julia/v0.6/Vinyl/src/interpret.jl:53
[12] #trace#6(::FluxJS.Trace, ::Function, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /home/lokesh/.julia/v0.6/FluxJS/src/trace.jl:30
[13] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at ./<missing>:0
[14] #_traceλ#9(::FluxJS.Trace, ::Function, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /home/lokesh/.julia/v0.6/FluxJS/src/trace.jl:39
[15] (::FluxJS.#kw##_traceλ)(::Array{Any,1}, ::FluxJS.#_traceλ, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at ./<missing>:0
[16] #tracecall#13(::FluxJS.Trace, ::Function, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /home/lokesh/.julia/v0.6/FluxJS/src/trace.jl:50
[17] (::FluxJS.#kw##tracecall)(::Array{Any,1}, ::FluxJS.#tracecall, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at ./<missing>:0
[18] macro expansion at /home/lokesh/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[19] primitive(::FluxJS.Trace, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}) at /home/lokesh/.julia/v0.6/Vinyl/src/hooks.jl:24
[20] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /home/lokesh/.julia/v0.6/Vinyl/src/interpret.jl:37
[21] overdub(::FluxJS.Trace, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at /home/lokesh/.julia/v0.6/Vinyl/src/interpret.jl:53
[22] #trace#6(::FluxJS.Trace, ::Function, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at /home/lokesh/.julia/v0.6/FluxJS/src/trace.jl:30
[23] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at ./<missing>:0
[24] macro expansion at /home/lokesh/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[25] primitive(::FluxJS.Trace, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}) at /home/lokesh/.julia/v0.6/Vinyl/src/hooks.jl:24
[26] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /home/lokesh/.julia/v0.6/Vinyl/src/interpret.jl:37
[27] overdub(::FluxJS.Trace, ::Function, ::Function, ::Vararg{Any,N} where N) at /home/lokesh/.julia/v0.6/Vinyl/src/interpret.jl:53
[28] #trace#6(::FluxJS.Trace, ::Function, ::Function, ::Function, ::Vararg{Any,N} where N) at /home/lokesh/.julia/v0.6/FluxJS/src/trace.jl:30
[29] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Function, ::Function, ::Vararg{Any,N} where N) at ./<missing>:0
[30] macro expansion at /home/lokesh/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[31] primitive(::FluxJS.Trace, ::Function, ::Function, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at /home/lokesh/.julia/v0.6/Vinyl/src/hooks.jl:24
[32] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /home/lokesh/.julia/v0.6/Vinyl/src/interpret.jl:37
[33] overdub(::FluxJS.Trace, ::Function, ::Function, ::Vararg{Any,N} where N) at /home/lokesh/.julia/v0.6/Vinyl/src/interpret.jl:53
[34] #trace#6(::FluxJS.Trace, ::Function, ::Function, ::Function, ::Vararg{Any,N} where N) at /home/lokesh/.julia/v0.6/FluxJS/src/trace.jl:30
[35] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Function, ::Function, ::Vararg{Any,N} where N) at ./<missing>:0
[36] macro expansion at /home/lokesh/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[37] primitive(::FluxJS.Trace, ::Function, ::Function, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at /home/lokesh/.julia/v0.6/Vinyl/src/hooks.jl:24
[38] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /home/lokesh/.julia/v0.6/Vinyl/src/interpret.jl:37
[39] overdub(::FluxJS.Trace, ::Function, ::Function, ::Vararg{Any,N} where N) at /home/lokesh/.julia/v0.6/Vinyl/src/interpret.jl:53
[40] #trace#6(::FluxJS.Trace, ::Function, ::Function, ::Function, ::Vararg{Any,N} where N) at /home/lokesh/.julia/v0.6/FluxJS/src/trace.jl:30
[41] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Function, ::Function, ::Vararg{Any,N} where N) at ./<missing>:0
[42] macro expansion at /home/lokesh/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[43] primitive(::FluxJS.Trace, ::Function, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Array{Any,1}, ::Vararg{Array{Any,1},N} where N) at /home/lokesh/.julia/v0.6/Vinyl/src/hooks.jl:24
[44] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /home/lokesh/.julia/v0.6/Vinyl/src/interpret.jl:37
[45] overdub(::FluxJS.Trace, ::Flux.Chain, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /home/lokesh/.julia/v0.6/Vinyl/src/interpret.jl:53
[46] #trace#6(::FluxJS.Trace, ::Function, ::Flux.Chain, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /home/lokesh/.julia/v0.6/FluxJS/src/trace.jl:30
[47] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Flux.Chain, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at ./<missing>:0
[48] #_traceλ#9(::FluxJS.Trace, ::Function, ::Flux.Chain, ::Type{T} where T, ::Vararg{Type{T} where T,N} where N) at /home/lokesh/.julia/v0.6/FluxJS/src/trace.jl:39
[49] (::FluxJS.#kw##_traceλ)(::Array{Any,1}, ::FluxJS.#_traceλ, ::Flux.Chain, ::DataType, ::Vararg{DataType,N} where N) at ./<missing>:0
[50] #traceλ#10(::FluxJS.Trace, ::Function, ::Flux.Chain, ::Type{T} where T, ::Vararg{Type{T} where T,N} where N) at /home/lokesh/.julia/v0.6/FluxJS/src/trace.jl:44
[51] (::FluxJS.#kw##traceλ)(::Array{Any,1}, ::FluxJS.#traceλ, ::Flux.Chain, ::Type{T} where T, ::Vararg{Type{T} where T,N} where N) at ./<missing>:0
[52] #compile#42 at /home/lokesh/.julia/v0.6/FluxJS/src/compile.jl:102 [inlined]
[53] compile(::Flux.Chain, ::Array{Float64,1}) at /home/lokesh/.julia/v0.6/FluxJS/src/compile.jl:101
As mentioned in the README.md
,
>>> x = rand(10)
>>> m = Chain(Dense(10,5,relu),Dense(5,2),softmax)
>>> @code_js m(x)
ERROR: UndefVarError: Tracker not defined
Stacktrace:
[1] (::FluxJS.##32#33{Array{Any,1}})(::IVertex) at /home/ayush99/.julia/v0.6/FluxJS.jl/src/compile.jl:39
[2] (::DataFlow.##89#91{FluxJS.##32#33{Array{Any,1}}})(::IVertex) at /home/ayush99/.julia/v0.6/DataFlow/src/syntax/sugar.jl:271
[3] #10 at /home/ayush99/.julia/v0.6/DataFlow/src/graph/ilgraph.jl:56 [inlined]
[4] walk!(::IVertex, ::DataFlow.##10#11{DataFlow.##89#91{FluxJS.##32#33{Array{Any,1}}}}, ::Base.#identity, ::ObjectIdDict) at /home/ayush99/.julia/v0.6/DataFlow/src/graph/ilgraph.jl:42
[5] (::DataFlow.##8#9{DataFlow.##10#11{DataFlow.##89#91{FluxJS.##32#33{Array{Any,1}}}},Base.#identity,ObjectIdDict})(::IVertex) at /home/ayush99/.julia/v0.6/DataFlow/src/graph/ilgraph.jl:44
[6] map!(::DataFlow.##8#9{DataFlow.##10#11{DataFlow.##89#91{FluxJS.##32#33{Array{Any,1}}}},Base.#identity,ObjectIdDict}, ::Array{IVertex,1}, ::Array{IVertex,1}) at ./abstractarray.jl:1862
[7] walk!(::IVertex, ::DataFlow.##10#11{DataFlow.##89#91{FluxJS.##32#33{Array{Any,1}}}}, ::Base.#identity, ::ObjectIdDict) at /home/ayush99/.julia/v0.6/DataFlow/src/graph/ilgraph.jl:44
[8] (::DataFlow.##8#9{DataFlow.##10#11{DataFlow.##89#91{FluxJS.##32#33{Array{Any,1}}}},Base.#identity,ObjectIdDict})(::IVertex) at /home/ayush99/.julia/v0.6/DataFlow/src/graph/ilgraph.jl:44
[9] map!(::DataFlow.##8#9{DataFlow.##10#11{DataFlow.##89#91{FluxJS.##32#33{Array{Any,1}}}},Base.#identity,ObjectIdDict}, ::Array{IVertex,1}, ::Array{IVertex,1}) at ./abstractarray.jl:1862
[10] walk!(::IVertex, ::DataFlow.##10#11{DataFlow.##89#91{FluxJS.##32#33{Array{Any,1}}}}, ::Base.#identity, ::ObjectIdDict) at /home/ayush99/.julia/v0.6/DataFlow/src/graph/ilgraph.jl:44
[11] prewalkλ(::FluxJS.##32#33{Array{Any,1}}, ::IVertex) at /home/ayush99/.julia/v0.6/DataFlow/src/syntax/sugar.jl:269
[12] applybody(::DataFlow.##90#92{FluxJS.##32#33{Array{Any,1}}}, ::IVertex) at /home/ayush99/.julia/v0.6/DataFlow/src/syntax/sugar.jl:265
[13] (::DataFlow.##89#91{FluxJS.##32#33{Array{Any,1}}})(::IVertex) at /home/ayush99/.julia/v0.6/DataFlow/src/syntax/sugar.jl:271
[14] #10 at /home/ayush99/.julia/v0.6/DataFlow/src/graph/ilgraph.jl:56 [inlined]
[15] walk!(::IVertex, ::DataFlow.##10#11{DataFlow.##89#91{FluxJS.##32#33{Array{Any,1}}}}, ::Base.#identity, ::ObjectIdDict) at /home/ayush99/.julia/v0.6/DataFlow/src/graph/ilgraph.jl:42
[16] (::DataFlow.##8#9{DataFlow.##10#11{DataFlow.##89#91{FluxJS.##32#33{Array{Any,1}}}},Base.#identity,ObjectIdDict})(::IVertex) at /home/ayush99/.julia/v0.6/DataFlow/src/graph/ilgraph.jl:44
[17] map!(::DataFlow.##8#9{DataFlow.##10#11{DataFlow.##89#91{FluxJS.##32#33{Array{Any,1}}}},Base.#identity,ObjectIdDict}, ::Array{IVertex,1}, ::Array{IVertex,1}) at ./abstractarray.jl:1862
[18] walk!(::IVertex, ::DataFlow.##10#11{DataFlow.##89#91{FluxJS.##32#33{Array{Any,1}}}}, ::Base.#identity, ::ObjectIdDict) at /home/ayush99/.julia/v0.6/DataFlow/src/graph/ilgraph.jl:44
[19] liftweights(::IVertex) at /home/ayush99/.julia/v0.6/FluxJS.jl/src/compile.jl:37
[20] compile(::IVertex, ::String, ::Array{Any,1}) at /home/ayush99/.julia/v0.6/FluxJS.jl/src/compile.jl:96
[21] compile(::Flux.Chain, ::Array{Float64,1}) at /home/ayush99/.julia/v0.6/FluxJS.jl/src/compile.jl:101
Flux.Tracker
isn't being imported.
How to create weights for FluxJS?
I tired by training the model through Flux and then exporting the weights using following code:
m = Chain(
Dense(28^2, 32, relu),
Dense(32, 10),
softmax)
...<train the model>
weights = Tracker.data.(params(m));
@save "mnist-mlp2.bson" weights
But upon loading the BSON I get following error:
uncaught exception: Array type Core,Float64 not supported.
I tried to run this basic code for a cppn
using Flux
using Images
using FluxJS
function transform(z)
x_dim = 256
y_dim = 256
n_points = x_dim*y_dim
scale = 8
z_dim = 32
net_size = 32
x_range = scale*(collect(0:(x_dim-1))-(x_dim-1)/2.0)/(x_dim-1)/0.5
y_range = scale*(collect(0:(y_dim-1))-(y_dim-1)/2.0)/(y_dim-1)/0.5
x_mat = ones(y_dim, 1)*reshape(x_range, 1, x_dim)
y_mat = reshape(y_range, y_dim, 1)*ones((1, x_dim))
r_mat = sqrt.(x_mat.^2 + y_mat.^2)
x_mat = reshape(transpose(x_mat), n_points)
y_mat = reshape(transpose(y_mat), n_points)
r_mat = reshape(transpose(r_mat), n_points)
unit = Dense(n_points, net_size)
unit(x_mat) + unit(y_mat) + unit(r_mat)
end
model = Chain(
transform,
Dense(32, 32, tanh),
Dense(32, 32, tanh),
Dense(32, 32, tanh),
Dense(32, 32, σ)
)
@code_js model(rand(32))
This example from README.md throws an UndefRefError.
julia> using Flux
julia> using FluxJS
julia> m = Chain(Dense(10,5,relu),Dense(5,2),softmax)
julia> @code_js m(rand(10))
ERROR: UndefRefError: access to undefined reference
Stacktrace:
[1] lookup_var_if_var at /Users/joyp.isahac/.julia/v0.6/ASTInterpreter2/src/ASTInterpreter2.jl:147 [inlined]
[2] lookup(::ASTInterpreter2.JuliaStackFrame, ::SSAValue) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:21
[3] broadcast_t(::Function, ::Type{Any}, ::Tuple{Base.OneTo{Int64}}, ::CartesianRange{CartesianIndex{1}}, ::ASTInterpreter2.JuliaStackFrame, ::Array{Any,1}) at ./broadcast.jl:256
[4] broadcast_c at ./broadcast.jl:319 [inlined]
[5] broadcast(::Function, ::ASTInterpreter2.JuliaStackFrame, ::Array{Any,1}) at ./broadcast.jl:434
[6] callargs(::DebuggerFramework.DebuggerState) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:29
[7] runall(::FluxJS.BTrace, ::DebuggerFramework.DebuggerState) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:34
[8] overdub(::FluxJS.BTrace, ::Function) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:53
[9] primitive(::FluxJS.Trace, ::Base.#broadcast, ::Function, ::Tuple{TrackedArray{…,Array{Float64,1}}}) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/hooks.jl:24
[10] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:37
[11] overdub(::FluxJS.Trace, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:53
[12] #trace#6(::FluxJS.Trace, ::Function, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:30
[13] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at ./<missing>:0
[14] #_traceλ#9(::FluxJS.Trace, ::Function, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:39
[15] (::FluxJS.#kw##_traceλ)(::Array{Any,1}, ::FluxJS.#_traceλ, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at ./<missing>:0
[16] #tracecall#13(::FluxJS.Trace, ::Function, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:50
[17] (::FluxJS.#kw##tracecall)(::Array{Any,1}, ::FluxJS.#tracecall, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at ./<missing>:0
[18] macro expansion at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[19] primitive(::FluxJS.Trace, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}, ::FluxJS.StagedArray{Float64,1}) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/hooks.jl:24
[20] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:37
[21] overdub(::FluxJS.Trace, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:53
[22] #trace#6(::FluxJS.Trace, ::Function, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:30
[23] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at ./<missing>:0
[24] macro expansion at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[25] primitive(::FluxJS.Trace, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Flux.Dense{NNlib.#relu,TrackedArray{…,Array{Float64,2}},TrackedArray{…,Array{Float64,1}}}) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/hooks.jl:24
[26] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:37
[27] overdub(::FluxJS.Trace, ::Function, ::Function, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:53
[28] #trace#6(::FluxJS.Trace, ::Function, ::Function, ::Function, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:30
[29] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Function, ::Function, ::Vararg{Any,N} where N) at ./<missing>:0
[30] macro expansion at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[31] primitive(::FluxJS.Trace, ::Function, ::Function, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/hooks.jl:24
[32] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:37
[33] overdub(::FluxJS.Trace, ::Function, ::Function, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:53
[34] #trace#6(::FluxJS.Trace, ::Function, ::Function, ::Function, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:30
[35] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Function, ::Function, ::Vararg{Any,N} where N) at ./<missing>:0
[36] macro expansion at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[37] primitive(::FluxJS.Trace, ::Function, ::Function, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/hooks.jl:24
[38] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:37
[39] overdub(::FluxJS.Trace, ::Function, ::Function, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:53
[40] #trace#6(::FluxJS.Trace, ::Function, ::Function, ::Function, ::Vararg{Any,N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:30
[41] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Function, ::Function, ::Vararg{Any,N} where N) at ./<missing>:0
[42] macro expansion at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:58 [inlined]
[43] primitive(::FluxJS.Trace, ::Function, ::Function, ::FluxJS.StagedArray{Float64,1}, ::Array{Any,1}, ::Vararg{Array{Any,1},N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/hooks.jl:24
[44] runall(::FluxJS.Trace, ::DebuggerFramework.DebuggerState) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:37
[45] overdub(::FluxJS.Trace, ::Flux.Chain, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /Users/joyp.isahac/.julia/v0.6/Vinyl/src/interpret.jl:53
[46] #trace#6(::FluxJS.Trace, ::Function, ::Flux.Chain, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:30
[47] (::FluxJS.#kw##trace)(::Array{Any,1}, ::FluxJS.#trace, ::Flux.Chain, ::FluxJS.StagedArray{Float64,1}, ::Vararg{FluxJS.StagedArray{Float64,1},N} where N) at ./<missing>:0
[48] #_traceλ#9(::FluxJS.Trace, ::Function, ::Flux.Chain, ::Type{T} where T, ::Vararg{Type{T} where T,N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:39
[49] (::FluxJS.#kw##_traceλ)(::Array{Any,1}, ::FluxJS.#_traceλ, ::Flux.Chain, ::DataType, ::Vararg{DataType,N} where N) at ./<missing>:0
[50] #traceλ#10(::FluxJS.Trace, ::Function, ::Flux.Chain, ::Type{T} where T, ::Vararg{Type{T} where T,N} where N) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/trace.jl:44
[51] (::FluxJS.#kw##traceλ)(::Array{Any,1}, ::FluxJS.#traceλ, ::Flux.Chain, ::Type{T} where T, ::Vararg{Type{T} where T,N} where N) at ./<missing>:0
[52] #compile#42 at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/compile.jl:102 [inlined]
[53] compile(::Flux.Chain, ::Array{Float64,1}) at /Users/joyp.isahac/.julia/v0.6/FluxJS/src/compile.jl:101
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.