Saving JUMPArray to JLD or JLD2 file

question

#1

Hi, I’m facing the problem that trying to save a JUMPArray with JLD or JLD2 causes the error that it “cannot write pointers to JLD file”. Is there any way to save an entire JUMPArray to a file without decomposing it into its .innerArray and .indexsets? Thanks


#2

The problem is likely that you are trying to write a JuMPArray of variables, each of which have a reference to the model, which has a pointer to the solver.

Why are you trying to do this?

It is probably better to save the data needed to build the model, rather than the model itself.

You may also want to take a look at:


#3

If You want to save the model have a look at https://github.com/JuliaOpt/ConicBenchmarkUtilities.jl


#4

Thanks for your response! It was a very useful information that it points to the entire model. I now just solve the indexsets and innerArray data and it works perfectly. (For my next question I’ll also include your other advise.)