Skip to content
This repository has been archived by the owner on Sep 18, 2024. It is now read-only.

Merge v0.2 to master #236

Closed
wants to merge 5 commits into from
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
4 changes: 2 additions & 2 deletions examples/trials/auto-gbdt/config_pai.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ trial:
#The docker image to run nni job on pai
image: openpai/pai.example.tensorflow
#The hdfs directory to store data on pai, format 'hdfs://host:port/directory'
hdfsDataDir: hdfs://10.10.10.10:9000/username/nni
dataDir: hdfs://10.10.10.10:9000/username/nni
#The hdfs directory to store output data generated by nni, format 'hdfs://host:port/directory'
hdfsOutputDir: hdfs://10.10.10.10:9000/username/nni
outputDir: hdfs://10.10.10.10:9000/username/nni
paiConfig:
#The username to login pai
userName: username
Expand Down
4 changes: 2 additions & 2 deletions examples/trials/ga_squad/config_pai.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ trial:
#The docker image to run nni job on pai
image: openpai/pai.example.tensorflow
#The hdfs directory to store data on pai, format 'hdfs://host:port/directory'
hdfsDataDir: hdfs://10.10.10.10:9000/username/nni
dataDir: hdfs://10.10.10.10:9000/username/nni
#The hdfs directory to store output data generated by nni, format 'hdfs://host:port/directory'
hdfsOutputDir: hdfs://10.10.10.10:9000/username/nni
outputDir: hdfs://10.10.10.10:9000/username/nni
paiConfig:
#The username to login pai
userName: username
Expand Down
4 changes: 2 additions & 2 deletions examples/trials/mnist-annotation/config_pai.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@ trial:
#The docker image to run nni job on pai
image: openpai/pai.example.tensorflow
#The hdfs directory to store data on pai, format 'hdfs://host:port/directory'
hdfsDataDir: hdfs://10.10.10.10:9000/username/nni
dataDir: hdfs://10.10.10.10:9000/username/nni
#The hdfs directory to store output data generated by nni, format 'hdfs://host:port/directory'
hdfsOutputDir: hdfs://10.10.10.10:9000/username/nni
outputDir: hdfs://10.10.10.10:9000/username/nni
paiConfig:
#The username to login pai
userName: username
Expand Down
4 changes: 2 additions & 2 deletions examples/trials/mnist-batch-tune-keras/config_pai.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ trial:
#The docker image to run nni job on pai
image: openpai/pai.example.tensorflow
#The hdfs directory to store data on pai, format 'hdfs://host:port/directory'
hdfsDataDir: hdfs://10.10.10.10:9000/username/nni
dataDir: hdfs://10.10.10.10:9000/username/nni
#The hdfs directory to store output data generated by nni, format 'hdfs://host:port/directory'
hdfsOutputDir: hdfs://10.10.10.10:9000/username/nni
outputDir: hdfs://10.10.10.10:9000/username/nni
paiConfig:
#The username to login pai
userName: username
Expand Down
4 changes: 2 additions & 2 deletions examples/trials/mnist-keras/config_pai.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ trial:
#The docker image to run nni job on pai
image: openpai/pai.example.tensorflow
#The hdfs directory to store data on pai, format 'hdfs://host:port/directory'
hdfsDataDir: hdfs://10.10.10.10:9000/username/nni
dataDir: hdfs://10.10.10.10:9000/username/nni
#The hdfs directory to store output data generated by nni, format 'hdfs://host:port/directory'
hdfsOutputDir: hdfs://10.10.10.10:9000/username/nni
outputDir: hdfs://10.10.10.10:9000/username/nni
paiConfig:
#The username to login pai
userName: username
Expand Down
4 changes: 2 additions & 2 deletions examples/trials/mnist-smartparam/config_pai.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@ trial:
#The docker image to run nni job on pai
image: openpai/pai.example.tensorflow
#The hdfs directory to store data on pai, format 'hdfs://host:port/directory'
hdfsDataDir: hdfs://10.10.10.10:9000/username/nni
dataDir: hdfs://10.10.10.10:9000/username/nni
#The hdfs directory to store output data generated by nni, format 'hdfs://host:port/directory'
hdfsOutputDir: hdfs://10.10.10.10:9000/username/nni
outputDir: hdfs://10.10.10.10:9000/username/nni
paiConfig:
#The username to login pai
userName: username
Expand Down
4 changes: 2 additions & 2 deletions examples/trials/mnist/config_pai.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ trial:
#The docker image to run nni job on pai
image: openpai/pai.example.tensorflow
#The hdfs directory to store data on pai, format 'hdfs://host:port/directory'
hdfsDataDir: hdfs://10.10.10.10:9000/username/nni
dataDir: hdfs://10.10.10.10:9000/username/nni
#The hdfs directory to store output data generated by nni, format 'hdfs://host:port/directory'
hdfsOutputDir: hdfs://10.10.10.10:9000/username/nni
outputDir: hdfs://10.10.10.10:9000/username/nni
paiConfig:
#The username to login pai
userName: username
Expand Down
4 changes: 2 additions & 2 deletions examples/trials/pytorch_cifar10/config_pai.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ trial:
#The docker image to run nni job on pai
image: openpai/pai.example.tensorflow
#The hdfs directory to store data on pai, format 'hdfs://host:port/directory'
hdfsDataDir: hdfs://10.10.10.10:9000/username/nni
dataDir: hdfs://10.10.10.10:9000/username/nni
#The hdfs directory to store output data generated by nni, format 'hdfs://host:port/directory'
hdfsOutputDir: hdfs://10.10.10.10:9000/username/nni
outputDir: hdfs://10.10.10.10:9000/username/nni
paiConfig:
#The username to login pai
userName: username
Expand Down
2 changes: 1 addition & 1 deletion src/webui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"version": "0.1.0",
"private": true,
"dependencies": {
"antd": "^3.9.3",
"antd": "^3.8.1",
"axios": "^0.18.0",
"babel-polyfill": "^6.26.0",
"echarts": "^4.1.0",
Expand Down
4 changes: 2 additions & 2 deletions src/webui/src/components/SlideBar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ class SlideBar extends React.Component<{}, {}> {
<ul className="nav">
<li>
<IndexLink to={'/oview'} activeClassName="high">
<Icon className="icon" type="experiment" theme="outlined" />Overview
<Icon className="icon" type="home" />Overview
<Icon className="floicon" type="right" />
</IndexLink>
</li>
Expand Down Expand Up @@ -41,7 +41,7 @@ class SlideBar extends React.Component<{}, {}> {
</li>
<li>
<a href="https://github.com/Microsoft/nni/issues" target="_blank">
<Icon className="icon" type="smile" theme="outlined" />Feedback
<Icon className="icon" type="smile" />Feedback
</a>
</li>
</ul>
Expand Down
31 changes: 27 additions & 4 deletions src/webui/src/components/TrialStatus.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ interface TabState {
trialJobs: object;
intermediateOption: object;
modalVisible: boolean;
disTensorButton: boolean;
}

class TrialStatus extends React.Component<{}, TabState> {
Expand Down Expand Up @@ -79,7 +80,8 @@ class TrialStatus extends React.Component<{}, TabState> {
option: {},
intermediateOption: {},
trialJobs: {},
modalVisible: false
modalVisible: false,
disTensorButton: false
};
}

Expand Down Expand Up @@ -346,13 +348,34 @@ class TrialStatus extends React.Component<{}, TabState> {
};
}

// experiment mode is pai, display tensorboard button
disTensorBoard = () => {
axios(`${MANAGER_IP}/experiment`, {
method: 'GET'
})
.then(res => {
if (res.status === 200) {
const experimentObj = res.data;
const trainPlatform = experimentObj.params.trainingServicePlatform;
if (trainPlatform && trainPlatform === 'pai') {
if (this._isMounted) {
this.setState(() => ({
disTensorButton: true
}));
}
}
}
});
}

componentDidMount() {

this._isMounted = true;
// the init of running chart
this.drawRunGraph();
// the init of trials status in the table
this.drawTable();
this.disTensorBoard();
this.intervalID = window.setInterval(this.drawRunGraph, 10000);
this.intervalIDS = window.setInterval(this.drawTable, 10000);
}
Expand All @@ -365,7 +388,7 @@ class TrialStatus extends React.Component<{}, TabState> {
}

render() {
const { intermediateOption, modalVisible, option, tableData } = this.state;
const { intermediateOption, modalVisible, option, tableData, disTensorButton } = this.state;
let bgColor = '';
const trialJob: Array<TrialJob> = [];
trialJobStatus.map(item => {
Expand Down Expand Up @@ -457,7 +480,7 @@ class TrialStatus extends React.Component<{}, TabState> {
</Button>
)
);
},
}
}, {
title: 'Tensor',
dataIndex: 'tensor',
Expand All @@ -468,6 +491,7 @@ class TrialStatus extends React.Component<{}, TabState> {
<Button
type="primary"
className="tableButton"
disabled={disTensorButton}
onClick={this.getTensorpage.bind(this, record.id)}
>
TensorBoard
Expand All @@ -476,7 +500,6 @@ class TrialStatus extends React.Component<{}, TabState> {
},
}
];

const openRow = (record: TableObj) => {
const parametersRow = {
parameters: record.description.parameters
Expand Down
2 changes: 1 addition & 1 deletion tools/nnicmd/config_schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
'builtinAssessorName': lambda x: x in ['Medianstop'],
'classArgs': {
'optimize_mode': lambda x: x in ['maximize', 'minimize']},
'gpuNum': And(int, lambda x: 0 <= x <= 99999)
Optional('gpuNum'): And(int, lambda x: 0 <= x <= 99999)
},{
'codeDir': os.path.exists,
'classFileName': str,
Expand Down