Skip to content

Commit f91e0f4

Browse files
authored
Add Automatic SParsity Utilities (#32995)
1 parent 1bb73c6 commit f91e0f4

File tree

5 files changed

+802
-0
lines changed

5 files changed

+802
-0
lines changed

python/paddle/fluid/contrib/__init__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
# Copyright (c) 2018 PaddlePaddle Authors. All Rights Reserve.
2+
# Copyright (c) 2021 NVIDIA Corporation. All rights reserved.
23
#
34
# Licensed under the Apache License, Version 2.0 (the "License");
45
# you may not use this file except in compliance with the License.
@@ -32,6 +33,8 @@
3233
from . import layers
3334
from .layers import *
3435
from . import optimizer
36+
from . import sparsity
37+
from .sparsity import *
3538

3639
__all__ = []
3740
__all__ += decoder.__all__
@@ -42,3 +45,4 @@
4245
__all__ += ['mixed_precision']
4346
__all__ += layers.__all__
4447
__all__ += optimizer.__all__
48+
__all__ += sparsity.__all__
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Copyright (c) 2021 PaddlePaddle Authors. All Rights Reserved.
2+
# Copyright (c) 2021 NVIDIA Corporation. All rights reserved.
3+
#
4+
# Licensed under the Apache License, Version 2.0 (the "License");
5+
# you may not use this file except in compliance with the License.
6+
# You may obtain a copy of the License at
7+
#
8+
# http://www.apache.org/licenses/LICENSE-2.0
9+
#
10+
# Unless required by applicable law or agreed to in writing, software
11+
# distributed under the License is distributed on an "AS IS" BASIS,
12+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
# See the License for the specific language governing permissions and
14+
# limitations under the License.
15+
16+
from __future__ import print_function
17+
18+
from . import utils
19+
from .utils import *
20+
21+
__all__ = utils.__all__

0 commit comments

Comments
 (0)