Skip to content
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
3 changes: 3 additions & 0 deletions docker/install/ubuntu_install_boost.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ cleanup() {

trap cleanup 0

# NOTE: by default, tvm-venv python is used. Install boost on the system.
PATH=${PATH/${TVM_VENV}\/bin:/}

curl -LO https://boostorg.jfrog.io/artifactory/main/release/1.67.0/source/boost_1_67_0.tar.gz
BOOST_HASH=8c247e040303a97895cee9c9407ef205e2c3ab09f0b8320997835ad6221dff23a87231629498ccfd0acca473f74e9ec27b8bd774707b062228df1e5f72d44c92
echo "$BOOST_HASH" boost_1_67_0.tar.gz | sha512sum -c
Expand Down
4 changes: 2 additions & 2 deletions docker/install/ubuntu_install_caffe.sh
Original file line number Diff line number Diff line change
Expand Up @@ -65,5 +65,5 @@ cd / && rm -rf /caffe_src

PYCAFFE_ROOT=${CAFFE_HOME}/python
echo "${CAFFE_HOME}/lib" >> /etc/ld.so.conf.d/caffe.conf && ldconfig
VENV_SITE_PACKAGE=$(pip3 show numpy | grep "Location:" | cut -d ' ' -f 2)
ln -s ${PYCAFFE_ROOT}/caffe ${VENV_SITE_PACKAGE}/caffe
Copy link
Member

Choose a reason for hiding this comment

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

fyi #12813 fixed this too via site-packages

Copy link
Contributor Author

Choose a reason for hiding this comment

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

true, do you have a preference? cc @ashutosh-arm

Copy link
Contributor Author

Choose a reason for hiding this comment

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

oh sorry, reading the CI failure now. ignore me :)

site_packages=$("${TVM_VENV}/bin/python3" -c 'import site; print(site.getsitepackages()[0])')
ln -s ${PYCAFFE_ROOT}/caffe "${site_packages}/caffe"
7 changes: 7 additions & 0 deletions docker/install/ubuntu_install_python.sh
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,13 @@ mkdir -p "${venv_dir}"
python3 -mvenv "${TVM_VENV}"
. "${TVM_VENV}/bin/activate"

# NOTE: Only in python3.9 does venv guarantee it creates the python3.X binary.
# This is needed so that cmake's find_package(PythonInterp) works inside the venv.
# See https://bugs.python.org/issue39656
if [ ! -e "${TVM_VENV}/bin/python${PYTHON_VERSION}" ]; then
ln -s "${TVM_VENV}/bin/python" "${TVM_VENV}/bin/python${PYTHON_VERSION}"
fi

# Update pip to match version used to produce requirements-hashed.txt. This step
# is necessary so that pip's dependency solver is recent.
pip_spec=$(cat /install/python/bootstrap/lockfiles/constraints-${PYTHON_VERSION}.txt | grep 'pip==')
Expand Down