Skip to content

Benchmark

Benchmark #301

Workflow file for this run

name: Benchmark
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
schedule:
- cron: '0 0 * * SAT'
env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Release
jobs:
coluna:
name: "Coluna.jl"
runs-on: ubuntu-latest
strategy:
matrix:
instances:
# - "dummies"
- "n2"
- "n3"
- "n4"
#- "n5"
steps:
- uses: actions/checkout@v4
#- name: Install Mosek license
# run: 'mkdir ${{github.workspace}}/mosek && echo "${MOSEK_LICENSE}" | base64 --decode > ${{github.workspace}}/mosek/mosek.lic'
# env:
# MOSEK_LICENSE: ${{secrets.MOSEK_LICENSE}}
- name: Update apt-get
run: sudo apt-get update
- uses: julia-actions/setup-julia@v1
with:
version: '1.8.5'
- name: Install JuMP, Coluna.jl and MosekTools.jl
run: julia -e 'using Pkg; Pkg.add("JuMP"); Pkg.add("BlockDecomposition"); Pkg.add("GLPK"); Pkg.add("Coluna"); Pkg.add("DelimitedFiles")'
# run: julia -e 'using Pkg; Pkg.add("JuMP"); Pkg.add("BlockDecomposition"); Pkg.add("MosekTools"); Pkg.add("GLPK"); Pkg.add("Coluna"); Pkg.add("DelimitedFiles")'
- name: Solve instances with Coluna.jl
run: ./run_coluna.sh ./GAP/data/${{ matrix.instances }}
- name: Rename results file
run: mv results_GAP_coluna.csv results_GAP_coluna__$(uuidgen).csv
- uses: actions/upload-artifact@v3
with:
name: results
path: results_GAP_coluna__*.csv
idol:
name: "idol"
runs-on: ubuntu-latest
strategy:
matrix:
arguments:
- "external"
- "bab true"
- "bab false"
- "bap true 0 false true"
- "bap true 0 false false"
- "bap true 0 true true"
- "bap true .3 true true"
instances:
# - "dummies"
- "n2"
- "n3"
- "n4"
#- "n5"
#- "n10"
steps:
- uses: actions/checkout@v4
- name: Update apt-get
run: sudo apt-get update
#- name: Download HiGHS
# run: git clone https://github.com/ERGO-Code/HiGHS.git
#- name: Install HiGHS
# run: mkdir HiGHS/build && cd HiGHS/build && cmake .. && make && sudo make install
- name: Install GLPK
run: sudo apt-get install libglpk-dev
- name: Download robin_hood map
run: wget https://raw.githubusercontent.com/martinus/robin-hood-hashing/3.11.5/src/include/robin_hood.h
- name: Install idol
run: git clone --branch main https://github.com/hlefebvr/idol.git && cd idol && cmake -DUSE_GLPK=YES -DUSE_ROBINHOOD=YES -DROBINHOOD_DIR=${{github.workspace}} . && make && sudo make install
#- name: Download Eigen
# run: wget https://gitlab.com/libeigen/eigen/-/archive/3.4.0/eigen-3.4.0.tar.bz2
#- name: Install Eigen
# run: tar -xvf eigen*.tar.bz2 && rm eigen*.tar.bz2 && find . -depth -type d -name eigen-* -execdir mv {} ${{github.workspace}}/Eigen \;
#- name: Download Mosek
# run: wget https://download.mosek.com/stable/10.0.40/mosektoolslinux64x86.tar.bz2
#- name: Install Mosek
# run: tar -xvf mosektoolslinux64x86.tar.bz2 -C ${{github.workspace}} && (cd ${{github.workspace}}/mosek/10.0/tools/platform/linux64x86/src/fusion_cxx && make install)
- name: Configure CMake
run: cmake -B ${{github.workspace}}/cmake-build-debug -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}}
# run: cmake -B ${{github.workspace}}/cmake-build-debug -DMOSEK_DIR=${{github.workspace}}/mosek/10.0/tools/platform/linux64x86 -DEIGEN_DIR=${{github.workspace}}/Eigen -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}}
- name: Build
run: cmake --build ${{github.workspace}}/cmake-build-debug --config ${{env.BUILD_TYPE}}
#- name: Install Mosek license
# run: 'echo "${MOSEK_LICENSE}" | base64 --decode > ${{github.workspace}}/mosek/mosek.lic'
# env:
# MOSEK_LICENSE: ${{secrets.MOSEK_LICENSE}}
- name: Solve instances with idol
run: ./run_idol.sh ./GAP/data/${{ matrix.instances }} ${{ matrix.arguments }}
shell: bash
#env:
# MOSEKLM_LICENSE_FILE: ${{github.workspace}}/mosek/mosek.lic
- name: Rename results file
run: mv results_GAP_idol.csv results_GAP_idol__$(uuidgen).csv
- name: Rename annex_results file
run: echo "" >> bap_annex_GAP_idol.csv && mv bap_annex_GAP_idol.csv bap_annex_GAP_idol__$(uuidgen).csv
- uses: actions/upload-artifact@v3
with:
name: results
path: results_GAP_idol__*.csv
- uses: actions/upload-artifact@v3
with:
name: results
path: bap_annex_GAP_idol__*.csv
render:
name: "Build report"
runs-on: ubuntu-latest
needs: [coluna, idol]
steps:
- uses: actions/checkout@v4
- name: Download a single artifact
uses: actions/download-artifact@v3
with:
name: results
- name: Collect all results from idol
run: cat results_GAP_idol__*.csv > results_GAP_idol.csv
- name: Collect all annex results from idol
run: cat bap_annex_GAP_idol__*.csv > bap_annex_GAP_idol.csv
- name: Collect all results from Coluna.jl
run: cat results_GAP_coluna__*.csv > results_GAP_coluna.csv
- name: Update apt-get
run: sudo apt-get update
- name: Install dependencies of kableExtra
run: sudo apt-get install libxml2-dev libfontconfig1-dev libcurl4-openssl-dev
- uses: r-lib/actions/setup-pandoc@v2
- uses: r-lib/actions/setup-r@v2
- name: Install rmarkdown
run: R -e "install.packages(\"rmarkdown\")"
- name: Install dplyr
run: R -e "install.packages(\"dplyr\")"
- name: Install rmdformats
run: R -e "install.packages(\"rmdformats\")"
- name: Install ggplot2
run: R -e "install.packages(\"ggplot2\")"
- name: Render report
run: ./build.sh
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
publish_branch: gh-pages
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: reports/
force_orphan: true