[ADMB Users] Memory allocation error

Skip to first unread message


Mar 29, 2011, 1:50:26 PM3/29/11
to us...@admb-project.org
I am working on a tag-integrated assessment model that allows movement
between 3 sub-populations (SCAA framework, 22 years of data, 6 ages, 3
stocks, ~200 estimated parameters including 6 movement parameters). The
data set I have includes only 4 years of tag releases and recoveries. The
original model I developed ran with this limited tagging data set (it does
not converge, but that is another issue for another time). I wanted to
run some simulations to see if I could get the model to converge if I
extended the tagging time series. I altered the model to account for a 10
year tagging dataset and turned off the parameter estimation in order to
simulate the data. However, I immediately ran into the following error:

"Memory allocation error -- Perhaps you are trying to allocate too much
memory in your program"

I kept reducing the length of the time series and discovered that for
simulating data 8 years of tagging data appeared to be the cutoff, but for
the actual model when estimating parameters 4 years of tagging data
calculations was about the maximum.

I've been through the forum and checked out all the manuals and memory
management documents including Ian and Allan's memory usage paper and
Mark's memory management page. I've played around with arrmblsize,
GRADSTACK_BUFFER_SIZE, and CMPDIF_BUFFER_SIZE within my .tpl file, looking
at combinations of high values, low values, and mixes of both, but no
matter what combination I use I still get the error message. In addition,
I've attempted to make my code more efficient by replacing loops with
matrix algebra as much as possible, etc...

After that long-winded preamble my main question is whether this is
actually a problem that can be fixed by altering the model or if it is
simply a matter of my computer not having enough memory/computing power to
handle the model?

I am currently using the ADMB-IDE and my computer specs are:

Dell Latitude E6500 laptop
Intel Core 2 Duo CPU
3.48GB of RAM
~240GB hard drive
Windows XP

I have talked to a few other people working on larger assessment models
that have run into a similar problem so I think it will be of interest to
a few people. Also, I am more than willing to share my code if anyone
wants to take a look at it and provide some suggestions. I am not a great
programmer so I am sure it could be made more efficient, but except for a
few tweaks I do not see any large scale changes that would make it more

Thanks for the help,

Dan Goethel

Users mailing list

dave fournier

Mar 30, 2011, 11:07:53 AM3/30/11
to us...@admb-project.org
If you compile your program in debug mode and put a breakpoint in ad_exit()
and do a stack trace you can find the line where this is happening. It may
be that you are doing something like trying to allocate a vector where
one of the
arguments is uninitialized.
Reply all
Reply to author
0 new messages