You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For some parameter values I get a segmentation fault while doing adjoint sensitivity analysis.
The problematic point is line 2033 in the following snippet:
It seems that the index i is not checked for being inside the bounds of the dt_mem array.
If I add the check if (i > ca_mem->ca_nsteps) return(CV_FWD_FAIL); at the beginning of the loop body the segmentation fault is solved.
However, I am not sure if this is the correct thing to do or if index i should always be inside the bounds and the actual problem lies elsewhere.
The text was updated successfully, but these errors were encountered:
I investigated the matter a bit more. It seems that the software package I use (https://github.com/AMICI-dev/AMICI) is calling functions not in the public API. So maybe when only the public API is used the index i would be guaranteed to be inside the valid bounds (not sure).
For some parameter values I get a segmentation fault while doing adjoint sensitivity analysis.
The problematic point is line 2033 in the following snippet:
sundials/src/cvodes/cvodea.c
Lines 2027 to 2037 in 0c83e0b
It seems that the index
i
is not checked for being inside the bounds of thedt_mem
array.If I add the check
if (i > ca_mem->ca_nsteps) return(CV_FWD_FAIL);
at the beginning of the loop body the segmentation fault is solved.However, I am not sure if this is the correct thing to do or if index
i
should always be inside the bounds and the actual problem lies elsewhere.The text was updated successfully, but these errors were encountered: