ommx.v1.solution_pb2
Attributes
The solver has determined that the solution is not optimal. |
|
The solver has determined that the solution is optimal. |
|
The solver cannot determine whether the solution is optimal. Most of heuristic solvers should use this value. |
|
The solution is obtained by a relaxed linear programming problem. |
|
No relaxation is used. |
Classes
The solver proved that the problem is infeasible. |
|
Solution with evaluated objective and constraints |
|
A set of values of decision variables, without any evaluation, even the |
|
The solver proved that the problem is unbounded. |
Module Contents
- class ommx.v1.solution_pb2.Infeasible
The solver proved that the problem is infeasible. TODO: Add more information about the infeasibility.
- class ommx.v1.solution_pb2.Result(*, error: str = ..., solution: global___Solution | None = ..., infeasible: global___Infeasible | None = ..., unbounded: global___Unbounded | None = ...)
- ClearField(field_name: Literal['error', b'error', 'infeasible', b'infeasible', 'result', b'result', 'solution', b'solution', 'unbounded', b'unbounded']) None
- HasField(field_name: Literal['error', b'error', 'infeasible', b'infeasible', 'result', b'result', 'solution', b'solution', 'unbounded', b'unbounded']) bool
- WhichOneof(oneof_group: Literal['result', b'result']) Literal['error', 'solution', 'infeasible', 'unbounded'] | None
- ERROR_FIELD_NUMBER: int
- INFEASIBLE_FIELD_NUMBER: int
- SOLUTION_FIELD_NUMBER: int
- UNBOUNDED_FIELD_NUMBER: int
- error: str
Error information by the solver which cannot be expressed by other messages. This string should be human-readable.
- property infeasible: global___Infeasible
The solver proved that the problem is infeasible, i.e. all solutions of the problem are infeasible. If the solver cannot get the proof of infeasibility, and just cannot find any feasible solution due to the time limit or due to heuristic algorithm limitation, the solver should return its best Solution message with feasible field set to false.
- property solution: global___Solution
Some feasible or infeasible solution for the problem is found. Most of heuristic solvers should use this value.
- property unbounded: global___Unbounded
The solver proved that the problem is unbounded.
- class ommx.v1.solution_pb2.Solution(*, state: global___State | None = ..., objective: float = ..., decision_variables: collections.abc.Iterable[ommx.v1.decision_variables_pb2.DecisionVariable] | None = ..., evaluated_constraints: collections.abc.Iterable[ommx.v1.constraint_pb2.EvaluatedConstraint] | None = ..., feasible: bool = ..., feasible_relaxed: bool | None = ..., feasible_unrelaxed: bool = ..., optimality: global___Optimality = ..., relaxation: global___Relaxation = ..., sense: ommx.v1.instance_pb2.Instance.Sense.ValueType = ...)
Solution with evaluated objective and constraints
- ClearField(field_name: Literal['_feasible_relaxed', b'_feasible_relaxed', 'decision_variables', b'decision_variables', 'evaluated_constraints', b'evaluated_constraints', 'feasible', b'feasible', 'feasible_relaxed', b'feasible_relaxed', 'feasible_unrelaxed', b'feasible_unrelaxed', 'objective', b'objective', 'optimality', b'optimality', 'relaxation', b'relaxation', 'sense', b'sense', 'state', b'state']) None
- HasField(field_name: Literal['_feasible_relaxed', b'_feasible_relaxed', 'feasible_relaxed', b'feasible_relaxed', 'state', b'state']) bool
- WhichOneof(oneof_group: Literal['_feasible_relaxed', b'_feasible_relaxed']) Literal['feasible_relaxed'] | None
- DECISION_VARIABLES_FIELD_NUMBER: int
- EVALUATED_CONSTRAINTS_FIELD_NUMBER: int
- FEASIBLE_FIELD_NUMBER: int
- FEASIBLE_RELAXED_FIELD_NUMBER: int
- FEASIBLE_UNRELAXED_FIELD_NUMBER: int
- OBJECTIVE_FIELD_NUMBER: int
- OPTIMALITY_FIELD_NUMBER: int
- RELAXATION_FIELD_NUMBER: int
- SENSE_FIELD_NUMBER: int
- STATE_FIELD_NUMBER: int
- property decision_variables: google.protobuf.internal.containers.RepeatedCompositeFieldContainer[ommx.v1.decision_variables_pb2.DecisionVariable]
- property evaluated_constraints: google.protobuf.internal.containers.RepeatedCompositeFieldContainer[ommx.v1.constraint_pb2.EvaluatedConstraint]
- feasible: bool
The feasibility of the solution for all, remaining and removed constraints.
The feasibility for the remaining constraints is represented by the feasible_relaxed field.
- feasible_relaxed: bool
Feasibility of the solution for remaining constraints, ignoring removed constraints.
This is optional due to the backward compatibility. If this field is NULL, the feasible field represents relaxed feasibility, and the deprecated feasible_unrelaxed field represents the feasibility including removed constraints.
- feasible_unrelaxed: bool
[DEPRECATED] Feasibility of the solution for all constraints. This field has been introduced in Python SDK 1.6.0 and deprecated in 1.7.0. The feasibility in this sense is represented by the feasible field after 1.7.0.
- objective: float
- optimality: global___Optimality
The optimality of the solution.
- relaxation: global___Relaxation
Whether the solution is obtained by a relaxed linear programming solver.
- sense: ommx.v1.instance_pb2.Instance.Sense.ValueType
Whether the problem is a minimization or maximization problem.
- property state: global___State
- class ommx.v1.solution_pb2.State(*, entries: collections.abc.Mapping[int, float] | None = ...)
A set of values of decision variables, without any evaluation, even the feasiblity of the solution.
- class EntriesEntry(*, key: int = ..., value: float = ...)
- ClearField(field_name: Literal['key', b'key', 'value', b'value']) None
- KEY_FIELD_NUMBER: int
- VALUE_FIELD_NUMBER: int
- key: int
- value: float
- ClearField(field_name: Literal['entries', b'entries']) None
- ENTRIES_FIELD_NUMBER: int
- property entries: google.protobuf.internal.containers.ScalarMap[int, float]
The value of the solution for each variable ID.
- class ommx.v1.solution_pb2.Unbounded
The solver proved that the problem is unbounded. TODO: Add more information about the unboundedness.
- ommx.v1.solution_pb2.OPTIMALITY_NOT_OPTIMAL: Optimality
The solver has determined that the solution is not optimal.
- ommx.v1.solution_pb2.OPTIMALITY_OPTIMAL: Optimality
The solver has determined that the solution is optimal.
- ommx.v1.solution_pb2.OPTIMALITY_UNSPECIFIED: Optimality
The solver cannot determine whether the solution is optimal. Most of heuristic solvers should use this value.
- ommx.v1.solution_pb2.RELAXATION_LP_RELAXED: Relaxation
The solution is obtained by a relaxed linear programming problem.
- ommx.v1.solution_pb2.RELAXATION_UNSPECIFIED: Relaxation
No relaxation is used.