ChrisRackauckas / universal_differential_equations

Repository for the Universal Differential Equations for Scientific Machine Learning paper, describing a computational basis for high performance SciML
https://arxiv.org/abs/2001.04385
MIT License
215 stars 59 forks source link

line 207 error DimensionMismatch("arrays could not be broadcast to a common size; got a dimension with lengths 22 and 106") #22

Closed matutenun closed 4 years ago

matutenun commented 4 years ago

line 207

L = β.(0:tspan[end],β0,D,N,κ,α).S.I./N

i get this error. DimensionMismatch("arrays could not be broadcast to a common size; got a dimension with lengths 22 and 106")

Stacktrace: [1] _bcs1 at .\broadcast.jl:490 [inlined] [2] _bcs at .\broadcast.jl:484 [inlined] [3] broadcast_shape at .\broadcast.jl:478 [inlined] [4] combine_axes at .\broadcast.jl:473 [inlined] [5] _axes at .\broadcast.jl:208 [inlined] [6] axes at .\broadcast.jl:206 [inlined] [7] combine_axes at C:\Users\matias.julia\packages\DiffEqBase\OmQhO\src\diffeqfastbc.jl:19 [inlined] [8] _axes at .\broadcast.jl:208 [inlined] [9] axes at .\broadcast.jl:206 [inlined] [10] combine_axes at C:\Users\matias.julia\packages\DiffEqBase\OmQhO\src\diffeqfastbc.jl:19 [inlined] [11] _axes at .\broadcast.jl:208 [inlined] [12] axes at .\broadcast.jl:206 [inlined] [13] combine_axes at C:\Users\matias.julia\packages\DiffEqBase\OmQhO\src\diffeqfastbc.jl:19 [inlined] [14] instantiate at .\broadcast.jl:256 [inlined] [15] materialize(::Base.Broadcast.Broadcasted{Base.Broadcast.DefaultArrayStyle{1},Nothing,typeof(/),Tuple{Base.Broadcast.Broadcasted{Base.Broadcast.DefaultArrayStyle{1},Nothing,typeof(),Tuple{Base.Broadcast.Broadcasted{Base.Broadcast.DefaultArrayStyle{1},Nothing,typeof(),Tuple{Base.Broadcast.Broadcasted{Base.Broadcast.DefaultArrayStyle{1},Nothing,typeof(β),Tuple{StepRangeLen{Float64,Base.TwicePrecision{Float64},Base.TwicePrecision{Float64}},Float64,SubArray{Float64,1,Array{Float64,2},Tuple{Int64,Base.Slice{Base.OneTo{Int64}}},true},SubArray{Float64,1,Array{Float64,2},Tuple{Int64,Base.Slice{Base.OneTo{Int64}}},true},Float64,Float64}},SubArray{Float64,1,Array{Float64,2},Tuple{Int64,Base.Slice{Base.OneTo{Int64}}},true}}},SubArray{Float64,1,Array{Float64,2},Tuple{Int64,Base.Slice{Base.OneTo{Int64}}},true}}},SubArray{Float64,1,Array{Float64,2},Tuple{Int64,Base.Slice{Base.OneTo{Int64}}},true}}}) at .\broadcast.jl:820

ChrisRackauckas commented 4 years ago

Sounds like you got this running due to the other post? I assume this is a versioning issue?