diff --git a/paddle/scripts/paddle_build.sh b/paddle/scripts/paddle_build.sh index 4bd93da72ef682cedf585871dc764da2a4da32c5..921455d52eccc391635c7bdf10da098fcf221824 100755 --- a/paddle/scripts/paddle_build.sh +++ b/paddle/scripts/paddle_build.sh @@ -580,7 +580,8 @@ function generate_api_spec() { cd ${PADDLE_ROOT}/build/.check_api_workspace virtualenv .${spec_kind}_env source .${spec_kind}_env/bin/activate - pip install ${PADDLE_ROOT}/build/python/dist/*whl + pip install -r ${PADDLE_ROOT}/python/requirements.txt + pip --no-cache-dir install ${PADDLE_ROOT}/build/python/dist/*whl spec_path=${PADDLE_ROOT}/paddle/fluid/API_${spec_kind}.spec python ${PADDLE_ROOT}/tools/print_signatures.py paddle > $spec_path diff --git a/python/requirements.txt b/python/requirements.txt index 76e6b5dedbeaf8acf726b634e3579f980ff9702f..28c84c1d630a66077a737a48bb8a26200ec48f0b 100644 --- a/python/requirements.txt +++ b/python/requirements.txt @@ -1,3 +1,4 @@ +opencv-python<=4.2.0.32 requests>=2.20.0 numpy>=1.13, <=1.16.4 ; python_version<"3.5" numpy>=1.13 ; python_version>="3.5"