diff --git a/examples/trials/mnist-pytorch/mnist.py b/examples/trials/mnist-pytorch/mnist.py index 91c68c12a9..af7dcce982 100644 --- a/examples/trials/mnist-pytorch/mnist.py +++ b/examples/trials/mnist-pytorch/mnist.py @@ -5,6 +5,7 @@ https://github.com/pytorch/examples/blob/master/mnist/main.py """ +import os import argparse import logging import nni @@ -84,15 +85,18 @@ def main(args): device = torch.device("cuda" if use_cuda else "cpu") kwargs = {'num_workers': 1, 'pin_memory': True} if use_cuda else {} + + data_dir = os.path.join(args['data_dir'], nni.get_trial_id()) + train_loader = torch.utils.data.DataLoader( - datasets.MNIST(args['data_dir'], train=True, download=True, + datasets.MNIST(data_dir, train=True, download=True, transform=transforms.Compose([ transforms.ToTensor(), transforms.Normalize((0.1307,), (0.3081,)) ])), batch_size=args['batch_size'], shuffle=True, **kwargs) test_loader = torch.utils.data.DataLoader( - datasets.MNIST(args['data_dir'], train=False, transform=transforms.Compose([ + datasets.MNIST(data_dir, train=False, transform=transforms.Compose([ transforms.ToTensor(), transforms.Normalize((0.1307,), (0.3081,)) ])), diff --git a/src/sdk/pynni/nni/hyperband_advisor/hyperband_advisor.py b/src/sdk/pynni/nni/hyperband_advisor/hyperband_advisor.py index 7e376c6d9e..699d02c050 100644 --- a/src/sdk/pynni/nni/hyperband_advisor/hyperband_advisor.py +++ b/src/sdk/pynni/nni/hyperband_advisor/hyperband_advisor.py @@ -32,6 +32,7 @@ from nni.msg_dispatcher_base import MsgDispatcherBase from nni.protocol import CommandType, send from nni.utils import NodeType, OptimizeMode, MetricType, extract_scalar_reward +import nni.parameter_expressions as parameter_expressions _logger = logging.getLogger(__name__) diff --git a/src/webui/src/index.css b/src/webui/src/index.css index 373637d4d4..118fc88769 100644 --- a/src/webui/src/index.css +++ b/src/webui/src/index.css @@ -19,8 +19,8 @@ time, mark, audio, video { margin: 0; padding: 0; border: 0; + font: inherit; font-size: 100%; - font: inherit; } /* HTML5 display-role reset for older browsers */ article, aside, details, figcaption, figure, @@ -48,4 +48,4 @@ q:before, q:after { table { border-collapse: collapse; border-spacing: 0; -} \ No newline at end of file +} diff --git a/test/pipelines-it-kubeflow.yml b/test/pipelines-it-kubeflow.yml index e9c160636c..3173a7312c 100644 --- a/test/pipelines-it-kubeflow.yml +++ b/test/pipelines-it-kubeflow.yml @@ -39,11 +39,6 @@ jobs: displayName: 'Install nni toolkit via source code' - script: | - python3 -m pip install scikit-learn==0.20.0 --user - python3 -m pip install torch==0.4.1 --user - python3 -m pip install torchvision==0.2.1 --user - python3 -m pip install keras==2.1.6 --user - python3 -m pip install tensorflow==1.12.0 --user sudo apt-get install swig -y PATH=$HOME/.local/bin:$PATH nnictl package install --name=SMAC PATH=$HOME/.local/bin:$PATH nnictl package install --name=BOHB diff --git a/test/pipelines-it-local.yml b/test/pipelines-it-local.yml index 4f054546fc..31a2e8cdb6 100644 --- a/test/pipelines-it-local.yml +++ b/test/pipelines-it-local.yml @@ -9,8 +9,8 @@ jobs: displayName: 'Install nni toolkit via source code' - script: | python3 -m pip install scikit-learn==0.20.0 --user - python3 -m pip install torch==0.4.1 --user - python3 -m pip install torchvision==0.2.1 --user + python3 -m pip install torch==1.2.0 --user + python3 -m pip install torchvision==0.4.0 --user python3 -m pip install keras==2.1.6 --user python3 -m pip install tensorflow-gpu==1.12.0 --user sudo apt-get install swig -y diff --git a/test/pipelines-it-pai.yml b/test/pipelines-it-pai.yml index 5e44c7a6be..26c1e05cd8 100644 --- a/test/pipelines-it-pai.yml +++ b/test/pipelines-it-pai.yml @@ -39,11 +39,6 @@ jobs: displayName: 'Install nni toolkit via source code' - script: | - python3 -m pip install scikit-learn==0.20.0 --user - python3 -m pip install torch==0.4.1 --user - python3 -m pip install torchvision==0.2.1 --user - python3 -m pip install keras==2.1.6 --user - python3 -m pip install tensorflow-gpu==1.12.0 --user sudo apt-get install swig -y PATH=$HOME/.local/bin:$PATH nnictl package install --name=SMAC PATH=$HOME/.local/bin:$PATH nnictl package install --name=BOHB