Hi,
I am running a small model several times (1000 to be more precise) and for each run I need to store the results. Usually I turn it to a DataFrame and save as a csv. But in this case I do not want to save 1000 csvs. I understand that this question is not exactly optimization but I wanted to know if there is any alternative in JuMP for this case. In R you can use RDS so I was trying to use jld, but I am not able to save and load the save data.
# Dataframe with model results
df = DataFrame(variable = [1, 2, 3, 4, 5],
value = [800, 250, 700, 1400, 120]
)
vec_dfs = []
# Simulated sequential results
push!(vec_dfs,df)
push!(vec_dfs,df)
save("/home/myfile.jld", "vec_dfs", vec_dfs)
d = load("/home/myfile.jld")
During the save I get:
┌ Warning: `object_info(obj::Union{File, Object})` is deprecated, use `API.h5o_get_info1(checkvalid(obj))` instead.
│ caller = typeindex(parent::JLD.JldFile, addr::UInt64) at jld_types.jl:812
└ @ JLD ~/.julia/packages/JLD/6OyJe/src/jld_types.jl:812
error parsing type string @where(Core.AbstractArray{#s77,1},#s77)
Error encountered while load File{FileIO.DataFormat{:JLD}, String}("/home/yuri/myfile.jld").
For simple variables I am able to sabe the jld.
I also tried to save as txt but had a similar problem trying to read.
Am I doing something wrong? Or can you help me with alternatives?
Thanks!