GRBModel.Dispose() take too much time

65 views
Skip to first unread message

Ying Zhang

unread,
May 17, 2015, 11:24:15 PM5/17/15
to gur...@googlegroups.com
Hello,

Now I use Gurobi (in C#.NET) to solve a larger scale MIP.

I set the time limit to 1800 seconds. When the time is up, via Windows Task Manager, I see that my Physical Memory is taken 98%,

Then after the method model.Optimize() is executed, I use model.Dispose() to release the resources.

But this single line needs more than 10 minutes!!

model.Dispose();

What I mean is that, Gurobi need more than 10 minuted to release all the resources! Via task manager, I see that the memory my program takes decrease from 98% to 0 very slowly.
How could this happern? I was expected the Dispose() method to implement rather fast.

How to fix this? Thank you.

Greg Glockner

unread,
May 17, 2015, 11:31:04 PM5/17/15
to gur...@googlegroups.com
Sounds like your computer is low on physical memory, so it is using virtual memory.

Ying Zhang

unread,
May 18, 2015, 11:08:12 AM5/18/15
to gur...@googlegroups.com
Dear Greg,

Thanks, so it seems that the program uses virtual memory automatically. Is there some methods to turn that off? If the physical memory is insufficient, can I write some nodes of the B&B tree to the local hard disk?

 If it does use virtual memory, so it will take so much time to release all the resources?

Renan Garcia

unread,
May 19, 2015, 2:17:10 PM5/19/15
to gur...@googlegroups.com
Please read FAQ 32 at http://www.gurobi.com/support/faqs#CHS for guidance on how to minimize Gurobi's memory footprint (i.e., physical and virtual). In particular, you can write B&B nodes to disk with the NodefileStart parameter (see http://www.gurobi.com/documentation/6.0/refman/nodefilestart.html). You might also consider reducing the Threads parameter (see http://www.gurobi.com/documentation/6.0/refman/threads.html).

--

---
You received this message because you are subscribed to the Google Groups "Gurobi Optimization" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gurobi+un...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages