HDAStar
Declared in astar/HDAStar.h; the same class on the site of Doxygen.
-
template<Domain D, class Dist = StateHashDistribution<D>, ADS::WorkerExecutor Executor = ADS::ThreadPool, class Open = std::conditional_t<std::is_integral_v<cost_t<D>>, BucketOpenList<Node<state_t<D>, cost_t<D>>>, HeapOpenList<Node<state_t<D>, cost_t<D>>>>>
class HDAStar Hash Distributed A* on a shared-memory machine.
Every worker runs A* on its own OPEN and CLOSED lists, and a global function Dist assigns every state to the worker that owns it: a node generated by a worker is sent to its owner, which checks it against its closed list and possibly adds it to its OPEN list [see section 4.1 of Fukunaga et al., 2017, and Kishimoto, Fukunaga and Botea, AIJ 2013]. Nodes are sent asynchronously, packed in batches of batch nodes, and an outbox not yet full is flushed every flush_period expansions and before the worker waits. The goal test is done at the expansion, the cost of the best goal found (the incumbent) prunes every node with f not smaller, and the search ends when no worker has a node with f smaller than the incumbent and no node is travelling, which the mailbox of ADS detects.
The node of a state belongs to its owner, which is the only worker that writes it; parent pointers cross the workers, and they are followed only after all the workers have finished.
Public Types
Public Functions
-
inline HDAStar(const D &domain, const Dist &dist, const ParallelOptions &options = {})
constructor, taking the Domain and the distribution (which must outlive the HDAStar)
-
struct Msg
a node travelling to its owner
-
inline HDAStar(const D &domain, const Dist &dist, const ParallelOptions &options = {})