Decision Optimization

Decision Optimization

Delivers prescriptive analytics capabilities and decision intelligence to improve decision-making.


#Analytics
#DecisionOptimization
#DecisionOptimization
 View Only
  • 1.  MIP not working when data size is large

    Posted 07/19/15 11:44 PM

    Originally posted by: prashanw


    My MIP takes a long time to start optimizing. And when optimizing it's stuck at the same place for a day. How can I change this behavior? The log is given below 

    start minimization iteration:  1 , type:  non_alternating
    
    
    Iteration log . . .
    Iteration:     1   Dual objective     =        323000.000800
    Perturbation started.
    Iteration:   102   Dual objective     =        323000.000800
    Elapsed time = 12.57 sec. (12843.84 ticks, 1185 iterations)
    Iteration:  1186   Dual objective     =        323000.001338
    Iteration:  1954   Dual objective     =        323000.001728
    Elapsed time = 56.77 sec. (22846.26 ticks, 2273 iterations)
    Elapsed time = 146.16 sec. (35595.43 ticks, 3755 iterations)
    Iteration:  3756   Dual objective     =        323000.002608
    Removing perturbation.
    Elapsed time = 161.38 sec. (48018.04 ticks, 3815 iterations)
    Iteration:  3816   Dual objective     =        323000.000800
    MIP start 'ws1' defined solution with objective 323000.0008.
    Reinitializing dual norms . . .
    
    Iteration log . . .
    Iteration:     1   Dual objective     =        327999.998728
    Perturbation started.
    Iteration:   203   Dual objective     =        328000.000464
    Elapsed time = 15.51 sec. (10004.76 ticks, 374 iterations)
    Iteration:  1215   Dual objective     =        328000.001264
    Elapsed time = 38.65 sec. (22445.58 ticks, 2113 iterations)
    Iteration:  2114   Dual objective     =        328000.002765
    Iteration:  3294   Dual objective     =        328000.003276
    Iteration:  4939   Dual objective     =        328000.004105
    Elapsed time = 48.12 sec. (32770.72 ticks, 5978 iterations)
    Iteration:  5979   Dual objective     =        328000.004593
    Iteration:  7679   Dual objective     =        328000.005445
    Iteration:  8033   Dual objective     =        328000.005913
    Elapsed time = 66.09 sec. (42784.53 ticks, 13635 iterations)
    Iteration: 14139   Dual objective     =        328000.159513
    Removing perturbation.
    Iteration: 14940    Objective     =        328000.001710
    Elapsed time = 92.38 sec. (61898.64 ticks, 14941 iterations)
    Iteration: 14942   Dual objective     =        328000.001710
    1 of 2 MIP starts provided solutions.
    MIP start 'ws1' defined initial solution with objective 323000.0008.
    MIP emphasis: integer feasibility.
    MIP search method: dynamic search.
    Parallel mode: none, using 1 thread.
    Initializing dual steep norms . . .
    
    Iteration log . . .
    Iteration:     1   Dual objective     =             0.000000
    Perturbation started.
    Iteration:   203   Dual objective     =             0.000100
    Elapsed time = 11.60 sec. (10230.48 ticks, 203 iterations)
    Iteration:  1757   Dual objective     =             0.000101
    Iteration:  3190   Dual objective     =             0.000102
    Iteration:  4635   Dual objective     =             0.000103
    Elapsed time = 31.39 sec. (23169.23 ticks, 6092 iterations)
    Iteration:  6093   Dual objective     =             0.000104
    Iteration:  7606   Dual objective     =             0.000105
    Iteration:  9107   Dual objective     =             0.000106
    Elapsed time = 56.50 sec. (34157.23 ticks, 10620 iterations)
    Iteration: 10621   Dual objective     =             0.000107
    Iteration: 12097   Dual objective     =             0.000108
    Iteration: 13669   Dual objective     =             0.000109
    Elapsed time = 93.13 sec. (46847.00 ticks, 15199 iterations)
    Iteration: 15200   Dual objective     =             0.000110
    Iteration: 16727   Dual objective     =             0.000111
    Iteration: 18261   Dual objective     =             0.000112
    Elapsed time = 126.89 sec. (56847.42 ticks, 18518 iterations)
    Iteration: 19799   Dual objective     =             0.000113
    Elapsed time = 163.15 sec. (67277.55 ticks, 21341 iterations)
    Iteration: 21342   Dual objective     =             0.000114
    Iteration: 22890   Dual objective     =             0.000115
    Elapsed time = 208.04 sec. (79015.26 ticks, 24451 iterations)
    Iteration: 24452   Dual objective     =             0.000116
    Iteration: 26038   Dual objective     =             0.000117
    Elapsed time = 262.17 sec. (92032.16 ticks, 27580 iterations)
    Iteration: 27581   Dual objective     =             0.000118
    Iteration: 29111   Dual objective     =             0.000119
    Elapsed time = 307.64 sec. (102033.47 ticks, 30241 iterations)
    Iteration: 30682   Dual objective     =             0.000119
    Elapsed time = 355.99 sec. (113930.01 ticks, 32286 iterations)
    Iteration: 32287   Dual objective     =             0.000120
    Iteration: 33885   Dual objective     =             0.000121
    Elapsed time = 402.68 sec. (123931.37 ticks, 34476 iterations)
    Iteration: 35485   Dual objective     =             0.000123
    Elapsed time = 450.48 sec. (133934.39 ticks, 36503 iterations)
    Iteration: 37013   Dual objective     =             0.000124
    Elapsed time = 497.81 sec. (143935.50 ticks, 38397 iterations)
    Iteration: 38534   Dual objective     =             0.000125
    
    
    
    My parameters are 
    
    time_limit,tl=True,30*60
        emphasis,emp=True,0
        max_num_sol,sol=False,1
        max_search_nodes,n=False,3
        aggregator_flag,agg=False,0
        #tolerances
        tolerane_flag,tolerance_value=False,0
        Integrality,i_value=False,0
        numerical_precision,numerical_precision_value=False,1    
        #presolve
        presolve_ignore,presolve_value=True,0
        #warm start related
        advance_start,advance_start_value=True,1
        repair_tries,repair_tries_value=True,10
        #conflicts
        conflict_display,conflict_value=False,2
        #parallel
        parallel_mode,parallel_mode_value=True,1
        #display
        display_interval,display_interval_value,display_value=True,3,5
        #tuning
        tuning,tuning_time=False,300
        
        parameter_str=''
        
        if time_limit==True:
            my_prob.parameters.timelimit.set(tl)
            parameter_str+='time_limit= '+str(tl)+'s | '
        if emphasis==True:
            my_prob.parameters.emphasis.mip.set(emp)
            parameter_str+='emphasis= '+str(emp)+' | ' 
        if max_num_sol==True:
            my_prob.parameters.mip.limits.solutions.set(sol)
            parameter_str+='max_num_sol= '+str(sol)+' | ' 
        if max_search_nodes==True:
            my_prob.parameters.mip.limits.nodes.set(n)
            parameter_str+='max_search_nodes= '+str(n)+' | '
        if aggregator_flag==True:   
            my_prob.parameters.preprocessing.aggregator.set(agg)
        if tolerane_flag==True:          
            #my_prob.parameters.mip.tolerances.absmipgap.set(tolerance_value)
            my_prob.parameters.mip.tolerances.mipgap.set(tolerance_value)
            my_prob.parameters.mip.polishing.mipgap.set(1)
        if Integrality==True:
            my_prob.parameters.mip.tolerances.integrality.set(i_value)
        if presolve_ignore==True:
            my_prob.parameters.preprocessing.presolve.set(presolve_value)
        if advance_start==True:
            my_prob.parameters.advance.set(advance_start_value) 
        if repair_tries==True:
            my_prob.parameters.mip.limits.repairtries.set(repair_tries_value) 
        if conflict_display==True:
            my_prob.parameters.conflict.display.set(conflict_value)        
        if numerical_precision==True:
            my_prob.parameters.emphasis.numerical.set(numerical_precision_value)  
        if parallel_mode==True:
            #my_prob.parameters.parallel.set(-1) #  opportunistic parallel search mode
            my_prob.parameters.threads.set(parallel_mode_value)  
        if display_interval==True:
            my_prob.parameters.mip.display.set(display_value)
            my_prob.parameters.mip.interval.set(display_interval_value)
        if tuning==True:        
            #my_prob.parameters.tune.timelimit.set(tuning_time)
            my_prob.parameters.tune_problem() 
        return parameter_str
    

    Any help is greatly appreciated. I tried most of the methods suggested in http://www-01.ibm.com/support/docview.wss?uid=swg21400023#Item7  but nothing seems to work. This happens when the size of the problem is large (given below). Since the parallel threads were consuming a lot of memory (>200GB) I went back to using one thread according to http://support.gams.com/doku.php?id=solver:error_1001_out_of_memory

    num_variables for original problem :  1,999,292
    num_constraints for original problem :  17,694,850

     

    When its small(given below) it seems to work ok.

    num_variables for original problem :  127,890
    num_constraints for original problem :  1,077,348

     

     


    #CPLEXOptimizers
    #DecisionOptimization


  • 2.  Re: MIP not working when data size is large

    Posted 08/11/15 02:36 AM

    Do I understand correctly, your solve is stuck at this point

    Elapsed time = 497.81 sec. (143935.50 ticks, 38397 iterations)
    Iteration: 38534   Dual objective     =             0.000125

    for one day? If so, can you share your model, either by posting it here or sending it to daniel(dot)junglas(at)de(dot)ibm(dot)com?

    Since you are already stuck in the initial LP solve, none of the strategies mentioned in the quoted technote are going to be helpful. One thing you could try is to solve the initial LP with parallel barrier. To do that set CPX_PARA_STARTALG=4 and CPX_PARAM_THREADS=0. Then stop right after the root by setting CPX_PARAM_NODELIM=0. Does this complete in a reasonable amount of time?


    #CPLEXOptimizers
    #DecisionOptimization


  • 3.  Re: MIP not working when data size is large

    Posted 08/12/15 02:38 PM

    Originally posted by: prashanw


    Hi Daniel.........after making those changes it doesn't complete in a reasonable amount of time. I dropped you an email. Thanks!


    #CPLEXOptimizers
    #DecisionOptimization