-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
92 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,12 +22,18 @@ jobs: | |
# https://sonarcloud.io/documentation/analysis/scan/sonarscanner/ | ||
SONAR_SERVER_URL: "https://sonarcloud.io" | ||
ORTOOLS_DIR: ${{ github.workspace }}/or-tools | ||
ORTOOLS_URL: "https://github.com/rte-france/or-tools/releases/download/v9.5-rte2.0/ortools_cxx_ubuntu-20.04_static_sirius.zip" | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis | ||
|
||
- name: Config OR-Tools URL | ||
run: | | ||
echo "ORTOOLS_URL=https://github.com/rte-france/or-tools/releases/download/$(cat ortools_tag)/ortools_cxx_ubuntu-20.04_static_sirius.zip" >> $GITHUB_ENV | ||
- name: Install sonar-scanner and build-wrapper | ||
uses: SonarSource/sonarcloud-github-c-cpp@v2 | ||
|
||
- name: ccache | ||
uses: hendrikmuhs/[email protected] | ||
|
@@ -42,16 +48,6 @@ jobs: | |
key: ${{ runner.os }}-sonar-${{ env.SONAR_SCANNER_VERSION }} | ||
restore-keys: ${{ runner.os }}-sonar-${{ env.SONAR_SCANNER_VERSION }} | ||
|
||
- name: Download and setup sonar-scanner | ||
shell: bash | ||
env: | ||
SONAR_SCANNER_DOWNLOAD_URL: https://binaries.sonarsource.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-${{ env.SONAR_SCANNER_VERSION }}-linux.zip | ||
if: steps.sonarcloud-cache.outputs.cache-hit != 'true' | ||
run: | | ||
mkdir -p $HOME/.sonar | ||
curl -sSLo $HOME/.sonar/sonar-scanner.zip ${{ env.SONAR_SCANNER_DOWNLOAD_URL }} | ||
unzip -o $HOME/.sonar/sonar-scanner.zip -d $HOME/.sonar/ | ||
- name: Download and setup build-wrapper | ||
shell: bash | ||
env: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
v9.5-rte2.0 | ||
v9.5-rte3.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
37 changes: 37 additions & 0 deletions
37
src/solver/utils/include/antares/solver/utils/named_problem.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
#pragma once | ||
|
||
#include "spx_definition_arguments.h" | ||
#include "spx_fonctions.h" | ||
|
||
#include <vector> | ||
#include <string> | ||
#include <algorithm> | ||
#include <iterator> | ||
#include "ortools/linear_solver/linear_solver.h" | ||
|
||
namespace Antares | ||
{ | ||
namespace Optimization | ||
{ | ||
struct PROBLEME_SIMPLEXE_NOMME : public PROBLEME_SIMPLEXE | ||
{ | ||
private: | ||
using BasisStatus = operations_research::MPSolver::BasisStatus; | ||
public: | ||
PROBLEME_SIMPLEXE_NOMME(std::vector<std::string>& NomDesVariables, | ||
std::vector<std::string>& NomDesContraintes, | ||
std::vector<BasisStatus>& StatutDesVariables, | ||
std::vector<BasisStatus>& StatutDesContraintes); | ||
|
||
std::vector<std::string>& NomDesVariables; | ||
std::vector<std::string>& NomDesContraintes; | ||
|
||
std::vector<BasisStatus>& StatutDesVariables; | ||
std::vector<BasisStatus>& StatutDesContraintes; | ||
|
||
bool isMIP() const; | ||
bool basisExists() const; | ||
|
||
}; | ||
} // namespace Optimization | ||
} // namespace Antares |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters