Commit b56e4a17 authored by Lijiao's avatar Lijiao Committed by xuehui
Browse files

fix bug of hyper-parameter graph when search space has loguniform type (#1399)

parent 5b62d048
......@@ -87,13 +87,10 @@ class Para extends React.Component<ParaProps, ParaState> {
let temp: Array<number> = [];
for (let i = 0; i < dimName.length; i++) {
if ('type' in parallelAxis[i]) {
temp.push(
eachTrialParams[item][dimName[i]].toString()
);
temp.push(eachTrialParams[item][dimName[i]].toString());
} else {
temp.push(
eachTrialParams[item][dimName[i]]
);
// default metric
temp.push(eachTrialParams[item][dimName[i]]);
}
}
paraYdata.push(temp);
......@@ -199,11 +196,18 @@ class Para extends React.Component<ParaProps, ParaState> {
break;
// support log distribute
case 'loguniform':
if (lenOfDataSource > 1) {
parallelAxis.push({
dim: i,
name: dimName[i],
type: 'log',
});
} else {
parallelAxis.push({
dim: i,
name: dimName[i]
});
}
break;
default:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment