Thanks again for the help. It was a question of going into the gsl C files and saving object s properly.
Pedro On Tue, Aug 6, 2019 at 10:29 PM Pedro Gardete <pedromgard...@gmail.com> wrote: > Thank you. In my application, it's important that I get to the same local > minimum as if I hadn't stopped the minimizer. I believe saving x only won't > do the trick. > > I've been trying to stop/resume the minimizer by saving the object > gsl_multimin_fminimizer, including its "void *state" pointer. Then, once I > resume, I load up all of the relevant fields. However, I think the > following command fails (which I found in fminimizer.c), probably because > of something wrong while saving/loading s->state. > > (s->type->set) (s->state, s->f, s->x, &(s->size), step_size); > > where s is the gsl_multimin_fminimizer object. > > Thanks again. > > On Tue, Aug 6, 2019 at 9:56 PM Patrick Alken <al...@colorado.edu> wrote: > >> Can you just save the current position vector (state->x) and then start >> from there the next time? >> >> On 8/6/19 5:06 PM, Pedro Gardete wrote: >> > Hi, >> > >> > I'm running a minimization that may need to be interrupted some times, >> due >> > to computational constraints. >> > >> > Is there a way I can save the "gsl_multimin_minimizer" variable, so I >> can >> > resume optimization? The tricky part is that this struct has a void >> pointer >> > with unknown size... I assume the remaining fields of the struct simply >> > depend on the chosen minimization method. >> > >> > Thank you! >> > Pedro >> >> >>