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
95b5e5f3
Unverified
Commit
95b5e5f3
authored
May 18, 2020
by
Lijiaoa
Committed by
GitHub
May 18, 2020
Browse files
show top trials (#2433)
Co-authored-by:
Lijiao
<
15910218274@163.com
>
parent
5c861676
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
1 deletion
+8
-1
src/webui/src/components/trial-detail/Para.tsx
src/webui/src/components/trial-detail/Para.tsx
+8
-1
No files found.
src/webui/src/components/trial-detail/Para.tsx
View file @
95b5e5f3
import
*
as
React
from
'
react
'
;
import
ReactEcharts
from
'
echarts-for-react
'
;
import
{
filterByStatus
}
from
'
../../static/function
'
;
import
{
EXPERIMENT
}
from
'
../../static/datamodel
'
;
import
{
Stack
,
PrimaryButton
,
Dropdown
,
IDropdownOption
,
}
from
'
office-ui-fabric-react
'
;
// eslint-disable-line no-unused-vars
import
{
ParaObj
,
Dimobj
,
TableObj
}
from
'
../../static/interface
'
;
// eslint-disable-line no-unused-vars
import
'
echarts/lib/chart/parallel
'
;
...
...
@@ -98,7 +99,13 @@ class Para extends React.Component<ParaProps, ParaState> {
// according acc to sort ydata // sort to find top percent dataset
if
(
paraYdata
.
length
!==
0
)
{
const
len
=
paraYdata
[
0
].
length
-
1
;
paraYdata
.
sort
((
a
,
b
)
=>
b
[
len
]
-
a
[
len
]);
// show top trials
if
(
EXPERIMENT
.
optimizeMode
===
'
minimize
'
)
{
paraYdata
.
sort
((
a
,
b
)
=>
a
[
len
]
-
b
[
len
]);
}
if
(
EXPERIMENT
.
optimizeMode
===
'
maximize
'
)
{
paraYdata
.
sort
((
a
,
b
)
=>
b
[
len
]
-
a
[
len
]);
}
}
const
paraData
=
{
parallelAxis
:
parallelAxis
,
...
...
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