[tune] Improve mnist_pytorch.py example (#3894)

## What do these changes do?

* Improved --no-cuda handling
* Removed deprecated Variable usage


## Related issue number

Fixes #3873 
<!-- Are there any issues opened that will be resolved by merging this change? -->
This commit is contained in:
vfdev
2019-02-04 17:59:54 -08:00
committed by Richard Liaw
parent 5fb813ff39
commit b2b8417790
3 changed files with 28 additions and 31 deletions
+2 -3
View File
@@ -367,12 +367,11 @@ docker run --rm --shm-size=${SHM_SIZE} --memory=${MEMORY_SIZE} $DOCKER_SHA \
--smoke-test
docker run --rm --shm-size=${SHM_SIZE} --memory=${MEMORY_SIZE} $DOCKER_SHA \
python /ray/python/ray/tune/examples/mnist_pytorch.py \
--smoke-test
python /ray/python/ray/tune/examples/mnist_pytorch.py --smoke-test --no-cuda
docker run --rm --shm-size=${SHM_SIZE} --memory=${MEMORY_SIZE} $DOCKER_SHA \
python /ray/python/ray/tune/examples/mnist_pytorch_trainable.py \
--smoke-test
--smoke-test --no-cuda
docker run --rm --shm-size=${SHM_SIZE} --memory=${MEMORY_SIZE} $DOCKER_SHA \
python /ray/python/ray/tune/examples/genetic_example.py \