operators ¶
BinaryBaseOperator dataclass ¶
BinaryBaseOperator(rpn_name: ExprOp)
Bases: BaseOperator
__call__ ¶
__call__(arg0: ExprOtherT, arg1: ExprOtherT) -> ComputedVar
Source code
68 69 70 | |
BinaryBoolOperator dataclass ¶
Bases: BinaryBaseOperator
__call__ ¶
__call__(arg0: ExprOtherT, arg1: ExprOtherT) -> ComputedVar
Source code
68 69 70 | |
BinaryMathOperator dataclass ¶
Bases: Generic[T, R], BinaryBaseOperator
__call__ ¶
__call__(arg0: ExprOtherT, arg1: ExprOtherT) -> ComputedVar
Source code
68 69 70 | |
BinaryOperator dataclass ¶
Bases: Generic[T, R], BinaryBaseOperator
__call__ ¶
__call__(arg0: ExprOtherT, arg1: ExprOtherT) -> ComputedVar
Source code
68 69 70 | |
ExprOperators ¶
ABS class-attribute instance-attribute ¶
ABS = UnaryMathOperator[SupportsAbs[SupportsIndex], SupportsIndex](ABS, abs)
ABS_PIX class-attribute instance-attribute ¶
ABS_PIX = TernaryPixelAccessOperator[Union[int, 'ExprVar']](ABS_PIX)
CLAMP class-attribute instance-attribute ¶
CLAMP = TernaryCompOperator(CLAMP, lambda x, y, z: max(y, min(x, z)))
FLOOR class-attribute instance-attribute ¶
FLOOR = UnaryMathOperator[SupportsFloatOrIndex, int](FLOOR, floor)
ROUND class-attribute instance-attribute ¶
ROUND = UnaryMathOperator[SupportsRound[int], int](ROUND, lambda x: round(x))
TERN class-attribute instance-attribute ¶
TERN = TernaryIfOperator(TERN, lambda x, y, z: x if z else y)
TRUNC class-attribute instance-attribute ¶
TRUNC = UnaryMathOperator[SupportsTrunc, int](TRUNC, trunc)
as_var classmethod ¶
as_var(arg0: ExprOtherT) -> ComputedVar
as_var(arg0: Sequence[ExprOtherT]) -> list[ComputedVar]
as_var(
arg0: ExprOtherT | Sequence[ExprOtherT],
) -> ComputedVar | list[ComputedVar]
Source code
235 236 237 238 239 240 | |
TernaryBaseOperator dataclass ¶
TernaryBaseOperator(rpn_name: ExprOp)
Bases: BaseOperator
__call__ ¶
__call__(arg0: ExprOtherT, arg1: ExprOtherT, arg2: ExprOtherT) -> ComputedVar
Source code
74 75 76 | |
TernaryCompOperator dataclass ¶
Bases: TernaryBaseOperator
__call__ ¶
__call__(arg0: ExprOtherT, arg1: ExprOtherT, arg2: ExprOtherT) -> ComputedVar
Source code
74 75 76 | |
TernaryIfOperator dataclass ¶
Bases: TernaryOperator[ExprOtherT, ExprOtherT]
__call__ ¶
__call__(
cond: ExprOtherT, if_true: ExprOtherT, if_false: ExprOtherT
) -> ComputedVar
Source code
115 116 | |
TernaryOperator dataclass ¶
Bases: Generic[T, R], TernaryBaseOperator
__call__ ¶
__call__(arg0: ExprOtherT, arg1: ExprOtherT, arg2: ExprOtherT) -> ComputedVar
Source code
74 75 76 | |
TernaryPixelAccessOperator dataclass ¶
TernaryPixelAccessOperator(rpn_name: ExprOp)
Bases: Generic[T], TernaryBaseOperator
__call__ ¶
__call__(char: str, x: T, y: T) -> ComputedVar
Source code
129 130 131 132 | |
UnaryBaseOperator dataclass ¶
UnaryBaseOperator(rpn_name: ExprOp)
Bases: BaseOperator
__call__ ¶
__call__(arg0: ExprOtherT) -> ComputedVar
Source code
62 63 64 | |
UnaryBoolOperator dataclass ¶
Bases: UnaryBaseOperator
__call__ ¶
__call__(arg0: ExprOtherT) -> ComputedVar
Source code
62 63 64 | |
UnaryMathOperator dataclass ¶
Bases: Generic[T, R], UnaryBaseOperator
__call__ ¶
__call__(arg0: ExprOtherT) -> ComputedVar
Source code
62 63 64 | |
UnaryOperator dataclass ¶
Bases: Generic[T], UnaryBaseOperator
__call__ ¶
__call__(arg0: ExprOtherT) -> ComputedVar
Source code
62 63 64 | |