We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
read_optimizer_stats
The changes to OptimizerStats in 0d6f377 prevent calling read_optimizer_stats on results serialized with a previous version of PowerSimulations.
OptimizerStats
using PowerSimulations res = get_decision_problem_results(SimulationResults("path/to/old/results"), "UC") read_optimizer_stats(res)
The above works with v0.27.0. With v0.27.1 I get:
v0.27.0
v0.27.1
ERROR: LoadError: BoundsError: attempt to access 20-element Vector{Float64} at index [21] Stacktrace: [1] getindex @ ./essentials.jl:13 [inlined] [2] PowerSimulations.OptimizerStats(data::Vector{Float64}) @ PowerSimulations ~/Documents/JuliaProjects/S-PA-Entity-Metric/PowerSimulations.jl/src/core/optimizer_stats.jl:69 [3] (::PowerSimulations.var"#305#306"{Matrix{Float64}})(i::Int64) @ PowerSimulations ./cartesian.jl:0 [4] iterate @ ./generator.jl:47 [inlined] [5] collect(itr::Base.Generator{Base.OneTo{Int64}, PowerSimulations.var"#305#306"{Matrix{Float64}}}) @ Base ./array.jl:834 [6] read_optimizer_stats(store::PowerSimulations.HdfSimulationStore, model_name::Symbol) @ PowerSimulations ~/Documents/JuliaProjects/S-PA-Entity-Metric/PowerSimulations.jl/src/simulation/hdf_simulation_store.jl:234 [7] _read_optimizer_stats @ ~/Documents/JuliaProjects/S-PA-Entity-Metric/PowerSimulations.jl/src/simulation/decision_model_simulation_results.jl:633 [inlined] [8] #376 @ ~/Documents/JuliaProjects/S-PA-Entity-Metric/PowerSimulations.jl/src/simulation/simulation_problem_results.jl:609 [inlined] [9] open_store(func::PowerSimulations.var"#376#377"{…}, ::Type{…}, directory::String, mode::String; filename::String) @ PowerSimulations ~/Documents/JuliaProjects/S-PA-Entity-Metric/PowerSimulations.jl/src/simulation/hdf_simulation_store.jl:108 [10] open_store @ ~/Documents/JuliaProjects/S-PA-Entity-Metric/PowerSimulations.jl/src/simulation/hdf_simulation_store.jl:98 [inlined] [11] _read_optimizer_stats @ ~/Documents/JuliaProjects/S-PA-Entity-Metric/PowerSimulations.jl/src/simulation/simulation_problem_results.jl:604 [inlined] [12] read_optimizer_stats(res::PowerSimulations.SimulationProblemResults{…}; store::Nothing) @ PowerSimulations ~/Documents/JuliaProjects/S-PA-Entity-Metric/PowerSimulations.jl/src/simulation/simulation_problem_results.jl:600 [13] read_optimizer_stats(res::PowerSimulations.SimulationProblemResults{PowerSimulations.DecisionModelSimulationResults}) @ PowerSimulations ~/Documents/JuliaProjects/S-PA-Entity-Metric/PowerSimulations.jl/src/simulation/simulation_problem_results.jl:595 [14] top-level scope @ ~/Documents/JuliaProjects/S-PA-Entity-Metric/PowerAnalytics-demos/~optimizer_stats_bug_repro.jl:4 [15] include(fname::String) @ Base.MainInclude ./client.jl:489 [16] top-level scope @ REPL[3]:1
The text was updated successfully, but these errors were encountered:
Fix #1065
1172165
(the commit I added there was named incorrectly, it is not relevant)
Sorry, something went wrong.
jd-lara
Successfully merging a pull request may close this issue.
The changes to
OptimizerStats
in 0d6f377 prevent callingread_optimizer_stats
on results serialized with a previous version of PowerSimulations.The above works with
v0.27.0
. Withv0.27.1
I get:The text was updated successfully, but these errors were encountered: