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
625a72d5
Unverified
Commit
625a72d5
authored
Aug 26, 2020
by
liuzhe-lz
Committed by
GitHub
Aug 26, 2020
Browse files
Fix IT (#2827)
parent
4f70fb30
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
+5
-3
src/sdk/pynni/nni/package_utils.py
src/sdk/pynni/nni/package_utils.py
+5
-3
No files found.
src/sdk/pynni/nni/package_utils.py
View file @
625a72d5
...
@@ -308,9 +308,11 @@ def _try_installation_path_sequentially(*sitepackages):
...
@@ -308,9 +308,11 @@ def _try_installation_path_sequentially(*sitepackages):
Return None if nothing is found
Return None if nothing is found
'''
'''
for
sitepackage
in
sitepackages
:
for
sitepackage
in
sitepackages
:
for
path
in
[
Path
(
sitepackage
).
parents
[
2
],
Path
(
sitepackage
)]:
path
=
Path
(
sitepackage
)
if
(
path
/
'nni'
/
'main.js'
).
is_file
():
if
len
(
path
.
parents
)
>
2
and
(
path
.
parents
[
2
]
/
'nni'
/
'main.js'
).
is_file
():
return
str
(
path
)
return
str
(
path
.
parents
[
2
])
if
(
path
/
'nni'
/
'main.js'
).
is_file
():
return
str
(
path
)
return
None
return
None
def
get_nni_installation_path
():
def
get_nni_installation_path
():
...
...
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