Skip to content

Commit

Permalink
[Other] Add new download dir for release version (PaddlePaddle#618)
Browse files Browse the repository at this point in the history
* Fix release_task cpp_run.sh

 Author:    felixhjh <[email protected]>
 Date:      Thu Nov 10 07:26:48 2022 +0000

* Add option for infer_ppyoloe.cc

  author:    felixhjh <[email protected]>

* Fix bug in release task scripts

* Add error check function

* Format code

* Add new download dir for release version

Co-authored-by: root <[email protected]>
  • Loading branch information
felixhjh and root authored Nov 17, 2022
1 parent dbe96cd commit 1694d9a
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
8 changes: 7 additions & 1 deletion tests/release_task/cpp_run.bat
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ echo "PLATFORM: " %PLATFORM%
echo "DEVICE: " %DEVICE%
echo "VERSION: " %VERSION%

if "%VERSION%" == "0.0.0" (
set DOWNLOAD_DIR=dev
) else (
set DOWNLOAD_DIR=rel_tmp
)

if "%DEVICE%" == "gpu" (
set CPP_FASTDEPLOY_PACKAGE=fastdeploy-%PLATFORM%-%DEVICE%-%VERSION%
set RUN_CASES=ort paddle trt
Expand All @@ -33,7 +39,7 @@ set MODEL_PATH=%CURRENT_DIR%\ppyoloe_crn_l_300e_coco
set GROUND_TRUTH_PATH=%CURRENT_DIR%\release_task_groud_truth_result.txt
set COMPARE_SHELL=%CURRENT_DIR%\compare_with_gt.py

python -c "from download import *; download_and_decompress('https://fastdeploy.bj.bcebos.com/dev/cpp/%CPP_FASTDEPLOY_PACKAGE%.zip', './')"
python -c "from download import *; download_and_decompress('https://fastdeploy.bj.bcebos.com/%DOWNLOAD_DIR%/cpp/%CPP_FASTDEPLOY_PACKAGE%.zip', './')"

mkdir build && cd build
cmake .. -G "Visual Studio 16 2019" -A x64 -DFASTDEPLOY_INSTALL_DIR=%cd%\..\%CPP_FASTDEPLOY_PACKAGE% -DCUDA_DIRECTORY="C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v11.2"
Expand Down
7 changes: 6 additions & 1 deletion tests/release_task/cpp_run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@ CURRENT_DIR=$(cd $(dirname $0); pwd)
PLATFORM=$1
DEVICE=$2
VERSION=$3
if [ "$VERSION" = "0.0.0" ];then
DOWNLOAD_DIR=dev
else
DOWNLOAD_DIR=rel_tmp
fi
if [ "$DEVICE" = "gpu" ];then
CPP_FASTDEPLOY_PACKAGE=fastdeploy-$PLATFORM-$DEVICE-$VERSION
else
Expand Down Expand Up @@ -42,7 +47,7 @@ fi

case_number=${#RUN_CASE[@]}

wget -q https://fastdeploy.bj.bcebos.com/dev/cpp/$CPP_FASTDEPLOY_PACKAGE.tgz
wget -q https://fastdeploy.bj.bcebos.com/$DOWNLOAD_DIR/cpp/$CPP_FASTDEPLOY_PACKAGE.tgz

tar xvf $CPP_FASTDEPLOY_PACKAGE.tgz
mkdir build && cd build
Expand Down

0 comments on commit 1694d9a

Please sign in to comment.