forked from google/or-tools
/
routing_parameters.pb.go
2234 lines (2084 loc) · 136 KB
/
routing_parameters.pb.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// Copyright 2010-2024 Google LLC
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
// Protocol buffer used to parametrize the routing library, in particular the
// search parameters such as first solution heuristics and local search
// neighborhoods.
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.28.1
// protoc v4.25.3
// source: ortools/constraint_solver/routing_parameters.proto
package constraintsolver
import (
sat "github.com/airspacetechnologies/or-tools/go/ortools/sat"
util "github.com/airspacetechnologies/or-tools/go/ortools/util"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
durationpb "google.golang.org/protobuf/types/known/durationpb"
reflect "reflect"
sync "sync"
)
const (
// Verify that this generated code is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
// Verify that runtime/protoimpl is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
// In insertion-based heuristics, describes what positions must be considered
// when inserting a pickup/delivery pair, and in what order they are
// considered.
type RoutingSearchParameters_PairInsertionStrategy int32
const (
// Let the solver decide the set of positions and its ordering.
RoutingSearchParameters_AUTOMATIC RoutingSearchParameters_PairInsertionStrategy = 0
// Consider all positions, by increasing (cost(pickup), cost(delivery)).
RoutingSearchParameters_BEST_PICKUP_THEN_BEST_DELIVERY RoutingSearchParameters_PairInsertionStrategy = 1
// Consider all positions, by increasing by cost(pickup) + cost(delivery).
RoutingSearchParameters_BEST_PICKUP_DELIVERY_PAIR RoutingSearchParameters_PairInsertionStrategy = 2
// Only consider insertion positions that are compatible with the multitour
// property, meaning a series of pickups may only start when the vehicle
// is not carrying any delivery. This setting is designed to explore much
// less possibilities than the full BEST_PICKUP_DELIVERY_PAIR.
// Order by increasing by cost(pickup) + cost(delivery).
RoutingSearchParameters_BEST_PICKUP_DELIVERY_PAIR_MULTITOUR RoutingSearchParameters_PairInsertionStrategy = 3
)
// Enum value maps for RoutingSearchParameters_PairInsertionStrategy.
var (
RoutingSearchParameters_PairInsertionStrategy_name = map[int32]string{
0: "AUTOMATIC",
1: "BEST_PICKUP_THEN_BEST_DELIVERY",
2: "BEST_PICKUP_DELIVERY_PAIR",
3: "BEST_PICKUP_DELIVERY_PAIR_MULTITOUR",
}
RoutingSearchParameters_PairInsertionStrategy_value = map[string]int32{
"AUTOMATIC": 0,
"BEST_PICKUP_THEN_BEST_DELIVERY": 1,
"BEST_PICKUP_DELIVERY_PAIR": 2,
"BEST_PICKUP_DELIVERY_PAIR_MULTITOUR": 3,
}
)
func (x RoutingSearchParameters_PairInsertionStrategy) Enum() *RoutingSearchParameters_PairInsertionStrategy {
p := new(RoutingSearchParameters_PairInsertionStrategy)
*p = x
return p
}
func (x RoutingSearchParameters_PairInsertionStrategy) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (RoutingSearchParameters_PairInsertionStrategy) Descriptor() protoreflect.EnumDescriptor {
return file_ortools_constraint_solver_routing_parameters_proto_enumTypes[0].Descriptor()
}
func (RoutingSearchParameters_PairInsertionStrategy) Type() protoreflect.EnumType {
return &file_ortools_constraint_solver_routing_parameters_proto_enumTypes[0]
}
func (x RoutingSearchParameters_PairInsertionStrategy) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use RoutingSearchParameters_PairInsertionStrategy.Descriptor instead.
func (RoutingSearchParameters_PairInsertionStrategy) EnumDescriptor() ([]byte, []int) {
return file_ortools_constraint_solver_routing_parameters_proto_rawDescGZIP(), []int{0, 0}
}
// Underlying solver to use in dimension scheduling, respectively for
// continuous and mixed models.
type RoutingSearchParameters_SchedulingSolver int32
const (
RoutingSearchParameters_SCHEDULING_UNSET RoutingSearchParameters_SchedulingSolver = 0
RoutingSearchParameters_SCHEDULING_GLOP RoutingSearchParameters_SchedulingSolver = 1
RoutingSearchParameters_SCHEDULING_CP_SAT RoutingSearchParameters_SchedulingSolver = 2
)
// Enum value maps for RoutingSearchParameters_SchedulingSolver.
var (
RoutingSearchParameters_SchedulingSolver_name = map[int32]string{
0: "SCHEDULING_UNSET",
1: "SCHEDULING_GLOP",
2: "SCHEDULING_CP_SAT",
}
RoutingSearchParameters_SchedulingSolver_value = map[string]int32{
"SCHEDULING_UNSET": 0,
"SCHEDULING_GLOP": 1,
"SCHEDULING_CP_SAT": 2,
}
)
func (x RoutingSearchParameters_SchedulingSolver) Enum() *RoutingSearchParameters_SchedulingSolver {
p := new(RoutingSearchParameters_SchedulingSolver)
*p = x
return p
}
func (x RoutingSearchParameters_SchedulingSolver) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (RoutingSearchParameters_SchedulingSolver) Descriptor() protoreflect.EnumDescriptor {
return file_ortools_constraint_solver_routing_parameters_proto_enumTypes[1].Descriptor()
}
func (RoutingSearchParameters_SchedulingSolver) Type() protoreflect.EnumType {
return &file_ortools_constraint_solver_routing_parameters_proto_enumTypes[1]
}
func (x RoutingSearchParameters_SchedulingSolver) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use RoutingSearchParameters_SchedulingSolver.Descriptor instead.
func (RoutingSearchParameters_SchedulingSolver) EnumDescriptor() ([]byte, []int) {
return file_ortools_constraint_solver_routing_parameters_proto_rawDescGZIP(), []int{0, 1}
}
// Parameters defining the search used to solve vehicle routing problems.
//
// If a parameter is unset (or, equivalently, set to its default value),
// then the routing library will pick its preferred value for that parameter
// automatically: this should be the case for most parameters.
// To see those "default" parameters, call GetDefaultRoutingSearchParameters().
// Next ID: 61
type RoutingSearchParameters struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// First solution strategies, used as starting point of local search.
FirstSolutionStrategy FirstSolutionStrategy_Value `protobuf:"varint,1,opt,name=first_solution_strategy,json=firstSolutionStrategy,proto3,enum=operations_research.FirstSolutionStrategy_Value" json:"first_solution_strategy,omitempty"`
// --- Advanced first solutions strategy settings ---
// Don't touch these unless you know what you are doing.
//
// Use filtered version of first solution strategy if available.
UseUnfilteredFirstSolutionStrategy bool `protobuf:"varint,2,opt,name=use_unfiltered_first_solution_strategy,json=useUnfilteredFirstSolutionStrategy,proto3" json:"use_unfiltered_first_solution_strategy,omitempty"`
// Parameters specific to the Savings first solution heuristic.
// Ratio (in ]0, 1]) of neighbors to consider for each node when constructing
// the savings. If unspecified, its value is considered to be 1.0.
SavingsNeighborsRatio float64 `protobuf:"fixed64,14,opt,name=savings_neighbors_ratio,json=savingsNeighborsRatio,proto3" json:"savings_neighbors_ratio,omitempty"`
// The number of neighbors considered for each node in the Savings heuristic
// is chosen so that the space used to store the savings doesn't exceed
// savings_max_memory_usage_bytes, which must be in ]0, 1e10].
// NOTE: If both savings_neighbors_ratio and savings_max_memory_usage_bytes
// are specified, the number of neighbors considered for each node will be the
// minimum of the two numbers determined by these parameters.
SavingsMaxMemoryUsageBytes float64 `protobuf:"fixed64,23,opt,name=savings_max_memory_usage_bytes,json=savingsMaxMemoryUsageBytes,proto3" json:"savings_max_memory_usage_bytes,omitempty"`
// Add savings related to reverse arcs when finding the nearest neighbors
// of the nodes.
SavingsAddReverseArcs bool `protobuf:"varint,15,opt,name=savings_add_reverse_arcs,json=savingsAddReverseArcs,proto3" json:"savings_add_reverse_arcs,omitempty"`
// Coefficient of the cost of the arc for which the saving value is being
// computed:
// Saving(a-->b) = Cost(a-->end) + Cost(start-->b)
// - savings_arc_coefficient * Cost(a-->b)
//
// This parameter must be greater than 0, and its default value is 1.
SavingsArcCoefficient float64 `protobuf:"fixed64,18,opt,name=savings_arc_coefficient,json=savingsArcCoefficient,proto3" json:"savings_arc_coefficient,omitempty"`
// When true, the routes are built in parallel, sequentially otherwise.
SavingsParallelRoutes bool `protobuf:"varint,19,opt,name=savings_parallel_routes,json=savingsParallelRoutes,proto3" json:"savings_parallel_routes,omitempty"`
// Ratio (between 0 and 1) of available vehicles in the model on which
// farthest nodes of the model are inserted as seeds in the
// GlobalCheapestInsertion first solution heuristic.
CheapestInsertionFarthestSeedsRatio float64 `protobuf:"fixed64,16,opt,name=cheapest_insertion_farthest_seeds_ratio,json=cheapestInsertionFarthestSeedsRatio,proto3" json:"cheapest_insertion_farthest_seeds_ratio,omitempty"`
// Ratio (in ]0, 1]) of closest non start/end nodes to consider as neighbors
// for each node when creating new insertions in the parallel/sequential
// cheapest insertion heuristic.
// If not overridden, its default value is 1, meaning all neighbors will be
// considered.
// The neighborhood ratio is coupled with the corresponding min_neighbors
// integer, indicating the minimum number of neighbors to consider for each
// node:
// num_closest_neighbors =
//
// max(min_neighbors, neighbors_ratio * NUM_NON_START_END_NODES)
//
// This minimum number of neighbors must be greater or equal to 1, its
// default value.
//
// Neighbors ratio and minimum number of neighbors for the first solution
// heuristic.
CheapestInsertionFirstSolutionNeighborsRatio float64 `protobuf:"fixed64,21,opt,name=cheapest_insertion_first_solution_neighbors_ratio,json=cheapestInsertionFirstSolutionNeighborsRatio,proto3" json:"cheapest_insertion_first_solution_neighbors_ratio,omitempty"`
CheapestInsertionFirstSolutionMinNeighbors int32 `protobuf:"varint,44,opt,name=cheapest_insertion_first_solution_min_neighbors,json=cheapestInsertionFirstSolutionMinNeighbors,proto3" json:"cheapest_insertion_first_solution_min_neighbors,omitempty"`
// Neighbors ratio and minimum number of neighbors for the heuristic when used
// in a local search operator (see
// local_search_operators.use_global_cheapest_insertion_path_lns and
// local_search_operators.use_global_cheapest_insertion_chain_lns below).
CheapestInsertionLsOperatorNeighborsRatio float64 `protobuf:"fixed64,31,opt,name=cheapest_insertion_ls_operator_neighbors_ratio,json=cheapestInsertionLsOperatorNeighborsRatio,proto3" json:"cheapest_insertion_ls_operator_neighbors_ratio,omitempty"`
CheapestInsertionLsOperatorMinNeighbors int32 `protobuf:"varint,45,opt,name=cheapest_insertion_ls_operator_min_neighbors,json=cheapestInsertionLsOperatorMinNeighbors,proto3" json:"cheapest_insertion_ls_operator_min_neighbors,omitempty"`
// Whether or not to only consider closest neighbors when initializing the
// assignment for the first solution.
CheapestInsertionFirstSolutionUseNeighborsRatioForInitialization bool `protobuf:"varint,46,opt,name=cheapest_insertion_first_solution_use_neighbors_ratio_for_initialization,json=cheapestInsertionFirstSolutionUseNeighborsRatioForInitialization,proto3" json:"cheapest_insertion_first_solution_use_neighbors_ratio_for_initialization,omitempty"`
// Whether or not to consider entries making the nodes/pairs unperformed in
// the GlobalCheapestInsertion heuristic.
CheapestInsertionAddUnperformedEntries bool `protobuf:"varint,40,opt,name=cheapest_insertion_add_unperformed_entries,json=cheapestInsertionAddUnperformedEntries,proto3" json:"cheapest_insertion_add_unperformed_entries,omitempty"`
// Choice of insertion strategy for pickup/delivery pairs, used in local
// cheapest insertion, both first solution heuristic and LNS.
LocalCheapestInsertionPickupDeliveryStrategy RoutingSearchParameters_PairInsertionStrategy `protobuf:"varint,49,opt,name=local_cheapest_insertion_pickup_delivery_strategy,json=localCheapestInsertionPickupDeliveryStrategy,proto3,enum=operations_research.RoutingSearchParameters_PairInsertionStrategy" json:"local_cheapest_insertion_pickup_delivery_strategy,omitempty"`
// Choice of insertion strategy for pickup/delivery pairs, used in local
// cheapest cost insertion, both first solution heuristic and LNS.
LocalCheapestCostInsertionPickupDeliveryStrategy RoutingSearchParameters_PairInsertionStrategy `protobuf:"varint,55,opt,name=local_cheapest_cost_insertion_pickup_delivery_strategy,json=localCheapestCostInsertionPickupDeliveryStrategy,proto3,enum=operations_research.RoutingSearchParameters_PairInsertionStrategy" json:"local_cheapest_cost_insertion_pickup_delivery_strategy,omitempty"`
// If true use minimum matching instead of minimal matching in the
// Christofides algorithm.
ChristofidesUseMinimumMatching bool `protobuf:"varint,30,opt,name=christofides_use_minimum_matching,json=christofidesUseMinimumMatching,proto3" json:"christofides_use_minimum_matching,omitempty"`
// If non zero, a period p indicates that every p node insertions or additions
// to a path, an optimization of the current partial solution will be
// performed. As of 12/2023:
// - this requires that a secondary routing model has been passed to the main
// one,
// - this is only supported by LOCAL_CHEAPEST_INSERTION and
//
// LOCAL_CHEAPEST_COST_INSERTION.
FirstSolutionOptimizationPeriod int32 `protobuf:"varint,59,opt,name=first_solution_optimization_period,json=firstSolutionOptimizationPeriod,proto3" json:"first_solution_optimization_period,omitempty"`
LocalSearchOperators *RoutingSearchParameters_LocalSearchNeighborhoodOperators `protobuf:"bytes,3,opt,name=local_search_operators,json=localSearchOperators,proto3" json:"local_search_operators,omitempty"`
// Neighbors ratio and minimum number of neighbors considered in local
// search operators (see cheapest_insertion_first_solution_neighbors_ratio
// and cheapest_insertion_first_solution_min_neighbors for more information).
LsOperatorNeighborsRatio float64 `protobuf:"fixed64,53,opt,name=ls_operator_neighbors_ratio,json=lsOperatorNeighborsRatio,proto3" json:"ls_operator_neighbors_ratio,omitempty"`
LsOperatorMinNeighbors int32 `protobuf:"varint,54,opt,name=ls_operator_min_neighbors,json=lsOperatorMinNeighbors,proto3" json:"ls_operator_min_neighbors,omitempty"`
// If true, the solver will use multi-armed bandit concatenate operators. It
// dynamically chooses the next neighbor operator in order to get the best
// objective improvement.
UseMultiArmedBanditConcatenateOperators bool `protobuf:"varint,41,opt,name=use_multi_armed_bandit_concatenate_operators,json=useMultiArmedBanditConcatenateOperators,proto3" json:"use_multi_armed_bandit_concatenate_operators,omitempty"`
// Memory coefficient related to the multi-armed bandit compound operator.
// Sets how much the objective improvement of previous accepted neighbors
// influence the current average improvement.
// This parameter should be between 0 and 1.
MultiArmedBanditCompoundOperatorMemoryCoefficient float64 `protobuf:"fixed64,42,opt,name=multi_armed_bandit_compound_operator_memory_coefficient,json=multiArmedBanditCompoundOperatorMemoryCoefficient,proto3" json:"multi_armed_bandit_compound_operator_memory_coefficient,omitempty"`
// Positive parameter defining the exploration coefficient of the multi-armed
// bandit compound operator. Sets how often we explore rarely used and
// unsuccessful in the past operators
MultiArmedBanditCompoundOperatorExplorationCoefficient float64 `protobuf:"fixed64,43,opt,name=multi_armed_bandit_compound_operator_exploration_coefficient,json=multiArmedBanditCompoundOperatorExplorationCoefficient,proto3" json:"multi_armed_bandit_compound_operator_exploration_coefficient,omitempty"`
// Number of expensive arcs to consider cutting in the RelocateExpensiveChain
// neighborhood operator (see
// LocalSearchNeighborhoodOperators.use_relocate_expensive_chain()).
// This parameter must be greater than 2.
// NOTE(user): The number of neighbors generated by the operator for
// relocate_expensive_chain_num_arcs_to_consider = K is around
// K*(K-1)/2 * number_of_routes * number_of_nodes.
RelocateExpensiveChainNumArcsToConsider int32 `protobuf:"varint,20,opt,name=relocate_expensive_chain_num_arcs_to_consider,json=relocateExpensiveChainNumArcsToConsider,proto3" json:"relocate_expensive_chain_num_arcs_to_consider,omitempty"`
// Number of expensive arcs to consider cutting in the
// FilteredHeuristicExpensiveChainLNSOperator operator.
HeuristicExpensiveChainLnsNumArcsToConsider int32 `protobuf:"varint,32,opt,name=heuristic_expensive_chain_lns_num_arcs_to_consider,json=heuristicExpensiveChainLnsNumArcsToConsider,proto3" json:"heuristic_expensive_chain_lns_num_arcs_to_consider,omitempty"`
// Number of closest nodes to consider for each node during the destruction
// phase of the FilteredHeuristicCloseNodesLNSOperator.
HeuristicCloseNodesLnsNumNodes int32 `protobuf:"varint,35,opt,name=heuristic_close_nodes_lns_num_nodes,json=heuristicCloseNodesLnsNumNodes,proto3" json:"heuristic_close_nodes_lns_num_nodes,omitempty"`
// Local search metaheuristics used to guide the search.
LocalSearchMetaheuristic LocalSearchMetaheuristic_Value `protobuf:"varint,4,opt,name=local_search_metaheuristic,json=localSearchMetaheuristic,proto3,enum=operations_research.LocalSearchMetaheuristic_Value" json:"local_search_metaheuristic,omitempty"`
// These are advanced settings which should not be modified unless you know
// what you are doing.
// Lambda coefficient used to penalize arc costs when GUIDED_LOCAL_SEARCH is
// used. Must be positive.
GuidedLocalSearchLambdaCoefficient float64 `protobuf:"fixed64,5,opt,name=guided_local_search_lambda_coefficient,json=guidedLocalSearchLambdaCoefficient,proto3" json:"guided_local_search_lambda_coefficient,omitempty"`
// Whether to reset penalties when a new best solution is found. The effect is
// that a greedy descent is started before the next penalization phase.
GuidedLocalSearchResetPenaltiesOnNewBestSolution bool `protobuf:"varint,51,opt,name=guided_local_search_reset_penalties_on_new_best_solution,json=guidedLocalSearchResetPenaltiesOnNewBestSolution,proto3" json:"guided_local_search_reset_penalties_on_new_best_solution,omitempty"`
// --- Search control ---
//
// If true, the solver should use depth-first search rather than local search
// to solve the problem.
UseDepthFirstSearch bool `protobuf:"varint,6,opt,name=use_depth_first_search,json=useDepthFirstSearch,proto3" json:"use_depth_first_search,omitempty"`
// If true, use the CP solver to find a solution. Either local or depth-first
// search will be used depending on the value of use_depth_first_search. Will
// be run before the CP-SAT solver (cf. use_cp_sat).
UseCp util.OptionalBoolean `protobuf:"varint,28,opt,name=use_cp,json=useCp,proto3,enum=operations_research.OptionalBoolean" json:"use_cp,omitempty"`
// If true, use the CP-SAT solver to find a solution. If use_cp is also true,
// the CP-SAT solver will be run after the CP solver if there is time
// remaining and will use the CP solution as a hint for the CP-SAT search.
// As of 5/2019, only TSP models can be solved.
UseCpSat util.OptionalBoolean `protobuf:"varint,27,opt,name=use_cp_sat,json=useCpSat,proto3,enum=operations_research.OptionalBoolean" json:"use_cp_sat,omitempty"`
// If true, use the CP-SAT solver to find a solution on generalized routing
// model. If use_cp is also true, the CP-SAT solver will be run after the CP
// solver if there is time remaining and will use the CP solution as a hint
// for the CP-SAT search.
UseGeneralizedCpSat util.OptionalBoolean `protobuf:"varint,47,opt,name=use_generalized_cp_sat,json=useGeneralizedCpSat,proto3,enum=operations_research.OptionalBoolean" json:"use_generalized_cp_sat,omitempty"`
// If use_cp_sat or use_generalized_cp_sat is true, contains the SAT algorithm
// parameters which will be used.
SatParameters *sat.SatParameters `protobuf:"bytes,48,opt,name=sat_parameters,json=satParameters,proto3" json:"sat_parameters,omitempty"`
// If use_cp_sat or use_generalized_cp_sat is true, will report intermediate
// solutions found by CP-SAT to solution listeners.
ReportIntermediateCpSatSolutions bool `protobuf:"varint,56,opt,name=report_intermediate_cp_sat_solutions,json=reportIntermediateCpSatSolutions,proto3" json:"report_intermediate_cp_sat_solutions,omitempty"`
// If model.Size() is less than the threshold and that no solution has been
// found, attempt a pass with CP-SAT.
FallbackToCpSatSizeThreshold int32 `protobuf:"varint,52,opt,name=fallback_to_cp_sat_size_threshold,json=fallbackToCpSatSizeThreshold,proto3" json:"fallback_to_cp_sat_size_threshold,omitempty"`
ContinuousSchedulingSolver RoutingSearchParameters_SchedulingSolver `protobuf:"varint,33,opt,name=continuous_scheduling_solver,json=continuousSchedulingSolver,proto3,enum=operations_research.RoutingSearchParameters_SchedulingSolver" json:"continuous_scheduling_solver,omitempty"`
MixedIntegerSchedulingSolver RoutingSearchParameters_SchedulingSolver `protobuf:"varint,34,opt,name=mixed_integer_scheduling_solver,json=mixedIntegerSchedulingSolver,proto3,enum=operations_research.RoutingSearchParameters_SchedulingSolver" json:"mixed_integer_scheduling_solver,omitempty"`
// Setting this to true completely disables the LP and MIP scheduling in the
// solver. This overrides the 2 SchedulingSolver options above.
DisableSchedulingBewareThisMayDegradePerformance *bool `protobuf:"varint,50,opt,name=disable_scheduling_beware_this_may_degrade_performance,json=disableSchedulingBewareThisMayDegradePerformance,proto3,oneof" json:"disable_scheduling_beware_this_may_degrade_performance,omitempty"`
// Minimum step by which the solution must be improved in local search. 0
// means "unspecified". If this value is fractional, it will get rounded to
// the nearest integer.
OptimizationStep float64 `protobuf:"fixed64,7,opt,name=optimization_step,json=optimizationStep,proto3" json:"optimization_step,omitempty"`
// Number of solutions to collect during the search. Corresponds to the best
// solutions found during the search. 0 means "unspecified".
NumberOfSolutionsToCollect int32 `protobuf:"varint,17,opt,name=number_of_solutions_to_collect,json=numberOfSolutionsToCollect,proto3" json:"number_of_solutions_to_collect,omitempty"`
// -- Search limits --
// Limit to the number of solutions generated during the search. 0 means
// "unspecified".
SolutionLimit int64 `protobuf:"varint,8,opt,name=solution_limit,json=solutionLimit,proto3" json:"solution_limit,omitempty"`
// Limit to the time spent in the search.
TimeLimit *durationpb.Duration `protobuf:"bytes,9,opt,name=time_limit,json=timeLimit,proto3" json:"time_limit,omitempty"`
// Limit to the time spent in the completion search for each local search
// neighbor.
LnsTimeLimit *durationpb.Duration `protobuf:"bytes,10,opt,name=lns_time_limit,json=lnsTimeLimit,proto3" json:"lns_time_limit,omitempty"`
// Ratio of the overall time limit spent in a secondary LS phase with only
// intra-route and insertion operators, meant to "cleanup" the current
// solution before stopping the search.
// TODO(user): Since these operators are very fast, add a parameter to cap
// the max time allocated for this second phase (e.g.
// Duration max_secondary_ls_time_limit).
SecondaryLsTimeLimitRatio float64 `protobuf:"fixed64,57,opt,name=secondary_ls_time_limit_ratio,json=secondaryLsTimeLimitRatio,proto3" json:"secondary_ls_time_limit_ratio,omitempty"`
// The improvement search limit is added to the solver if the following
// parameters are set.
ImprovementLimitParameters *RoutingSearchParameters_ImprovementSearchLimitParameters `protobuf:"bytes,37,opt,name=improvement_limit_parameters,json=improvementLimitParameters,proto3" json:"improvement_limit_parameters,omitempty"`
// --- Propagation control ---
// These are advanced settings which should not be modified unless you know
// what you are doing.
//
// Use constraints with full propagation in routing model (instead of 'light'
// propagation only). Full propagation is only necessary when using
// depth-first search or for models which require strong propagation to
// finalize the value of secondary variables.
// Changing this setting to true will slow down the search in most cases and
// increase memory consumption in all cases.
UseFullPropagation bool `protobuf:"varint,11,opt,name=use_full_propagation,json=useFullPropagation,proto3" json:"use_full_propagation,omitempty"`
// --- Miscellaneous ---
// Some of these are advanced settings which should not be modified unless you
// know what you are doing.
//
// Activates search logging. For each solution found during the search, the
// following will be displayed: its objective value, the maximum objective
// value since the beginning of the search, the elapsed time since the
// beginning of the search, the number of branches explored in the search
// tree, the number of failures in the search tree, the depth of the search
// tree, the number of local search neighbors explored, the number of local
// search neighbors filtered by local search filters, the number of local
// search neighbors accepted, the total memory used and the percentage of the
// search done.
LogSearch bool `protobuf:"varint,13,opt,name=log_search,json=logSearch,proto3" json:"log_search,omitempty"`
// In logs, cost values will be scaled and offset by the given values in the
// following way: log_cost_scaling_factor * (cost + log_cost_offset)
LogCostScalingFactor float64 `protobuf:"fixed64,22,opt,name=log_cost_scaling_factor,json=logCostScalingFactor,proto3" json:"log_cost_scaling_factor,omitempty"`
LogCostOffset float64 `protobuf:"fixed64,29,opt,name=log_cost_offset,json=logCostOffset,proto3" json:"log_cost_offset,omitempty"`
// In logs, this tag will be appended to each line corresponding to a new
// solution. Useful to sort out logs when several solves are run in parallel.
LogTag string `protobuf:"bytes,36,opt,name=log_tag,json=logTag,proto3" json:"log_tag,omitempty"`
// Whether the solver should use an Iterated Local Search approach to solve
// the problem.
UseIteratedLocalSearch bool `protobuf:"varint,58,opt,name=use_iterated_local_search,json=useIteratedLocalSearch,proto3" json:"use_iterated_local_search,omitempty"`
// Iterated Local Search parameters.
IteratedLocalSearchParameters *IteratedLocalSearchParameters `protobuf:"bytes,60,opt,name=iterated_local_search_parameters,json=iteratedLocalSearchParameters,proto3" json:"iterated_local_search_parameters,omitempty"`
}
func (x *RoutingSearchParameters) Reset() {
*x = RoutingSearchParameters{}
if protoimpl.UnsafeEnabled {
mi := &file_ortools_constraint_solver_routing_parameters_proto_msgTypes[0]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *RoutingSearchParameters) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*RoutingSearchParameters) ProtoMessage() {}
func (x *RoutingSearchParameters) ProtoReflect() protoreflect.Message {
mi := &file_ortools_constraint_solver_routing_parameters_proto_msgTypes[0]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use RoutingSearchParameters.ProtoReflect.Descriptor instead.
func (*RoutingSearchParameters) Descriptor() ([]byte, []int) {
return file_ortools_constraint_solver_routing_parameters_proto_rawDescGZIP(), []int{0}
}
func (x *RoutingSearchParameters) GetFirstSolutionStrategy() FirstSolutionStrategy_Value {
if x != nil {
return x.FirstSolutionStrategy
}
return FirstSolutionStrategy_UNSET
}
func (x *RoutingSearchParameters) GetUseUnfilteredFirstSolutionStrategy() bool {
if x != nil {
return x.UseUnfilteredFirstSolutionStrategy
}
return false
}
func (x *RoutingSearchParameters) GetSavingsNeighborsRatio() float64 {
if x != nil {
return x.SavingsNeighborsRatio
}
return 0
}
func (x *RoutingSearchParameters) GetSavingsMaxMemoryUsageBytes() float64 {
if x != nil {
return x.SavingsMaxMemoryUsageBytes
}
return 0
}
func (x *RoutingSearchParameters) GetSavingsAddReverseArcs() bool {
if x != nil {
return x.SavingsAddReverseArcs
}
return false
}
func (x *RoutingSearchParameters) GetSavingsArcCoefficient() float64 {
if x != nil {
return x.SavingsArcCoefficient
}
return 0
}
func (x *RoutingSearchParameters) GetSavingsParallelRoutes() bool {
if x != nil {
return x.SavingsParallelRoutes
}
return false
}
func (x *RoutingSearchParameters) GetCheapestInsertionFarthestSeedsRatio() float64 {
if x != nil {
return x.CheapestInsertionFarthestSeedsRatio
}
return 0
}
func (x *RoutingSearchParameters) GetCheapestInsertionFirstSolutionNeighborsRatio() float64 {
if x != nil {
return x.CheapestInsertionFirstSolutionNeighborsRatio
}
return 0
}
func (x *RoutingSearchParameters) GetCheapestInsertionFirstSolutionMinNeighbors() int32 {
if x != nil {
return x.CheapestInsertionFirstSolutionMinNeighbors
}
return 0
}
func (x *RoutingSearchParameters) GetCheapestInsertionLsOperatorNeighborsRatio() float64 {
if x != nil {
return x.CheapestInsertionLsOperatorNeighborsRatio
}
return 0
}
func (x *RoutingSearchParameters) GetCheapestInsertionLsOperatorMinNeighbors() int32 {
if x != nil {
return x.CheapestInsertionLsOperatorMinNeighbors
}
return 0
}
func (x *RoutingSearchParameters) GetCheapestInsertionFirstSolutionUseNeighborsRatioForInitialization() bool {
if x != nil {
return x.CheapestInsertionFirstSolutionUseNeighborsRatioForInitialization
}
return false
}
func (x *RoutingSearchParameters) GetCheapestInsertionAddUnperformedEntries() bool {
if x != nil {
return x.CheapestInsertionAddUnperformedEntries
}
return false
}
func (x *RoutingSearchParameters) GetLocalCheapestInsertionPickupDeliveryStrategy() RoutingSearchParameters_PairInsertionStrategy {
if x != nil {
return x.LocalCheapestInsertionPickupDeliveryStrategy
}
return RoutingSearchParameters_AUTOMATIC
}
func (x *RoutingSearchParameters) GetLocalCheapestCostInsertionPickupDeliveryStrategy() RoutingSearchParameters_PairInsertionStrategy {
if x != nil {
return x.LocalCheapestCostInsertionPickupDeliveryStrategy
}
return RoutingSearchParameters_AUTOMATIC
}
func (x *RoutingSearchParameters) GetChristofidesUseMinimumMatching() bool {
if x != nil {
return x.ChristofidesUseMinimumMatching
}
return false
}
func (x *RoutingSearchParameters) GetFirstSolutionOptimizationPeriod() int32 {
if x != nil {
return x.FirstSolutionOptimizationPeriod
}
return 0
}
func (x *RoutingSearchParameters) GetLocalSearchOperators() *RoutingSearchParameters_LocalSearchNeighborhoodOperators {
if x != nil {
return x.LocalSearchOperators
}
return nil
}
func (x *RoutingSearchParameters) GetLsOperatorNeighborsRatio() float64 {
if x != nil {
return x.LsOperatorNeighborsRatio
}
return 0
}
func (x *RoutingSearchParameters) GetLsOperatorMinNeighbors() int32 {
if x != nil {
return x.LsOperatorMinNeighbors
}
return 0
}
func (x *RoutingSearchParameters) GetUseMultiArmedBanditConcatenateOperators() bool {
if x != nil {
return x.UseMultiArmedBanditConcatenateOperators
}
return false
}
func (x *RoutingSearchParameters) GetMultiArmedBanditCompoundOperatorMemoryCoefficient() float64 {
if x != nil {
return x.MultiArmedBanditCompoundOperatorMemoryCoefficient
}
return 0
}
func (x *RoutingSearchParameters) GetMultiArmedBanditCompoundOperatorExplorationCoefficient() float64 {
if x != nil {
return x.MultiArmedBanditCompoundOperatorExplorationCoefficient
}
return 0
}
func (x *RoutingSearchParameters) GetRelocateExpensiveChainNumArcsToConsider() int32 {
if x != nil {
return x.RelocateExpensiveChainNumArcsToConsider
}
return 0
}
func (x *RoutingSearchParameters) GetHeuristicExpensiveChainLnsNumArcsToConsider() int32 {
if x != nil {
return x.HeuristicExpensiveChainLnsNumArcsToConsider
}
return 0
}
func (x *RoutingSearchParameters) GetHeuristicCloseNodesLnsNumNodes() int32 {
if x != nil {
return x.HeuristicCloseNodesLnsNumNodes
}
return 0
}
func (x *RoutingSearchParameters) GetLocalSearchMetaheuristic() LocalSearchMetaheuristic_Value {
if x != nil {
return x.LocalSearchMetaheuristic
}
return LocalSearchMetaheuristic_UNSET
}
func (x *RoutingSearchParameters) GetGuidedLocalSearchLambdaCoefficient() float64 {
if x != nil {
return x.GuidedLocalSearchLambdaCoefficient
}
return 0
}
func (x *RoutingSearchParameters) GetGuidedLocalSearchResetPenaltiesOnNewBestSolution() bool {
if x != nil {
return x.GuidedLocalSearchResetPenaltiesOnNewBestSolution
}
return false
}
func (x *RoutingSearchParameters) GetUseDepthFirstSearch() bool {
if x != nil {
return x.UseDepthFirstSearch
}
return false
}
func (x *RoutingSearchParameters) GetUseCp() util.OptionalBoolean {
if x != nil {
return x.UseCp
}
return util.OptionalBoolean(0)
}
func (x *RoutingSearchParameters) GetUseCpSat() util.OptionalBoolean {
if x != nil {
return x.UseCpSat
}
return util.OptionalBoolean(0)
}
func (x *RoutingSearchParameters) GetUseGeneralizedCpSat() util.OptionalBoolean {
if x != nil {
return x.UseGeneralizedCpSat
}
return util.OptionalBoolean(0)
}
func (x *RoutingSearchParameters) GetSatParameters() *sat.SatParameters {
if x != nil {
return x.SatParameters
}
return nil
}
func (x *RoutingSearchParameters) GetReportIntermediateCpSatSolutions() bool {
if x != nil {
return x.ReportIntermediateCpSatSolutions
}
return false
}
func (x *RoutingSearchParameters) GetFallbackToCpSatSizeThreshold() int32 {
if x != nil {
return x.FallbackToCpSatSizeThreshold
}
return 0
}
func (x *RoutingSearchParameters) GetContinuousSchedulingSolver() RoutingSearchParameters_SchedulingSolver {
if x != nil {
return x.ContinuousSchedulingSolver
}
return RoutingSearchParameters_SCHEDULING_UNSET
}
func (x *RoutingSearchParameters) GetMixedIntegerSchedulingSolver() RoutingSearchParameters_SchedulingSolver {
if x != nil {
return x.MixedIntegerSchedulingSolver
}
return RoutingSearchParameters_SCHEDULING_UNSET
}
func (x *RoutingSearchParameters) GetDisableSchedulingBewareThisMayDegradePerformance() bool {
if x != nil && x.DisableSchedulingBewareThisMayDegradePerformance != nil {
return *x.DisableSchedulingBewareThisMayDegradePerformance
}
return false
}
func (x *RoutingSearchParameters) GetOptimizationStep() float64 {
if x != nil {
return x.OptimizationStep
}
return 0
}
func (x *RoutingSearchParameters) GetNumberOfSolutionsToCollect() int32 {
if x != nil {
return x.NumberOfSolutionsToCollect
}
return 0
}
func (x *RoutingSearchParameters) GetSolutionLimit() int64 {
if x != nil {
return x.SolutionLimit
}
return 0
}
func (x *RoutingSearchParameters) GetTimeLimit() *durationpb.Duration {
if x != nil {
return x.TimeLimit
}
return nil
}
func (x *RoutingSearchParameters) GetLnsTimeLimit() *durationpb.Duration {
if x != nil {
return x.LnsTimeLimit
}
return nil
}
func (x *RoutingSearchParameters) GetSecondaryLsTimeLimitRatio() float64 {
if x != nil {
return x.SecondaryLsTimeLimitRatio
}
return 0
}
func (x *RoutingSearchParameters) GetImprovementLimitParameters() *RoutingSearchParameters_ImprovementSearchLimitParameters {
if x != nil {
return x.ImprovementLimitParameters
}
return nil
}
func (x *RoutingSearchParameters) GetUseFullPropagation() bool {
if x != nil {
return x.UseFullPropagation
}
return false
}
func (x *RoutingSearchParameters) GetLogSearch() bool {
if x != nil {
return x.LogSearch
}
return false
}
func (x *RoutingSearchParameters) GetLogCostScalingFactor() float64 {
if x != nil {
return x.LogCostScalingFactor
}
return 0
}
func (x *RoutingSearchParameters) GetLogCostOffset() float64 {
if x != nil {
return x.LogCostOffset
}
return 0
}
func (x *RoutingSearchParameters) GetLogTag() string {
if x != nil {
return x.LogTag
}
return ""
}
func (x *RoutingSearchParameters) GetUseIteratedLocalSearch() bool {
if x != nil {
return x.UseIteratedLocalSearch
}
return false
}
func (x *RoutingSearchParameters) GetIteratedLocalSearchParameters() *IteratedLocalSearchParameters {
if x != nil {
return x.IteratedLocalSearchParameters
}
return nil
}
// Parameters which have to be set when creating a RoutingModel.
type RoutingModelParameters struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Parameters to use in the underlying constraint solver.
SolverParameters *ConstraintSolverParameters `protobuf:"bytes,1,opt,name=solver_parameters,json=solverParameters,proto3" json:"solver_parameters,omitempty"`
// Advanced settings.
// If set to true reduction of the underlying constraint model will be
// attempted when all vehicles have exactly the same cost structure. This can
// result in significant speedups.
ReduceVehicleCostModel bool `protobuf:"varint,2,opt,name=reduce_vehicle_cost_model,json=reduceVehicleCostModel,proto3" json:"reduce_vehicle_cost_model,omitempty"`
// Cache callback calls if the number of nodes in the model is less or equal
// to this value.
MaxCallbackCacheSize int32 `protobuf:"varint,3,opt,name=max_callback_cache_size,json=maxCallbackCacheSize,proto3" json:"max_callback_cache_size,omitempty"`
}
func (x *RoutingModelParameters) Reset() {
*x = RoutingModelParameters{}
if protoimpl.UnsafeEnabled {
mi := &file_ortools_constraint_solver_routing_parameters_proto_msgTypes[1]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *RoutingModelParameters) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*RoutingModelParameters) ProtoMessage() {}
func (x *RoutingModelParameters) ProtoReflect() protoreflect.Message {
mi := &file_ortools_constraint_solver_routing_parameters_proto_msgTypes[1]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use RoutingModelParameters.ProtoReflect.Descriptor instead.
func (*RoutingModelParameters) Descriptor() ([]byte, []int) {
return file_ortools_constraint_solver_routing_parameters_proto_rawDescGZIP(), []int{1}
}
func (x *RoutingModelParameters) GetSolverParameters() *ConstraintSolverParameters {
if x != nil {
return x.SolverParameters
}
return nil
}
func (x *RoutingModelParameters) GetReduceVehicleCostModel() bool {
if x != nil {
return x.ReduceVehicleCostModel
}
return false
}
func (x *RoutingModelParameters) GetMaxCallbackCacheSize() int32 {
if x != nil {
return x.MaxCallbackCacheSize
}
return 0
}
// Local search neighborhood operators used to build a solutions neighborhood.
// Next ID: 35
type RoutingSearchParameters_LocalSearchNeighborhoodOperators struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// --- Inter-route operators ---
// Operator which moves a single node to another position.
// Possible neighbors for the path 1 -> 2 -> 3 -> 4 -> 5
// (where (1, 5) are first and last nodes of the path and can therefore not
// be moved):
//
// 1 -> 3 -> [2] -> 4 -> 5
// 1 -> 3 -> 4 -> [2] -> 5
// 1 -> 2 -> 4 -> [3] -> 5
// 1 -> [4] -> 2 -> 3 -> 5
UseRelocate util.OptionalBoolean `protobuf:"varint,1,opt,name=use_relocate,json=useRelocate,proto3,enum=operations_research.OptionalBoolean" json:"use_relocate,omitempty"`
// Operator which moves a pair of pickup and delivery nodes to another
// position where the first node of the pair must be before the second node
// on the same path. Compared to the light_relocate_pair operator, tries all
// possible positions of insertion of a pair (not only after another pair).
// Possible neighbors for the path 1 -> A -> B -> 2 -> 3 (where (1, 3) are
// first and last nodes of the path and can therefore not be moved, and
// (A, B) is a pair of nodes):
//
// 1 -> [A] -> 2 -> [B] -> 3
// 1 -> 2 -> [A] -> [B] -> 3
UseRelocatePair util.OptionalBoolean `protobuf:"varint,2,opt,name=use_relocate_pair,json=useRelocatePair,proto3,enum=operations_research.OptionalBoolean" json:"use_relocate_pair,omitempty"`
// Operator which moves a pair of pickup and delivery nodes after another
// pair.
// Possible neighbors for paths 1 -> A -> B -> 2, 3 -> C -> D -> 4 (where
// (1, 2) and (3, 4) are first and last nodes of paths and can therefore not
// be moved, and (A, B) and (C, D) are pair of nodes):
//
// 1 -> 2, 3 -> C -> [A] -> D -> [B] -> 4
// 1 -> A -> [C] -> B -> [D] -> 2, 3 -> 4
UseLightRelocatePair util.OptionalBoolean `protobuf:"varint,24,opt,name=use_light_relocate_pair,json=useLightRelocatePair,proto3,enum=operations_research.OptionalBoolean" json:"use_light_relocate_pair,omitempty"`
// Relocate neighborhood which moves chains of neighbors.
// The operator starts by relocating a node n after a node m, then continues
// moving nodes which were after n as long as the "cost" added is less than
// the "cost" of the arc (m, n). If the new chain doesn't respect the domain
// of next variables, it will try reordering the nodes until it finds a
// valid path.
// Possible neighbors for path 1 -> A -> B -> C -> D -> E -> 2 (where (1, 2)
// are first and last nodes of the path and can therefore not be moved, A
// must be performed before B, and A, D and E are located at the same
// place):
// 1 -> A -> C -> [B] -> D -> E -> 2
// 1 -> A -> C -> D -> [B] -> E -> 2
// 1 -> A -> C -> D -> E -> [B] -> 2
// 1 -> A -> B -> D -> [C] -> E -> 2
// 1 -> A -> B -> D -> E -> [C] -> 2
// 1 -> A -> [D] -> [E] -> B -> C -> 2
// 1 -> A -> B -> [D] -> [E] -> C -> 2
// 1 -> A -> [E] -> B -> C -> D -> 2
// 1 -> A -> B -> [E] -> C -> D -> 2
// 1 -> A -> B -> C -> [E] -> D -> 2
// This operator is extremely useful to move chains of nodes which are
// located at the same place (for instance nodes part of a same stop).
UseRelocateNeighbors util.OptionalBoolean `protobuf:"varint,3,opt,name=use_relocate_neighbors,json=useRelocateNeighbors,proto3,enum=operations_research.OptionalBoolean" json:"use_relocate_neighbors,omitempty"`
// Relocate neighborhood that moves subpaths all pickup and delivery
// pairs have both pickup and delivery inside the subpath or both outside
// the subpath. For instance, for given paths:
// 0 -> A -> B -> A' -> B' -> 5 -> 6 -> 8
// 7 -> 9
// Pairs (A,A') and (B,B') are interleaved, so the expected neighbors are:
// 0 -> 5 -> A -> B -> A' -> B' -> 6 -> 8
// 7 -> 9
//
// 0 -> 5 -> 6 -> A -> B -> A' -> B' -> 8
// 7 -> 9
//
// 0 -> 5 -> 6 -> 8
// 7 -> A -> B -> A' -> B' -> 9
UseRelocateSubtrip util.OptionalBoolean `protobuf:"varint,25,opt,name=use_relocate_subtrip,json=useRelocateSubtrip,proto3,enum=operations_research.OptionalBoolean" json:"use_relocate_subtrip,omitempty"`
// Operator which exchanges the positions of two nodes.
// Possible neighbors for the path 1 -> 2 -> 3 -> 4 -> 5
// (where (1, 5) are first and last nodes of the path and can therefore not
// be moved):
//
// 1 -> [3] -> [2] -> 4 -> 5
// 1 -> [4] -> 3 -> [2] -> 5
// 1 -> 2 -> [4] -> [3] -> 5
UseExchange util.OptionalBoolean `protobuf:"varint,4,opt,name=use_exchange,json=useExchange,proto3,enum=operations_research.OptionalBoolean" json:"use_exchange,omitempty"`
// Operator which exchanges the positions of two pair of nodes. Pairs
// correspond to the pickup and delivery pairs defined in the routing model.
// Possible neighbor for the paths
// 1 -> A -> B -> 2 -> 3 and 4 -> C -> D -> 5
// (where (1, 3) and (4, 5) are first and last nodes of the paths and can
// therefore not be moved, and (A, B) and (C,D) are pairs of nodes):
//
// 1 -> [C] -> [D] -> 2 -> 3, 4 -> [A] -> [B] -> 5
UseExchangePair util.OptionalBoolean `protobuf:"varint,22,opt,name=use_exchange_pair,json=useExchangePair,proto3,enum=operations_research.OptionalBoolean" json:"use_exchange_pair,omitempty"`
// Operator which exchanges subtrips associated to two pairs of nodes,
// see use_relocate_subtrip for a definition of subtrips.
UseExchangeSubtrip util.OptionalBoolean `protobuf:"varint,26,opt,name=use_exchange_subtrip,json=useExchangeSubtrip,proto3,enum=operations_research.OptionalBoolean" json:"use_exchange_subtrip,omitempty"`
// Operator which cross exchanges the starting chains of 2 paths, including
// exchanging the whole paths.
// First and last nodes are not moved.
// Possible neighbors for the paths 1 -> 2 -> 3 -> 4 -> 5 and 6 -> 7 -> 8
// (where (1, 5) and (6, 8) are first and last nodes of the paths and can
// therefore not be moved):
//
// 1 -> [7] -> 3 -> 4 -> 5 6 -> [2] -> 8
// 1 -> [7] -> 4 -> 5 6 -> [2 -> 3] -> 8
// 1 -> [7] -> 5 6 -> [2 -> 3 -> 4] -> 8
UseCross util.OptionalBoolean `protobuf:"varint,5,opt,name=use_cross,json=useCross,proto3,enum=operations_research.OptionalBoolean" json:"use_cross,omitempty"`
// Not implemented yet. TODO(b/68128619): Implement.
UseCrossExchange util.OptionalBoolean `protobuf:"varint,6,opt,name=use_cross_exchange,json=useCrossExchange,proto3,enum=operations_research.OptionalBoolean" json:"use_cross_exchange,omitempty"`
// Operator which detects the relocate_expensive_chain_num_arcs_to_consider
// most expensive arcs on a path, and moves the chain resulting from cutting
// pairs of arcs among these to another position.
// Possible neighbors for paths 1 -> 2 (empty) and
// 3 -> A ------> B --> C -----> D -> 4 (where A -> B and C -> D are the 2
// most expensive arcs, and the chain resulting from breaking them is
// B -> C):
//
// 1 -> [B -> C] -> 2 3 -> A -> D -> 4
// 1 -> 2 3 -> [B -> C] -> A -> D -> 4
// 1 -> 2 3 -> A -> D -> [B -> C] -> 4
UseRelocateExpensiveChain util.OptionalBoolean `protobuf:"varint,23,opt,name=use_relocate_expensive_chain,json=useRelocateExpensiveChain,proto3,enum=operations_research.OptionalBoolean" json:"use_relocate_expensive_chain,omitempty"`
// --- Intra-route operators ---
// Operator which reverses a subchain of a path. It is called TwoOpt
// because it breaks two arcs on the path; resulting paths are called
// two-optimal.
// Possible neighbors for the path 1 -> 2 -> 3 -> 4 -> 5