consider "caching" compute_contrast results in GLM models
I doubt I am the first one to think of it, so is there any reason why results from compute_contrast have to be recomputed every time the method is called rather than keeping track of contrasts that have already been computed and we re accessing them?
@bthirion @emdupre
Sorry, I'm less familiar with this part of the code base, so just to make sure :
Are you referring to this issue, where make_stat_maps is repeatedly calling compute_contrast ? Or do you mean within compute_contrast itself things are being called repeatedly ?
IIUC in many practical cases, contrasts are computed several times, at least twice, for reporting and to write them on disk. Indeed caching would help here.