mirror of
https://github.com/open-mmlab/mmsegmentation.git
synced 2025-06-03 22:03:48 +08:00
* delete markdownlint * Support MobileNetV3 * fix import * add mobilenetv3 head and configs * Modify MobileNetV3 to semantic segmentation version * modify mobilenetv3 configs * add std configs * fix Conv2dAdaptivePadding bug * add configs * add unitest and fix bugs * fix lraspp unitest bugs * restore * fix unitest * add MobileNetV3 docstring * add mmcv * add mmcv * fix syntax bug * fix unitest bug * fix unitest bug * fix unitest bugs * fix docstring * add configs * restore * delete unnecessary assert * modify unitest * delete benchmark
14 lines
376 B
Python
14 lines
376 B
Python
from mmseg.models.utils import make_divisible
|
|
|
|
|
|
def test_make_divisible():
|
|
# test with min_value = None
|
|
assert make_divisible(10, 4) == 12
|
|
assert make_divisible(9, 4) == 12
|
|
assert make_divisible(1, 4) == 4
|
|
|
|
# test with min_value = 8
|
|
assert make_divisible(10, 4, 8) == 12
|
|
assert make_divisible(9, 4, 8) == 12
|
|
assert make_divisible(1, 4, 8) == 8
|