Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
nni
Commits
97f9d8a9
Unverified
Commit
97f9d8a9
authored
Jun 17, 2020
by
Lijiaoa
Committed by
GitHub
Jun 17, 2020
Browse files
Show original search space (#2570)
parent
1a6cc414
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
19 deletions
+1
-19
src/webui/src/components/Overview.tsx
src/webui/src/components/Overview.tsx
+1
-19
No files found.
src/webui/src/components/Overview.tsx
View file @
97f9d8a9
...
...
@@ -61,7 +61,6 @@ class Overview extends React.Component<OverviewProps, OverviewState> {
render
():
React
.
ReactNode
{
const
{
trialConcurrency
}
=
this
.
state
;
const
{
experimentUpdateBroadcast
,
metricGraphMode
,
bestTrialEntries
}
=
this
.
props
;
const
searchSpace
=
this
.
convertSearchSpace
();
const
bestTrials
=
this
.
findBestTrials
();
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
const
bestAccuracy
=
bestTrials
.
length
>
0
?
bestTrials
[
0
].
accuracy
!
:
NaN
;
...
...
@@ -105,7 +104,7 @@ class Overview extends React.Component<OverviewProps, OverviewState> {
<
Stack
.
Item
grow
styles
=
{
{
root
:
{
width
:
450
}}
}
className
=
"overviewBoder borderRight bgNNI"
>
<
Title1
text
=
"Search space"
icon
=
"10.png"
/>
<
Stack
className
=
"experiment"
>
<
SearchSpace
searchSpace
=
{
searchSpace
}
/>
<
SearchSpace
searchSpace
=
{
EXPERIMENT
.
searchSpace
}
/>
</
Stack
>
</
Stack
.
Item
>
{
/* <Stack.Item grow styles={{root: {width: 450}}} className="bgNNI"> */
}
...
...
@@ -163,23 +162,6 @@ class Overview extends React.Component<OverviewProps, OverviewState> {
);
}
private
convertSearchSpace
():
object
{
const
searchSpace
=
Object
.
assign
({},
EXPERIMENT
.
searchSpace
);
Object
.
keys
(
searchSpace
).
map
(
item
=>
{
const
key
=
searchSpace
[
item
].
_type
;
const
value
=
searchSpace
[
item
].
_value
;
switch
(
key
)
{
case
'
quniform
'
:
case
'
qnormal
'
:
case
'
qlognormal
'
:
searchSpace
[
item
].
_value
=
[
value
[
0
],
value
[
1
]];
break
;
default
:
}
});
return
searchSpace
;
}
private
findBestTrials
():
Trial
[]
{
const
bestTrials
=
TRIALS
.
sort
();
const
{
bestTrialEntries
}
=
this
.
props
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment