-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMatchMasking.py
More file actions
72 lines (65 loc) · 2.01 KB
/
MatchMasking.py
File metadata and controls
72 lines (65 loc) · 2.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
__version__ = "1.0"
import os
from pathlib import Path
from meshroom.core import desc
from meshroom.core.utils import DESCRIBER_TYPES
from pyalicevision import parallelization as avpar
class MatchMasking(desc.CommandLineNode):
category = "ROMA"
documentation = """
Mask the certainty images generated by RomaMatcher given the associated
masks of the reference and matched images.
"""
size = avpar.DynamicViewsSize('inputSfMData')
parallelization = desc.Parallelization(blockSize=40)
commandLineRange = "--rangeIteration {rangeIteration} --rangeBlocksCount {rangeBlocksCount}"
exePath = (Path(__file__).absolute().parent.parent.parent / "python" / "masker.py").as_posix()
commandLine="python "+exePath+" {allParams}"
inputs = [
desc.File(
name="inputSfMData",
label="SfMData",
description="Input SfMData file.",
value="",
),
desc.File(
name="imagePairsList",
label="Image Pairs",
description="Path to a file which contains the list of image pairs to match.",
value="",
),
desc.File(
name="warpFolder",
label="warp folder",
description="",
value=""
),
desc.File(
name="certaintyFolder",
label="Certainty folder",
description="",
value=""
),
desc.File(
name="masksFolder",
label="Masks folder",
description="",
value=""
),
desc.ChoiceParam(
name="masksExtension",
label="Mask File Extension",
description="Mask file extension",
value="exr",
values=["exr", "png", "jpg"],
exclusive=True,
)
]
outputs = [
desc.File(
name="outputCertaintyFolder",
label="Output Certainty folder",
description="",
value="{nodeCacheFolder}"
)
]