class ModelCache: (source)
Undocumented
Static Method | combine |
Undocumented |
Method | __eq__ |
Undocumented |
Method | __getstate__ |
Undocumented |
Method | __hash__ |
Undocumented |
Method | __init__ |
Undocumented |
Method | __setstate__ |
Undocumented |
Method | eval |
Eval the ast, replacing symbols by their last value in the model. |
Method | eval |
Returns whether the constraints is satisfied trivially by using the last model. |
Method | eval |
Evaluate a list of ASTs. |
Method | filter |
Undocumented |
Instance Variable | constraint |
Undocumented |
Instance Variable | model |
Undocumented |
Instance Variable | replacements |
Undocumented |
Method | _leaf |
Undocumented |
Method | _leaf |
Undocumented |
Class Variable | _defaults |
Undocumented |
Instance Variable | _hash |
Undocumented |
Eval the ast, replacing symbols by their last value in the model. :param ast: The AST to evaluate. :param allow_unconstrained: When set to True, we will treat non-existent variables as unconstrained variables and will use arbitrary concrete values for them during evaluation. Otherwise, raise KeyErrors for non-existent variables.
Evaluate a list of ASTs. :param asts: A list of ASTs to evaluate. :param allow_unconstrained: When set to True, we will treat non-existent variables as unconstrained variables and will use arbitrary concrete values for them during evaluation. Otherwise, raise KeyErrors for non-existent variables. :return: A tuple of evaluated results, one element per AST.