MCPcopy Create free account
hub / github.com/NeuralNetworkVerification/Marabou / VarConstraint

Class VarConstraint

maraboupy/MarabouPythonic.py:202–217  ·  view source on GitHub ↗

Define constraints on neurons of a neural network. Assuming neuron x, constants a b, and an affine transformation a * x + b, then example constraints are a * x + b <= or >= or == a' * x' + b'. Attributes: combination: an instance of the VarAffine class, i.e., affine transfo

Source from the content-addressed store, hash-verified

200
201@dataclass()
202class VarConstraint:
203 """
204 Define constraints on neurons of a neural network.
205 Assuming neuron x, constants a b, and an affine transformation a * x + b,
206 then example constraints are a * x + b <= or >= or == a' * x' + b&#x27;.
207
208 Attributes:
209 combination: an instance of the VarAffine class, i.e., affine transformation of neuron(s)
210 isEquality: whether it is an equality or inequality, i.e., True if ==; False if >= or <=.
211 lowerBound: whether it is a lower bound, e.g., True if x + b >= b&#x27;.
212 upperBound: whether it is an upper bound, e.g., True if x + b <= b&#x27;.
213 """
214 combination: VarAffine
215 isEquality: bool
216 lowerBound: Optional[float]
217 upperBound: Optional[float]
218
219
220def Var(index):

Callers 3

__le__Method · 0.85
__ge__Method · 0.85
__eq__Method · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected