Google OR-Tools v9.11
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
ortools.constraint_solver.pywrapcp.LocalSearchOperator Class Reference
Inheritance diagram for ortools.constraint_solver.pywrapcp.LocalSearchOperator:
ortools.constraint_solver.pywrapcp.BaseObject ortools.constraint_solver.pywrapcp.IntVarLocalSearchOperator ortools.constraint_solver.pywrapcp.BaseLns ortools.constraint_solver.pywrapcp.ChangeValue ortools.constraint_solver.pywrapcp.PathOperator

Public Member Functions

 __init__ (self, *args, **kwargs)
 
 NextNeighbor (self, delta, deltadelta)
 
 Start (self, assignment)
 
 __disown__ (self)
 
- Public Member Functions inherited from ortools.constraint_solver.pywrapcp.BaseObject
 DebugString (self)
 
 __str__ (self)
 
 __repr__ (self)
 

Properties

 thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
 
- Properties inherited from ortools.constraint_solver.pywrapcp.BaseObject
 thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
 

Detailed Description

The base class for all local search operators.

A local search operator is an object that defines the neighborhood of a
solution. In other words, a neighborhood is the set of solutions which can
be reached from a given solution using an operator.

The behavior of the LocalSearchOperator class is similar to iterators.
The operator is synchronized with an assignment (gives the
current values of the variables); this is done in the Start() method.

Then one can iterate over the neighbors using the MakeNextNeighbor method.
This method returns an assignment which represents the incremental changes
to the current solution. It also returns a second assignment representing
the changes to the last solution defined by the neighborhood operator; this
assignment is empty if the neighborhood operator cannot track this
information.

Definition at line 3953 of file pywrapcp.py.

Constructor & Destructor Documentation

◆ __init__()

ortools.constraint_solver.pywrapcp.LocalSearchOperator.__init__ ( self,
* args,
** kwargs )

Member Function Documentation

◆ __disown__()

ortools.constraint_solver.pywrapcp.LocalSearchOperator.__disown__ ( self)

◆ NextNeighbor()

ortools.constraint_solver.pywrapcp.LocalSearchOperator.NextNeighbor ( self,
delta,
deltadelta )

Reimplemented in ortools.constraint_solver.pywrapcp.IntVarLocalSearchOperator.

Definition at line 3979 of file pywrapcp.py.

◆ Start()

ortools.constraint_solver.pywrapcp.LocalSearchOperator.Start ( self,
assignment )

Reimplemented in ortools.constraint_solver.pywrapcp.IntVarLocalSearchOperator.

Definition at line 3982 of file pywrapcp.py.

Property Documentation

◆ thisown

ortools.constraint_solver.pywrapcp.LocalSearchOperator.thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
static

Definition at line 3973 of file pywrapcp.py.


The documentation for this class was generated from the following file: