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
42879806
"docs/en_US/git@developer.sourcefind.cn:OpenDAS/nni.git" did not exist on "faca02c3e1490690a52b5181d30aab69af56a370"
Unverified
Commit
42879806
authored
Sep 07, 2020
by
liuzhe-lz
Committed by
GitHub
Sep 07, 2020
Browse files
shut validator ipc warning (#2864)
parent
c6ec21f4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
1 deletion
+3
-1
tools/nni_cmd/config_schema.py
tools/nni_cmd/config_schema.py
+3
-1
No files found.
tools/nni_cmd/config_schema.py
View file @
42879806
# Copyright (c) Microsoft Corporation.
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
# Licensed under the MIT license.
import
os
import
json
import
json
import
logging
import
os
import
netifaces
import
netifaces
from
schema
import
Schema
,
And
,
Optional
,
Regex
,
Or
,
SchemaError
from
schema
import
Schema
,
And
,
Optional
,
Regex
,
Or
,
SchemaError
from
nni.package_utils
import
create_validator_instance
,
get_all_builtin_names
,
get_builtin_algo_meta
from
nni.package_utils
import
create_validator_instance
,
get_all_builtin_names
,
get_builtin_algo_meta
...
@@ -78,6 +79,7 @@ class AlgoSchema:
...
@@ -78,6 +79,7 @@ class AlgoSchema:
if
meta
and
'accept_class_args'
in
meta
and
meta
[
'accept_class_args'
]
==
False
:
if
meta
and
'accept_class_args'
in
meta
and
meta
[
'accept_class_args'
]
==
False
:
raise
SchemaError
(
'classArgs is not allowed.'
)
raise
SchemaError
(
'classArgs is not allowed.'
)
logging
.
getLogger
(
'nni.protocol'
).
setLevel
(
logging
.
ERROR
)
# we know IPC is not there, don't complain
validator
=
create_validator_instance
(
algo_type
+
's'
,
builtin_name
)
validator
=
create_validator_instance
(
algo_type
+
's'
,
builtin_name
)
if
validator
:
if
validator
:
try
:
try
:
...
...
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