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

Support search space type='choice' value=[true, false] for customized trial #3003

Merged
merged 1 commit into from
Oct 21, 2020
Merged
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
5 changes: 4 additions & 1 deletion src/webui/src/components/modals/CustomizedTrial.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,10 @@ class Customize extends React.Component<CustomizeProps, CustomizeState> {
Object.keys(customized).map(item => {
if (item !== 'tag') {
// unified data type
if (typeof copyTrialParameter[item] === 'number' && typeof customized[item] === 'string') {
if (
(typeof copyTrialParameter[item] === 'number' && typeof customized[item] === 'string') ||
(typeof copyTrialParameter[item] === 'boolean' && typeof customized[item] === 'string')
) {
customized[item] = JSON.parse(customized[item]);
}
if (searchSpace[item] === undefined) {
Expand Down