MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / test_CenterCrop

Function test_CenterCrop

imperative/python/test/unit/data/test_transform.py:33–38  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

31
32
33def test_CenterCrop():
34 t = CenterCrop(output_size=CenterCrop_size)
35 aug_data = t.apply_batch(generate_data())
36 aug_data_shape = [(a.shape, b.shape) for a, b in aug_data]
37 target_shape = [(CenterCrop_target_shape, label_shape)] * 4
38 assert aug_data_shape == target_shape
39
40
41def test_ColorJitter():

Callers

nothing calls this directly

Calls 3

CenterCropClass · 0.85
generate_dataFunction · 0.85
apply_batchMethod · 0.45

Tested by

no test coverage detected