|
FRODO Version 2.19.1
An open-source framework for Distributed Constraint Optimization (DCOP)
|
Distributed algorithm to compute one variable linear ordering per connected component in the constraint graph. More...

Classes | |
| interface | Heuristic |
| Variable ordering heuristic. More... | |
| class | MaxWidthMinDom |
| A heuristic that maximizes the number of neighbors already in the order, breaking ties by minimizing the domain size, and then by variable name. More... | |
| class | ComponentInfo |
| All relevant information about a connected component of the constraint graph. More... | |
Public Member Functions | |
| LinearOrdering (Element parameters, DCOPProblemInterface< V, U > problem) | |
| The constructor called in "statistics gatherer" mode. | |
| LinearOrdering (DCOPProblemInterface< V, U > problem, Element parameters) | |
| Constructor. | |
| void | reset () |
| void | getStatsFromQueue (Queue queue) |
| void | setQueue (Queue queue) |
| void | setSilent (boolean silent) |
| Collection< MessageType > | getMsgTypes () |
| void | notifyIn (Message msg) |
| Public Member Functions inherited from frodo2.communication.IncomingMsgPolicyInterface< T > | |
| default void | notifyIn (Message msg, Object toAgent) |
| Notifies the listener of an incoming message. | |
Static Public Attributes | |
| static MessageType | START_MSG_TYPE = AgentInterface.START_AGENT |
| The type of the message telling the module to start. | |
Static Package Attributes | |
| static final MessageType | REQUEST_MSG_TYPE = new MessageType ("VarOrdering", "LinearOrdering", "NextVarRequest") |
| The type of the messages sent to request proposals for the next variable to put in the order. | |
| static final MessageType | PROPOSAL_MSG_TYPE = new MessageType ("VarOrdering", "LinearOrdering", "NextVarProposal") |
| The type of the messages containing a proposal for the next variable to put in the order. | |
| static final MessageType | NEXT_VAR_MSG_TYPE = new MessageType ("VarOrdering", "LinearOrdering", "NextVarChosen") |
| The type of the messages notifying an agent that one of its variable is next in the order. | |
Private Member Functions | |
| void | init () |
| Parses the problem. | |
| void | printOrder () |
| Prints the variable order in DOT format. | |
Private Attributes | |
| Queue | queue |
| This module's queue. | |
| boolean | silent = false |
| Whether the stats gatherer should display the resulting linear order. | |
| String | dotRendererClass |
| Renderer to display DOT code. | |
| DCOPProblemInterface< V, U > | problem |
| The problem. | |
| boolean | started = false |
| Whether the module has already started the algorithm. | |
| int | countdown |
| The number of my variables for which I have not yet received the output of VariableElection. | |
| HashMap< Comparable<?>, ComponentInfo > | compInfos |
| The information about each connected component in the constraint graph. | |
| String | myID |
| This agent's name. | |
| Set< String > | allAgents |
| The set of all agents in the problem. | |
| ArrayList< RequestMsg > | pendingMsgs |
| A list of pending requests. | |
| Heuristic< IntIntStringTuple > | heuristic |
| The heuristic. | |
| Map< String, Set< String > > | agentNeighborhoods |
| For each internal variable, its list of agent neighbors. | |
| Map< String, String > | owners |
| The owner of each variable I know. | |
| HashMap< String, Comparable<?> > | componentIDs |
| The component ID for this agent's variables and all their neighbors. | |
| Map< String, ? extends Collection< String > > | neighborhoods |
| For each internal variable, its list of neighbors. | |
Static Private Attributes | |
| static final MessageType | TEMP_OUTPUT_MSG_TYPE = new MessageType ("VarOrdering", "LinearOrdering", "VarOrderNoSpace") |
| The type of the message notifying the agent of the chosen ordering, excluding the spaces. | |
Distributed algorithm to compute one variable linear ordering per connected component in the constraint graph.
The algorithm is initiated by the variable(s) chosen by VariableElection. At each iteration, the current variable prompts all agents for their best proposals for the next variable.
| <V> | the type used for variable values |
| <U> | the type used for utility values |
| frodo2.algorithms.varOrdering.linear.LinearOrdering< V extends Addable< V >, U extends Addable< U > >.LinearOrdering | ( | Element | parameters, |
| DCOPProblemInterface< V, U > | problem ) |
The constructor called in "statistics gatherer" mode.
| problem | the overall problem |
| parameters | the description of what statistics should be reported (currently unused) |
References problem.
| frodo2.algorithms.varOrdering.linear.LinearOrdering< V extends Addable< V >, U extends Addable< U > >.LinearOrdering | ( | DCOPProblemInterface< V, U > | problem, |
| Element | parameters ) |
Constructor.
| problem | this agent's problem |
| parameters | the parameters for LinearOrdering |
References problem.
| Collection< MessageType > frodo2.algorithms.varOrdering.linear.LinearOrdering< V extends Addable< V >, U extends Addable< U > >.getMsgTypes | ( | ) |
Implements frodo2.communication.MessageListener< T >.
References NEXT_VAR_MSG_TYPE, frodo2.algorithms.varOrdering.election.LeaderElectionMaxID< T extends Comparable< T > &Serializable >.OUTPUT_MSG_TYPE, PROPOSAL_MSG_TYPE, REQUEST_MSG_TYPE, START_MSG_TYPE, and TEMP_OUTPUT_MSG_TYPE.
| void frodo2.algorithms.varOrdering.linear.LinearOrdering< V extends Addable< V >, U extends Addable< U > >.getStatsFromQueue | ( | Queue | queue | ) |
Implements frodo2.algorithms.StatsReporter.
References queue, and frodo2.algorithms.varOrdering.linear.OrderMsg< V extends Addable< V >, U extends Addable< U > >.STATS_MSG_TYPE.
Referenced by frodo2.algorithms.afb.test.AFBagentTest< V extends Addable< V >, U extends Addable< U > >.setUp(), and frodo2.algorithms.synchbb.test.SynchBBagentTest< V extends Addable< V >, U extends Addable< U > >.setUp().
|
private |
Parses the problem.
References frodo2.solutionSpaces.ProblemInterface< V extends Addable< V >, U extends Addable< U > >.getAgent(), frodo2.solutionSpaces.DCOPProblemInterface< V extends Addable< V >, U extends Addable< U > >.getAgentNeighborhoods(), frodo2.solutionSpaces.ProblemInterface< V extends Addable< V >, U extends Addable< U > >.getAgents(), frodo2.solutionSpaces.DCOPProblemInterface< V extends Addable< V >, U extends Addable< U > >.getNbrIntVars(), frodo2.solutionSpaces.DCOPProblemInterface< V extends Addable< V >, U extends Addable< U > >.getNeighborhoods(), and frodo2.solutionSpaces.DCOPProblemInterface< V extends Addable< V >, U extends Addable< U > >.getOwners().
Referenced by notifyIn().

| void frodo2.algorithms.varOrdering.linear.LinearOrdering< V extends Addable< V >, U extends Addable< U > >.notifyIn | ( | Message | msg | ) |
Implements frodo2.communication.IncomingMsgPolicyInterface< T >.
References agentNeighborhoods, frodo2.communication.MessageType.equals(), frodo2.solutionSpaces.DCOPProblemInterface< V extends Addable< V >, U extends Addable< U > >.getNbrNeighbors(), init(), notifyIn(), frodo2.algorithms.varOrdering.election.LeaderElectionMaxID< T extends Comparable< T > &Serializable >.OUTPUT_MSG_TYPE, frodo2.communication.Queue.sendMessage(), frodo2.communication.Queue.sendMessageToMulti(), frodo2.communication.Queue.sendMessageToSelf(), frodo2.algorithms.AgentInterface< V extends Addable< V > >.STATS_MONITOR, frodo2.algorithms.varOrdering.linear.OrderMsg< V extends Addable< V >, U extends Addable< U > >.STATS_MSG_TYPE, and TEMP_OUTPUT_MSG_TYPE.
Referenced by notifyIn().

|
private |
Prints the variable order in DOT format.
References dotRendererClass, and problem.
| void frodo2.algorithms.varOrdering.linear.LinearOrdering< V extends Addable< V >, U extends Addable< U > >.reset | ( | ) |
Implements frodo2.algorithms.StatsReporter.
| void frodo2.algorithms.varOrdering.linear.LinearOrdering< V extends Addable< V >, U extends Addable< U > >.setQueue | ( | Queue | queue | ) |
Implements frodo2.communication.MessageListener< T >.
References queue.
| void frodo2.algorithms.varOrdering.linear.LinearOrdering< V extends Addable< V >, U extends Addable< U > >.setSilent | ( | boolean | silent | ) |
Implements frodo2.algorithms.StatsReporter.
References silent.
Referenced by frodo2.algorithms.afb.test.AFBagentTest< V extends Addable< V >, U extends Addable< U > >.setUp(), and frodo2.algorithms.synchbb.test.SynchBBagentTest< V extends Addable< V >, U extends Addable< U > >.setUp().
|
private |
For each internal variable, its list of agent neighbors.
Referenced by notifyIn().
|
private |
The set of all agents in the problem.
|
private |
The information about each connected component in the constraint graph.
|
private |
The component ID for this agent's variables and all their neighbors.
|
private |
The number of my variables for which I have not yet received the output of VariableElection.
|
private |
Renderer to display DOT code.
Referenced by printOrder().
|
private |
The heuristic.
|
private |
This agent's name.
|
private |
For each internal variable, its list of neighbors.
|
staticpackage |
The type of the messages notifying an agent that one of its variable is next in the order.
Referenced by getMsgTypes(), frodo2.algorithms.varOrdering.linear.NextVarMsg.NextVarMsg(), and frodo2.algorithms.varOrdering.linear.NextVarMsg.NextVarMsg().
|
private |
The owner of each variable I know.
|
private |
A list of pending requests.
|
private |
The problem.
Referenced by LinearOrdering(), LinearOrdering(), and printOrder().
|
staticpackage |
The type of the messages containing a proposal for the next variable to put in the order.
Referenced by getMsgTypes(), frodo2.algorithms.varOrdering.linear.ProposalMsg< S extends Comparable< S > &Serializable >.ProposalMsg(), and frodo2.algorithms.varOrdering.linear.ProposalMsg< S extends Comparable< S > &Serializable >.ProposalMsg().
|
private |
This module's queue.
Referenced by getStatsFromQueue(), and setQueue().
|
staticpackage |
The type of the messages sent to request proposals for the next variable to put in the order.
Referenced by getMsgTypes(), frodo2.algorithms.varOrdering.linear.RequestMsg.RequestMsg(), and frodo2.algorithms.varOrdering.linear.RequestMsg.RequestMsg().
|
private |
Whether the stats gatherer should display the resulting linear order.
Referenced by setSilent().
|
static |
The type of the message telling the module to start.
Referenced by getMsgTypes().
|
private |
Whether the module has already started the algorithm.
|
staticprivate |
The type of the message notifying the agent of the chosen ordering, excluding the spaces.
Referenced by getMsgTypes(), and notifyIn().