Skip to content
Closed
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
11 changes: 6 additions & 5 deletions ci/travis/install-dependencies.sh
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ install_nvm() {
fi
}

install_pip() {
install_upgrade_pip() {
local python=python
if command -v python3 > /dev/null; then
python=python3
Expand Down Expand Up @@ -237,10 +237,12 @@ install_dependencies() {
install_base
install_toolchains
install_nvm
install_pip
install_upgrade_pip

if [ -n "${PYTHON-}" ] || [ "${LINT-}" = 1 ]; then
install_miniconda
# Upgrade the miniconda pip.
install_upgrade_pip
fi

# Install modules needed in all jobs.
Expand Down Expand Up @@ -278,8 +280,8 @@ install_dependencies() {
if [ "${OSTYPE}" = msys ] && [ "${python_version}" = "3.8" ]; then
{ echo "WARNING: Pillow binaries not available on Windows; cannot build docs"; } 2> /dev/null
else
pip install -r "${WORKSPACE_DIR}"/doc/requirements-rtd.txt
pip install -r "${WORKSPACE_DIR}"/doc/requirements-doc.txt
pip install --use-deprecated=legacy-resolver -r "${WORKSPACE_DIR}"/doc/requirements-rtd.txt
pip install --use-deprecated=legacy-resolver -r "${WORKSPACE_DIR}"/doc/requirements-doc.txt
fi
fi

Expand Down Expand Up @@ -314,7 +316,6 @@ install_dependencies() {
1.5) TORCHVISION_VERSION=0.6.0;;
*) TORCHVISION_VERSION=0.5.0;;
esac

pip install --use-deprecated=legacy-resolver --upgrade tensorflow-probability=="${TFP_VERSION-0.8}" \
torch=="${TORCH_VERSION-1.6}" torchvision=="${TORCHVISION_VERSION}" \
tensorflow=="${TF_VERSION-2.2.0}" gym
Expand Down
4 changes: 2 additions & 2 deletions python/ray/util/sgd/torch/examples/dcgan.py
Original file line number Diff line number Diff line change
Expand Up @@ -182,8 +182,8 @@ def get_pred(x):
@override(TrainingOperator)
def train_batch(self, batch, batch_info):
"""Trains on one batch of data from the data creator."""
real_label = 1
fake_label = 0
real_label = 1.0
fake_label = 0.
discriminator, generator = self.models
optimD, optimG = self.optimizers

Expand Down