Skip to content

Commit

Permalink
Remove duplicate useOrtools (#541)
Browse files Browse the repository at this point in the history
Having 2 attributes results in OR-Tools not being used even if
the flag --use-ortools is present.
  • Loading branch information
flomnes authored Feb 7, 2022
1 parent a12b233 commit 73e8d8d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 0 additions & 2 deletions src/libs/antares/study/load-options.h
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,6 @@ class StudyLoadOptions
YString studyFolder;
YString simulationName;
std::string ortoolsSolver;

bool useOrtools = false;
}; // class StudyLoadOptions

} // namespace Data
Expand Down
4 changes: 2 additions & 2 deletions src/solver/misc/options.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ GetOpt::Parser CreateParser(Settings& settings, Antares::Data::StudyLoadOptions&

// add option for ortools use
// --use-ortools
parser.addFlag(options.useOrtools, ' ', "use-ortools", "Use ortools library to launch solver");
parser.addFlag(options.ortoolsUsed, ' ', "use-ortools", "Use ortools library to launch solver");

//--ortools-solver
parser.add(options.ortoolsSolver,
Expand Down Expand Up @@ -259,7 +259,7 @@ void checkAndCorrectSettingsAndOptions(Settings& settings, Data::StudyLoadOption
void checkOrtoolsSolver(Data::StudyLoadOptions& options)
{
// ortools solver
if (options.useOrtools)
if (options.ortoolsUsed)
{
const std::list<std::string> availableSolverList
= OrtoolsUtils().getAvailableOrtoolsSolverName();
Expand Down

0 comments on commit 73e8d8d

Please sign in to comment.