Decision Optimization

Decision Optimization

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


#Analytics
#DecisionOptimization
#DecisionOptimization
 View Only
  • 1.  Tune multiple .lp in IloCplex (Java)

    Posted 11/30/17 11:49 AM

    Originally posted by: CamilaSalles


    Hello Guys,

    I got tune one lp (export of opl) in java with IloCPlex.

    But, I need run multiple lp's, because are multiples scenarios of model, and I need of one option that's good for all scenarios.

    And I cannot import multiple lp in IloCplex. Has some away to do that in IloCplex?

    I tried to run it in opl, but I had a overflow memory.

    Someone can help me with that ?

    Thank you,


    #DecisionOptimization
    #MathematicalProgramming-General


  • 2.  Re: Tune multiple .lp in IloCplex (Java)

    Posted 11/30/17 12:44 PM

    Hi,

    You tried with OPL within the IDE

    But have you tried with oplrun ?

       -tune ops-file      tune cplex parameters, with -p
                             multiple run-configurations can be selected,
                             otherwise all

    And with interactive cplex ?

    Examples: time limits on tuning in the Interactive Optimizer

    Shows the effect of both deterministic and nondeterministic time limits on the tuning tool in the Interactive Optimizer.

    Both overall system time limits (in seconds) and overall deterministic time limits (in ticks) have an impact on tuning. Likewise, both overall time limits and per-problem, per-optimization time limits also govern tuning. These examples in the Interactive Optimizer illustrate key points about time limits and tuning.

    regards


    #DecisionOptimization
    #MathematicalProgramming-General


  • 3.  Re: Tune multiple .lp in IloCplex (Java)

    Posted 11/30/17 12:58 PM

    Originally posted by: CamilaSalles


    Hello AlexFleischer,

    I could not open your link, I think that is with error.

    I will try with oplrun.

    Thank you.

     


    #DecisionOptimization
    #MathematicalProgramming-General


  • 4.  Re: Tune multiple .lp in IloCplex (Java)



  • 5.  Re: Tune multiple .lp in IloCplex (Java)

    Posted 11/30/17 01:32 PM

    Since the link Alex posted is not that detailed, here is the help text for the 'tune' command in the interactive optimizer:

    The TUNE command solves the current problem, or a set of problems
    specified in a file, repeatedly with a variety of parameter
    settings in order to find settings which reduce solution time.
    The current parameter settings are automatically
    changed to correspond to the best settings that were found.
    These settings can be displayed or written to a file.

    Syntax:  TUNE [{parameter file name}] [{problem set file name}]

    The first optional filename specifies a parameter file containing
    parameter settings that should not be changed while tuning. The
    parameter file name must end with .prm. The other optional file
    specifies a list of problem file names including directories for
    a set of problems for tuning.

    Note that this command does not produce a solution to the current
    problem.

    Example: TUNE
    Tunes the problem that exists in memory from a READ or ENTER command.

    Example: TUNE myparams.prm
    Tunes the problem that exists in memory from a READ or ENTER command,
    but leaves the parameters given in the file myparams.prm at their
    given values.

    Example: TUNE probset.txt
    Tunes a set of problems, which are given in the file probset.txt.
    Each line in the file is a filename of a problem including directory,
    for example:
       /myproblems/problem1.lp
       /myproblems/problem2.lp

    Example: TUNE myparams.prm probset.txt
    Tunes a set of problems, but leaves the parameters given in the file
    myparams.prm at their given values.

    So if you have all your models in different .lp files then just create a file that lists all those files and supply it as an argument for tuning. To create the parameters file required as first argument you can just issue command 'write myparams.prm'. That will create a file with appropriate format that does not fix any parameters.

     

    Moreover, the IloCplex class has an overload for the tuneParam() function that takes as argument a list of file names. You can use that to tune for multiple models at the same time. Just check the reference manual for your API here.


    #DecisionOptimization
    #MathematicalProgramming-General


  • 6.  Re: Tune multiple .lp in IloCplex (Java)

    Posted 11/30/17 03:06 PM

    Originally posted by: CamilaSalles


    Thanks both for the answer.

    I will test the options.


    #DecisionOptimization
    #MathematicalProgramming-General


Global message icon