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

add tensorflow-probability to resource tar #500

Merged
merged 16 commits into from
Nov 13, 2024
Merged
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
1 change: 0 additions & 1 deletion .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,3 @@ python:
- requirements: requirements/docs.txt
- method: setuptools
path: .
- tensorflow-probability
24 changes: 22 additions & 2 deletions pai_jobs/deploy_ext.sh
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,6 @@ fi
cp -R $root_dir/easy_rec ./easy_rec
sed -i -e "s/\[VERSION\]/$VERSION/g" easy_rec/__init__.py
find -L easy_rec -name "*.pyc" | xargs rm -rf
echo "tensorflow-probability==0.5.0" > requirements.txt

if [ ! -d "datahub" ]
then
Expand Down Expand Up @@ -144,7 +143,28 @@ then
rm -rf faiss.tar.gz
fi

tar -cvzhf $RES_PATH easy_rec datahub lz4 cprotobuf kafka faiss run.py requirements.txt
if [ ! -d "tensorflow_probability" ]
then
if [ $is_tf15 -gt 0 ]; then
tfp_version='0.8.0'
else
tfp_version='0.5.0'
fi
if [ ! -e "tensorflow_probability" ]
then
wget http://easyrec.oss-cn-beijing.aliyuncs.com/3rdparty/probability-${tfp_version}.tar.gz
if [ $? -ne 0 ]
then
echo "tensorflow_probability download failed."
fi
fi
tar -xzvf probability-${tfp_version}.tar.gz --strip-components=1 probability-${tfp_version}/tensorflow_probability
rm -rf tensorflow_probability/examples
rm -rf tensorflow_probability/g3doc
rm -rf probability-${tfp_version}.tar.gz
fi

tar -cvzhf $RES_PATH easy_rec datahub lz4 cprotobuf kafka faiss tensorflow_probability run.py

# 2 means generate only
if [ $mode -ne 2 ]
Expand Down
1 change: 1 addition & 0 deletions requirements/docs.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ recommonmark==0.6.0
sphinx==5.1.1
sphinx_markdown_tables==0.0.17
sphinx_rtd_theme
tensorflow-probability
Loading