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
587dd3af
Unverified
Commit
587dd3af
authored
Nov 25, 2019
by
liuzhe-lz
Committed by
GitHub
Nov 25, 2019
Browse files
Update license header (#1757)
parent
17e267f8
Changes
223
Show whitespace changes
Inline
Side-by-side
Showing
20 changed files
with
54 additions
and
172 deletions
+54
-172
src/nni_manager/training_service/test/sshClientUtility.test.ts
...ni_manager/training_service/test/sshClientUtility.test.ts
+2
-18
src/sdk/pycli/nnicli/__init__.py
src/sdk/pycli/nnicli/__init__.py
+2
-19
src/sdk/pycli/nnicli/nni_client.py
src/sdk/pycli/nnicli/nni_client.py
+2
-19
src/sdk/pycli/setup.py
src/sdk/pycli/setup.py
+3
-0
src/sdk/pynni/nni/__init__.py
src/sdk/pynni/nni/__init__.py
+2
-20
src/sdk/pynni/nni/__main__.py
src/sdk/pynni/nni/__main__.py
+3
-19
src/sdk/pynni/nni/assessor.py
src/sdk/pynni/nni/assessor.py
+2
-19
src/sdk/pynni/nni/batch_tuner/batch_tuner.py
src/sdk/pynni/nni/batch_tuner/batch_tuner.py
+3
-19
src/sdk/pynni/nni/bohb_advisor/bohb_advisor.py
src/sdk/pynni/nni/bohb_advisor/bohb_advisor.py
+3
-19
src/sdk/pynni/nni/common.py
src/sdk/pynni/nni/common.py
+2
-20
src/sdk/pynni/nni/compression/tensorflow/__init__.py
src/sdk/pynni/nni/compression/tensorflow/__init__.py
+3
-0
src/sdk/pynni/nni/compression/tensorflow/builtin_pruners.py
src/sdk/pynni/nni/compression/tensorflow/builtin_pruners.py
+3
-0
src/sdk/pynni/nni/compression/tensorflow/builtin_quantizers.py
...dk/pynni/nni/compression/tensorflow/builtin_quantizers.py
+3
-0
src/sdk/pynni/nni/compression/tensorflow/compressor.py
src/sdk/pynni/nni/compression/tensorflow/compressor.py
+3
-0
src/sdk/pynni/nni/compression/tensorflow/default_layers.py
src/sdk/pynni/nni/compression/tensorflow/default_layers.py
+3
-0
src/sdk/pynni/nni/compression/torch/__init__.py
src/sdk/pynni/nni/compression/torch/__init__.py
+3
-0
src/sdk/pynni/nni/compression/torch/builtin_pruners.py
src/sdk/pynni/nni/compression/torch/builtin_pruners.py
+3
-0
src/sdk/pynni/nni/compression/torch/builtin_quantizers.py
src/sdk/pynni/nni/compression/torch/builtin_quantizers.py
+3
-0
src/sdk/pynni/nni/compression/torch/compressor.py
src/sdk/pynni/nni/compression/torch/compressor.py
+3
-0
src/sdk/pynni/nni/compression/torch/default_layers.py
src/sdk/pynni/nni/compression/torch/default_layers.py
+3
-0
No files found.
src/nni_manager/training_service/test/sshClientUtility.test.ts
View file @
587dd3af
/**
// Copyright (c) Microsoft Corporation.
* Copyright (c) Microsoft Corporation
// Licensed under the MIT license.
* All rights reserved.
*
* MIT License
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
* documentation files (the "Software"), to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
* to permit persons to whom the Software is furnished to do so, subject to the following conditions:
* The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
* BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
* DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
'
use strict
'
;
'
use strict
'
;
...
...
src/sdk/pycli/nnicli/__init__.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation. All rights reserved.
# Copyright (c) Microsoft Corporation.
#
# Licensed under the MIT license.
# MIT License
#
# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
# associated documentation files (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge, publish, distribute,
# sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in all copies or
# substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT
# NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT
# OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
# ==================================================================================================
from
.nni_client
import
*
from
.nni_client
import
*
src/sdk/pycli/nnicli/nni_client.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation. All rights reserved.
# Copyright (c) Microsoft Corporation.
#
# Licensed under the MIT license.
# MIT License
#
# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
# associated documentation files (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge, publish, distribute,
# sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in all copies or
# substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT
# NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT
# OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
# ==================================================================================================
""" A python wrapper for nni rest api
""" A python wrapper for nni rest api
...
...
src/sdk/pycli/setup.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
import
setuptools
import
setuptools
setuptools
.
setup
(
setuptools
.
setup
(
...
...
src/sdk/pynni/nni/__init__.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation. All rights reserved.
# Copyright (c) Microsoft Corporation.
#
# Licensed under the MIT license.
# MIT License
#
# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
# associated documentation files (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge, publish, distribute,
# sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in all copies or
# substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT
# NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT
# OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
# ==================================================================================================
from
.trial
import
*
from
.trial
import
*
from
.smartparam
import
*
from
.smartparam
import
*
...
...
src/sdk/pynni/nni/__main__.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation
# Copyright (c) Microsoft Corporation.
# All rights reserved.
# Licensed under the MIT license.
#
# MIT License
#
# Permission is hereby granted, free of charge,
# to any person obtaining a copy of this software and associated
# documentation files (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge, publish,
# distribute, sublicense, and/or sell copies of the Software, and
# to permit persons to whom the Software is furnished to do so, subject to the following conditions:
# The above copyright notice and this permission notice shall be included
# in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
# BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
'''
'''
__main__.py
__main__.py
'''
'''
...
...
src/sdk/pynni/nni/assessor.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation. All rights reserved.
# Copyright (c) Microsoft Corporation.
#
# Licensed under the MIT license.
# MIT License
#
# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
# associated documentation files (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge, publish, distribute,
# sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in all copies or
# substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT
# NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT
# OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
# ==================================================================================================
"""
"""
Assessor analyzes trial's intermediate results (e.g., periodically evaluated accuracy on test dataset)
Assessor analyzes trial's intermediate results (e.g., periodically evaluated accuracy on test dataset)
...
...
src/sdk/pynni/nni/batch_tuner/batch_tuner.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation
# Copyright (c) Microsoft Corporation.
# All rights reserved.
# Licensed under the MIT license.
#
# MIT License
#
# Permission is hereby granted, free of charge,
# to any person obtaining a copy of this software and associated
# documentation files (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge, publish,
# distribute, sublicense, and/or sell copies of the Software, and
# to permit persons to whom the Software is furnished to do so, subject to the following conditions:
# The above copyright notice and this permission notice shall be included
# in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
# BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
"""
"""
batch_tuner.py including:
batch_tuner.py including:
class BatchTuner
class BatchTuner
...
...
src/sdk/pynni/nni/bohb_advisor/bohb_advisor.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation
# Copyright (c) Microsoft Corporation.
# All rights reserved.
# Licensed under the MIT license.
#
# MIT License
#
# Permission is hereby granted, free of charge,
# to any person obtaining a copy of this software and associated
# documentation files (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge, publish,
# distribute, sublicense, and/or sell copies of the Software, and
# to permit persons to whom the Software is furnished to do so, subject to the following conditions:
# The above copyright notice and this permission notice shall be included
# in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
# BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
'''
'''
bohb_advisor.py
bohb_advisor.py
'''
'''
...
...
src/sdk/pynni/nni/common.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation. All rights reserved.
# Copyright (c) Microsoft Corporation.
#
# Licensed under the MIT license.
# MIT License
#
# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
# associated documentation files (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge, publish, distribute,
# sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in all copies or
# substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT
# NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT
# OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
# ==================================================================================================
from
datetime
import
datetime
from
datetime
import
datetime
from
io
import
TextIOBase
from
io
import
TextIOBase
...
...
src/sdk/pynni/nni/compression/tensorflow/__init__.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
from
.compressor
import
LayerInfo
,
Compressor
,
Pruner
,
Quantizer
from
.compressor
import
LayerInfo
,
Compressor
,
Pruner
,
Quantizer
from
.builtin_pruners
import
*
from
.builtin_pruners
import
*
from
.builtin_quantizers
import
*
from
.builtin_quantizers
import
*
src/sdk/pynni/nni/compression/tensorflow/builtin_pruners.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
import
logging
import
logging
import
numpy
as
np
import
numpy
as
np
import
tensorflow
as
tf
import
tensorflow
as
tf
...
...
src/sdk/pynni/nni/compression/tensorflow/builtin_quantizers.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
import
logging
import
logging
import
tensorflow
as
tf
import
tensorflow
as
tf
from
.compressor
import
Quantizer
from
.compressor
import
Quantizer
...
...
src/sdk/pynni/nni/compression/tensorflow/compressor.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
import
logging
import
logging
import
tensorflow
as
tf
import
tensorflow
as
tf
from
.
import
default_layers
from
.
import
default_layers
...
...
src/sdk/pynni/nni/compression/tensorflow/default_layers.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
from
tensorflow
import
keras
from
tensorflow
import
keras
supported_layers
=
{
supported_layers
=
{
...
...
src/sdk/pynni/nni/compression/torch/__init__.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
from
.compressor
import
LayerInfo
,
Compressor
,
Pruner
,
Quantizer
from
.compressor
import
LayerInfo
,
Compressor
,
Pruner
,
Quantizer
from
.builtin_pruners
import
*
from
.builtin_pruners
import
*
from
.builtin_quantizers
import
*
from
.builtin_quantizers
import
*
...
...
src/sdk/pynni/nni/compression/torch/builtin_pruners.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
import
logging
import
logging
import
torch
import
torch
from
.compressor
import
Pruner
from
.compressor
import
Pruner
...
...
src/sdk/pynni/nni/compression/torch/builtin_quantizers.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
import
logging
import
logging
import
torch
import
torch
from
.compressor
import
Quantizer
from
.compressor
import
Quantizer
...
...
src/sdk/pynni/nni/compression/torch/compressor.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
import
logging
import
logging
import
torch
import
torch
from
.
import
default_layers
from
.
import
default_layers
...
...
src/sdk/pynni/nni/compression/torch/default_layers.py
View file @
587dd3af
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
weighted_modules
=
[
weighted_modules
=
[
'Conv1d'
,
'Conv2d'
,
'Conv3d'
,
'ConvTranspose1d'
,
'ConvTranspose2d'
,
'ConvTranspose3d'
,
'Conv1d'
,
'Conv2d'
,
'Conv3d'
,
'ConvTranspose1d'
,
'ConvTranspose2d'
,
'ConvTranspose3d'
,
'Linear'
,
'Bilinear'
,
'Linear'
,
'Bilinear'
,
...
...
Prev
1
2
3
4
5
6
7
8
9
…
12
Next
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