mirror of
https://github.com/open-mmlab/mmclassification.git
synced 2025-06-03 21:53:55 +08:00
* [Feature]: Add resize rel pos embed * [Refactor]: Create a separated resize_rel_pos_bias_table func * [Refactor]: Refactor rel pos embed bias * [Refactor]: Move interpolate into func * Remove index buffer only when window_size changes Co-authored-by: mzr1996 <mzr1996@163.com>
20 lines
935 B
Python
20 lines
935 B
Python
# Copyright (c) OpenMMLab. All rights reserved.
|
|
from .attention import MultiheadAttention, ShiftWindowMSA
|
|
from .augment.augments import Augments
|
|
from .channel_shuffle import channel_shuffle
|
|
from .embed import (HybridEmbed, PatchEmbed, PatchMerging, resize_pos_embed,
|
|
resize_relative_position_bias_table)
|
|
from .helpers import is_tracing, to_2tuple, to_3tuple, to_4tuple, to_ntuple
|
|
from .inverted_residual import InvertedResidual
|
|
from .make_divisible import make_divisible
|
|
from .position_encoding import ConditionalPositionEncoding
|
|
from .se_layer import SELayer
|
|
|
|
__all__ = [
|
|
'channel_shuffle', 'make_divisible', 'InvertedResidual', 'SELayer',
|
|
'to_ntuple', 'to_2tuple', 'to_3tuple', 'to_4tuple', 'PatchEmbed',
|
|
'PatchMerging', 'HybridEmbed', 'Augments', 'ShiftWindowMSA', 'is_tracing',
|
|
'MultiheadAttention', 'ConditionalPositionEncoding', 'resize_pos_embed',
|
|
'resize_relative_position_bias_table'
|
|
]
|