| 1 |
import pytest |
| 2 |
|
| 3 |
import pycolmap |
| 4 |
|
| 5 |
pytestmark = pytest.mark.skipif( |
| 6 |
not hasattr(pycolmap, "PatchMatchOptions"), |
| 7 |
reason="PatchMatchOptions not available (requires CUDA)", |
| 8 |
) |
| 9 |
|
| 10 |
|
| 11 |
def test_patch_match_options_init(): |
| 12 |
options = pycolmap.PatchMatchOptions() |
| 13 |
assert options is not None |
| 14 |
|
| 15 |
|
| 16 |
def test_stereo_fusion_options_init(): |
| 17 |
options = pycolmap.StereoFusionOptions() |
| 18 |
assert options is not None |
| 19 |
|
| 20 |
|
| 21 |
@pytest.mark.parametrize( |
| 22 |
"name", |
| 23 |
[ |
| 24 |
"patch_match_stereo", |
| 25 |
"stereo_fusion", |
| 26 |
], |
| 27 |
) |
| 28 |
def test_public_api_callable(name): |
| 29 |
assert callable(getattr(pycolmap, name)) |