Skip to content

Commit

Permalink
Error
Browse files Browse the repository at this point in the history
  • Loading branch information
mivanicERS committed Jan 29, 2025
1 parent af22826 commit 625b939
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/initialize_model!.jl
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ function initialize_model!(mc)
end

# Fix fixed values and delete missing ones
for fv keys(fixed)
for fv keys(mc.fixed)
println(fv)
if size(fixed[fv]) == ()
if fixed[fv] && is_valid(mc.model, mc.model[Symbol(fv)])
if size(mc.fixed[fv]) == ()
if mc.fixed[fv] && is_valid(mc.model, mc.model[Symbol(fv)])
if isnan(mc.data[fv])
if is_valid(mc.model, mc.model[Symbol(fv)])
delete(mc.model, mc.model[Symbol(fv)])
Expand All @@ -30,8 +30,8 @@ function initialize_model!(mc)
end
end
else
for fvi CartesianIndices(fixed[fv])
if fixed[fv][fvi] && is_valid(mc.model, mc.model[Symbol(fv)][fvi])
for fvi CartesianIndices(mc.fixed[fv])
if mc.fixed[fv][fvi] && is_valid(mc.model, mc.model[Symbol(fv)][fvi])
if isnan(mc.data[fv][fvi])
println(fvi)
if is_valid(mc.model, mc.model[Symbol(fv)][fvi])
Expand Down

0 comments on commit 625b939

Please sign in to comment.