Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[‌CI]Update CI scripts #9929

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion csrc/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,13 @@ def read_version():
"""
read version and return content
"""
VERSION = "3.0.0b3.post"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个要不要考虑直接拿paddlenlp的版本?

if os.getenv(PADDLENLP_STABLE_VERSION):
VERSION = VERSION.replace(".post", "")
else:
formatted_date = datetime.now().date().strftime("%Y%m%d")
VERSION = VERSION.replace(".post", ".post{}".format(formatted_date))

return VERSION


Expand All @@ -50,7 +57,7 @@ def read_readme():
setup(
name="paddlenlp_ops",
packages=find_packages(),
version="0.0.0",
version=read_version(),
author="Paddle Infernce Team",
author_email="[email protected]",
description=description,
Expand Down
13 changes: 8 additions & 5 deletions scripts/regression/ci_case.sh
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,12 @@ print_info() {
else
tail -n 1 ${log_path}/$2.log
echo -e "\033[32m ${log_path}/$2_SUCCESS \033[0m"
if [ -e "${PPNLP_HOME}/upload" ] && [ "$(ls -A "${PPNLP_HOME}/upload")" ]; then
cd ${PPNLP_HOME} && ls -A "${PPNLP_HOME}/upload"
python upload.py ${PPNLP_HOME}/upload 'paddlenlp/wheels'
rm -rf upload/*
echo -e "\033[32m upload wheels SUCCESS \033[0m"
fi
fi
}
# case list
Expand Down Expand Up @@ -561,13 +567,10 @@ llm(){
cd ${nlp_dir}/csrc
# python setup_cuda.py install
bash tools/build_wheel.sh python3.10 80
cp ./dist/p****.whl ${PPNLP_HOME}/upload/
cd ${PPNLP_HOME}
python upload.py ${PPNLP_HOME}/upload 'paddlenlp/wheels'
rm -rf upload/*
cp ${nlp_dir}/csrc/dist/p****.whl ${PPNLP_HOME}/upload/
else
echo "No modifications in csrc, installing paddlenlp_ops wheel file..."
python -m pip install https://paddlenlp.bj.bcebos.com/wheels/paddlenlp_ops-0.0.0-py3-none-any.whl
python -m pip install --pre --upgrade paddlenlp_ops -f https://www.paddlepaddle.org.cn/whl/paddlenlp.html --no-cache-dir
fi

sleep 5
Expand Down
8 changes: 4 additions & 4 deletions scripts/regression/run_ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -217,9 +217,9 @@ if [[ ${#Build_list[*]} -ne 0 ]];then
cd PaddleNLP_dev && git submodule update --init --recursive
cd /workspace && tar -zcf PaddleNLP.tar.gz PaddleNLP_dev/
mv PaddleNLP.tar.gz ${PPNLP_HOME}/upload
cd ${PPNLP_HOME}
python upload.py ${PPNLP_HOME}/upload 'paddlenlp/wheels'
rm -rf upload/*
# cd ${PPNLP_HOME}
# python upload.py ${PPNLP_HOME}/upload 'paddlenlp/wheels'
# rm -rf upload/*
else
echo -e "\033[32m Don't need build whl \033[0m"
fi
Expand All @@ -234,7 +234,7 @@ if [[ ${#P0case_list[*]} -ne 0 ]] || [[ ${#APIcase_list[*]} -ne 0 ]];then
install_paddle
echo "install_nlp_develop"
wget https://paddlenlp.bj.bcebos.com/wheels/paddlenlp-ci-py3-none-any.whl
python -m pip install --user paddlenlp-ci-py3-none-any.whl
python -m pip install --user paddlenlp-ci-py3-none-any.whl --no-cache-dir
else
echo "instal_nlp_pr"
python -m pip install dist/p****.whl
Expand Down
2 changes: 1 addition & 1 deletion scripts/unit_test/ci_unit.sh
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ install_requirements() {
# rm -rf upload/*
else
echo "No modifications in csrc, installing paddlenlp_ops wheel file..."
python -m pip install https://paddlenlp.bj.bcebos.com/wheels/paddlenlp_ops-0.0.0-py3-none-any.whl
python -m pip install --pre --upgrade paddlenlp_ops -f https://www.paddlepaddle.org.cn/whl/paddlenlp.html --no-cache-dir
fi

pip list
Expand Down
Loading