Why the cplex_options with 'memoryemphasis=1' doesn't work as it is expected ?

169 views
Skip to first unread message

Tiancivalen

unread,
Mar 31, 2014, 2:47:52 AM3/31/14
to am...@googlegroups.com
Hi everyone,
I'm new to AMPL and CPLEX and encountered a big problem when trying to solve a path planning problem with only 3 vehicles involved. I coded the model , data and run files in the Scite editing environment. The road network I used is not so complex which has only 80 nodes. However when I run the solver ( CPLEX 12.6 ), the RAM used increased all the way until the following error occured:
    Error at _cmdno 5 executing "solve" command
    (file clare.run, line 7, offset 155):

    Too much memory used -- 2100753552 bytes; couldn't get 25600 more.


Then I set the "cplex_options" according to the IBM ILOG AMPL User’s Guide trying to let it use disk memories :
    option cplex_options 'mipdisplay=2 memoryemphasis=1 workfilelim=512 workfiledir="D:"';
but it seems that only the 'mipdisplay=2' directive works, and the RAM usage shows no difference as before. So I wander why the memoryemphasis=1 directive doesn't work? What's wrong?

By the way, when I tried to reduce the vehicles number to 2, it can solve the problem properly, though used a lot of the RAM (about 84% of 3GB).

Could anyone tell me something about this problem? I'd really appreciate it. Thank you!

Robert Fourer

unread,
Apr 1, 2014, 10:40:48 AM4/1/14
to am...@googlegroups.com
The error that you are seeing occurs in AMPL, while it is generating the problem instance. AMPL runs out of memory before it can send the problem to CPLEX. Thus, changing the CPLEX options cannot help in this situation.

The "memory used" shown in the error message is slightly less than 2GB. If you have a lot more memory than that, you are probably running a 32-bit version of AMPL, and you will need to switch to a 64-bit version to take advantage of all your computer's memory. (The AMPL command "option version;" provides some information about the version you have.)

If AMPL is using much more memory than you expect, see the following link for help in determining what part of your model is using all of that memory:

http://www.ampl.com/FAQ/index.html#WhatshouldIdoifIsuspectthatthereisinsufficientmemoryformyAMPLsession

Bob Fourer
am...@googlegroups.com

=======

Tiancivalen

unread,
Apr 30, 2014, 12:58:36 AM4/30/14
to am...@googlegroups.com, 4...@ampl.com
Thank you very much. That is exactly the reason.

Since I'm using an 32bit operation system, the 64bit AMPL may not be suitable for it. Is there any way to make AMPL use the disk memory to generate the problem instance?

在 2014年4月1日星期二UTC+8下午10时40分48秒,AMPL Optimization写道:

Robert Fourer

unread,
May 1, 2014, 4:47:37 PM5/1/14
to am...@googlegroups.com
AMPL cannot use disk space in place of RAM memory in generating a problem instance.
Reply all
Reply to author
Forward
0 new messages