Class MPSolverCommonParameters
java.lang.Object
com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessage
com.google.protobuf.GeneratedMessage
com.google.ortools.linearsolver.MPSolverCommonParameters
- All Implemented Interfaces:
MPSolverCommonParametersOrBuilder
,com.google.protobuf.Message
,com.google.protobuf.MessageLite
,com.google.protobuf.MessageLiteOrBuilder
,com.google.protobuf.MessageOrBuilder
,Serializable
@Generated
public final class MPSolverCommonParameters
extends com.google.protobuf.GeneratedMessage
implements MPSolverCommonParametersOrBuilder
MPSolverCommonParameters holds advanced usage parameters that apply to any of the solvers we support. All of the fields in this proto can have a value of unspecified. In this case each inner solver will use their own safe defaults. Some values won't be supported by some solvers. The behavior in that case is not defined yet.Protobuf type
operations_research.MPSolverCommonParameters
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final class
MPSolverCommonParameters holds advanced usage parameters that apply to any of the solvers we support.static enum
Protobuf enumoperations_research.MPSolverCommonParameters.LPAlgorithmValues
Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessage
com.google.protobuf.GeneratedMessage.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>, BuilderT extends com.google.protobuf.GeneratedMessage.ExtendableBuilder<MessageT,
BuilderT>>, com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessage.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessage.FieldAccessorTable, com.google.protobuf.GeneratedMessage.GeneratedExtension<ContainingT extends com.google.protobuf.Message, T>, com.google.protobuf.GeneratedMessage.UnusedPrivateParameter Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessage
com.google.protobuf.AbstractMessage.BuilderParent
Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessageLite.InternalOneOfEnum
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int
static final int
static final int
static final int
static final int
static final int
Fields inherited from class com.google.protobuf.GeneratedMessage
alwaysUseFieldBuilders, unknownFields
Fields inherited from class com.google.protobuf.AbstractMessage
memoizedSize
Fields inherited from class com.google.protobuf.AbstractMessageLite
memoizedHashCode
-
Method Summary
Modifier and TypeMethodDescriptionboolean
static MPSolverCommonParameters
static final com.google.protobuf.Descriptors.Descriptor
Tolerance for dual feasibility.Tolerance for dual feasibility.Algorithm to solve linear programs.com.google.protobuf.Parser
<MPSolverCommonParameters> Gurobi and SCIP enable presolve by default.Tolerance for primal feasibility of basic solutions: this is the maximum allowed error in constraint satisfiability.Tolerance for primal feasibility of basic solutions: this is the maximum allowed error in constraint satisfiability.The solver stops if the relative MIP gap reaches this value or below.The solver stops if the relative MIP gap reaches this value or below.Enable automatic scaling of matrix coefficients and objective.int
boolean
Tolerance for dual feasibility.int
hashCode()
boolean
Algorithm to solve linear programs.boolean
Gurobi and SCIP enable presolve by default.boolean
Tolerance for primal feasibility of basic solutions: this is the maximum allowed error in constraint satisfiability.boolean
The solver stops if the relative MIP gap reaches this value or below.boolean
Enable automatic scaling of matrix coefficients and objective.protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
final boolean
newBuilder
(MPSolverCommonParameters prototype) protected MPSolverCommonParameters.Builder
newBuilderForType
(com.google.protobuf.AbstractMessage.BuilderParent parent) static MPSolverCommonParameters
parseDelimitedFrom
(InputStream input) static MPSolverCommonParameters
parseDelimitedFrom
(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static MPSolverCommonParameters
parseFrom
(byte[] data) static MPSolverCommonParameters
parseFrom
(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static MPSolverCommonParameters
parseFrom
(com.google.protobuf.ByteString data) static MPSolverCommonParameters
parseFrom
(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static MPSolverCommonParameters
parseFrom
(com.google.protobuf.CodedInputStream input) static MPSolverCommonParameters
parseFrom
(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static MPSolverCommonParameters
parseFrom
(InputStream input) static MPSolverCommonParameters
parseFrom
(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static MPSolverCommonParameters
parseFrom
(ByteBuffer data) static MPSolverCommonParameters
parseFrom
(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static com.google.protobuf.Parser
<MPSolverCommonParameters> parser()
void
writeTo
(com.google.protobuf.CodedOutputStream output) Methods inherited from class com.google.protobuf.GeneratedMessage
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, isStringEmpty, makeMutableCopy, makeMutableCopy, mergeFromAndMakeImmutableInternal, newFileScopedGeneratedExtension, newInstance, newMessageScopedGeneratedExtension, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTag
Methods inherited from class com.google.protobuf.AbstractMessage
findInitializationErrors, getInitializationErrorString, hashFields, toString
Methods inherited from class com.google.protobuf.AbstractMessageLite
addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeTo
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.google.protobuf.MessageLite
toByteArray, toByteString, writeDelimitedTo, writeTo
Methods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Field Details
-
RELATIVE_MIP_GAP_FIELD_NUMBER
public static final int RELATIVE_MIP_GAP_FIELD_NUMBER- See Also:
-
PRIMAL_TOLERANCE_FIELD_NUMBER
public static final int PRIMAL_TOLERANCE_FIELD_NUMBER- See Also:
-
DUAL_TOLERANCE_FIELD_NUMBER
public static final int DUAL_TOLERANCE_FIELD_NUMBER- See Also:
-
LP_ALGORITHM_FIELD_NUMBER
public static final int LP_ALGORITHM_FIELD_NUMBER- See Also:
-
PRESOLVE_FIELD_NUMBER
public static final int PRESOLVE_FIELD_NUMBER- See Also:
-
SCALING_FIELD_NUMBER
public static final int SCALING_FIELD_NUMBER- See Also:
-
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTable
in classcom.google.protobuf.GeneratedMessage
-
hasRelativeMipGap
public boolean hasRelativeMipGap()The solver stops if the relative MIP gap reaches this value or below. The relative MIP gap is an upper bound of the relative distance to the optimum, and it is defined as: abs(best_bound - incumbent) / abs(incumbent) [Gurobi] abs(best_bound - incumbent) / min(abs(best_bound), abs(incumbent)) [SCIP] where "incumbent" is the objective value of the best solution found so far (i.e., lowest when minimizing, highest when maximizing), and "best_bound" is the tightest bound of the objective determined so far (i.e., highest when minimizing, and lowest when maximizing). The MIP Gap is sensitive to objective offset. If the denominator is 0 the MIP Gap is INFINITY for SCIP and Gurobi. Of note, "incumbent" and "best bound" are called "primal bound" and "dual bound" in SCIP, respectively. Ask or-core-team@ for other solvers.
optional .operations_research.OptionalDouble relative_mip_gap = 1;
- Specified by:
hasRelativeMipGap
in interfaceMPSolverCommonParametersOrBuilder
- Returns:
- Whether the relativeMipGap field is set.
-
getRelativeMipGap
The solver stops if the relative MIP gap reaches this value or below. The relative MIP gap is an upper bound of the relative distance to the optimum, and it is defined as: abs(best_bound - incumbent) / abs(incumbent) [Gurobi] abs(best_bound - incumbent) / min(abs(best_bound), abs(incumbent)) [SCIP] where "incumbent" is the objective value of the best solution found so far (i.e., lowest when minimizing, highest when maximizing), and "best_bound" is the tightest bound of the objective determined so far (i.e., highest when minimizing, and lowest when maximizing). The MIP Gap is sensitive to objective offset. If the denominator is 0 the MIP Gap is INFINITY for SCIP and Gurobi. Of note, "incumbent" and "best bound" are called "primal bound" and "dual bound" in SCIP, respectively. Ask or-core-team@ for other solvers.
optional .operations_research.OptionalDouble relative_mip_gap = 1;
- Specified by:
getRelativeMipGap
in interfaceMPSolverCommonParametersOrBuilder
- Returns:
- The relativeMipGap.
-
getRelativeMipGapOrBuilder
The solver stops if the relative MIP gap reaches this value or below. The relative MIP gap is an upper bound of the relative distance to the optimum, and it is defined as: abs(best_bound - incumbent) / abs(incumbent) [Gurobi] abs(best_bound - incumbent) / min(abs(best_bound), abs(incumbent)) [SCIP] where "incumbent" is the objective value of the best solution found so far (i.e., lowest when minimizing, highest when maximizing), and "best_bound" is the tightest bound of the objective determined so far (i.e., highest when minimizing, and lowest when maximizing). The MIP Gap is sensitive to objective offset. If the denominator is 0 the MIP Gap is INFINITY for SCIP and Gurobi. Of note, "incumbent" and "best bound" are called "primal bound" and "dual bound" in SCIP, respectively. Ask or-core-team@ for other solvers.
optional .operations_research.OptionalDouble relative_mip_gap = 1;
- Specified by:
getRelativeMipGapOrBuilder
in interfaceMPSolverCommonParametersOrBuilder
-
hasPrimalTolerance
public boolean hasPrimalTolerance()Tolerance for primal feasibility of basic solutions: this is the maximum allowed error in constraint satisfiability. For SCIP this includes integrality constraints. For Gurobi it does not, you need to set the custom parameter IntFeasTol.
optional .operations_research.OptionalDouble primal_tolerance = 2;
- Specified by:
hasPrimalTolerance
in interfaceMPSolverCommonParametersOrBuilder
- Returns:
- Whether the primalTolerance field is set.
-
getPrimalTolerance
Tolerance for primal feasibility of basic solutions: this is the maximum allowed error in constraint satisfiability. For SCIP this includes integrality constraints. For Gurobi it does not, you need to set the custom parameter IntFeasTol.
optional .operations_research.OptionalDouble primal_tolerance = 2;
- Specified by:
getPrimalTolerance
in interfaceMPSolverCommonParametersOrBuilder
- Returns:
- The primalTolerance.
-
getPrimalToleranceOrBuilder
Tolerance for primal feasibility of basic solutions: this is the maximum allowed error in constraint satisfiability. For SCIP this includes integrality constraints. For Gurobi it does not, you need to set the custom parameter IntFeasTol.
optional .operations_research.OptionalDouble primal_tolerance = 2;
- Specified by:
getPrimalToleranceOrBuilder
in interfaceMPSolverCommonParametersOrBuilder
-
hasDualTolerance
public boolean hasDualTolerance()Tolerance for dual feasibility. For SCIP and Gurobi this is the feasibility tolerance for reduced costs in LP solution: reduced costs must all be smaller than this value in the improving direction in order for a model to be declared optimal. Not supported for other solvers.
optional .operations_research.OptionalDouble dual_tolerance = 3;
- Specified by:
hasDualTolerance
in interfaceMPSolverCommonParametersOrBuilder
- Returns:
- Whether the dualTolerance field is set.
-
getDualTolerance
Tolerance for dual feasibility. For SCIP and Gurobi this is the feasibility tolerance for reduced costs in LP solution: reduced costs must all be smaller than this value in the improving direction in order for a model to be declared optimal. Not supported for other solvers.
optional .operations_research.OptionalDouble dual_tolerance = 3;
- Specified by:
getDualTolerance
in interfaceMPSolverCommonParametersOrBuilder
- Returns:
- The dualTolerance.
-
getDualToleranceOrBuilder
Tolerance for dual feasibility. For SCIP and Gurobi this is the feasibility tolerance for reduced costs in LP solution: reduced costs must all be smaller than this value in the improving direction in order for a model to be declared optimal. Not supported for other solvers.
optional .operations_research.OptionalDouble dual_tolerance = 3;
- Specified by:
getDualToleranceOrBuilder
in interfaceMPSolverCommonParametersOrBuilder
-
hasLpAlgorithm
public boolean hasLpAlgorithm()Algorithm to solve linear programs. Ask or-core-team@ if you want to know what this does exactly.
optional .operations_research.MPSolverCommonParameters.LPAlgorithmValues lp_algorithm = 4 [default = LP_ALGO_UNSPECIFIED];
- Specified by:
hasLpAlgorithm
in interfaceMPSolverCommonParametersOrBuilder
- Returns:
- Whether the lpAlgorithm field is set.
-
getLpAlgorithm
Algorithm to solve linear programs. Ask or-core-team@ if you want to know what this does exactly.
optional .operations_research.MPSolverCommonParameters.LPAlgorithmValues lp_algorithm = 4 [default = LP_ALGO_UNSPECIFIED];
- Specified by:
getLpAlgorithm
in interfaceMPSolverCommonParametersOrBuilder
- Returns:
- The lpAlgorithm.
-
hasPresolve
public boolean hasPresolve()Gurobi and SCIP enable presolve by default. Ask or-core-team@ for other solvers.
optional .operations_research.OptionalBoolean presolve = 5 [default = BOOL_UNSPECIFIED];
- Specified by:
hasPresolve
in interfaceMPSolverCommonParametersOrBuilder
- Returns:
- Whether the presolve field is set.
-
getPresolve
Gurobi and SCIP enable presolve by default. Ask or-core-team@ for other solvers.
optional .operations_research.OptionalBoolean presolve = 5 [default = BOOL_UNSPECIFIED];
- Specified by:
getPresolve
in interfaceMPSolverCommonParametersOrBuilder
- Returns:
- The presolve.
-
hasScaling
public boolean hasScaling()Enable automatic scaling of matrix coefficients and objective. Available for Gurobi and GLOP. Ask or-core-team@ if you want more details.
optional .operations_research.OptionalBoolean scaling = 7 [default = BOOL_UNSPECIFIED];
- Specified by:
hasScaling
in interfaceMPSolverCommonParametersOrBuilder
- Returns:
- Whether the scaling field is set.
-
getScaling
Enable automatic scaling of matrix coefficients and objective. Available for Gurobi and GLOP. Ask or-core-team@ if you want more details.
optional .operations_research.OptionalBoolean scaling = 7 [default = BOOL_UNSPECIFIED];
- Specified by:
getScaling
in interfaceMPSolverCommonParametersOrBuilder
- Returns:
- The scaling.
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitialized
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Overrides:
isInitialized
in classcom.google.protobuf.GeneratedMessage
-
writeTo
- Specified by:
writeTo
in interfacecom.google.protobuf.MessageLite
- Overrides:
writeTo
in classcom.google.protobuf.GeneratedMessage
- Throws:
IOException
-
getSerializedSize
public int getSerializedSize()- Specified by:
getSerializedSize
in interfacecom.google.protobuf.MessageLite
- Overrides:
getSerializedSize
in classcom.google.protobuf.GeneratedMessage
-
equals
- Specified by:
equals
in interfacecom.google.protobuf.Message
- Overrides:
equals
in classcom.google.protobuf.AbstractMessage
-
hashCode
public int hashCode()- Specified by:
hashCode
in interfacecom.google.protobuf.Message
- Overrides:
hashCode
in classcom.google.protobuf.AbstractMessage
-
parseFrom
public static MPSolverCommonParameters parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static MPSolverCommonParameters parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static MPSolverCommonParameters parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static MPSolverCommonParameters parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static MPSolverCommonParameters parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static MPSolverCommonParameters parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static MPSolverCommonParameters parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseDelimitedFrom
- Throws:
IOException
-
parseDelimitedFrom
public static MPSolverCommonParameters parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseFrom
public static MPSolverCommonParameters parseFrom(com.google.protobuf.CodedInputStream input) throws IOException - Throws:
IOException
-
parseFrom
public static MPSolverCommonParameters parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
newBuilderForType
- Specified by:
newBuilderForType
in interfacecom.google.protobuf.Message
- Specified by:
newBuilderForType
in interfacecom.google.protobuf.MessageLite
-
newBuilder
-
newBuilder
-
toBuilder
- Specified by:
toBuilder
in interfacecom.google.protobuf.Message
- Specified by:
toBuilder
in interfacecom.google.protobuf.MessageLite
-
newBuilderForType
protected MPSolverCommonParameters.Builder newBuilderForType(com.google.protobuf.AbstractMessage.BuilderParent parent) - Overrides:
newBuilderForType
in classcom.google.protobuf.AbstractMessage
-
getDefaultInstance
-
parser
-
getParserForType
- Specified by:
getParserForType
in interfacecom.google.protobuf.Message
- Specified by:
getParserForType
in interfacecom.google.protobuf.MessageLite
- Overrides:
getParserForType
in classcom.google.protobuf.GeneratedMessage
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageOrBuilder
-