test_env.py 832 B

1234567891011121314151617181920212223242526
  1. import warnings
  2. warnings.filterwarnings('ignore')
  3. # mmcv、mmengin测试代码
  4. from mmcv.ops.modulated_deform_conv import ModulatedDeformConv2d, modulated_deform_conv2d
  5. from mmcv.cnn import ConvModule, build_norm_layer
  6. from mmengine.model import BaseModule
  7. from mmengine.model import constant_init
  8. from mmengine.model.weight_init import trunc_normal_init, normal_init
  9. # mamba测试代码
  10. from mamba_ssm.ops.selective_scan_interface import selective_scan_fn
  11. # dcnv3测试代码
  12. import DCNv3
  13. import pkg_resources
  14. dcn_version = float(pkg_resources.get_distribution('DCNv3').version)
  15. # dcnv4测试代码
  16. from DCNv4.modules.dcnv4 import DCNv4
  17. # smpconv测试代码
  18. from depthwise_conv2d_implicit_gemm import _DepthWiseConv2dImplicitGEMMFP16, _DepthWiseConv2dImplicitGEMMFP32
  19. # mamba-yolo测试代码
  20. import selective_scan_cuda_core