-
-
Notifications
You must be signed in to change notification settings - Fork 153
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Training loop => ERROR: DimensionMismatch && Multiple Shooting => Domain Error #587
Comments
@adrhill I assume ode_data is assumed to be array of array? |
@ChrisRackauckas It should be an array of shape @VoSiLk the DomainError in your multiple shooting code occurred because group_size > size(ode_data, 2) which means that the specified group size is longer than your dataset (in time). |
@adrhill I also tried different group sizes e.g. 3, but the error message is the same. The data which pass to the optimizer is sampled from 0.1 s to 10.2 s |
It's because the data shape is a vector. |
It optimizes without an error. Now just the result isn't good. Thanks. |
Do you know what it the reason for the Training loop => ERROR: DimensionMismatch? |
Since your data was a vector (IIRC, I only quickly ran the code), your size was |
https://discourse.julialang.org/t/what-does-the-maxiters-solver-option-do/37376/13
Environment details:
OS: Windows 10 x64
Julia Version : 1.6.0
Packages:
Hey, I have solved the problems I had at 29th of June (I used the whole tspan = 0.1 s to 200 s and for the loss I just considered specific indices of it e.g. 0.1s to 1.6s etc.)
function loss(p)
sol = predict_neuralode_rk4(p)
N = sum(idx)
return sum(abs2.(y[idx] .- sol'))/N
end
Now I change the tspan see code below. In this case stiffness or instability weren’t problem.
However, now I get an error message of the loss function
ERROR: DimensionMismatch("arrays could not be broadcast to a common size; got a dimension with lengths 122 and 102").
I already have proved the dimensions of the prediction and the data (both 122). I don’t know the reason for the error and why it just occurs at iteration 13.
Furthermore, I tried to train with multiple shooting, but for this I’m getting a domain error although my specified group size is in the limits.
ERROR: DomainError with 12:
group_size can't be < 2 or > number of data points
Note that the code of multiple shooting depends on the above code.
The text was updated successfully, but these errors were encountered: