Google OR-Tools v9.14
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
PrimalDualHybridGradientParams.java
Go to the documentation of this file.
1// Generated by the protocol buffer compiler. DO NOT EDIT!
2// NO CHECKED-IN PROTOBUF GENCODE
3// source: ortools/pdlp/solvers.proto
4// Protobuf Java Version: 4.31.1
5
6package com.google.ortools.pdlp;
7
24@com.google.protobuf.Generated
25public final class PrimalDualHybridGradientParams extends
26 com.google.protobuf.GeneratedMessage implements
27 // @@protoc_insertion_point(message_implements:operations_research.pdlp.PrimalDualHybridGradientParams)
29private static final long serialVersionUID = 0L;
30 static {
31 com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion(
32 com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC,
33 /* major= */ 4,
34 /* minor= */ 31,
35 /* patch= */ 1,
36 /* suffix= */ "",
37 PrimalDualHybridGradientParams.class.getName());
38 }
39 // Use PrimalDualHybridGradientParams.newBuilder() to construct.
40 private PrimalDualHybridGradientParams(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
41 super(builder);
42 }
43 private PrimalDualHybridGradientParams() {
44 numThreads_ = 1;
45 schedulerType_ = 1;
46 majorIterationFrequency_ = 64;
47 terminationCheckFrequency_ = 64;
48 restartStrategy_ = 3;
49 primalWeightUpdateSmoothing_ = 0.5D;
50 lInfRuizIterations_ = 5;
51 l2NormRescaling_ = true;
52 sufficientReductionForRestart_ = 0.1D;
53 necessaryReductionForRestart_ = 0.9D;
54 linesearchRule_ = 1;
55 initialStepSizeScaling_ = 1D;
56 randomProjectionSeeds_ = emptyIntList();
57 infiniteConstraintBoundThreshold_ = Double.POSITIVE_INFINITY;
58 handleSomePrimalGradientsOnFiniteBoundsAsResiduals_ = true;
59 diagonalQpTrustRegionSolverTolerance_ = 1e-08D;
60 }
61
62 public static final com.google.protobuf.Descriptors.Descriptor
64 return com.google.ortools.pdlp.Solvers.internal_static_operations_research_pdlp_PrimalDualHybridGradientParams_descriptor;
65 }
66
67 @java.lang.Override
68 protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
70 return com.google.ortools.pdlp.Solvers.internal_static_operations_research_pdlp_PrimalDualHybridGradientParams_fieldAccessorTable
71 .ensureFieldAccessorsInitialized(
72 com.google.ortools.pdlp.PrimalDualHybridGradientParams.class, com.google.ortools.pdlp.PrimalDualHybridGradientParams.Builder.class);
73 }
74
78 public enum RestartStrategy
79 implements com.google.protobuf.ProtocolMessageEnum {
127 ;
128
129 static {
130 com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion(
131 com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC,
132 /* major= */ 4,
133 /* minor= */ 31,
134 /* patch= */ 1,
135 /* suffix= */ "",
136 RestartStrategy.class.getName());
137 }
141 public static final int RESTART_STRATEGY_UNSPECIFIED_VALUE = 0;
150 public static final int NO_RESTARTS_VALUE = 1;
159 public static final int EVERY_MAJOR_ITERATION_VALUE = 2;
172 public static final int ADAPTIVE_HEURISTIC_VALUE = 3;
184 public static final int ADAPTIVE_DISTANCE_BASED_VALUE = 4;
185
186
187 public final int getNumber() {
188 return value;
189 }
190
196 @java.lang.Deprecated
197 public static RestartStrategy valueOf(int value) {
198 return forNumber(value);
199 }
200
205 public static RestartStrategy forNumber(int value) {
206 switch (value) {
207 case 0: return RESTART_STRATEGY_UNSPECIFIED;
208 case 1: return NO_RESTARTS;
209 case 2: return EVERY_MAJOR_ITERATION;
210 case 3: return ADAPTIVE_HEURISTIC;
211 case 4: return ADAPTIVE_DISTANCE_BASED;
212 default: return null;
213 }
214 }
215
216 public static com.google.protobuf.Internal.EnumLiteMap<RestartStrategy>
218 return internalValueMap;
219 }
220 private static final com.google.protobuf.Internal.EnumLiteMap<
221 RestartStrategy> internalValueMap =
222 new com.google.protobuf.Internal.EnumLiteMap<RestartStrategy>() {
223 public RestartStrategy findValueByNumber(int number) {
224 return RestartStrategy.forNumber(number);
225 }
226 };
227
228 public final com.google.protobuf.Descriptors.EnumValueDescriptor
230 return getDescriptor().getValues().get(ordinal());
231 }
232 public final com.google.protobuf.Descriptors.EnumDescriptor
234 return getDescriptor();
235 }
236 public static com.google.protobuf.Descriptors.EnumDescriptor
238 return com.google.ortools.pdlp.PrimalDualHybridGradientParams.getDescriptor().getEnumTypes().get(0);
239 }
240
241 private static final RestartStrategy[] VALUES = values();
242
243 public static RestartStrategy valueOf(
244 com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
245 if (desc.getType() != getDescriptor()) {
246 throw new java.lang.IllegalArgumentException(
247 "EnumValueDescriptor is not for this type.");
248 }
249 return VALUES[desc.getIndex()];
250 }
251
252 private final int value;
253
254 private RestartStrategy(int value) {
255 this.value = value;
256 }
257
258 // @@protoc_insertion_point(enum_scope:operations_research.pdlp.PrimalDualHybridGradientParams.RestartStrategy)
259 }
260
264 public enum LinesearchRule
265 implements com.google.protobuf.ProtocolMessageEnum {
301 ;
302
303 static {
304 com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion(
305 com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC,
306 /* major= */ 4,
307 /* minor= */ 31,
308 /* patch= */ 1,
309 /* suffix= */ "",
310 LinesearchRule.class.getName());
311 }
315 public static final int LINESEARCH_RULE_UNSPECIFIED_VALUE = 0;
326 public static final int ADAPTIVE_LINESEARCH_RULE_VALUE = 1;
337 public static final int MALITSKY_POCK_LINESEARCH_RULE_VALUE = 2;
346 public static final int CONSTANT_STEP_SIZE_RULE_VALUE = 3;
347
348
349 public final int getNumber() {
350 return value;
351 }
352
358 @java.lang.Deprecated
359 public static LinesearchRule valueOf(int value) {
360 return forNumber(value);
361 }
362
367 public static LinesearchRule forNumber(int value) {
368 switch (value) {
369 case 0: return LINESEARCH_RULE_UNSPECIFIED;
370 case 1: return ADAPTIVE_LINESEARCH_RULE;
371 case 2: return MALITSKY_POCK_LINESEARCH_RULE;
372 case 3: return CONSTANT_STEP_SIZE_RULE;
373 default: return null;
374 }
375 }
376
377 public static com.google.protobuf.Internal.EnumLiteMap<LinesearchRule>
379 return internalValueMap;
380 }
381 private static final com.google.protobuf.Internal.EnumLiteMap<
382 LinesearchRule> internalValueMap =
383 new com.google.protobuf.Internal.EnumLiteMap<LinesearchRule>() {
384 public LinesearchRule findValueByNumber(int number) {
385 return LinesearchRule.forNumber(number);
386 }
387 };
388
389 public final com.google.protobuf.Descriptors.EnumValueDescriptor
391 return getDescriptor().getValues().get(ordinal());
392 }
393 public final com.google.protobuf.Descriptors.EnumDescriptor
395 return getDescriptor();
396 }
397 public static com.google.protobuf.Descriptors.EnumDescriptor
399 return com.google.ortools.pdlp.PrimalDualHybridGradientParams.getDescriptor().getEnumTypes().get(1);
400 }
401
402 private static final LinesearchRule[] VALUES = values();
403
404 public static LinesearchRule valueOf(
405 com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
406 if (desc.getType() != getDescriptor()) {
407 throw new java.lang.IllegalArgumentException(
408 "EnumValueDescriptor is not for this type.");
409 }
410 return VALUES[desc.getIndex()];
411 }
412
413 private final int value;
414
415 private LinesearchRule(int value) {
416 this.value = value;
417 }
418
419 // @@protoc_insertion_point(enum_scope:operations_research.pdlp.PrimalDualHybridGradientParams.LinesearchRule)
420 }
421
422 public interface PresolveOptionsOrBuilder extends
423 // @@protoc_insertion_point(interface_extends:operations_research.pdlp.PrimalDualHybridGradientParams.PresolveOptions)
424 com.google.protobuf.MessageOrBuilder {
425
441 boolean hasUseGlop();
457 boolean getUseGlop();
458
488 }
489
492 public static final class PresolveOptions extends
493 com.google.protobuf.GeneratedMessage implements
494 // @@protoc_insertion_point(message_implements:operations_research.pdlp.PrimalDualHybridGradientParams.PresolveOptions)
496 private static final long serialVersionUID = 0L;
497 static {
498 com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion(
499 com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC,
500 /* major= */ 4,
501 /* minor= */ 31,
502 /* patch= */ 1,
503 /* suffix= */ "",
504 PresolveOptions.class.getName());
505 }
506 // Use PresolveOptions.newBuilder() to construct.
507 private PresolveOptions(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
508 super(builder);
509 }
510 private PresolveOptions() {
511 }
512
513 public static final com.google.protobuf.Descriptors.Descriptor
515 return com.google.ortools.pdlp.Solvers.internal_static_operations_research_pdlp_PrimalDualHybridGradientParams_PresolveOptions_descriptor;
516 }
517
518 @java.lang.Override
519 protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
521 return com.google.ortools.pdlp.Solvers.internal_static_operations_research_pdlp_PrimalDualHybridGradientParams_PresolveOptions_fieldAccessorTable
522 .ensureFieldAccessorsInitialized(
523 com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.class, com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.Builder.class);
524 }
525
526 private int bitField0_;
527 public static final int USE_GLOP_FIELD_NUMBER = 1;
528 private boolean useGlop_ = false;
544 @java.lang.Override
545 public boolean hasUseGlop() {
546 return ((bitField0_ & 0x00000001) != 0);
547 }
548
563 @java.lang.Override
564 public boolean getUseGlop() {
565 return useGlop_;
566 }
567
568 public static final int GLOP_PARAMETERS_FIELD_NUMBER = 2;
569 private com.google.ortools.glop.GlopParameters glopParameters_;
579 @java.lang.Override
580 public boolean hasGlopParameters() {
581 return ((bitField0_ & 0x00000002) != 0);
582 }
583
592 @java.lang.Override
594 return glopParameters_ == null ? com.google.ortools.glop.GlopParameters.getDefaultInstance() : glopParameters_;
595 }
596
604 @java.lang.Override
606 return glopParameters_ == null ? com.google.ortools.glop.GlopParameters.getDefaultInstance() : glopParameters_;
607 }
608
609 private byte memoizedIsInitialized = -1;
610 @java.lang.Override
611 public final boolean isInitialized() {
612 byte isInitialized = memoizedIsInitialized;
613 if (isInitialized == 1) return true;
614 if (isInitialized == 0) return false;
615
616 memoizedIsInitialized = 1;
617 return true;
618 }
619
620 @java.lang.Override
621 public void writeTo(com.google.protobuf.CodedOutputStream output)
622 throws java.io.IOException {
623 if (((bitField0_ & 0x00000001) != 0)) {
624 output.writeBool(1, useGlop_);
625 }
626 if (((bitField0_ & 0x00000002) != 0)) {
627 output.writeMessage(2, getGlopParameters());
628 }
629 getUnknownFields().writeTo(output);
630 }
631
632 @java.lang.Override
633 public int getSerializedSize() {
634 int size = memoizedSize;
635 if (size != -1) return size;
636
637 size = 0;
638 if (((bitField0_ & 0x00000001) != 0)) {
639 size += com.google.protobuf.CodedOutputStream
640 .computeBoolSize(1, useGlop_);
641 }
642 if (((bitField0_ & 0x00000002) != 0)) {
643 size += com.google.protobuf.CodedOutputStream
644 .computeMessageSize(2, getGlopParameters());
645 }
646 size += getUnknownFields().getSerializedSize();
647 memoizedSize = size;
648 return size;
649 }
650
651 @java.lang.Override
652 public boolean equals(final java.lang.Object obj) {
653 if (obj == this) {
654 return true;
655 }
656 if (!(obj instanceof com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions)) {
657 return super.equals(obj);
658 }
659 com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions other = (com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions) obj;
660
661 if (hasUseGlop() != other.hasUseGlop()) return false;
662 if (hasUseGlop()) {
663 if (getUseGlop()
664 != other.getUseGlop()) return false;
665 }
666 if (hasGlopParameters() != other.hasGlopParameters()) return false;
667 if (hasGlopParameters()) {
668 if (!getGlopParameters()
669 .equals(other.getGlopParameters())) return false;
670 }
671 if (!getUnknownFields().equals(other.getUnknownFields())) return false;
672 return true;
673 }
674
675 @java.lang.Override
676 public int hashCode() {
677 if (memoizedHashCode != 0) {
678 return memoizedHashCode;
679 }
680 int hash = 41;
681 hash = (19 * hash) + getDescriptor().hashCode();
682 if (hasUseGlop()) {
683 hash = (37 * hash) + USE_GLOP_FIELD_NUMBER;
684 hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
685 getUseGlop());
686 }
687 if (hasGlopParameters()) {
688 hash = (37 * hash) + GLOP_PARAMETERS_FIELD_NUMBER;
689 hash = (53 * hash) + getGlopParameters().hashCode();
690 }
691 hash = (29 * hash) + getUnknownFields().hashCode();
692 memoizedHashCode = hash;
693 return hash;
694 }
695
697 java.nio.ByteBuffer data)
698 throws com.google.protobuf.InvalidProtocolBufferException {
699 return PARSER.parseFrom(data);
700 }
702 java.nio.ByteBuffer data,
703 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
704 throws com.google.protobuf.InvalidProtocolBufferException {
705 return PARSER.parseFrom(data, extensionRegistry);
706 }
708 com.google.protobuf.ByteString data)
709 throws com.google.protobuf.InvalidProtocolBufferException {
710 return PARSER.parseFrom(data);
711 }
713 com.google.protobuf.ByteString data,
714 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
715 throws com.google.protobuf.InvalidProtocolBufferException {
716 return PARSER.parseFrom(data, extensionRegistry);
717 }
719 throws com.google.protobuf.InvalidProtocolBufferException {
720 return PARSER.parseFrom(data);
721 }
723 byte[] data,
724 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
725 throws com.google.protobuf.InvalidProtocolBufferException {
726 return PARSER.parseFrom(data, extensionRegistry);
727 }
729 throws java.io.IOException {
730 return com.google.protobuf.GeneratedMessage
731 .parseWithIOException(PARSER, input);
732 }
734 java.io.InputStream input,
735 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
736 throws java.io.IOException {
737 return com.google.protobuf.GeneratedMessage
738 .parseWithIOException(PARSER, input, extensionRegistry);
739 }
740
742 throws java.io.IOException {
743 return com.google.protobuf.GeneratedMessage
744 .parseDelimitedWithIOException(PARSER, input);
745 }
746
748 java.io.InputStream input,
749 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
750 throws java.io.IOException {
751 return com.google.protobuf.GeneratedMessage
752 .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
753 }
755 com.google.protobuf.CodedInputStream input)
756 throws java.io.IOException {
757 return com.google.protobuf.GeneratedMessage
758 .parseWithIOException(PARSER, input);
759 }
761 com.google.protobuf.CodedInputStream input,
762 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
763 throws java.io.IOException {
764 return com.google.protobuf.GeneratedMessage
765 .parseWithIOException(PARSER, input, extensionRegistry);
766 }
767
768 @java.lang.Override
769 public Builder newBuilderForType() { return newBuilder(); }
770 public static Builder newBuilder() {
771 return DEFAULT_INSTANCE.toBuilder();
772 }
773 public static Builder newBuilder(com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions prototype) {
774 return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
775 }
776 @java.lang.Override
778 return this == DEFAULT_INSTANCE
779 ? new Builder() : new Builder().mergeFrom(this);
780 }
781
782 @java.lang.Override
784 com.google.protobuf.GeneratedMessage.BuilderParent parent) {
785 Builder builder = new Builder(parent);
786 return builder;
787 }
788
791 public static final class Builder extends
792 com.google.protobuf.GeneratedMessage.Builder<Builder> implements
793 // @@protoc_insertion_point(builder_implements:operations_research.pdlp.PrimalDualHybridGradientParams.PresolveOptions)
794 com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptionsOrBuilder {
795 public static final com.google.protobuf.Descriptors.Descriptor
797 return com.google.ortools.pdlp.Solvers.internal_static_operations_research_pdlp_PrimalDualHybridGradientParams_PresolveOptions_descriptor;
798 }
799
800 @java.lang.Override
801 protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
803 return com.google.ortools.pdlp.Solvers.internal_static_operations_research_pdlp_PrimalDualHybridGradientParams_PresolveOptions_fieldAccessorTable
804 .ensureFieldAccessorsInitialized(
805 com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.class, com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.Builder.class);
806 }
807
808 // Construct using com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.newBuilder()
809 private Builder() {
810 maybeForceBuilderInitialization();
811 }
812
813 private Builder(
814 com.google.protobuf.GeneratedMessage.BuilderParent parent) {
815 super(parent);
816 maybeForceBuilderInitialization();
817 }
818 private void maybeForceBuilderInitialization() {
819 if (com.google.protobuf.GeneratedMessage
820 .alwaysUseFieldBuilders) {
821 internalGetGlopParametersFieldBuilder();
822 }
823 }
824 @java.lang.Override
825 public Builder clear() {
826 super.clear();
827 bitField0_ = 0;
828 useGlop_ = false;
829 glopParameters_ = null;
830 if (glopParametersBuilder_ != null) {
831 glopParametersBuilder_.dispose();
832 glopParametersBuilder_ = null;
833 }
834 return this;
835 }
836
837 @java.lang.Override
838 public com.google.protobuf.Descriptors.Descriptor
840 return com.google.ortools.pdlp.Solvers.internal_static_operations_research_pdlp_PrimalDualHybridGradientParams_PresolveOptions_descriptor;
841 }
842
843 @java.lang.Override
845 return com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.getDefaultInstance();
846 }
847
848 @java.lang.Override
851 if (!result.isInitialized()) {
852 throw newUninitializedMessageException(result);
853 }
854 return result;
855 }
856
857 @java.lang.Override
859 com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions result = new com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions(this);
860 if (bitField0_ != 0) { buildPartial0(result); }
861 onBuilt();
862 return result;
863 }
864
865 private void buildPartial0(com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions result) {
866 int from_bitField0_ = bitField0_;
867 int to_bitField0_ = 0;
868 if (((from_bitField0_ & 0x00000001) != 0)) {
869 result.useGlop_ = useGlop_;
870 to_bitField0_ |= 0x00000001;
871 }
872 if (((from_bitField0_ & 0x00000002) != 0)) {
873 result.glopParameters_ = glopParametersBuilder_ == null
874 ? glopParameters_
875 : glopParametersBuilder_.build();
876 to_bitField0_ |= 0x00000002;
877 }
878 result.bitField0_ |= to_bitField0_;
879 }
880
881 @java.lang.Override
882 public Builder mergeFrom(com.google.protobuf.Message other) {
883 if (other instanceof com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions) {
884 return mergeFrom((com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions)other);
885 } else {
886 super.mergeFrom(other);
887 return this;
888 }
889 }
890
891 public Builder mergeFrom(com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions other) {
892 if (other == com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.getDefaultInstance()) return this;
893 if (other.hasUseGlop()) {
894 setUseGlop(other.getUseGlop());
895 }
896 if (other.hasGlopParameters()) {
897 mergeGlopParameters(other.getGlopParameters());
898 }
899 this.mergeUnknownFields(other.getUnknownFields());
900 onChanged();
901 return this;
902 }
903
904 @java.lang.Override
905 public final boolean isInitialized() {
906 return true;
907 }
908
909 @java.lang.Override
910 public Builder mergeFrom(
911 com.google.protobuf.CodedInputStream input,
912 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
913 throws java.io.IOException {
914 if (extensionRegistry == null) {
915 throw new java.lang.NullPointerException();
916 }
917 try {
918 boolean done = false;
919 while (!done) {
920 int tag = input.readTag();
921 switch (tag) {
922 case 0:
923 done = true;
924 break;
925 case 8: {
926 useGlop_ = input.readBool();
927 bitField0_ |= 0x00000001;
928 break;
929 } // case 8
930 case 18: {
931 input.readMessage(
932 internalGetGlopParametersFieldBuilder().getBuilder(),
933 extensionRegistry);
934 bitField0_ |= 0x00000002;
935 break;
936 } // case 18
937 default: {
938 if (!super.parseUnknownField(input, extensionRegistry, tag)) {
939 done = true; // was an endgroup tag
940 }
941 break;
942 } // default:
943 } // switch (tag)
944 } // while (!done)
945 } catch (com.google.protobuf.InvalidProtocolBufferException e) {
946 throw e.unwrapIOException();
947 } finally {
948 onChanged();
949 } // finally
950 return this;
951 }
952 private int bitField0_;
953
954 private boolean useGlop_ ;
970 @java.lang.Override
971 public boolean hasUseGlop() {
972 return ((bitField0_ & 0x00000001) != 0);
973 }
974
989 @java.lang.Override
990 public boolean getUseGlop() {
991 return useGlop_;
992 }
993
1009 public Builder setUseGlop(boolean value) {
1010
1011 useGlop_ = value;
1012 bitField0_ |= 0x00000001;
1013 onChanged();
1014 return this;
1015 }
1016
1031 public Builder clearUseGlop() {
1032 bitField0_ = (bitField0_ & ~0x00000001);
1033 useGlop_ = false;
1034 onChanged();
1035 return this;
1036 }
1037
1038 private com.google.ortools.glop.GlopParameters glopParameters_;
1039 private com.google.protobuf.SingleFieldBuilder<
1040 com.google.ortools.glop.GlopParameters, com.google.ortools.glop.GlopParameters.Builder, com.google.ortools.glop.GlopParametersOrBuilder> glopParametersBuilder_;
1050 public boolean hasGlopParameters() {
1051 return ((bitField0_ & 0x00000002) != 0);
1052 }
1053
1063 if (glopParametersBuilder_ == null) {
1064 return glopParameters_ == null ? com.google.ortools.glop.GlopParameters.getDefaultInstance() : glopParameters_;
1065 } else {
1066 return glopParametersBuilder_.getMessage();
1067 }
1068 }
1069
1077 public Builder setGlopParameters(com.google.ortools.glop.GlopParameters value) {
1078 if (glopParametersBuilder_ == null) {
1079 if (value == null) {
1080 throw new NullPointerException();
1081 }
1082 glopParameters_ = value;
1083 } else {
1084 glopParametersBuilder_.setMessage(value);
1085 }
1086 bitField0_ |= 0x00000002;
1087 onChanged();
1088 return this;
1089 }
1090
1098 public Builder setGlopParameters(
1099 com.google.ortools.glop.GlopParameters.Builder builderForValue) {
1100 if (glopParametersBuilder_ == null) {
1101 glopParameters_ = builderForValue.build();
1102 } else {
1103 glopParametersBuilder_.setMessage(builderForValue.build());
1104 }
1105 bitField0_ |= 0x00000002;
1106 onChanged();
1107 return this;
1108 }
1109
1117 public Builder mergeGlopParameters(com.google.ortools.glop.GlopParameters value) {
1118 if (glopParametersBuilder_ == null) {
1119 if (((bitField0_ & 0x00000002) != 0) &&
1120 glopParameters_ != null &&
1121 glopParameters_ != com.google.ortools.glop.GlopParameters.getDefaultInstance()) {
1123 } else {
1124 glopParameters_ = value;
1125 }
1126 } else {
1127 glopParametersBuilder_.mergeFrom(value);
1128 }
1129 if (glopParameters_ != null) {
1130 bitField0_ |= 0x00000002;
1131 onChanged();
1132 }
1133 return this;
1134 }
1135
1143 public Builder clearGlopParameters() {
1144 bitField0_ = (bitField0_ & ~0x00000002);
1145 glopParameters_ = null;
1146 if (glopParametersBuilder_ != null) {
1147 glopParametersBuilder_.dispose();
1148 glopParametersBuilder_ = null;
1149 }
1150 onChanged();
1151 return this;
1152 }
1153
1162 bitField0_ |= 0x00000002;
1163 onChanged();
1164 return internalGetGlopParametersFieldBuilder().getBuilder();
1165 }
1166
1175 if (glopParametersBuilder_ != null) {
1176 return glopParametersBuilder_.getMessageOrBuilder();
1177 } else {
1178 return glopParameters_ == null ?
1179 com.google.ortools.glop.GlopParameters.getDefaultInstance() : glopParameters_;
1180 }
1181 }
1182
1190 private com.google.protobuf.SingleFieldBuilder<
1191 com.google.ortools.glop.GlopParameters, com.google.ortools.glop.GlopParameters.Builder, com.google.ortools.glop.GlopParametersOrBuilder>
1192 internalGetGlopParametersFieldBuilder() {
1193 if (glopParametersBuilder_ == null) {
1194 glopParametersBuilder_ = new com.google.protobuf.SingleFieldBuilder<
1195 com.google.ortools.glop.GlopParameters, com.google.ortools.glop.GlopParameters.Builder, com.google.ortools.glop.GlopParametersOrBuilder>(
1197 getParentForChildren(),
1198 isClean());
1199 glopParameters_ = null;
1200 }
1201 return glopParametersBuilder_;
1202 }
1203
1204 // @@protoc_insertion_point(builder_scope:operations_research.pdlp.PrimalDualHybridGradientParams.PresolveOptions)
1205 }
1206
1207 // @@protoc_insertion_point(class_scope:operations_research.pdlp.PrimalDualHybridGradientParams.PresolveOptions)
1209 static {
1210 DEFAULT_INSTANCE = new com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions();
1211 }
1212
1216
1217 private static final com.google.protobuf.Parser<PresolveOptions>
1218 PARSER = new com.google.protobuf.AbstractParser<PresolveOptions>() {
1219 @java.lang.Override
1220 public PresolveOptions parsePartialFrom(
1221 com.google.protobuf.CodedInputStream input,
1222 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
1223 throws com.google.protobuf.InvalidProtocolBufferException {
1224 Builder builder = newBuilder();
1225 try {
1226 builder.mergeFrom(input, extensionRegistry);
1227 } catch (com.google.protobuf.InvalidProtocolBufferException e) {
1228 throw e.setUnfinishedMessage(builder.buildPartial());
1229 } catch (com.google.protobuf.UninitializedMessageException e) {
1230 throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
1231 } catch (java.io.IOException e) {
1232 throw new com.google.protobuf.InvalidProtocolBufferException(e)
1233 .setUnfinishedMessage(builder.buildPartial());
1234 }
1235 return builder.buildPartial();
1236 }
1237 };
1238
1239 public static com.google.protobuf.Parser<PresolveOptions> parser() {
1240 return PARSER;
1241 }
1242
1243 @java.lang.Override
1244 public com.google.protobuf.Parser<PresolveOptions> getParserForType() {
1245 return PARSER;
1246 }
1247
1248 @java.lang.Override
1252
1253 }
1254
1255 private int bitField0_;
1256 public static final int TERMINATION_CRITERIA_FIELD_NUMBER = 1;
1257 private com.google.ortools.pdlp.TerminationCriteria terminationCriteria_;
1262 @java.lang.Override
1263 public boolean hasTerminationCriteria() {
1264 return ((bitField0_ & 0x00000001) != 0);
1265 }
1266
1270 @java.lang.Override
1272 return terminationCriteria_ == null ? com.google.ortools.pdlp.TerminationCriteria.getDefaultInstance() : terminationCriteria_;
1273 }
1274
1277 @java.lang.Override
1279 return terminationCriteria_ == null ? com.google.ortools.pdlp.TerminationCriteria.getDefaultInstance() : terminationCriteria_;
1280 }
1281
1282 public static final int NUM_THREADS_FIELD_NUMBER = 2;
1283 private int numThreads_ = 1;
1295 @java.lang.Override
1296 public boolean hasNumThreads() {
1297 return ((bitField0_ & 0x00000002) != 0);
1298 }
1299
1310 @java.lang.Override
1311 public int getNumThreads() {
1312 return numThreads_;
1313 }
1314
1315 public static final int NUM_SHARDS_FIELD_NUMBER = 27;
1316 private int numShards_ = 0;
1333 @java.lang.Override
1334 public boolean hasNumShards() {
1335 return ((bitField0_ & 0x00000004) != 0);
1336 }
1337
1353 @java.lang.Override
1354 public int getNumShards() {
1355 return numShards_;
1356 }
1357
1358 public static final int SCHEDULER_TYPE_FIELD_NUMBER = 32;
1359 private int schedulerType_ = 1;
1369 @java.lang.Override public boolean hasSchedulerType() {
1370 return ((bitField0_ & 0x00000008) != 0);
1371 }
1372
1382 com.google.ortools.pdlp.SchedulerType result = com.google.ortools.pdlp.SchedulerType.forNumber(schedulerType_);
1384 }
1385
1386 public static final int RECORD_ITERATION_STATS_FIELD_NUMBER = 3;
1387 private boolean recordIterationStats_ = false;
1399 @java.lang.Override
1400 public boolean hasRecordIterationStats() {
1401 return ((bitField0_ & 0x00000010) != 0);
1402 }
1403
1414 @java.lang.Override
1415 public boolean getRecordIterationStats() {
1416 return recordIterationStats_;
1417 }
1418
1419 public static final int VERBOSITY_LEVEL_FIELD_NUMBER = 26;
1420 private int verbosityLevel_ = 0;
1439 @java.lang.Override
1440 public boolean hasVerbosityLevel() {
1441 return ((bitField0_ & 0x00000020) != 0);
1442 }
1443
1461 @java.lang.Override
1462 public int getVerbosityLevel() {
1463 return verbosityLevel_;
1464 }
1465
1466 public static final int LOG_INTERVAL_SECONDS_FIELD_NUMBER = 31;
1467 private double logIntervalSeconds_ = 0D;
1480 @java.lang.Override
1481 public boolean hasLogIntervalSeconds() {
1482 return ((bitField0_ & 0x00000040) != 0);
1483 }
1484
1496 @java.lang.Override
1497 public double getLogIntervalSeconds() {
1498 return logIntervalSeconds_;
1499 }
1500
1501 public static final int MAJOR_ITERATION_FREQUENCY_FIELD_NUMBER = 4;
1502 private int majorIterationFrequency_ = 64;
1516 @java.lang.Override
1518 return ((bitField0_ & 0x00000080) != 0);
1519 }
1520
1533 @java.lang.Override
1535 return majorIterationFrequency_;
1536 }
1537
1538 public static final int TERMINATION_CHECK_FREQUENCY_FIELD_NUMBER = 5;
1539 private int terminationCheckFrequency_ = 64;
1550 @java.lang.Override
1552 return ((bitField0_ & 0x00000100) != 0);
1553 }
1554
1564 @java.lang.Override
1566 return terminationCheckFrequency_;
1567 }
1568
1569 public static final int RESTART_STRATEGY_FIELD_NUMBER = 6;
1570 private int restartStrategy_ = 3;
1581 @java.lang.Override public boolean hasRestartStrategy() {
1582 return ((bitField0_ & 0x00000200) != 0);
1583 }
1584
1595 com.google.ortools.pdlp.PrimalDualHybridGradientParams.RestartStrategy result = com.google.ortools.pdlp.PrimalDualHybridGradientParams.RestartStrategy.forNumber(restartStrategy_);
1597 }
1598
1600 private double primalWeightUpdateSmoothing_ = 0.5D;
1616 @java.lang.Override
1618 return ((bitField0_ & 0x00000400) != 0);
1619 }
1620
1635 @java.lang.Override
1637 return primalWeightUpdateSmoothing_;
1638 }
1639
1640 public static final int INITIAL_PRIMAL_WEIGHT_FIELD_NUMBER = 8;
1641 private double initialPrimalWeight_ = 0D;
1656 @java.lang.Override
1657 public boolean hasInitialPrimalWeight() {
1658 return ((bitField0_ & 0x00000800) != 0);
1659 }
1660
1674 @java.lang.Override
1675 public double getInitialPrimalWeight() {
1676 return initialPrimalWeight_;
1677 }
1678
1679 public static final int PRESOLVE_OPTIONS_FIELD_NUMBER = 16;
1685 @java.lang.Override
1686 public boolean hasPresolveOptions() {
1687 return ((bitField0_ & 0x00001000) != 0);
1688 }
1689
1693 @java.lang.Override
1695 return presolveOptions_ == null ? com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.getDefaultInstance() : presolveOptions_;
1696 }
1697
1700 @java.lang.Override
1702 return presolveOptions_ == null ? com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.getDefaultInstance() : presolveOptions_;
1703 }
1704
1705 public static final int L_INF_RUIZ_ITERATIONS_FIELD_NUMBER = 9;
1706 private int lInfRuizIterations_ = 5;
1717 @java.lang.Override
1718 public boolean hasLInfRuizIterations() {
1719 return ((bitField0_ & 0x00002000) != 0);
1720 }
1721
1731 @java.lang.Override
1733 return lInfRuizIterations_;
1734 }
1735
1736 public static final int L2_NORM_RESCALING_FIELD_NUMBER = 10;
1737 private boolean l2NormRescaling_ = true;
1747 @java.lang.Override
1748 public boolean hasL2NormRescaling() {
1749 return ((bitField0_ & 0x00004000) != 0);
1750 }
1751
1760 @java.lang.Override
1761 public boolean getL2NormRescaling() {
1762 return l2NormRescaling_;
1763 }
1764
1766 private double sufficientReductionForRestart_ = 0.1D;
1777 @java.lang.Override
1779 return ((bitField0_ & 0x00008000) != 0);
1780 }
1781
1791 @java.lang.Override
1793 return sufficientReductionForRestart_;
1794 }
1795
1797 private double necessaryReductionForRestart_ = 0.9D;
1810 @java.lang.Override
1812 return ((bitField0_ & 0x00010000) != 0);
1813 }
1814
1826 @java.lang.Override
1828 return necessaryReductionForRestart_;
1829 }
1830
1831 public static final int LINESEARCH_RULE_FIELD_NUMBER = 12;
1832 private int linesearchRule_ = 1;
1841 @java.lang.Override public boolean hasLinesearchRule() {
1842 return ((bitField0_ & 0x00020000) != 0);
1843 }
1844
1853 com.google.ortools.pdlp.PrimalDualHybridGradientParams.LinesearchRule result = com.google.ortools.pdlp.PrimalDualHybridGradientParams.LinesearchRule.forNumber(linesearchRule_);
1855 }
1856
1858 private com.google.ortools.pdlp.AdaptiveLinesearchParams adaptiveLinesearchParameters_;
1863 @java.lang.Override
1865 return ((bitField0_ & 0x00040000) != 0);
1866 }
1867
1871 @java.lang.Override
1873 return adaptiveLinesearchParameters_ == null ? com.google.ortools.pdlp.AdaptiveLinesearchParams.getDefaultInstance() : adaptiveLinesearchParameters_;
1874 }
1875
1878 @java.lang.Override
1880 return adaptiveLinesearchParameters_ == null ? com.google.ortools.pdlp.AdaptiveLinesearchParams.getDefaultInstance() : adaptiveLinesearchParameters_;
1881 }
1882
1883 public static final int MALITSKY_POCK_PARAMETERS_FIELD_NUMBER = 19;
1884 private com.google.ortools.pdlp.MalitskyPockParams malitskyPockParameters_;
1889 @java.lang.Override
1890 public boolean hasMalitskyPockParameters() {
1891 return ((bitField0_ & 0x00080000) != 0);
1892 }
1893
1897 @java.lang.Override
1899 return malitskyPockParameters_ == null ? com.google.ortools.pdlp.MalitskyPockParams.getDefaultInstance() : malitskyPockParameters_;
1900 }
1901
1904 @java.lang.Override
1906 return malitskyPockParameters_ == null ? com.google.ortools.pdlp.MalitskyPockParams.getDefaultInstance() : malitskyPockParameters_;
1907 }
1908
1909 public static final int INITIAL_STEP_SIZE_SCALING_FIELD_NUMBER = 25;
1910 private double initialStepSizeScaling_ = 1D;
1920 @java.lang.Override
1921 public boolean hasInitialStepSizeScaling() {
1922 return ((bitField0_ & 0x00100000) != 0);
1923 }
1924
1933 @java.lang.Override
1935 return initialStepSizeScaling_;
1936 }
1937
1938 public static final int RANDOM_PROJECTION_SEEDS_FIELD_NUMBER = 28;
1939 @SuppressWarnings("serial")
1940 private com.google.protobuf.Internal.IntList randomProjectionSeeds_ =
1941 emptyIntList();
1955 @java.lang.Override
1956 public java.util.List<java.lang.Integer>
1958 return randomProjectionSeeds_;
1959 }
1960
1974 return randomProjectionSeeds_.size();
1975 }
1976
1990 public int getRandomProjectionSeeds(int index) {
1991 return randomProjectionSeeds_.getInt(index);
1992 }
1993 private int randomProjectionSeedsMemoizedSerializedSize = -1;
1994
1996 private double infiniteConstraintBoundThreshold_ = Double.POSITIVE_INFINITY;
2010 @java.lang.Override
2012 return ((bitField0_ & 0x00200000) != 0);
2013 }
2014
2027 @java.lang.Override
2029 return infiniteConstraintBoundThreshold_;
2030 }
2031
2033 private boolean handleSomePrimalGradientsOnFiniteBoundsAsResiduals_ = true;
2044 @java.lang.Override
2046 return ((bitField0_ & 0x00400000) != 0);
2047 }
2048
2058 @java.lang.Override
2060 return handleSomePrimalGradientsOnFiniteBoundsAsResiduals_;
2061 }
2062
2064 private boolean useDiagonalQpTrustRegionSolver_ = false;
2078 @java.lang.Override
2080 return ((bitField0_ & 0x00800000) != 0);
2081 }
2082
2095 @java.lang.Override
2097 return useDiagonalQpTrustRegionSolver_;
2098 }
2099
2101 private double diagonalQpTrustRegionSolverTolerance_ = 1e-08D;
2114 @java.lang.Override
2116 return ((bitField0_ & 0x01000000) != 0);
2117 }
2118
2130 @java.lang.Override
2132 return diagonalQpTrustRegionSolverTolerance_;
2133 }
2134
2135 public static final int USE_FEASIBILITY_POLISHING_FIELD_NUMBER = 30;
2136 private boolean useFeasibilityPolishing_ = false;
2170 @java.lang.Override
2172 return ((bitField0_ & 0x02000000) != 0);
2173 }
2174
2207 @java.lang.Override
2209 return useFeasibilityPolishing_;
2210 }
2211
2213 private boolean applyFeasibilityPolishingAfterLimitsReached_ = false;
2225 @java.lang.Override
2227 return ((bitField0_ & 0x04000000) != 0);
2228 }
2229
2240 @java.lang.Override
2242 return applyFeasibilityPolishingAfterLimitsReached_;
2243 }
2244
2246 private boolean applyFeasibilityPolishingIfSolverIsInterrupted_ = false;
2257 @java.lang.Override
2259 return ((bitField0_ & 0x08000000) != 0);
2260 }
2261
2271 @java.lang.Override
2273 return applyFeasibilityPolishingIfSolverIsInterrupted_;
2274 }
2275
2276 private byte memoizedIsInitialized = -1;
2277 @java.lang.Override
2278 public final boolean isInitialized() {
2279 byte isInitialized = memoizedIsInitialized;
2280 if (isInitialized == 1) return true;
2281 if (isInitialized == 0) return false;
2282
2283 memoizedIsInitialized = 1;
2284 return true;
2285 }
2286
2287 @java.lang.Override
2288 public void writeTo(com.google.protobuf.CodedOutputStream output)
2289 throws java.io.IOException {
2291 if (((bitField0_ & 0x00000001) != 0)) {
2292 output.writeMessage(1, getTerminationCriteria());
2293 }
2294 if (((bitField0_ & 0x00000002) != 0)) {
2295 output.writeInt32(2, numThreads_);
2296 }
2297 if (((bitField0_ & 0x00000010) != 0)) {
2298 output.writeBool(3, recordIterationStats_);
2299 }
2300 if (((bitField0_ & 0x00000080) != 0)) {
2301 output.writeInt32(4, majorIterationFrequency_);
2302 }
2303 if (((bitField0_ & 0x00000100) != 0)) {
2304 output.writeInt32(5, terminationCheckFrequency_);
2305 }
2306 if (((bitField0_ & 0x00000200) != 0)) {
2307 output.writeEnum(6, restartStrategy_);
2308 }
2309 if (((bitField0_ & 0x00000400) != 0)) {
2310 output.writeDouble(7, primalWeightUpdateSmoothing_);
2311 }
2312 if (((bitField0_ & 0x00000800) != 0)) {
2313 output.writeDouble(8, initialPrimalWeight_);
2314 }
2315 if (((bitField0_ & 0x00002000) != 0)) {
2316 output.writeInt32(9, lInfRuizIterations_);
2317 }
2318 if (((bitField0_ & 0x00004000) != 0)) {
2319 output.writeBool(10, l2NormRescaling_);
2320 }
2321 if (((bitField0_ & 0x00008000) != 0)) {
2322 output.writeDouble(11, sufficientReductionForRestart_);
2323 }
2324 if (((bitField0_ & 0x00020000) != 0)) {
2325 output.writeEnum(12, linesearchRule_);
2326 }
2327 if (((bitField0_ & 0x00001000) != 0)) {
2328 output.writeMessage(16, getPresolveOptions());
2329 }
2330 if (((bitField0_ & 0x00010000) != 0)) {
2331 output.writeDouble(17, necessaryReductionForRestart_);
2332 }
2333 if (((bitField0_ & 0x00040000) != 0)) {
2334 output.writeMessage(18, getAdaptiveLinesearchParameters());
2335 }
2336 if (((bitField0_ & 0x00080000) != 0)) {
2337 output.writeMessage(19, getMalitskyPockParameters());
2338 }
2339 if (((bitField0_ & 0x00200000) != 0)) {
2340 output.writeDouble(22, infiniteConstraintBoundThreshold_);
2341 }
2342 if (((bitField0_ & 0x00800000) != 0)) {
2343 output.writeBool(23, useDiagonalQpTrustRegionSolver_);
2344 }
2345 if (((bitField0_ & 0x01000000) != 0)) {
2346 output.writeDouble(24, diagonalQpTrustRegionSolverTolerance_);
2347 }
2348 if (((bitField0_ & 0x00100000) != 0)) {
2349 output.writeDouble(25, initialStepSizeScaling_);
2350 }
2351 if (((bitField0_ & 0x00000020) != 0)) {
2352 output.writeInt32(26, verbosityLevel_);
2353 }
2354 if (((bitField0_ & 0x00000004) != 0)) {
2355 output.writeInt32(27, numShards_);
2356 }
2357 if (getRandomProjectionSeedsList().size() > 0) {
2358 output.writeUInt32NoTag(226);
2359 output.writeUInt32NoTag(randomProjectionSeedsMemoizedSerializedSize);
2360 }
2361 for (int i = 0; i < randomProjectionSeeds_.size(); i++) {
2362 output.writeInt32NoTag(randomProjectionSeeds_.getInt(i));
2363 }
2364 if (((bitField0_ & 0x00400000) != 0)) {
2365 output.writeBool(29, handleSomePrimalGradientsOnFiniteBoundsAsResiduals_);
2366 }
2367 if (((bitField0_ & 0x02000000) != 0)) {
2368 output.writeBool(30, useFeasibilityPolishing_);
2369 }
2370 if (((bitField0_ & 0x00000040) != 0)) {
2371 output.writeDouble(31, logIntervalSeconds_);
2372 }
2373 if (((bitField0_ & 0x00000008) != 0)) {
2374 output.writeEnum(32, schedulerType_);
2375 }
2376 if (((bitField0_ & 0x04000000) != 0)) {
2377 output.writeBool(33, applyFeasibilityPolishingAfterLimitsReached_);
2378 }
2379 if (((bitField0_ & 0x08000000) != 0)) {
2380 output.writeBool(34, applyFeasibilityPolishingIfSolverIsInterrupted_);
2381 }
2382 getUnknownFields().writeTo(output);
2383 }
2384
2385 @java.lang.Override
2386 public int getSerializedSize() {
2387 int size = memoizedSize;
2388 if (size != -1) return size;
2389
2390 size = 0;
2391 if (((bitField0_ & 0x00000001) != 0)) {
2392 size += com.google.protobuf.CodedOutputStream
2393 .computeMessageSize(1, getTerminationCriteria());
2394 }
2395 if (((bitField0_ & 0x00000002) != 0)) {
2396 size += com.google.protobuf.CodedOutputStream
2397 .computeInt32Size(2, numThreads_);
2398 }
2399 if (((bitField0_ & 0x00000010) != 0)) {
2400 size += com.google.protobuf.CodedOutputStream
2401 .computeBoolSize(3, recordIterationStats_);
2402 }
2403 if (((bitField0_ & 0x00000080) != 0)) {
2404 size += com.google.protobuf.CodedOutputStream
2405 .computeInt32Size(4, majorIterationFrequency_);
2406 }
2407 if (((bitField0_ & 0x00000100) != 0)) {
2408 size += com.google.protobuf.CodedOutputStream
2409 .computeInt32Size(5, terminationCheckFrequency_);
2410 }
2411 if (((bitField0_ & 0x00000200) != 0)) {
2412 size += com.google.protobuf.CodedOutputStream
2413 .computeEnumSize(6, restartStrategy_);
2414 }
2415 if (((bitField0_ & 0x00000400) != 0)) {
2416 size += com.google.protobuf.CodedOutputStream
2417 .computeDoubleSize(7, primalWeightUpdateSmoothing_);
2418 }
2419 if (((bitField0_ & 0x00000800) != 0)) {
2420 size += com.google.protobuf.CodedOutputStream
2421 .computeDoubleSize(8, initialPrimalWeight_);
2422 }
2423 if (((bitField0_ & 0x00002000) != 0)) {
2424 size += com.google.protobuf.CodedOutputStream
2425 .computeInt32Size(9, lInfRuizIterations_);
2426 }
2427 if (((bitField0_ & 0x00004000) != 0)) {
2428 size += com.google.protobuf.CodedOutputStream
2429 .computeBoolSize(10, l2NormRescaling_);
2430 }
2431 if (((bitField0_ & 0x00008000) != 0)) {
2432 size += com.google.protobuf.CodedOutputStream
2433 .computeDoubleSize(11, sufficientReductionForRestart_);
2434 }
2435 if (((bitField0_ & 0x00020000) != 0)) {
2436 size += com.google.protobuf.CodedOutputStream
2437 .computeEnumSize(12, linesearchRule_);
2438 }
2439 if (((bitField0_ & 0x00001000) != 0)) {
2440 size += com.google.protobuf.CodedOutputStream
2441 .computeMessageSize(16, getPresolveOptions());
2442 }
2443 if (((bitField0_ & 0x00010000) != 0)) {
2444 size += com.google.protobuf.CodedOutputStream
2445 .computeDoubleSize(17, necessaryReductionForRestart_);
2446 }
2447 if (((bitField0_ & 0x00040000) != 0)) {
2448 size += com.google.protobuf.CodedOutputStream
2449 .computeMessageSize(18, getAdaptiveLinesearchParameters());
2450 }
2451 if (((bitField0_ & 0x00080000) != 0)) {
2452 size += com.google.protobuf.CodedOutputStream
2453 .computeMessageSize(19, getMalitskyPockParameters());
2454 }
2455 if (((bitField0_ & 0x00200000) != 0)) {
2456 size += com.google.protobuf.CodedOutputStream
2457 .computeDoubleSize(22, infiniteConstraintBoundThreshold_);
2458 }
2459 if (((bitField0_ & 0x00800000) != 0)) {
2460 size += com.google.protobuf.CodedOutputStream
2461 .computeBoolSize(23, useDiagonalQpTrustRegionSolver_);
2462 }
2463 if (((bitField0_ & 0x01000000) != 0)) {
2464 size += com.google.protobuf.CodedOutputStream
2465 .computeDoubleSize(24, diagonalQpTrustRegionSolverTolerance_);
2466 }
2467 if (((bitField0_ & 0x00100000) != 0)) {
2468 size += com.google.protobuf.CodedOutputStream
2469 .computeDoubleSize(25, initialStepSizeScaling_);
2470 }
2471 if (((bitField0_ & 0x00000020) != 0)) {
2472 size += com.google.protobuf.CodedOutputStream
2473 .computeInt32Size(26, verbosityLevel_);
2474 }
2475 if (((bitField0_ & 0x00000004) != 0)) {
2476 size += com.google.protobuf.CodedOutputStream
2477 .computeInt32Size(27, numShards_);
2478 }
2479 {
2480 int dataSize = 0;
2481 for (int i = 0; i < randomProjectionSeeds_.size(); i++) {
2482 dataSize += com.google.protobuf.CodedOutputStream
2483 .computeInt32SizeNoTag(randomProjectionSeeds_.getInt(i));
2484 }
2485 size += dataSize;
2486 if (!getRandomProjectionSeedsList().isEmpty()) {
2487 size += 2;
2488 size += com.google.protobuf.CodedOutputStream
2489 .computeInt32SizeNoTag(dataSize);
2490 }
2491 randomProjectionSeedsMemoizedSerializedSize = dataSize;
2492 }
2493 if (((bitField0_ & 0x00400000) != 0)) {
2494 size += com.google.protobuf.CodedOutputStream
2495 .computeBoolSize(29, handleSomePrimalGradientsOnFiniteBoundsAsResiduals_);
2496 }
2497 if (((bitField0_ & 0x02000000) != 0)) {
2498 size += com.google.protobuf.CodedOutputStream
2499 .computeBoolSize(30, useFeasibilityPolishing_);
2500 }
2501 if (((bitField0_ & 0x00000040) != 0)) {
2502 size += com.google.protobuf.CodedOutputStream
2503 .computeDoubleSize(31, logIntervalSeconds_);
2504 }
2505 if (((bitField0_ & 0x00000008) != 0)) {
2506 size += com.google.protobuf.CodedOutputStream
2507 .computeEnumSize(32, schedulerType_);
2508 }
2509 if (((bitField0_ & 0x04000000) != 0)) {
2510 size += com.google.protobuf.CodedOutputStream
2511 .computeBoolSize(33, applyFeasibilityPolishingAfterLimitsReached_);
2512 }
2513 if (((bitField0_ & 0x08000000) != 0)) {
2514 size += com.google.protobuf.CodedOutputStream
2515 .computeBoolSize(34, applyFeasibilityPolishingIfSolverIsInterrupted_);
2516 }
2517 size += getUnknownFields().getSerializedSize();
2518 memoizedSize = size;
2519 return size;
2520 }
2521
2522 @java.lang.Override
2523 public boolean equals(final java.lang.Object obj) {
2524 if (obj == this) {
2525 return true;
2526 }
2527 if (!(obj instanceof com.google.ortools.pdlp.PrimalDualHybridGradientParams)) {
2528 return super.equals(obj);
2529 }
2530 com.google.ortools.pdlp.PrimalDualHybridGradientParams other = (com.google.ortools.pdlp.PrimalDualHybridGradientParams) obj;
2531
2532 if (hasTerminationCriteria() != other.hasTerminationCriteria()) return false;
2533 if (hasTerminationCriteria()) {
2535 .equals(other.getTerminationCriteria())) return false;
2536 }
2537 if (hasNumThreads() != other.hasNumThreads()) return false;
2538 if (hasNumThreads()) {
2539 if (getNumThreads()
2540 != other.getNumThreads()) return false;
2541 }
2542 if (hasNumShards() != other.hasNumShards()) return false;
2543 if (hasNumShards()) {
2544 if (getNumShards()
2545 != other.getNumShards()) return false;
2546 }
2547 if (hasSchedulerType() != other.hasSchedulerType()) return false;
2548 if (hasSchedulerType()) {
2549 if (schedulerType_ != other.schedulerType_) return false;
2550 }
2551 if (hasRecordIterationStats() != other.hasRecordIterationStats()) return false;
2554 != other.getRecordIterationStats()) return false;
2555 }
2556 if (hasVerbosityLevel() != other.hasVerbosityLevel()) return false;
2557 if (hasVerbosityLevel()) {
2558 if (getVerbosityLevel()
2559 != other.getVerbosityLevel()) return false;
2560 }
2561 if (hasLogIntervalSeconds() != other.hasLogIntervalSeconds()) return false;
2562 if (hasLogIntervalSeconds()) {
2563 if (java.lang.Double.doubleToLongBits(getLogIntervalSeconds())
2564 != java.lang.Double.doubleToLongBits(
2565 other.getLogIntervalSeconds())) return false;
2566 }
2567 if (hasMajorIterationFrequency() != other.hasMajorIterationFrequency()) return false;
2570 != other.getMajorIterationFrequency()) return false;
2571 }
2572 if (hasTerminationCheckFrequency() != other.hasTerminationCheckFrequency()) return false;
2575 != other.getTerminationCheckFrequency()) return false;
2576 }
2577 if (hasRestartStrategy() != other.hasRestartStrategy()) return false;
2578 if (hasRestartStrategy()) {
2579 if (restartStrategy_ != other.restartStrategy_) return false;
2580 }
2583 if (java.lang.Double.doubleToLongBits(getPrimalWeightUpdateSmoothing())
2584 != java.lang.Double.doubleToLongBits(
2585 other.getPrimalWeightUpdateSmoothing())) return false;
2586 }
2587 if (hasInitialPrimalWeight() != other.hasInitialPrimalWeight()) return false;
2588 if (hasInitialPrimalWeight()) {
2589 if (java.lang.Double.doubleToLongBits(getInitialPrimalWeight())
2590 != java.lang.Double.doubleToLongBits(
2591 other.getInitialPrimalWeight())) return false;
2592 }
2593 if (hasPresolveOptions() != other.hasPresolveOptions()) return false;
2594 if (hasPresolveOptions()) {
2595 if (!getPresolveOptions()
2596 .equals(other.getPresolveOptions())) return false;
2597 }
2598 if (hasLInfRuizIterations() != other.hasLInfRuizIterations()) return false;
2599 if (hasLInfRuizIterations()) {
2601 != other.getLInfRuizIterations()) return false;
2602 }
2603 if (hasL2NormRescaling() != other.hasL2NormRescaling()) return false;
2604 if (hasL2NormRescaling()) {
2605 if (getL2NormRescaling()
2606 != other.getL2NormRescaling()) return false;
2607 }
2610 if (java.lang.Double.doubleToLongBits(getSufficientReductionForRestart())
2611 != java.lang.Double.doubleToLongBits(
2612 other.getSufficientReductionForRestart())) return false;
2613 }
2616 if (java.lang.Double.doubleToLongBits(getNecessaryReductionForRestart())
2617 != java.lang.Double.doubleToLongBits(
2618 other.getNecessaryReductionForRestart())) return false;
2619 }
2620 if (hasLinesearchRule() != other.hasLinesearchRule()) return false;
2621 if (hasLinesearchRule()) {
2622 if (linesearchRule_ != other.linesearchRule_) return false;
2623 }
2627 .equals(other.getAdaptiveLinesearchParameters())) return false;
2628 }
2629 if (hasMalitskyPockParameters() != other.hasMalitskyPockParameters()) return false;
2632 .equals(other.getMalitskyPockParameters())) return false;
2633 }
2634 if (hasInitialStepSizeScaling() != other.hasInitialStepSizeScaling()) return false;
2636 if (java.lang.Double.doubleToLongBits(getInitialStepSizeScaling())
2637 != java.lang.Double.doubleToLongBits(
2638 other.getInitialStepSizeScaling())) return false;
2639 }
2641 .equals(other.getRandomProjectionSeedsList())) return false;
2644 if (java.lang.Double.doubleToLongBits(getInfiniteConstraintBoundThreshold())
2645 != java.lang.Double.doubleToLongBits(
2646 other.getInfiniteConstraintBoundThreshold())) return false;
2647 }
2652 }
2656 != other.getUseDiagonalQpTrustRegionSolver()) return false;
2657 }
2660 if (java.lang.Double.doubleToLongBits(getDiagonalQpTrustRegionSolverTolerance())
2661 != java.lang.Double.doubleToLongBits(
2662 other.getDiagonalQpTrustRegionSolverTolerance())) return false;
2663 }
2664 if (hasUseFeasibilityPolishing() != other.hasUseFeasibilityPolishing()) return false;
2667 != other.getUseFeasibilityPolishing()) return false;
2668 }
2672 != other.getApplyFeasibilityPolishingAfterLimitsReached()) return false;
2673 }
2678 }
2679 if (!getUnknownFields().equals(other.getUnknownFields())) return false;
2680 return true;
2681 }
2682
2683 @java.lang.Override
2684 public int hashCode() {
2685 if (memoizedHashCode != 0) {
2686 return memoizedHashCode;
2687 }
2688 int hash = 41;
2689 hash = (19 * hash) + getDescriptor().hashCode();
2690 if (hasTerminationCriteria()) {
2691 hash = (37 * hash) + TERMINATION_CRITERIA_FIELD_NUMBER;
2692 hash = (53 * hash) + getTerminationCriteria().hashCode();
2693 }
2694 if (hasNumThreads()) {
2695 hash = (37 * hash) + NUM_THREADS_FIELD_NUMBER;
2696 hash = (53 * hash) + getNumThreads();
2697 }
2698 if (hasNumShards()) {
2699 hash = (37 * hash) + NUM_SHARDS_FIELD_NUMBER;
2700 hash = (53 * hash) + getNumShards();
2701 }
2702 if (hasSchedulerType()) {
2703 hash = (37 * hash) + SCHEDULER_TYPE_FIELD_NUMBER;
2704 hash = (53 * hash) + schedulerType_;
2705 }
2707 hash = (37 * hash) + RECORD_ITERATION_STATS_FIELD_NUMBER;
2708 hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
2710 }
2711 if (hasVerbosityLevel()) {
2712 hash = (37 * hash) + VERBOSITY_LEVEL_FIELD_NUMBER;
2713 hash = (53 * hash) + getVerbosityLevel();
2714 }
2715 if (hasLogIntervalSeconds()) {
2716 hash = (37 * hash) + LOG_INTERVAL_SECONDS_FIELD_NUMBER;
2717 hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
2718 java.lang.Double.doubleToLongBits(getLogIntervalSeconds()));
2719 }
2721 hash = (37 * hash) + MAJOR_ITERATION_FREQUENCY_FIELD_NUMBER;
2722 hash = (53 * hash) + getMajorIterationFrequency();
2723 }
2725 hash = (37 * hash) + TERMINATION_CHECK_FREQUENCY_FIELD_NUMBER;
2726 hash = (53 * hash) + getTerminationCheckFrequency();
2727 }
2728 if (hasRestartStrategy()) {
2729 hash = (37 * hash) + RESTART_STRATEGY_FIELD_NUMBER;
2730 hash = (53 * hash) + restartStrategy_;
2731 }
2734 hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
2735 java.lang.Double.doubleToLongBits(getPrimalWeightUpdateSmoothing()));
2736 }
2737 if (hasInitialPrimalWeight()) {
2738 hash = (37 * hash) + INITIAL_PRIMAL_WEIGHT_FIELD_NUMBER;
2739 hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
2740 java.lang.Double.doubleToLongBits(getInitialPrimalWeight()));
2741 }
2742 if (hasPresolveOptions()) {
2743 hash = (37 * hash) + PRESOLVE_OPTIONS_FIELD_NUMBER;
2744 hash = (53 * hash) + getPresolveOptions().hashCode();
2745 }
2746 if (hasLInfRuizIterations()) {
2747 hash = (37 * hash) + L_INF_RUIZ_ITERATIONS_FIELD_NUMBER;
2748 hash = (53 * hash) + getLInfRuizIterations();
2749 }
2750 if (hasL2NormRescaling()) {
2751 hash = (37 * hash) + L2_NORM_RESCALING_FIELD_NUMBER;
2752 hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
2754 }
2757 hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
2758 java.lang.Double.doubleToLongBits(getSufficientReductionForRestart()));
2759 }
2762 hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
2763 java.lang.Double.doubleToLongBits(getNecessaryReductionForRestart()));
2764 }
2765 if (hasLinesearchRule()) {
2766 hash = (37 * hash) + LINESEARCH_RULE_FIELD_NUMBER;
2767 hash = (53 * hash) + linesearchRule_;
2768 }
2771 hash = (53 * hash) + getAdaptiveLinesearchParameters().hashCode();
2772 }
2774 hash = (37 * hash) + MALITSKY_POCK_PARAMETERS_FIELD_NUMBER;
2775 hash = (53 * hash) + getMalitskyPockParameters().hashCode();
2776 }
2778 hash = (37 * hash) + INITIAL_STEP_SIZE_SCALING_FIELD_NUMBER;
2779 hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
2780 java.lang.Double.doubleToLongBits(getInitialStepSizeScaling()));
2781 }
2783 hash = (37 * hash) + RANDOM_PROJECTION_SEEDS_FIELD_NUMBER;
2784 hash = (53 * hash) + getRandomProjectionSeedsList().hashCode();
2785 }
2788 hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
2789 java.lang.Double.doubleToLongBits(getInfiniteConstraintBoundThreshold()));
2790 }
2793 hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
2795 }
2798 hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
2800 }
2803 hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
2804 java.lang.Double.doubleToLongBits(getDiagonalQpTrustRegionSolverTolerance()));
2805 }
2807 hash = (37 * hash) + USE_FEASIBILITY_POLISHING_FIELD_NUMBER;
2808 hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
2810 }
2813 hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
2815 }
2818 hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
2820 }
2821 hash = (29 * hash) + getUnknownFields().hashCode();
2822 memoizedHashCode = hash;
2823 return hash;
2824 }
2825
2827 java.nio.ByteBuffer data)
2828 throws com.google.protobuf.InvalidProtocolBufferException {
2829 return PARSER.parseFrom(data);
2830 }
2832 java.nio.ByteBuffer data,
2833 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
2834 throws com.google.protobuf.InvalidProtocolBufferException {
2835 return PARSER.parseFrom(data, extensionRegistry);
2836 }
2838 com.google.protobuf.ByteString data)
2839 throws com.google.protobuf.InvalidProtocolBufferException {
2840 return PARSER.parseFrom(data);
2841 }
2843 com.google.protobuf.ByteString data,
2844 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
2845 throws com.google.protobuf.InvalidProtocolBufferException {
2846 return PARSER.parseFrom(data, extensionRegistry);
2847 }
2849 throws com.google.protobuf.InvalidProtocolBufferException {
2850 return PARSER.parseFrom(data);
2851 }
2853 byte[] data,
2854 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
2855 throws com.google.protobuf.InvalidProtocolBufferException {
2856 return PARSER.parseFrom(data, extensionRegistry);
2857 }
2859 throws java.io.IOException {
2860 return com.google.protobuf.GeneratedMessage
2861 .parseWithIOException(PARSER, input);
2862 }
2864 java.io.InputStream input,
2865 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
2866 throws java.io.IOException {
2867 return com.google.protobuf.GeneratedMessage
2868 .parseWithIOException(PARSER, input, extensionRegistry);
2869 }
2870
2872 throws java.io.IOException {
2873 return com.google.protobuf.GeneratedMessage
2874 .parseDelimitedWithIOException(PARSER, input);
2875 }
2876
2878 java.io.InputStream input,
2879 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
2880 throws java.io.IOException {
2881 return com.google.protobuf.GeneratedMessage
2882 .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
2883 }
2885 com.google.protobuf.CodedInputStream input)
2886 throws java.io.IOException {
2887 return com.google.protobuf.GeneratedMessage
2888 .parseWithIOException(PARSER, input);
2889 }
2891 com.google.protobuf.CodedInputStream input,
2892 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
2893 throws java.io.IOException {
2894 return com.google.protobuf.GeneratedMessage
2895 .parseWithIOException(PARSER, input, extensionRegistry);
2896 }
2897
2898 @java.lang.Override
2899 public Builder newBuilderForType() { return newBuilder(); }
2900 public static Builder newBuilder() {
2901 return DEFAULT_INSTANCE.toBuilder();
2902 }
2903 public static Builder newBuilder(com.google.ortools.pdlp.PrimalDualHybridGradientParams prototype) {
2904 return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
2905 }
2906 @java.lang.Override
2908 return this == DEFAULT_INSTANCE
2909 ? new Builder() : new Builder().mergeFrom(this);
2910 }
2911
2912 @java.lang.Override
2914 com.google.protobuf.GeneratedMessage.BuilderParent parent) {
2915 Builder builder = new Builder(parent);
2916 return builder;
2917 }
2918
2934 public static final class Builder extends
2935 com.google.protobuf.GeneratedMessage.Builder<Builder> implements
2936 // @@protoc_insertion_point(builder_implements:operations_research.pdlp.PrimalDualHybridGradientParams)
2938 public static final com.google.protobuf.Descriptors.Descriptor
2940 return com.google.ortools.pdlp.Solvers.internal_static_operations_research_pdlp_PrimalDualHybridGradientParams_descriptor;
2941 }
2942
2943 @java.lang.Override
2944 protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
2946 return com.google.ortools.pdlp.Solvers.internal_static_operations_research_pdlp_PrimalDualHybridGradientParams_fieldAccessorTable
2947 .ensureFieldAccessorsInitialized(
2948 com.google.ortools.pdlp.PrimalDualHybridGradientParams.class, com.google.ortools.pdlp.PrimalDualHybridGradientParams.Builder.class);
2949 }
2950
2951 // Construct using com.google.ortools.pdlp.PrimalDualHybridGradientParams.newBuilder()
2952 private Builder() {
2953 maybeForceBuilderInitialization();
2954 }
2955
2956 private Builder(
2957 com.google.protobuf.GeneratedMessage.BuilderParent parent) {
2958 super(parent);
2959 maybeForceBuilderInitialization();
2960 }
2961 private void maybeForceBuilderInitialization() {
2962 if (com.google.protobuf.GeneratedMessage
2963 .alwaysUseFieldBuilders) {
2964 internalGetTerminationCriteriaFieldBuilder();
2965 internalGetPresolveOptionsFieldBuilder();
2966 internalGetAdaptiveLinesearchParametersFieldBuilder();
2967 internalGetMalitskyPockParametersFieldBuilder();
2968 }
2969 }
2970 @java.lang.Override
2971 public Builder clear() {
2972 super.clear();
2973 bitField0_ = 0;
2974 terminationCriteria_ = null;
2975 if (terminationCriteriaBuilder_ != null) {
2976 terminationCriteriaBuilder_.dispose();
2977 terminationCriteriaBuilder_ = null;
2978 }
2979 numThreads_ = 1;
2980 numShards_ = 0;
2981 schedulerType_ = 1;
2982 recordIterationStats_ = false;
2983 verbosityLevel_ = 0;
2984 logIntervalSeconds_ = 0D;
2985 majorIterationFrequency_ = 64;
2986 terminationCheckFrequency_ = 64;
2987 restartStrategy_ = 3;
2988 primalWeightUpdateSmoothing_ = 0.5D;
2989 initialPrimalWeight_ = 0D;
2990 presolveOptions_ = null;
2991 if (presolveOptionsBuilder_ != null) {
2992 presolveOptionsBuilder_.dispose();
2993 presolveOptionsBuilder_ = null;
2994 }
2995 lInfRuizIterations_ = 5;
2996 l2NormRescaling_ = true;
2997 sufficientReductionForRestart_ = 0.1D;
2998 necessaryReductionForRestart_ = 0.9D;
2999 linesearchRule_ = 1;
3000 adaptiveLinesearchParameters_ = null;
3001 if (adaptiveLinesearchParametersBuilder_ != null) {
3002 adaptiveLinesearchParametersBuilder_.dispose();
3003 adaptiveLinesearchParametersBuilder_ = null;
3004 }
3005 malitskyPockParameters_ = null;
3006 if (malitskyPockParametersBuilder_ != null) {
3007 malitskyPockParametersBuilder_.dispose();
3008 malitskyPockParametersBuilder_ = null;
3009 }
3010 initialStepSizeScaling_ = 1D;
3011 randomProjectionSeeds_ = emptyIntList();
3012 infiniteConstraintBoundThreshold_ = Double.POSITIVE_INFINITY;
3013 handleSomePrimalGradientsOnFiniteBoundsAsResiduals_ = true;
3014 useDiagonalQpTrustRegionSolver_ = false;
3015 diagonalQpTrustRegionSolverTolerance_ = 1e-08D;
3016 useFeasibilityPolishing_ = false;
3017 applyFeasibilityPolishingAfterLimitsReached_ = false;
3018 applyFeasibilityPolishingIfSolverIsInterrupted_ = false;
3019 return this;
3020 }
3021
3022 @java.lang.Override
3023 public com.google.protobuf.Descriptors.Descriptor
3025 return com.google.ortools.pdlp.Solvers.internal_static_operations_research_pdlp_PrimalDualHybridGradientParams_descriptor;
3026 }
3027
3028 @java.lang.Override
3030 return com.google.ortools.pdlp.PrimalDualHybridGradientParams.getDefaultInstance();
3031 }
3032
3033 @java.lang.Override
3036 if (!result.isInitialized()) {
3037 throw newUninitializedMessageException(result);
3038 }
3039 return result;
3040 }
3041
3042 @java.lang.Override
3044 com.google.ortools.pdlp.PrimalDualHybridGradientParams result = new com.google.ortools.pdlp.PrimalDualHybridGradientParams(this);
3045 if (bitField0_ != 0) { buildPartial0(result); }
3046 onBuilt();
3047 return result;
3048 }
3049
3050 private void buildPartial0(com.google.ortools.pdlp.PrimalDualHybridGradientParams result) {
3051 int from_bitField0_ = bitField0_;
3052 int to_bitField0_ = 0;
3053 if (((from_bitField0_ & 0x00000001) != 0)) {
3054 result.terminationCriteria_ = terminationCriteriaBuilder_ == null
3055 ? terminationCriteria_
3056 : terminationCriteriaBuilder_.build();
3057 to_bitField0_ |= 0x00000001;
3058 }
3059 if (((from_bitField0_ & 0x00000002) != 0)) {
3060 result.numThreads_ = numThreads_;
3061 to_bitField0_ |= 0x00000002;
3062 }
3063 if (((from_bitField0_ & 0x00000004) != 0)) {
3064 result.numShards_ = numShards_;
3065 to_bitField0_ |= 0x00000004;
3066 }
3067 if (((from_bitField0_ & 0x00000008) != 0)) {
3068 result.schedulerType_ = schedulerType_;
3069 to_bitField0_ |= 0x00000008;
3070 }
3071 if (((from_bitField0_ & 0x00000010) != 0)) {
3072 result.recordIterationStats_ = recordIterationStats_;
3073 to_bitField0_ |= 0x00000010;
3074 }
3075 if (((from_bitField0_ & 0x00000020) != 0)) {
3076 result.verbosityLevel_ = verbosityLevel_;
3077 to_bitField0_ |= 0x00000020;
3078 }
3079 if (((from_bitField0_ & 0x00000040) != 0)) {
3080 result.logIntervalSeconds_ = logIntervalSeconds_;
3081 to_bitField0_ |= 0x00000040;
3082 }
3083 if (((from_bitField0_ & 0x00000080) != 0)) {
3084 result.majorIterationFrequency_ = majorIterationFrequency_;
3085 to_bitField0_ |= 0x00000080;
3086 }
3087 if (((from_bitField0_ & 0x00000100) != 0)) {
3088 result.terminationCheckFrequency_ = terminationCheckFrequency_;
3089 to_bitField0_ |= 0x00000100;
3090 }
3091 if (((from_bitField0_ & 0x00000200) != 0)) {
3092 result.restartStrategy_ = restartStrategy_;
3093 to_bitField0_ |= 0x00000200;
3094 }
3095 if (((from_bitField0_ & 0x00000400) != 0)) {
3096 result.primalWeightUpdateSmoothing_ = primalWeightUpdateSmoothing_;
3097 to_bitField0_ |= 0x00000400;
3098 }
3099 if (((from_bitField0_ & 0x00000800) != 0)) {
3100 result.initialPrimalWeight_ = initialPrimalWeight_;
3101 to_bitField0_ |= 0x00000800;
3102 }
3103 if (((from_bitField0_ & 0x00001000) != 0)) {
3104 result.presolveOptions_ = presolveOptionsBuilder_ == null
3105 ? presolveOptions_
3106 : presolveOptionsBuilder_.build();
3107 to_bitField0_ |= 0x00001000;
3108 }
3109 if (((from_bitField0_ & 0x00002000) != 0)) {
3110 result.lInfRuizIterations_ = lInfRuizIterations_;
3111 to_bitField0_ |= 0x00002000;
3112 }
3113 if (((from_bitField0_ & 0x00004000) != 0)) {
3114 result.l2NormRescaling_ = l2NormRescaling_;
3115 to_bitField0_ |= 0x00004000;
3116 }
3117 if (((from_bitField0_ & 0x00008000) != 0)) {
3118 result.sufficientReductionForRestart_ = sufficientReductionForRestart_;
3119 to_bitField0_ |= 0x00008000;
3120 }
3121 if (((from_bitField0_ & 0x00010000) != 0)) {
3122 result.necessaryReductionForRestart_ = necessaryReductionForRestart_;
3123 to_bitField0_ |= 0x00010000;
3124 }
3125 if (((from_bitField0_ & 0x00020000) != 0)) {
3126 result.linesearchRule_ = linesearchRule_;
3127 to_bitField0_ |= 0x00020000;
3128 }
3129 if (((from_bitField0_ & 0x00040000) != 0)) {
3130 result.adaptiveLinesearchParameters_ = adaptiveLinesearchParametersBuilder_ == null
3131 ? adaptiveLinesearchParameters_
3132 : adaptiveLinesearchParametersBuilder_.build();
3133 to_bitField0_ |= 0x00040000;
3134 }
3135 if (((from_bitField0_ & 0x00080000) != 0)) {
3136 result.malitskyPockParameters_ = malitskyPockParametersBuilder_ == null
3137 ? malitskyPockParameters_
3138 : malitskyPockParametersBuilder_.build();
3139 to_bitField0_ |= 0x00080000;
3140 }
3141 if (((from_bitField0_ & 0x00100000) != 0)) {
3142 result.initialStepSizeScaling_ = initialStepSizeScaling_;
3143 to_bitField0_ |= 0x00100000;
3144 }
3145 if (((from_bitField0_ & 0x00200000) != 0)) {
3146 randomProjectionSeeds_.makeImmutable();
3147 result.randomProjectionSeeds_ = randomProjectionSeeds_;
3148 }
3149 if (((from_bitField0_ & 0x00400000) != 0)) {
3150 result.infiniteConstraintBoundThreshold_ = infiniteConstraintBoundThreshold_;
3151 to_bitField0_ |= 0x00200000;
3152 }
3153 if (((from_bitField0_ & 0x00800000) != 0)) {
3154 result.handleSomePrimalGradientsOnFiniteBoundsAsResiduals_ = handleSomePrimalGradientsOnFiniteBoundsAsResiduals_;
3155 to_bitField0_ |= 0x00400000;
3156 }
3157 if (((from_bitField0_ & 0x01000000) != 0)) {
3158 result.useDiagonalQpTrustRegionSolver_ = useDiagonalQpTrustRegionSolver_;
3159 to_bitField0_ |= 0x00800000;
3160 }
3161 if (((from_bitField0_ & 0x02000000) != 0)) {
3162 result.diagonalQpTrustRegionSolverTolerance_ = diagonalQpTrustRegionSolverTolerance_;
3163 to_bitField0_ |= 0x01000000;
3164 }
3165 if (((from_bitField0_ & 0x04000000) != 0)) {
3166 result.useFeasibilityPolishing_ = useFeasibilityPolishing_;
3167 to_bitField0_ |= 0x02000000;
3168 }
3169 if (((from_bitField0_ & 0x08000000) != 0)) {
3170 result.applyFeasibilityPolishingAfterLimitsReached_ = applyFeasibilityPolishingAfterLimitsReached_;
3171 to_bitField0_ |= 0x04000000;
3172 }
3173 if (((from_bitField0_ & 0x10000000) != 0)) {
3174 result.applyFeasibilityPolishingIfSolverIsInterrupted_ = applyFeasibilityPolishingIfSolverIsInterrupted_;
3175 to_bitField0_ |= 0x08000000;
3176 }
3177 result.bitField0_ |= to_bitField0_;
3178 }
3179
3180 @java.lang.Override
3181 public Builder mergeFrom(com.google.protobuf.Message other) {
3182 if (other instanceof com.google.ortools.pdlp.PrimalDualHybridGradientParams) {
3183 return mergeFrom((com.google.ortools.pdlp.PrimalDualHybridGradientParams)other);
3184 } else {
3185 super.mergeFrom(other);
3186 return this;
3187 }
3188 }
3189
3190 public Builder mergeFrom(com.google.ortools.pdlp.PrimalDualHybridGradientParams other) {
3191 if (other == com.google.ortools.pdlp.PrimalDualHybridGradientParams.getDefaultInstance()) return this;
3192 if (other.hasTerminationCriteria()) {
3193 mergeTerminationCriteria(other.getTerminationCriteria());
3194 }
3195 if (other.hasNumThreads()) {
3196 setNumThreads(other.getNumThreads());
3197 }
3198 if (other.hasNumShards()) {
3199 setNumShards(other.getNumShards());
3200 }
3201 if (other.hasSchedulerType()) {
3202 setSchedulerType(other.getSchedulerType());
3203 }
3204 if (other.hasRecordIterationStats()) {
3205 setRecordIterationStats(other.getRecordIterationStats());
3206 }
3207 if (other.hasVerbosityLevel()) {
3208 setVerbosityLevel(other.getVerbosityLevel());
3209 }
3210 if (other.hasLogIntervalSeconds()) {
3211 setLogIntervalSeconds(other.getLogIntervalSeconds());
3212 }
3213 if (other.hasMajorIterationFrequency()) {
3214 setMajorIterationFrequency(other.getMajorIterationFrequency());
3215 }
3216 if (other.hasTerminationCheckFrequency()) {
3217 setTerminationCheckFrequency(other.getTerminationCheckFrequency());
3218 }
3219 if (other.hasRestartStrategy()) {
3220 setRestartStrategy(other.getRestartStrategy());
3221 }
3222 if (other.hasPrimalWeightUpdateSmoothing()) {
3223 setPrimalWeightUpdateSmoothing(other.getPrimalWeightUpdateSmoothing());
3224 }
3225 if (other.hasInitialPrimalWeight()) {
3226 setInitialPrimalWeight(other.getInitialPrimalWeight());
3227 }
3228 if (other.hasPresolveOptions()) {
3229 mergePresolveOptions(other.getPresolveOptions());
3230 }
3231 if (other.hasLInfRuizIterations()) {
3232 setLInfRuizIterations(other.getLInfRuizIterations());
3233 }
3234 if (other.hasL2NormRescaling()) {
3235 setL2NormRescaling(other.getL2NormRescaling());
3236 }
3237 if (other.hasSufficientReductionForRestart()) {
3238 setSufficientReductionForRestart(other.getSufficientReductionForRestart());
3239 }
3240 if (other.hasNecessaryReductionForRestart()) {
3241 setNecessaryReductionForRestart(other.getNecessaryReductionForRestart());
3242 }
3243 if (other.hasLinesearchRule()) {
3244 setLinesearchRule(other.getLinesearchRule());
3245 }
3246 if (other.hasAdaptiveLinesearchParameters()) {
3247 mergeAdaptiveLinesearchParameters(other.getAdaptiveLinesearchParameters());
3248 }
3249 if (other.hasMalitskyPockParameters()) {
3250 mergeMalitskyPockParameters(other.getMalitskyPockParameters());
3251 }
3252 if (other.hasInitialStepSizeScaling()) {
3253 setInitialStepSizeScaling(other.getInitialStepSizeScaling());
3254 }
3255 if (!other.randomProjectionSeeds_.isEmpty()) {
3256 if (randomProjectionSeeds_.isEmpty()) {
3257 randomProjectionSeeds_ = other.randomProjectionSeeds_;
3258 randomProjectionSeeds_.makeImmutable();
3259 bitField0_ |= 0x00200000;
3260 } else {
3261 ensureRandomProjectionSeedsIsMutable();
3262 randomProjectionSeeds_.addAll(other.randomProjectionSeeds_);
3263 }
3264 onChanged();
3265 }
3266 if (other.hasInfiniteConstraintBoundThreshold()) {
3267 setInfiniteConstraintBoundThreshold(other.getInfiniteConstraintBoundThreshold());
3268 }
3269 if (other.hasHandleSomePrimalGradientsOnFiniteBoundsAsResiduals()) {
3270 setHandleSomePrimalGradientsOnFiniteBoundsAsResiduals(other.getHandleSomePrimalGradientsOnFiniteBoundsAsResiduals());
3271 }
3272 if (other.hasUseDiagonalQpTrustRegionSolver()) {
3273 setUseDiagonalQpTrustRegionSolver(other.getUseDiagonalQpTrustRegionSolver());
3274 }
3275 if (other.hasDiagonalQpTrustRegionSolverTolerance()) {
3276 setDiagonalQpTrustRegionSolverTolerance(other.getDiagonalQpTrustRegionSolverTolerance());
3277 }
3278 if (other.hasUseFeasibilityPolishing()) {
3279 setUseFeasibilityPolishing(other.getUseFeasibilityPolishing());
3280 }
3281 if (other.hasApplyFeasibilityPolishingAfterLimitsReached()) {
3282 setApplyFeasibilityPolishingAfterLimitsReached(other.getApplyFeasibilityPolishingAfterLimitsReached());
3283 }
3284 if (other.hasApplyFeasibilityPolishingIfSolverIsInterrupted()) {
3285 setApplyFeasibilityPolishingIfSolverIsInterrupted(other.getApplyFeasibilityPolishingIfSolverIsInterrupted());
3286 }
3287 this.mergeUnknownFields(other.getUnknownFields());
3288 onChanged();
3289 return this;
3290 }
3291
3292 @java.lang.Override
3293 public final boolean isInitialized() {
3294 return true;
3295 }
3296
3297 @java.lang.Override
3298 public Builder mergeFrom(
3299 com.google.protobuf.CodedInputStream input,
3300 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
3301 throws java.io.IOException {
3302 if (extensionRegistry == null) {
3303 throw new java.lang.NullPointerException();
3304 }
3305 try {
3306 boolean done = false;
3307 while (!done) {
3308 int tag = input.readTag();
3309 switch (tag) {
3310 case 0:
3311 done = true;
3312 break;
3313 case 10: {
3314 input.readMessage(
3315 internalGetTerminationCriteriaFieldBuilder().getBuilder(),
3316 extensionRegistry);
3317 bitField0_ |= 0x00000001;
3318 break;
3319 } // case 10
3320 case 16: {
3321 numThreads_ = input.readInt32();
3322 bitField0_ |= 0x00000002;
3323 break;
3324 } // case 16
3325 case 24: {
3326 recordIterationStats_ = input.readBool();
3327 bitField0_ |= 0x00000010;
3328 break;
3329 } // case 24
3330 case 32: {
3331 majorIterationFrequency_ = input.readInt32();
3332 bitField0_ |= 0x00000080;
3333 break;
3334 } // case 32
3335 case 40: {
3336 terminationCheckFrequency_ = input.readInt32();
3337 bitField0_ |= 0x00000100;
3338 break;
3339 } // case 40
3340 case 48: {
3341 int tmpRaw = input.readEnum();
3343 com.google.ortools.pdlp.PrimalDualHybridGradientParams.RestartStrategy.forNumber(tmpRaw);
3344 if (tmpValue == null) {
3345 mergeUnknownVarintField(6, tmpRaw);
3346 } else {
3347 restartStrategy_ = tmpRaw;
3348 bitField0_ |= 0x00000200;
3349 }
3350 break;
3351 } // case 48
3352 case 57: {
3353 primalWeightUpdateSmoothing_ = input.readDouble();
3354 bitField0_ |= 0x00000400;
3355 break;
3356 } // case 57
3357 case 65: {
3358 initialPrimalWeight_ = input.readDouble();
3359 bitField0_ |= 0x00000800;
3360 break;
3361 } // case 65
3362 case 72: {
3363 lInfRuizIterations_ = input.readInt32();
3364 bitField0_ |= 0x00002000;
3365 break;
3366 } // case 72
3367 case 80: {
3368 l2NormRescaling_ = input.readBool();
3369 bitField0_ |= 0x00004000;
3370 break;
3371 } // case 80
3372 case 89: {
3373 sufficientReductionForRestart_ = input.readDouble();
3374 bitField0_ |= 0x00008000;
3375 break;
3376 } // case 89
3377 case 96: {
3378 int tmpRaw = input.readEnum();
3380 com.google.ortools.pdlp.PrimalDualHybridGradientParams.LinesearchRule.forNumber(tmpRaw);
3381 if (tmpValue == null) {
3382 mergeUnknownVarintField(12, tmpRaw);
3383 } else {
3384 linesearchRule_ = tmpRaw;
3385 bitField0_ |= 0x00020000;
3386 }
3387 break;
3388 } // case 96
3389 case 130: {
3390 input.readMessage(
3391 internalGetPresolveOptionsFieldBuilder().getBuilder(),
3392 extensionRegistry);
3393 bitField0_ |= 0x00001000;
3394 break;
3395 } // case 130
3396 case 137: {
3397 necessaryReductionForRestart_ = input.readDouble();
3398 bitField0_ |= 0x00010000;
3399 break;
3400 } // case 137
3401 case 146: {
3402 input.readMessage(
3403 internalGetAdaptiveLinesearchParametersFieldBuilder().getBuilder(),
3404 extensionRegistry);
3405 bitField0_ |= 0x00040000;
3406 break;
3407 } // case 146
3408 case 154: {
3409 input.readMessage(
3410 internalGetMalitskyPockParametersFieldBuilder().getBuilder(),
3411 extensionRegistry);
3412 bitField0_ |= 0x00080000;
3413 break;
3414 } // case 154
3415 case 177: {
3416 infiniteConstraintBoundThreshold_ = input.readDouble();
3417 bitField0_ |= 0x00400000;
3418 break;
3419 } // case 177
3420 case 184: {
3421 useDiagonalQpTrustRegionSolver_ = input.readBool();
3422 bitField0_ |= 0x01000000;
3423 break;
3424 } // case 184
3425 case 193: {
3426 diagonalQpTrustRegionSolverTolerance_ = input.readDouble();
3427 bitField0_ |= 0x02000000;
3428 break;
3429 } // case 193
3430 case 201: {
3431 initialStepSizeScaling_ = input.readDouble();
3432 bitField0_ |= 0x00100000;
3433 break;
3434 } // case 201
3435 case 208: {
3436 verbosityLevel_ = input.readInt32();
3437 bitField0_ |= 0x00000020;
3438 break;
3439 } // case 208
3440 case 216: {
3441 numShards_ = input.readInt32();
3442 bitField0_ |= 0x00000004;
3443 break;
3444 } // case 216
3445 case 224: {
3446 int v = input.readInt32();
3447 ensureRandomProjectionSeedsIsMutable();
3448 randomProjectionSeeds_.addInt(v);
3449 break;
3450 } // case 224
3451 case 226: {
3452 int length = input.readRawVarint32();
3453 int limit = input.pushLimit(length);
3454 ensureRandomProjectionSeedsIsMutable();
3455 while (input.getBytesUntilLimit() > 0) {
3456 randomProjectionSeeds_.addInt(input.readInt32());
3457 }
3458 input.popLimit(limit);
3459 break;
3460 } // case 226
3461 case 232: {
3462 handleSomePrimalGradientsOnFiniteBoundsAsResiduals_ = input.readBool();
3463 bitField0_ |= 0x00800000;
3464 break;
3465 } // case 232
3466 case 240: {
3467 useFeasibilityPolishing_ = input.readBool();
3468 bitField0_ |= 0x04000000;
3469 break;
3470 } // case 240
3471 case 249: {
3472 logIntervalSeconds_ = input.readDouble();
3473 bitField0_ |= 0x00000040;
3474 break;
3475 } // case 249
3476 case 256: {
3477 int tmpRaw = input.readEnum();
3479 com.google.ortools.pdlp.SchedulerType.forNumber(tmpRaw);
3480 if (tmpValue == null) {
3481 mergeUnknownVarintField(32, tmpRaw);
3482 } else {
3483 schedulerType_ = tmpRaw;
3484 bitField0_ |= 0x00000008;
3485 }
3486 break;
3487 } // case 256
3488 case 264: {
3489 applyFeasibilityPolishingAfterLimitsReached_ = input.readBool();
3490 bitField0_ |= 0x08000000;
3491 break;
3492 } // case 264
3493 case 272: {
3494 applyFeasibilityPolishingIfSolverIsInterrupted_ = input.readBool();
3495 bitField0_ |= 0x10000000;
3496 break;
3497 } // case 272
3498 default: {
3499 if (!super.parseUnknownField(input, extensionRegistry, tag)) {
3500 done = true; // was an endgroup tag
3501 }
3502 break;
3503 } // default:
3504 } // switch (tag)
3505 } // while (!done)
3506 } catch (com.google.protobuf.InvalidProtocolBufferException e) {
3507 throw e.unwrapIOException();
3508 } finally {
3509 onChanged();
3510 } // finally
3511 return this;
3512 }
3513 private int bitField0_;
3514
3515 private com.google.ortools.pdlp.TerminationCriteria terminationCriteria_;
3516 private com.google.protobuf.SingleFieldBuilder<
3517 com.google.ortools.pdlp.TerminationCriteria, com.google.ortools.pdlp.TerminationCriteria.Builder, com.google.ortools.pdlp.TerminationCriteriaOrBuilder> terminationCriteriaBuilder_;
3522 public boolean hasTerminationCriteria() {
3523 return ((bitField0_ & 0x00000001) != 0);
3524 }
3525
3530 if (terminationCriteriaBuilder_ == null) {
3531 return terminationCriteria_ == null ? com.google.ortools.pdlp.TerminationCriteria.getDefaultInstance() : terminationCriteria_;
3532 } else {
3533 return terminationCriteriaBuilder_.getMessage();
3534 }
3535 }
3536
3539 public Builder setTerminationCriteria(com.google.ortools.pdlp.TerminationCriteria value) {
3540 if (terminationCriteriaBuilder_ == null) {
3541 if (value == null) {
3542 throw new NullPointerException();
3543 }
3544 terminationCriteria_ = value;
3545 } else {
3546 terminationCriteriaBuilder_.setMessage(value);
3547 }
3548 bitField0_ |= 0x00000001;
3549 onChanged();
3550 return this;
3551 }
3552
3556 com.google.ortools.pdlp.TerminationCriteria.Builder builderForValue) {
3557 if (terminationCriteriaBuilder_ == null) {
3558 terminationCriteria_ = builderForValue.build();
3559 } else {
3560 terminationCriteriaBuilder_.setMessage(builderForValue.build());
3561 }
3562 bitField0_ |= 0x00000001;
3563 onChanged();
3564 return this;
3565 }
3566
3569 public Builder mergeTerminationCriteria(com.google.ortools.pdlp.TerminationCriteria value) {
3570 if (terminationCriteriaBuilder_ == null) {
3571 if (((bitField0_ & 0x00000001) != 0) &&
3572 terminationCriteria_ != null &&
3573 terminationCriteria_ != com.google.ortools.pdlp.TerminationCriteria.getDefaultInstance()) {
3574 getTerminationCriteriaBuilder().mergeFrom(value);
3575 } else {
3576 terminationCriteria_ = value;
3577 }
3578 } else {
3579 terminationCriteriaBuilder_.mergeFrom(value);
3580 }
3581 if (terminationCriteria_ != null) {
3582 bitField0_ |= 0x00000001;
3583 onChanged();
3584 }
3585 return this;
3586 }
3587
3590 public Builder clearTerminationCriteria() {
3591 bitField0_ = (bitField0_ & ~0x00000001);
3592 terminationCriteria_ = null;
3593 if (terminationCriteriaBuilder_ != null) {
3594 terminationCriteriaBuilder_.dispose();
3595 terminationCriteriaBuilder_ = null;
3596 }
3597 onChanged();
3598 return this;
3599 }
3600
3604 bitField0_ |= 0x00000001;
3605 onChanged();
3606 return internalGetTerminationCriteriaFieldBuilder().getBuilder();
3607 }
3608
3612 if (terminationCriteriaBuilder_ != null) {
3613 return terminationCriteriaBuilder_.getMessageOrBuilder();
3614 } else {
3615 return terminationCriteria_ == null ?
3616 com.google.ortools.pdlp.TerminationCriteria.getDefaultInstance() : terminationCriteria_;
3617 }
3618 }
3619
3622 private com.google.protobuf.SingleFieldBuilder<
3623 com.google.ortools.pdlp.TerminationCriteria, com.google.ortools.pdlp.TerminationCriteria.Builder, com.google.ortools.pdlp.TerminationCriteriaOrBuilder>
3624 internalGetTerminationCriteriaFieldBuilder() {
3625 if (terminationCriteriaBuilder_ == null) {
3626 terminationCriteriaBuilder_ = new com.google.protobuf.SingleFieldBuilder<
3627 com.google.ortools.pdlp.TerminationCriteria, com.google.ortools.pdlp.TerminationCriteria.Builder, com.google.ortools.pdlp.TerminationCriteriaOrBuilder>(
3629 getParentForChildren(),
3630 isClean());
3631 terminationCriteria_ = null;
3632 }
3633 return terminationCriteriaBuilder_;
3634 }
3635
3636 private int numThreads_ = 1;
3648 @java.lang.Override
3649 public boolean hasNumThreads() {
3650 return ((bitField0_ & 0x00000002) != 0);
3651 }
3652
3663 @java.lang.Override
3664 public int getNumThreads() {
3665 return numThreads_;
3666 }
3667
3679 public Builder setNumThreads(int value) {
3680
3681 numThreads_ = value;
3682 bitField0_ |= 0x00000002;
3683 onChanged();
3684 return this;
3685 }
3686
3697 public Builder clearNumThreads() {
3698 bitField0_ = (bitField0_ & ~0x00000002);
3699 numThreads_ = 1;
3700 onChanged();
3701 return this;
3702 }
3703
3704 private int numShards_ ;
3721 @java.lang.Override
3722 public boolean hasNumShards() {
3723 return ((bitField0_ & 0x00000004) != 0);
3724 }
3725
3741 @java.lang.Override
3742 public int getNumShards() {
3743 return numShards_;
3744 }
3745
3762 public Builder setNumShards(int value) {
3763
3764 numShards_ = value;
3765 bitField0_ |= 0x00000004;
3766 onChanged();
3767 return this;
3768 }
3769
3785 public Builder clearNumShards() {
3786 bitField0_ = (bitField0_ & ~0x00000004);
3787 numShards_ = 0;
3788 onChanged();
3789 return this;
3790 }
3791
3792 private int schedulerType_ = 1;
3802 @java.lang.Override public boolean hasSchedulerType() {
3803 return ((bitField0_ & 0x00000008) != 0);
3804 }
3805
3814 @java.lang.Override
3816 com.google.ortools.pdlp.SchedulerType result = com.google.ortools.pdlp.SchedulerType.forNumber(schedulerType_);
3818 }
3819
3829 public Builder setSchedulerType(com.google.ortools.pdlp.SchedulerType value) {
3830 if (value == null) { throw new NullPointerException(); }
3831 bitField0_ |= 0x00000008;
3832 schedulerType_ = value.getNumber();
3833 onChanged();
3834 return this;
3835 }
3836
3845 public Builder clearSchedulerType() {
3846 bitField0_ = (bitField0_ & ~0x00000008);
3847 schedulerType_ = 1;
3848 onChanged();
3849 return this;
3850 }
3851
3852 private boolean recordIterationStats_ ;
3864 @java.lang.Override
3865 public boolean hasRecordIterationStats() {
3866 return ((bitField0_ & 0x00000010) != 0);
3867 }
3868
3879 @java.lang.Override
3880 public boolean getRecordIterationStats() {
3881 return recordIterationStats_;
3882 }
3883
3895 public Builder setRecordIterationStats(boolean value) {
3896
3897 recordIterationStats_ = value;
3898 bitField0_ |= 0x00000010;
3899 onChanged();
3900 return this;
3901 }
3902
3913 public Builder clearRecordIterationStats() {
3914 bitField0_ = (bitField0_ & ~0x00000010);
3915 recordIterationStats_ = false;
3916 onChanged();
3917 return this;
3918 }
3919
3920 private int verbosityLevel_ ;
3939 @java.lang.Override
3940 public boolean hasVerbosityLevel() {
3941 return ((bitField0_ & 0x00000020) != 0);
3942 }
3943
3961 @java.lang.Override
3962 public int getVerbosityLevel() {
3963 return verbosityLevel_;
3964 }
3965
3984 public Builder setVerbosityLevel(int value) {
3985
3986 verbosityLevel_ = value;
3987 bitField0_ |= 0x00000020;
3988 onChanged();
3989 return this;
3990 }
3991
4009 public Builder clearVerbosityLevel() {
4010 bitField0_ = (bitField0_ & ~0x00000020);
4011 verbosityLevel_ = 0;
4012 onChanged();
4013 return this;
4014 }
4015
4016 private double logIntervalSeconds_ ;
4029 @java.lang.Override
4030 public boolean hasLogIntervalSeconds() {
4031 return ((bitField0_ & 0x00000040) != 0);
4032 }
4033
4045 @java.lang.Override
4046 public double getLogIntervalSeconds() {
4047 return logIntervalSeconds_;
4048 }
4049
4062 public Builder setLogIntervalSeconds(double value) {
4063
4064 logIntervalSeconds_ = value;
4065 bitField0_ |= 0x00000040;
4066 onChanged();
4067 return this;
4068 }
4069
4081 public Builder clearLogIntervalSeconds() {
4082 bitField0_ = (bitField0_ & ~0x00000040);
4083 logIntervalSeconds_ = 0D;
4084 onChanged();
4085 return this;
4086 }
4087
4088 private int majorIterationFrequency_ = 64;
4102 @java.lang.Override
4104 return ((bitField0_ & 0x00000080) != 0);
4105 }
4106
4119 @java.lang.Override
4121 return majorIterationFrequency_;
4122 }
4123
4137 public Builder setMajorIterationFrequency(int value) {
4138
4139 majorIterationFrequency_ = value;
4140 bitField0_ |= 0x00000080;
4141 onChanged();
4142 return this;
4143 }
4144
4158 bitField0_ = (bitField0_ & ~0x00000080);
4159 majorIterationFrequency_ = 64;
4160 onChanged();
4161 return this;
4162 }
4163
4164 private int terminationCheckFrequency_ = 64;
4175 @java.lang.Override
4177 return ((bitField0_ & 0x00000100) != 0);
4178 }
4179
4189 @java.lang.Override
4191 return terminationCheckFrequency_;
4192 }
4193
4204 public Builder setTerminationCheckFrequency(int value) {
4205
4206 terminationCheckFrequency_ = value;
4207 bitField0_ |= 0x00000100;
4208 onChanged();
4209 return this;
4210 }
4211
4222 bitField0_ = (bitField0_ & ~0x00000100);
4223 terminationCheckFrequency_ = 64;
4224 onChanged();
4225 return this;
4226 }
4227
4228 private int restartStrategy_ = 3;
4239 @java.lang.Override public boolean hasRestartStrategy() {
4240 return ((bitField0_ & 0x00000200) != 0);
4241 }
4242
4252 @java.lang.Override
4254 com.google.ortools.pdlp.PrimalDualHybridGradientParams.RestartStrategy result = com.google.ortools.pdlp.PrimalDualHybridGradientParams.RestartStrategy.forNumber(restartStrategy_);
4256 }
4257
4268 public Builder setRestartStrategy(com.google.ortools.pdlp.PrimalDualHybridGradientParams.RestartStrategy value) {
4269 if (value == null) { throw new NullPointerException(); }
4270 bitField0_ |= 0x00000200;
4271 restartStrategy_ = value.getNumber();
4272 onChanged();
4273 return this;
4274 }
4275
4285 public Builder clearRestartStrategy() {
4286 bitField0_ = (bitField0_ & ~0x00000200);
4287 restartStrategy_ = 3;
4288 onChanged();
4289 return this;
4290 }
4291
4292 private double primalWeightUpdateSmoothing_ = 0.5D;
4308 @java.lang.Override
4310 return ((bitField0_ & 0x00000400) != 0);
4311 }
4312
4327 @java.lang.Override
4329 return primalWeightUpdateSmoothing_;
4330 }
4331
4347 public Builder setPrimalWeightUpdateSmoothing(double value) {
4348
4349 primalWeightUpdateSmoothing_ = value;
4350 bitField0_ |= 0x00000400;
4351 onChanged();
4352 return this;
4353 }
4354
4370 bitField0_ = (bitField0_ & ~0x00000400);
4371 primalWeightUpdateSmoothing_ = 0.5D;
4372 onChanged();
4373 return this;
4374 }
4375
4376 private double initialPrimalWeight_ ;
4391 @java.lang.Override
4392 public boolean hasInitialPrimalWeight() {
4393 return ((bitField0_ & 0x00000800) != 0);
4394 }
4395
4409 @java.lang.Override
4410 public double getInitialPrimalWeight() {
4411 return initialPrimalWeight_;
4412 }
4413
4428 public Builder setInitialPrimalWeight(double value) {
4429
4430 initialPrimalWeight_ = value;
4431 bitField0_ |= 0x00000800;
4432 onChanged();
4433 return this;
4434 }
4435
4449 public Builder clearInitialPrimalWeight() {
4450 bitField0_ = (bitField0_ & ~0x00000800);
4451 initialPrimalWeight_ = 0D;
4452 onChanged();
4453 return this;
4454 }
4455
4457 private com.google.protobuf.SingleFieldBuilder<
4458 com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions, com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.Builder, com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptionsOrBuilder> presolveOptionsBuilder_;
4463 public boolean hasPresolveOptions() {
4464 return ((bitField0_ & 0x00001000) != 0);
4465 }
4466
4471 if (presolveOptionsBuilder_ == null) {
4472 return presolveOptions_ == null ? com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.getDefaultInstance() : presolveOptions_;
4473 } else {
4474 return presolveOptionsBuilder_.getMessage();
4475 }
4476 }
4477
4480 public Builder setPresolveOptions(com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions value) {
4481 if (presolveOptionsBuilder_ == null) {
4482 if (value == null) {
4483 throw new NullPointerException();
4484 }
4485 presolveOptions_ = value;
4486 } else {
4487 presolveOptionsBuilder_.setMessage(value);
4488 }
4489 bitField0_ |= 0x00001000;
4490 onChanged();
4491 return this;
4492 }
4493
4496 public Builder setPresolveOptions(
4497 com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.Builder builderForValue) {
4498 if (presolveOptionsBuilder_ == null) {
4499 presolveOptions_ = builderForValue.build();
4500 } else {
4501 presolveOptionsBuilder_.setMessage(builderForValue.build());
4502 }
4503 bitField0_ |= 0x00001000;
4504 onChanged();
4505 return this;
4506 }
4507
4510 public Builder mergePresolveOptions(com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions value) {
4511 if (presolveOptionsBuilder_ == null) {
4512 if (((bitField0_ & 0x00001000) != 0) &&
4513 presolveOptions_ != null &&
4514 presolveOptions_ != com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.getDefaultInstance()) {
4515 getPresolveOptionsBuilder().mergeFrom(value);
4516 } else {
4517 presolveOptions_ = value;
4518 }
4519 } else {
4520 presolveOptionsBuilder_.mergeFrom(value);
4521 }
4522 if (presolveOptions_ != null) {
4523 bitField0_ |= 0x00001000;
4524 onChanged();
4525 }
4526 return this;
4527 }
4528
4531 public Builder clearPresolveOptions() {
4532 bitField0_ = (bitField0_ & ~0x00001000);
4533 presolveOptions_ = null;
4534 if (presolveOptionsBuilder_ != null) {
4535 presolveOptionsBuilder_.dispose();
4536 presolveOptionsBuilder_ = null;
4537 }
4538 onChanged();
4539 return this;
4540 }
4541
4545 bitField0_ |= 0x00001000;
4546 onChanged();
4547 return internalGetPresolveOptionsFieldBuilder().getBuilder();
4548 }
4549
4553 if (presolveOptionsBuilder_ != null) {
4554 return presolveOptionsBuilder_.getMessageOrBuilder();
4555 } else {
4556 return presolveOptions_ == null ?
4557 com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.getDefaultInstance() : presolveOptions_;
4558 }
4559 }
4560
4563 private com.google.protobuf.SingleFieldBuilder<
4564 com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions, com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.Builder, com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptionsOrBuilder>
4565 internalGetPresolveOptionsFieldBuilder() {
4566 if (presolveOptionsBuilder_ == null) {
4567 presolveOptionsBuilder_ = new com.google.protobuf.SingleFieldBuilder<
4568 com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions, com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.Builder, com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptionsOrBuilder>(
4570 getParentForChildren(),
4571 isClean());
4572 presolveOptions_ = null;
4573 }
4574 return presolveOptionsBuilder_;
4575 }
4576
4577 private int lInfRuizIterations_ = 5;
4588 @java.lang.Override
4589 public boolean hasLInfRuizIterations() {
4590 return ((bitField0_ & 0x00002000) != 0);
4591 }
4592
4602 @java.lang.Override
4604 return lInfRuizIterations_;
4605 }
4606
4617 public Builder setLInfRuizIterations(int value) {
4618
4619 lInfRuizIterations_ = value;
4620 bitField0_ |= 0x00002000;
4621 onChanged();
4622 return this;
4623 }
4624
4634 public Builder clearLInfRuizIterations() {
4635 bitField0_ = (bitField0_ & ~0x00002000);
4636 lInfRuizIterations_ = 5;
4637 onChanged();
4638 return this;
4639 }
4640
4641 private boolean l2NormRescaling_ = true;
4651 @java.lang.Override
4652 public boolean hasL2NormRescaling() {
4653 return ((bitField0_ & 0x00004000) != 0);
4654 }
4655
4664 @java.lang.Override
4665 public boolean getL2NormRescaling() {
4666 return l2NormRescaling_;
4667 }
4668
4678 public Builder setL2NormRescaling(boolean value) {
4679
4680 l2NormRescaling_ = value;
4681 bitField0_ |= 0x00004000;
4682 onChanged();
4683 return this;
4684 }
4685
4694 public Builder clearL2NormRescaling() {
4695 bitField0_ = (bitField0_ & ~0x00004000);
4696 l2NormRescaling_ = true;
4697 onChanged();
4698 return this;
4699 }
4700
4701 private double sufficientReductionForRestart_ = 0.1D;
4712 @java.lang.Override
4714 return ((bitField0_ & 0x00008000) != 0);
4715 }
4716
4726 @java.lang.Override
4728 return sufficientReductionForRestart_;
4729 }
4730
4741 public Builder setSufficientReductionForRestart(double value) {
4742
4743 sufficientReductionForRestart_ = value;
4744 bitField0_ |= 0x00008000;
4745 onChanged();
4746 return this;
4747 }
4748
4759 bitField0_ = (bitField0_ & ~0x00008000);
4760 sufficientReductionForRestart_ = 0.1D;
4761 onChanged();
4762 return this;
4763 }
4764
4765 private double necessaryReductionForRestart_ = 0.9D;
4778 @java.lang.Override
4780 return ((bitField0_ & 0x00010000) != 0);
4781 }
4782
4794 @java.lang.Override
4796 return necessaryReductionForRestart_;
4797 }
4798
4811 public Builder setNecessaryReductionForRestart(double value) {
4812
4813 necessaryReductionForRestart_ = value;
4814 bitField0_ |= 0x00010000;
4815 onChanged();
4816 return this;
4817 }
4818
4831 bitField0_ = (bitField0_ & ~0x00010000);
4832 necessaryReductionForRestart_ = 0.9D;
4833 onChanged();
4834 return this;
4835 }
4836
4837 private int linesearchRule_ = 1;
4846 @java.lang.Override public boolean hasLinesearchRule() {
4847 return ((bitField0_ & 0x00020000) != 0);
4848 }
4849
4857 @java.lang.Override
4859 com.google.ortools.pdlp.PrimalDualHybridGradientParams.LinesearchRule result = com.google.ortools.pdlp.PrimalDualHybridGradientParams.LinesearchRule.forNumber(linesearchRule_);
4861 }
4862
4871 public Builder setLinesearchRule(com.google.ortools.pdlp.PrimalDualHybridGradientParams.LinesearchRule value) {
4872 if (value == null) { throw new NullPointerException(); }
4873 bitField0_ |= 0x00020000;
4874 linesearchRule_ = value.getNumber();
4875 onChanged();
4876 return this;
4877 }
4878
4886 public Builder clearLinesearchRule() {
4887 bitField0_ = (bitField0_ & ~0x00020000);
4888 linesearchRule_ = 1;
4889 onChanged();
4890 return this;
4891 }
4892
4893 private com.google.ortools.pdlp.AdaptiveLinesearchParams adaptiveLinesearchParameters_;
4894 private com.google.protobuf.SingleFieldBuilder<
4895 com.google.ortools.pdlp.AdaptiveLinesearchParams, com.google.ortools.pdlp.AdaptiveLinesearchParams.Builder, com.google.ortools.pdlp.AdaptiveLinesearchParamsOrBuilder> adaptiveLinesearchParametersBuilder_;
4901 return ((bitField0_ & 0x00040000) != 0);
4902 }
4903
4908 if (adaptiveLinesearchParametersBuilder_ == null) {
4909 return adaptiveLinesearchParameters_ == null ? com.google.ortools.pdlp.AdaptiveLinesearchParams.getDefaultInstance() : adaptiveLinesearchParameters_;
4910 } else {
4911 return adaptiveLinesearchParametersBuilder_.getMessage();
4912 }
4913 }
4914
4917 public Builder setAdaptiveLinesearchParameters(com.google.ortools.pdlp.AdaptiveLinesearchParams value) {
4918 if (adaptiveLinesearchParametersBuilder_ == null) {
4919 if (value == null) {
4920 throw new NullPointerException();
4921 }
4922 adaptiveLinesearchParameters_ = value;
4923 } else {
4924 adaptiveLinesearchParametersBuilder_.setMessage(value);
4925 }
4926 bitField0_ |= 0x00040000;
4927 onChanged();
4928 return this;
4929 }
4930
4934 com.google.ortools.pdlp.AdaptiveLinesearchParams.Builder builderForValue) {
4935 if (adaptiveLinesearchParametersBuilder_ == null) {
4936 adaptiveLinesearchParameters_ = builderForValue.build();
4937 } else {
4938 adaptiveLinesearchParametersBuilder_.setMessage(builderForValue.build());
4939 }
4940 bitField0_ |= 0x00040000;
4941 onChanged();
4942 return this;
4943 }
4944
4947 public Builder mergeAdaptiveLinesearchParameters(com.google.ortools.pdlp.AdaptiveLinesearchParams value) {
4948 if (adaptiveLinesearchParametersBuilder_ == null) {
4949 if (((bitField0_ & 0x00040000) != 0) &&
4950 adaptiveLinesearchParameters_ != null &&
4951 adaptiveLinesearchParameters_ != com.google.ortools.pdlp.AdaptiveLinesearchParams.getDefaultInstance()) {
4952 getAdaptiveLinesearchParametersBuilder().mergeFrom(value);
4953 } else {
4954 adaptiveLinesearchParameters_ = value;
4955 }
4956 } else {
4957 adaptiveLinesearchParametersBuilder_.mergeFrom(value);
4958 }
4959 if (adaptiveLinesearchParameters_ != null) {
4960 bitField0_ |= 0x00040000;
4961 onChanged();
4962 }
4963 return this;
4964 }
4965
4969 bitField0_ = (bitField0_ & ~0x00040000);
4970 adaptiveLinesearchParameters_ = null;
4971 if (adaptiveLinesearchParametersBuilder_ != null) {
4972 adaptiveLinesearchParametersBuilder_.dispose();
4973 adaptiveLinesearchParametersBuilder_ = null;
4974 }
4975 onChanged();
4976 return this;
4977 }
4978
4982 bitField0_ |= 0x00040000;
4983 onChanged();
4984 return internalGetAdaptiveLinesearchParametersFieldBuilder().getBuilder();
4985 }
4986
4990 if (adaptiveLinesearchParametersBuilder_ != null) {
4991 return adaptiveLinesearchParametersBuilder_.getMessageOrBuilder();
4992 } else {
4993 return adaptiveLinesearchParameters_ == null ?
4994 com.google.ortools.pdlp.AdaptiveLinesearchParams.getDefaultInstance() : adaptiveLinesearchParameters_;
4995 }
4996 }
4997
5000 private com.google.protobuf.SingleFieldBuilder<
5001 com.google.ortools.pdlp.AdaptiveLinesearchParams, com.google.ortools.pdlp.AdaptiveLinesearchParams.Builder, com.google.ortools.pdlp.AdaptiveLinesearchParamsOrBuilder>
5002 internalGetAdaptiveLinesearchParametersFieldBuilder() {
5003 if (adaptiveLinesearchParametersBuilder_ == null) {
5004 adaptiveLinesearchParametersBuilder_ = new com.google.protobuf.SingleFieldBuilder<
5005 com.google.ortools.pdlp.AdaptiveLinesearchParams, com.google.ortools.pdlp.AdaptiveLinesearchParams.Builder, com.google.ortools.pdlp.AdaptiveLinesearchParamsOrBuilder>(
5007 getParentForChildren(),
5008 isClean());
5009 adaptiveLinesearchParameters_ = null;
5010 }
5011 return adaptiveLinesearchParametersBuilder_;
5012 }
5013
5014 private com.google.ortools.pdlp.MalitskyPockParams malitskyPockParameters_;
5015 private com.google.protobuf.SingleFieldBuilder<
5016 com.google.ortools.pdlp.MalitskyPockParams, com.google.ortools.pdlp.MalitskyPockParams.Builder, com.google.ortools.pdlp.MalitskyPockParamsOrBuilder> malitskyPockParametersBuilder_;
5021 public boolean hasMalitskyPockParameters() {
5022 return ((bitField0_ & 0x00080000) != 0);
5023 }
5024
5029 if (malitskyPockParametersBuilder_ == null) {
5030 return malitskyPockParameters_ == null ? com.google.ortools.pdlp.MalitskyPockParams.getDefaultInstance() : malitskyPockParameters_;
5031 } else {
5032 return malitskyPockParametersBuilder_.getMessage();
5033 }
5034 }
5035
5038 public Builder setMalitskyPockParameters(com.google.ortools.pdlp.MalitskyPockParams value) {
5039 if (malitskyPockParametersBuilder_ == null) {
5040 if (value == null) {
5041 throw new NullPointerException();
5042 }
5043 malitskyPockParameters_ = value;
5044 } else {
5045 malitskyPockParametersBuilder_.setMessage(value);
5046 }
5047 bitField0_ |= 0x00080000;
5048 onChanged();
5049 return this;
5050 }
5051
5055 com.google.ortools.pdlp.MalitskyPockParams.Builder builderForValue) {
5056 if (malitskyPockParametersBuilder_ == null) {
5057 malitskyPockParameters_ = builderForValue.build();
5058 } else {
5059 malitskyPockParametersBuilder_.setMessage(builderForValue.build());
5060 }
5061 bitField0_ |= 0x00080000;
5062 onChanged();
5063 return this;
5064 }
5065
5068 public Builder mergeMalitskyPockParameters(com.google.ortools.pdlp.MalitskyPockParams value) {
5069 if (malitskyPockParametersBuilder_ == null) {
5070 if (((bitField0_ & 0x00080000) != 0) &&
5071 malitskyPockParameters_ != null &&
5072 malitskyPockParameters_ != com.google.ortools.pdlp.MalitskyPockParams.getDefaultInstance()) {
5073 getMalitskyPockParametersBuilder().mergeFrom(value);
5074 } else {
5075 malitskyPockParameters_ = value;
5076 }
5077 } else {
5078 malitskyPockParametersBuilder_.mergeFrom(value);
5079 }
5080 if (malitskyPockParameters_ != null) {
5081 bitField0_ |= 0x00080000;
5082 onChanged();
5083 }
5084 return this;
5085 }
5086
5090 bitField0_ = (bitField0_ & ~0x00080000);
5091 malitskyPockParameters_ = null;
5092 if (malitskyPockParametersBuilder_ != null) {
5093 malitskyPockParametersBuilder_.dispose();
5094 malitskyPockParametersBuilder_ = null;
5095 }
5096 onChanged();
5097 return this;
5098 }
5099
5103 bitField0_ |= 0x00080000;
5104 onChanged();
5105 return internalGetMalitskyPockParametersFieldBuilder().getBuilder();
5106 }
5107
5111 if (malitskyPockParametersBuilder_ != null) {
5112 return malitskyPockParametersBuilder_.getMessageOrBuilder();
5113 } else {
5114 return malitskyPockParameters_ == null ?
5115 com.google.ortools.pdlp.MalitskyPockParams.getDefaultInstance() : malitskyPockParameters_;
5116 }
5117 }
5118
5121 private com.google.protobuf.SingleFieldBuilder<
5122 com.google.ortools.pdlp.MalitskyPockParams, com.google.ortools.pdlp.MalitskyPockParams.Builder, com.google.ortools.pdlp.MalitskyPockParamsOrBuilder>
5123 internalGetMalitskyPockParametersFieldBuilder() {
5124 if (malitskyPockParametersBuilder_ == null) {
5125 malitskyPockParametersBuilder_ = new com.google.protobuf.SingleFieldBuilder<
5126 com.google.ortools.pdlp.MalitskyPockParams, com.google.ortools.pdlp.MalitskyPockParams.Builder, com.google.ortools.pdlp.MalitskyPockParamsOrBuilder>(
5128 getParentForChildren(),
5129 isClean());
5130 malitskyPockParameters_ = null;
5131 }
5132 return malitskyPockParametersBuilder_;
5133 }
5134
5135 private double initialStepSizeScaling_ = 1D;
5145 @java.lang.Override
5146 public boolean hasInitialStepSizeScaling() {
5147 return ((bitField0_ & 0x00100000) != 0);
5148 }
5149
5158 @java.lang.Override
5160 return initialStepSizeScaling_;
5161 }
5162
5172 public Builder setInitialStepSizeScaling(double value) {
5173
5174 initialStepSizeScaling_ = value;
5175 bitField0_ |= 0x00100000;
5176 onChanged();
5177 return this;
5178 }
5179
5189 bitField0_ = (bitField0_ & ~0x00100000);
5190 initialStepSizeScaling_ = 1D;
5191 onChanged();
5192 return this;
5193 }
5194
5195 private com.google.protobuf.Internal.IntList randomProjectionSeeds_ = emptyIntList();
5196 private void ensureRandomProjectionSeedsIsMutable() {
5197 if (!randomProjectionSeeds_.isModifiable()) {
5198 randomProjectionSeeds_ = makeMutableCopy(randomProjectionSeeds_);
5199 }
5200 bitField0_ |= 0x00200000;
5201 }
5215 public java.util.List<java.lang.Integer>
5217 randomProjectionSeeds_.makeImmutable();
5218 return randomProjectionSeeds_;
5219 }
5220
5234 return randomProjectionSeeds_.size();
5235 }
5236
5250 public int getRandomProjectionSeeds(int index) {
5251 return randomProjectionSeeds_.getInt(index);
5252 }
5253
5269 int index, int value) {
5270
5271 ensureRandomProjectionSeedsIsMutable();
5272 randomProjectionSeeds_.setInt(index, value);
5273 bitField0_ |= 0x00200000;
5274 onChanged();
5275 return this;
5276 }
5277
5291 public Builder addRandomProjectionSeeds(int value) {
5292
5293 ensureRandomProjectionSeedsIsMutable();
5294 randomProjectionSeeds_.addInt(value);
5295 bitField0_ |= 0x00200000;
5296 onChanged();
5297 return this;
5298 }
5299
5314 java.lang.Iterable<? extends java.lang.Integer> values) {
5315 ensureRandomProjectionSeedsIsMutable();
5316 com.google.protobuf.AbstractMessageLite.Builder.addAll(
5317 values, randomProjectionSeeds_);
5318 bitField0_ |= 0x00200000;
5319 onChanged();
5320 return this;
5321 }
5322
5336 randomProjectionSeeds_ = emptyIntList();
5337 bitField0_ = (bitField0_ & ~0x00200000);
5338 onChanged();
5339 return this;
5340 }
5341
5342 private double infiniteConstraintBoundThreshold_ = Double.POSITIVE_INFINITY;
5356 @java.lang.Override
5358 return ((bitField0_ & 0x00400000) != 0);
5359 }
5360
5373 @java.lang.Override
5375 return infiniteConstraintBoundThreshold_;
5376 }
5377
5391 public Builder setInfiniteConstraintBoundThreshold(double value) {
5392
5393 infiniteConstraintBoundThreshold_ = value;
5394 bitField0_ |= 0x00400000;
5395 onChanged();
5396 return this;
5397 }
5398
5412 bitField0_ = (bitField0_ & ~0x00400000);
5413 infiniteConstraintBoundThreshold_ = Double.POSITIVE_INFINITY;
5414 onChanged();
5415 return this;
5416 }
5417
5418 private boolean handleSomePrimalGradientsOnFiniteBoundsAsResiduals_ = true;
5429 @java.lang.Override
5431 return ((bitField0_ & 0x00800000) != 0);
5432 }
5433
5443 @java.lang.Override
5445 return handleSomePrimalGradientsOnFiniteBoundsAsResiduals_;
5446 }
5447
5459
5460 handleSomePrimalGradientsOnFiniteBoundsAsResiduals_ = value;
5461 bitField0_ |= 0x00800000;
5462 onChanged();
5463 return this;
5464 }
5465
5476 bitField0_ = (bitField0_ & ~0x00800000);
5477 handleSomePrimalGradientsOnFiniteBoundsAsResiduals_ = true;
5478 onChanged();
5479 return this;
5480 }
5481
5482 private boolean useDiagonalQpTrustRegionSolver_ ;
5496 @java.lang.Override
5498 return ((bitField0_ & 0x01000000) != 0);
5499 }
5500
5513 @java.lang.Override
5515 return useDiagonalQpTrustRegionSolver_;
5516 }
5517
5531 public Builder setUseDiagonalQpTrustRegionSolver(boolean value) {
5532
5533 useDiagonalQpTrustRegionSolver_ = value;
5534 bitField0_ |= 0x01000000;
5535 onChanged();
5536 return this;
5537 }
5538
5552 bitField0_ = (bitField0_ & ~0x01000000);
5553 useDiagonalQpTrustRegionSolver_ = false;
5554 onChanged();
5555 return this;
5556 }
5557
5558 private double diagonalQpTrustRegionSolverTolerance_ = 1e-08D;
5571 @java.lang.Override
5573 return ((bitField0_ & 0x02000000) != 0);
5574 }
5575
5587 @java.lang.Override
5589 return diagonalQpTrustRegionSolverTolerance_;
5590 }
5591
5604 public Builder setDiagonalQpTrustRegionSolverTolerance(double value) {
5605
5606 diagonalQpTrustRegionSolverTolerance_ = value;
5607 bitField0_ |= 0x02000000;
5608 onChanged();
5609 return this;
5610 }
5611
5624 bitField0_ = (bitField0_ & ~0x02000000);
5625 diagonalQpTrustRegionSolverTolerance_ = 1e-08D;
5626 onChanged();
5627 return this;
5628 }
5629
5630 private boolean useFeasibilityPolishing_ ;
5664 @java.lang.Override
5666 return ((bitField0_ & 0x04000000) != 0);
5667 }
5668
5701 @java.lang.Override
5703 return useFeasibilityPolishing_;
5704 }
5705
5739 public Builder setUseFeasibilityPolishing(boolean value) {
5740
5741 useFeasibilityPolishing_ = value;
5742 bitField0_ |= 0x04000000;
5743 onChanged();
5744 return this;
5745 }
5746
5780 bitField0_ = (bitField0_ & ~0x04000000);
5781 useFeasibilityPolishing_ = false;
5782 onChanged();
5783 return this;
5784 }
5785
5786 private boolean applyFeasibilityPolishingAfterLimitsReached_ ;
5798 @java.lang.Override
5800 return ((bitField0_ & 0x08000000) != 0);
5801 }
5802
5813 @java.lang.Override
5815 return applyFeasibilityPolishingAfterLimitsReached_;
5816 }
5817
5830
5831 applyFeasibilityPolishingAfterLimitsReached_ = value;
5832 bitField0_ |= 0x08000000;
5833 onChanged();
5834 return this;
5835 }
5836
5848 bitField0_ = (bitField0_ & ~0x08000000);
5849 applyFeasibilityPolishingAfterLimitsReached_ = false;
5850 onChanged();
5851 return this;
5852 }
5853
5854 private boolean applyFeasibilityPolishingIfSolverIsInterrupted_ ;
5865 @java.lang.Override
5867 return ((bitField0_ & 0x10000000) != 0);
5868 }
5869
5879 @java.lang.Override
5881 return applyFeasibilityPolishingIfSolverIsInterrupted_;
5882 }
5883
5895
5896 applyFeasibilityPolishingIfSolverIsInterrupted_ = value;
5897 bitField0_ |= 0x10000000;
5898 onChanged();
5899 return this;
5900 }
5901
5912 bitField0_ = (bitField0_ & ~0x10000000);
5913 applyFeasibilityPolishingIfSolverIsInterrupted_ = false;
5914 onChanged();
5915 return this;
5916 }
5917
5918 // @@protoc_insertion_point(builder_scope:operations_research.pdlp.PrimalDualHybridGradientParams)
5919 }
5920
5921 // @@protoc_insertion_point(class_scope:operations_research.pdlp.PrimalDualHybridGradientParams)
5922 private static final com.google.ortools.pdlp.PrimalDualHybridGradientParams DEFAULT_INSTANCE;
5923 static {
5924 DEFAULT_INSTANCE = new com.google.ortools.pdlp.PrimalDualHybridGradientParams();
5925 }
5926
5928 return DEFAULT_INSTANCE;
5929 }
5930
5931 private static final com.google.protobuf.Parser<PrimalDualHybridGradientParams>
5932 PARSER = new com.google.protobuf.AbstractParser<PrimalDualHybridGradientParams>() {
5933 @java.lang.Override
5934 public PrimalDualHybridGradientParams parsePartialFrom(
5935 com.google.protobuf.CodedInputStream input,
5936 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
5937 throws com.google.protobuf.InvalidProtocolBufferException {
5938 Builder builder = newBuilder();
5939 try {
5940 builder.mergeFrom(input, extensionRegistry);
5941 } catch (com.google.protobuf.InvalidProtocolBufferException e) {
5942 throw e.setUnfinishedMessage(builder.buildPartial());
5943 } catch (com.google.protobuf.UninitializedMessageException e) {
5944 throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
5945 } catch (java.io.IOException e) {
5946 throw new com.google.protobuf.InvalidProtocolBufferException(e)
5947 .setUnfinishedMessage(builder.buildPartial());
5948 }
5949 return builder.buildPartial();
5950 }
5951 };
5952
5953 public static com.google.protobuf.Parser<PrimalDualHybridGradientParams> parser() {
5954 return PARSER;
5955 }
5956
5957 @java.lang.Override
5958 public com.google.protobuf.Parser<PrimalDualHybridGradientParams> getParserForType() {
5959 return PARSER;
5960 }
5961
5962 @java.lang.Override
5964 return DEFAULT_INSTANCE;
5965 }
5966
5967}
5968
Builder mergeMalitskyPockParameters(com.google.ortools.pdlp.MalitskyPockParams value)
static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
com.google.ortools.pdlp.AdaptiveLinesearchParams getAdaptiveLinesearchParameters()
Builder setPresolveOptions(com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions value)
com.google.ortools.pdlp.PrimalDualHybridGradientParams getDefaultInstanceForType()
com.google.ortools.pdlp.TerminationCriteria.Builder getTerminationCriteriaBuilder()
Builder setMalitskyPockParameters(com.google.ortools.pdlp.MalitskyPockParams value)
Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
Builder setRestartStrategy(com.google.ortools.pdlp.PrimalDualHybridGradientParams.RestartStrategy value)
Builder setMalitskyPockParameters(com.google.ortools.pdlp.MalitskyPockParams.Builder builderForValue)
Builder setPresolveOptions(com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.Builder builderForValue)
Builder setTerminationCriteria(com.google.ortools.pdlp.TerminationCriteria.Builder builderForValue)
com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions getPresolveOptions()
Builder addAllRandomProjectionSeeds(java.lang.Iterable<? extends java.lang.Integer > values)
com.google.ortools.pdlp.PrimalDualHybridGradientParams.LinesearchRule getLinesearchRule()
com.google.ortools.pdlp.PrimalDualHybridGradientParams.RestartStrategy getRestartStrategy()
com.google.ortools.pdlp.AdaptiveLinesearchParamsOrBuilder getAdaptiveLinesearchParametersOrBuilder()
Builder setTerminationCriteria(com.google.ortools.pdlp.TerminationCriteria value)
com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions.Builder getPresolveOptionsBuilder()
com.google.ortools.pdlp.AdaptiveLinesearchParams.Builder getAdaptiveLinesearchParametersBuilder()
Builder setAdaptiveLinesearchParameters(com.google.ortools.pdlp.AdaptiveLinesearchParams value)
Builder setSchedulerType(com.google.ortools.pdlp.SchedulerType value)
com.google.ortools.pdlp.MalitskyPockParamsOrBuilder getMalitskyPockParametersOrBuilder()
com.google.ortools.pdlp.PrimalDualHybridGradientParams buildPartial()
Builder setAdaptiveLinesearchParameters(com.google.ortools.pdlp.AdaptiveLinesearchParams.Builder builderForValue)
com.google.ortools.pdlp.TerminationCriteriaOrBuilder getTerminationCriteriaOrBuilder()
Builder mergePresolveOptions(com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions value)
com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
Builder setLinesearchRule(com.google.ortools.pdlp.PrimalDualHybridGradientParams.LinesearchRule value)
Builder mergeFrom(com.google.ortools.pdlp.PrimalDualHybridGradientParams other)
Builder mergeAdaptiveLinesearchParameters(com.google.ortools.pdlp.AdaptiveLinesearchParams value)
com.google.ortools.pdlp.MalitskyPockParams.Builder getMalitskyPockParametersBuilder()
Builder mergeTerminationCriteria(com.google.ortools.pdlp.TerminationCriteria value)
com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptionsOrBuilder getPresolveOptionsOrBuilder()
com.google.ortools.pdlp.PrimalDualHybridGradientParams build()
com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions buildPartial()
com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions build()
com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions getDefaultInstanceForType()
Builder setGlopParameters(com.google.ortools.glop.GlopParameters.Builder builderForValue)
com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
Builder mergeFrom(com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions other)
Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions parseDelimitedFrom(java.io.InputStream input)
static com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions parseFrom(com.google.protobuf.ByteString data)
static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
static Builder newBuilder(com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions prototype)
Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent)
static com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions parseFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions parseDelimitedFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions getDefaultInstance()
com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions getDefaultInstanceForType()
static com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions parseFrom(java.io.InputStream input)
static com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions parseFrom(byte[] data)
static com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions parseFrom(java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
static com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions parseFrom(java.nio.ByteBuffer data)
static com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions parseFrom(com.google.protobuf.CodedInputStream input)
com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
static com.google.ortools.pdlp.PrimalDualHybridGradientParams parseDelimitedFrom(java.io.InputStream input)
static com.google.ortools.pdlp.PrimalDualHybridGradientParams parseFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.pdlp.PrimalDualHybridGradientParams parseFrom(java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
com.google.ortools.pdlp.PrimalDualHybridGradientParams getDefaultInstanceForType()
Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent)
com.google.ortools.pdlp.TerminationCriteria getTerminationCriteria()
static com.google.ortools.pdlp.PrimalDualHybridGradientParams parseFrom(com.google.protobuf.CodedInputStream input)
com.google.ortools.pdlp.MalitskyPockParams getMalitskyPockParameters()
static com.google.protobuf.Parser< PrimalDualHybridGradientParams > parser()
static com.google.ortools.pdlp.PrimalDualHybridGradientParams parseFrom(byte[] data)
com.google.ortools.pdlp.AdaptiveLinesearchParamsOrBuilder getAdaptiveLinesearchParametersOrBuilder()
static com.google.ortools.pdlp.PrimalDualHybridGradientParams parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.pdlp.PrimalDualHybridGradientParams getDefaultInstance()
static com.google.ortools.pdlp.PrimalDualHybridGradientParams parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
void writeTo(com.google.protobuf.CodedOutputStream output)
com.google.ortools.pdlp.AdaptiveLinesearchParams getAdaptiveLinesearchParameters()
com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptions getPresolveOptions()
com.google.ortools.pdlp.PrimalDualHybridGradientParams.RestartStrategy getRestartStrategy()
com.google.ortools.pdlp.PrimalDualHybridGradientParams.PresolveOptionsOrBuilder getPresolveOptionsOrBuilder()
static Builder newBuilder(com.google.ortools.pdlp.PrimalDualHybridGradientParams prototype)
com.google.ortools.pdlp.PrimalDualHybridGradientParams.LinesearchRule getLinesearchRule()
com.google.ortools.pdlp.TerminationCriteriaOrBuilder getTerminationCriteriaOrBuilder()
static com.google.ortools.pdlp.PrimalDualHybridGradientParams parseFrom(java.io.InputStream input)
static com.google.ortools.pdlp.PrimalDualHybridGradientParams parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.pdlp.PrimalDualHybridGradientParams parseDelimitedFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.pdlp.PrimalDualHybridGradientParams parseFrom(java.nio.ByteBuffer data)
com.google.ortools.pdlp.MalitskyPockParamsOrBuilder getMalitskyPockParametersOrBuilder()
static com.google.ortools.pdlp.PrimalDualHybridGradientParams parseFrom(com.google.protobuf.ByteString data)
com.google.protobuf.Parser< PrimalDualHybridGradientParams > getParserForType()
static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
static com.google.protobuf.Internal.EnumLiteMap< LinesearchRule > internalGetValueMap()
static LinesearchRule valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc)
final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor()
final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType()
static RestartStrategy valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc)
static com.google.protobuf.Internal.EnumLiteMap< RestartStrategy > internalGetValueMap()
final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor()
com.google.ortools.glop.GlopParametersOrBuilder getGlopParametersOrBuilder()