File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 9696
9797# Install PyTorch and ONNX related
9898# NOTE set ONE_PREPVENV_TORCH_SOURCE to override options for source URL.
99- TORCH_SOURCE_OPTION=" --extra-index-url https://download.pytorch.org/whl/cpu"
100- if [[ ! -z " $ONE_PREPVENV_TORCH_SOURCE " ]]; then
99+ TORCH_SOURCE_OPTION=" "
100+ if [[ -n " $ONE_PREPVENV_PIP_OPTION " ]]; then
101+ echo " ONE_PREPVENV_PIP_OPTION is set; skipping default torch source option."
102+ elif [[ -n " $ONE_PREPVENV_TORCH_SOURCE " ]]; then
101103 TORCH_SOURCE_OPTION=" ${ONE_PREPVENV_TORCH_SOURCE} "
104+ else
105+ TORCH_SOURCE_OPTION=" --extra-index-url https://download.pytorch.org/whl/cpu"
102106fi
103- # TODO remove torch message
104- echo " Torch from ' ${ONE_PREPVENV_TORCH_SOURCE} ' -> '${TORCH_SOURCE_OPTION} '"
107+
108+ echo " Torch source option: '${TORCH_SOURCE_OPTION} '"
105109
106110${VENV_PYTHON} -m pip ${PIP_OPTIONS} install --upgrade pip setuptools
107111
You can’t perform that action at this time.
0 commit comments