mirror of
https://github.com/alibaba/EasyCV.git
synced 2025-06-03 14:49:00 +08:00
* avoid numpy version check when xtcocotools can be imported Link: https://code.alibaba-inc.com/pai-vision/EasyCV/codereview/10377599 * * move thirdparty into easycv * fix code style Link: https://code.alibaba-inc.com/pai-vision/EasyCV/codereview/10395748 * move thirdparty into easycv * fix missing thirdparty/deformable_attention/src when build package * optimize ci_test * update version to 0.6.3.8 Link: https://code.alibaba-inc.com/pai-vision/EasyCV/codereview/10412059 * update version to 0.6.3.8 * fix face keypoints bugs in FT * update version to 0.6.3.9 Link: https://code.alibaba-inc.com/pai-vision/EasyCV/codereview/10443200 * update version to 0.6.3.9 * fix import thirdparty * fix unittest * fix unittest Co-authored-by: wenmeng.zwm <wenmeng.zwm@alibaba-inc.com> Co-authored-by: shouzhou.bx <shouzhou.bx@alibaba-inc.com>
44 lines
1.2 KiB
Bash
44 lines
1.2 KiB
Bash
#!/system/bin/sh
|
|
|
|
#================================================================
|
|
# Copyright (C) 2022 Alibaba Ltd. All rights reserved.
|
|
#
|
|
#================================================================
|
|
|
|
# linter test
|
|
pip install -r requirements/tests.txt
|
|
# use internal project for pre-commit due to the network problem
|
|
if [ `git remote -v | grep alibaba | wc -l` -gt 1 ]; then
|
|
cp .pre-commit-config.yaml.alibaba .pre-commit-config.yaml
|
|
fi
|
|
pre-commit run --all-files
|
|
if [ $? -ne 0 ]; then
|
|
echo "linter test failed, please run 'pre-commit run --all-files' to check"
|
|
exit -1
|
|
fi
|
|
|
|
#add ossconfig for unittest
|
|
UNITTEST_OSS_CONFIG=~/.ossutilconfig.unittest
|
|
if [ ! -e $UNITTEST_OSS_CONFIG ]; then
|
|
echo "$UNITTEST_OSS_CONFIG does not exists"
|
|
exit
|
|
fi
|
|
|
|
export OSS_CONFIG_FILE=$UNITTEST_OSS_CONFIG
|
|
export TEST_DIR="/tmp/easycv_test_${USER}_`date +%s`"
|
|
|
|
# build package
|
|
python setup.py sdist bdist_wheel
|
|
|
|
# get package path
|
|
PACKAGE_PATH=$(ls package/dist/*.whl)
|
|
|
|
# install easycv
|
|
pip uninstall -y pai-easycv
|
|
pip install $PACKAGE_PATH
|
|
|
|
# move source code, ensure import easycv from site-package
|
|
mv ./easycv ./easycv_src
|
|
#run test
|
|
PYTHONPATH=. python tests/run.py
|