Implement end-to-end benchmark

This commit is contained in:
Siarhei Fedartsou 2024-05-26 14:45:00 +02:00
parent 30b1c95774
commit edc6f5cbf2
2 changed files with 10 additions and 7 deletions

View File

@ -640,13 +640,16 @@ jobs:
key: v1-conan-benchmarks-${{ github.sha }} key: v1-conan-benchmarks-${{ github.sha }}
restore-keys: | restore-keys: |
v1-conan-benchmarks- v1-conan-benchmarks-
- run: pip install locust - name: Prepare data
run: |
wget http://download.geofabrik.de/europe/germany/berlin-latest.osm.pbf -O ~/data.osm.pbf
- name: Install dependencies
run: python3 -m pip install "conan<2.0.0" "requests==2.31.0" "locust==2.28.0"
- name: Checkout PR Branch - name: Checkout PR Branch
uses: actions/checkout@v4 uses: actions/checkout@v4
with: with:
ref: ${{ github.head_ref }} ref: ${{ github.head_ref }}
path: pr path: pr
- run: python3 -m pip install "conan<2.0.0" "requests==2.31.0"
- name: Build PR Branch - name: Build PR Branch
run: | run: |
mkdir -p pr/build mkdir -p pr/build

View File

@ -21,12 +21,12 @@ function run_benchmarks_for_folder {
# ./$BENCHMARKS_FOLDER/rtree-bench "./$FOLDER/test/data/monaco.osrm.ramIndex" "./$FOLDER/test/data/monaco.osrm.fileIndex" "./$FOLDER/test/data/monaco.osrm.nbg_nodes" > "$RESULTS_FOLDER/rtree.bench" # ./$BENCHMARKS_FOLDER/rtree-bench "./$FOLDER/test/data/monaco.osrm.ramIndex" "./$FOLDER/test/data/monaco.osrm.fileIndex" "./$FOLDER/test/data/monaco.osrm.nbg_nodes" > "$RESULTS_FOLDER/rtree.bench"
BINARIES_FOLDER="$FOLDER/build" BINARIES_FOLDER="$FOLDER/build"
wget http://download.geofabrik.de/europe/germany/berlin-latest.osm.pbf
echo "PWD: $FOLDER" echo "PWD: $FOLDER"
$BINARIES_FOLDER/osrm-extract -p $FOLDER/profiles/car.lua $FOLDER/berlin-latest.osm.pbf cp ~/data.osm.pbf $FOLDER
$BINARIES_FOLDER/osrm-partition $FOLDER/berlin-latest.osrm $BINARIES_FOLDER/osrm-extract -p $FOLDER/profiles/car.lua $FOLDER/data.osm.pbf
$BINARIES_FOLDER/osrm-customize $FOLDER/berlin-latest.osrm $BINARIES_FOLDER/osrm-partition $FOLDER/data.osrm
$BINARIES_FOLDER/osrm-routed --algorithm mld $FOLDER/berlin-latest.osrm & $BINARIES_FOLDER/osrm-customize $FOLDER/data.osrm
$BINARIES_FOLDER/osrm-routed --algorithm mld $FOLDER/data.osrm &
OSRM_ROUTED_PID=$! OSRM_ROUTED_PID=$!
# TODO: save results # TODO: save results