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
5f62543f
"docs/en_US/git@developer.sourcefind.cn:OpenDAS/nni.git" did not exist on "3ec26b40afd88b8255ebc74b46f475b77aa4d19b"
Commit
5f62543f
authored
Dec 02, 2019
by
Yuge Zhang
Committed by
chicm-ms
Dec 02, 2019
Browse files
Fix naive test and tuner test on Windows pipeline with sleep (#1800)
parent
2576e55c
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
3 additions
and
1 deletion
+3
-1
test/metrics_test/trial.py
test/metrics_test/trial.py
+1
-0
test/naive_test/naive_trial.py
test/naive_test/naive_trial.py
+1
-0
test/utils.py
test/utils.py
+1
-1
No files found.
test/metrics_test/trial.py
View file @
5f62543f
...
@@ -6,6 +6,7 @@ import nni
...
@@ -6,6 +6,7 @@ import nni
if
__name__
==
'__main__'
:
if
__name__
==
'__main__'
:
nni
.
get_next_parameter
()
nni
.
get_next_parameter
()
time
.
sleep
(
1
)
for
i
in
range
(
10
):
for
i
in
range
(
10
):
if
i
%
2
==
0
:
if
i
%
2
==
0
:
print
(
'report intermediate result without end of line.'
,
end
=
''
)
print
(
'report intermediate result without end of line.'
,
end
=
''
)
...
...
test/naive_test/naive_trial.py
View file @
5f62543f
...
@@ -9,6 +9,7 @@ params = nni.get_next_parameter()
...
@@ -9,6 +9,7 @@ params = nni.get_next_parameter()
print
(
'params:'
,
params
)
print
(
'params:'
,
params
)
x
=
params
[
'x'
]
x
=
params
[
'x'
]
time
.
sleep
(
1
)
for
i
in
range
(
1
,
10
):
for
i
in
range
(
1
,
10
):
nni
.
report_intermediate_result
(
x
**
i
)
nni
.
report_intermediate_result
(
x
**
i
)
time
.
sleep
(
0.5
)
time
.
sleep
(
0.5
)
...
...
test/utils.py
View file @
5f62543f
...
@@ -83,7 +83,7 @@ def is_experiment_done(nnimanager_log_path):
...
@@ -83,7 +83,7 @@ def is_experiment_done(nnimanager_log_path):
with
open
(
nnimanager_log_path
,
'r'
)
as
f
:
with
open
(
nnimanager_log_path
,
'r'
)
as
f
:
log_content
=
f
.
read
()
log_content
=
f
.
read
()
return
EXPERIMENT_DONE_SIGNAL
in
log_content
return
EXPERIMENT_DONE_SIGNAL
in
log_content
def
get_experiment_status
(
status_url
):
def
get_experiment_status
(
status_url
):
...
...
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