Learning Graph Search Heuristics
Abstract
Searching for a path between two nodes in a graph is one of the most well-studied and fundamental problems in computer science.
In numerous domains such as robotics, AI, or biology, practitioners develop search heuristics to accelerate their pathﬁnding algorithms.
However, it is a laborious and complex process to handdesign heuristics based on the problem and the structure of a given use case.
Here we present PHIL (Path Heuristic with Imitation Learning), a novel neural architecture and a training algorithm for discovering graph search and navigation heuristics from data by leveraging recent advances in imitation learning and graph representation learning.
At training time, we aggregate datasets of search trajectories and ground-truth shortest path distances, which we use to train a specialized graph neural network-based heuristic function using backpropagation through steps of the pathﬁnding process.
Our heuristic function learns graph embeddings useful for inferring node distances, runs in constant time independent of graph sizes, and can be easily incorporated in an algorithm such as A* at test time.
Experiments show that PHIL reduces the number of explored nodes compared to state-of-the-art methods on benchmark datasets by 58 .
5% on average, can be directly applied in diverse graphs ranging from biological networks to road networks, and allows for fast planning in time-critical robotics domains.
Introduction
Search heuristics are essential in several domains, including robotics, AI, biology, and chemistry [1– 6].
For example, in robotics, complex robot geometries often yield slow collision checks and search algorithms are constrained by the robot’s onboard computation resources, requiring well-performing search heuristics that visit as few nodes as possible [1, 4].
In AI, domain-speciﬁc search heuristics are useful for improving the performance of inference engines operating on knowledge bases [3, 5].
Search heuristics have been previously also developed to reduce search efforts in protein-protein interaction networks [6] and in planning chemical reactions that can synthesize target chemical products [2].
This broad set of applications underlines the importance of good search heuristics that are applicable to a wide range of problems.
The search task can be formulated as a pathﬁnding problem on a graph, where given a graph, the task is to navigate and ﬁnd a short feasible path from a start node to a goal node, while in the process visiting as few nodes as possible (Figure 1).
The most straightforward approach would be to launch a search algorithm such as breadth-ﬁrst search (BFS) and iteratively expand the graph from the start node until it reaches the goal node.
Since BFS does not harness any prior knowledge about the graph, it usually visits many nodes before reaching the goal, which is expensive in cases such as robotics where visiting nodes is costly.
To visit fewer nodes during the search, one may use domain-speciﬁc information about the graph via a heuristic function [7], which allows one to deﬁne a distance metric on graph nodes to prune directions that seem less promising to explore.
Unfortunately, coming up with good search heuristics requires signiﬁcant domain expertise and manual effort.
While there has been signiﬁcant progress in designing search heuristics, it remains a challenging problem.
Classical approaches [8, 9] tend to hand-design search heuristics, which requires domain knowledge and a lot of trial and error.
To alleviate this problem, there has been signiﬁcant development in general-purpose search heuristics based on trading-off greedy expansions and novelty-based exploration [10–13] or search problem simpliﬁcations [14–16].
These approaches alleviate some of the common pitfalls of goal-directed heuristics, but we demonstrate that if possible, it is useful to learn domain-speciﬁc heuristics that can better exploit problem structure.
On the other hand, learning-based methods face a set of different challenges.
Firstly, the data distribution is not i.i.d., as newly encountered graph nodes depend on past heuristic values, which means that supervised learning-based methods are not directly applicable.
Secondly, heuristics should run fast, with ideally constant time complexity.
Otherwise, the overall asymptotic time complexity of the search procedure could be increased.
Finally, as the environment (search graph) sizes increase, reinforcement learning-based heuristic learning approaches tend to perform poorly [1].
State-of-theart imitation learning-based methods can learn useful search heuristics [1]; however, these methods still rely on feature-engineering for a speciﬁc domain and do not generally guarantee a constant time complexity with respect to graph sizes.
[Figure]
In this paper, we propose Path Heuristic with Imitation Learning (PHIL), a framework that extends the recent imitation learning-based heuristic search paradigm with a learnable explored graph memory .
This means that PHIL learns a representation that allows it to capture the structure of the so far explored graph, so that it can then better select what node to explore next (Figure 2).
We train our approach to predict the node-to-goal distances ( h ∗ in Figure 2) of graph nodes during search.
To train our memory module, which captures the explored graph, we use truncated backpropagation through time (TBTT) [17], where we utilize ground-truth node-to-goal distances as a supervision signal at each search step.
Our TBTT procedure is embedded within an adaptation of the AggreVaTe imitation learning algorithm [18].
PHIL also includes a specialized graph neural network architecture , which allows us to apply PHIL to diverse graphs from different domains.
We evaluate PHIL on standard benchmark heuristic learning datasets (Section 5.1), diverse graphbased datasets from different domains (Section 5.2), and practical UAV ﬂight use cases (Section 5.3).
Experiments demonstrate that PHIL outperforms state-of-the-art heuristic learning methods up to 4 × .
Further, PHIL performs within 4 .
9% of an oracle in indoor drone planning scenarios, which is up to a 21 . 5% reduction compared with commonly used approaches.
In practice, our contributions enable practitioners to quickly extract useful search heuristics from their graph datasets without any hand-engineering.
Preliminaries
Graph search .
Suppose that we are given an unweighted connected graph G =
( V , E ) , where V is a set of nodes, and E a corresponding set of edges.
Further suppose that each node i ∈ V has corresponding features x i ∈ R D v , and each edge ( i,
j ) ∈
E has features e ij ∈ R D e .
Assume that we are also given a start node v s ∈ V and a goal node v g ∈ V .
At any stage of our search algorithm, we can partition the nodes of our graph into three sets as V = CLOSE ∪ OPEN ∪ REST, where
CLOSE are the nodes already explored, OPEN are candidate nodes for exploration (i.e., all nodes connected to any node in CLOSE, but not yet in CLOSE), and REST is the rest of the graph.
Each expansion moves a node from OPEN to CLOSE, and adds the neighbors of the given node from
REST to OPEN.
We call the set of newly added fringe nodes V new at each search step.
At the start of the search procedure, CLOSE =
{ v s }
and we expand the nodes until v g is encountered (i.e., until v g ∈ CLOSE).
Greedy best-ﬁrst search .
We can perform greedy best-ﬁrst search using a greedy fringe expansion policy, such that we always expand the node v ∈ OPEN that minimizes h ( v, v g ) .
Here, h : V ×V −→ R is a tailored heuristic function for a given use case.
In our work, we are interested in learning a function h that predicts shortest path lengths, this way minimizing | CLOSE | in a greedy best-ﬁrst search regime.
Imitation of perfect heuristics .
Partially observable Markov decision processes (POMDPs) are a suitable framework to describe the problem of learning search heuristics [1].
We can have s = ( CLOSE , OPEN , REST ) as our state, an action a ∈ A corresponds to moving a node from OPEN to
CLOSE, and the observations o ∈
O are the features of newly included nodes in OPEN.
Note that one could consider an MDP framework to learn heuristics, but the time complexity of operating on the whole state is in most cases prohibitive.
We also deﬁne a history ψ ∈ Ψ as a sequence of observations ψ
=
o 1 , o 2 , o 3 , ... .
Our work leverages the observation that using a heuristic function during greedy best-ﬁrst search that correctly determines the length of the shortest path between fringe nodes and the goal node will also yield minimal | CLOSE | .
For training, we adopt a perfect heuristic h ∗ , similar to [1], which has full information about s during search.
Such oracle can provide ground-truth distances h ∗ ( s, v, v g ) , where v ∈ OPEN.
To conclude, we deﬁne a greedy best-ﬁrst search policy π θ that uses a parameterized heuristic h θ to expand nodes from OPEN with minimal heuristic values.
One could also directly use a POMDP solver for the above-described problem, but this approach is usually infeasible due to the dimensionality of the search state [19].
Related Work
General purpose heuristic design .
There has been signiﬁcant research in designing general-purpose heuristics for speeding up satisﬁcing planning.
The ﬁrst set of approaches are based on simplifying the search problem for example using landmark heuristics [14, 16].
The next set of approaches aim to include novelty-based exploration in greedy best-ﬁrst search [10–13].
The latter set of approaches showed state-of-the-art performance (best-ﬁrst width search [12, 13], BFWS) in numerous settings.
We show that in domains where data is available, it can be more effective to incorporate a learned heuristic into a greedy best-ﬁrst search procedure.
Learning heuristic search .
There have been numerous previous works that attempt to learn search heuristics: Arfaee et al.
[20] propose to improve heuristics iteratively, Virseda et al.
[21] learn to combine heuristics to estimate graph node distances, Wilt et al.
[22] and Garrett et al.
[23] propose to learn node rankings, Thayer et al.
[24] suggest to infer heuristics during a search, and Kim et al.
[25] train a neural network to predict graph node distances.
These methods generally do not consider the non-i.i.d.
nature of heuristic search.
Further, Bhardwaj et al.
[1] propose S A IL, where heuristic learning is framed as an imitation learning problem with cost-to-go oracles.
The S A IL heuristic uses hand-designed features tailored for obstacle avoidance, with a linear time-complexity in the number of explored grid nodes found to be colliding with an obstacle.
Feature-engineering becomes more difﬁcult as we attempt to learn heuristics on diverse graphs such as ones seen in Section 5.2, where we may need expert knowledge.
Further, heuristics that do not have a constant time complexity in the size of the graph [1, 26–29] generally scale poorly with graph size and hence have constrained use cases.
Recent approaches to learning heuristics include Retro* [2] by Chen et al. , where a heuristic is learned in the context of AND-OR search trees for chemical retrosynthetic planning.
Our work focuses on a more general graph setting.
There has been signiﬁcant progress on learning heuristics for NP-hard combinatorial optimization problems [30–32].
Focusing on solving NP-hard problems allows these approaches to design algorithms that are often non-exact and have a relatively large computational budget.
This is not the case for methods that focus on polynomial time search, where learning-based methods are bounded by the determinism and time complexity of classical algorithms such as greedy best-ﬁrst search.
Learning general purpose search .
Learning general search policies is a very well-studied research area with a rich set of developments and applications.
These include Monte Carlo Tree Search methods [33, 34], implicit planning methods [35–37], and imagination-based planning approaches [38, 39].
Learning search heuristics can be seen as a special case of general purpose search , where the search problem is treated as a partially observable Markov decision process with restricted action evaluation (see Section 4), and with models running in O (1) to remain competitive time-complexitywise on problems where best-ﬁrst search performs well.
General purpose search methods do not take into account the above-mentioned constraints, which motivates the development of tailored approaches for learning heuristics [1, 2].
Imitation learning .
Our approach builds on prior work in imitation learning (IL) with cost-to-go oracles.
Cost-to-go oracles have been incorporated in the context of IL in methods such as SEARN [40], AggreVaTe [18], LOLS [41], AggrevaTeD [42], DART [43], and THOR [44].
S
A IL [1] presents an AggreVaTe-based algorithm for learning heuristic search.
We extend S A IL by incorporating a recurrent Q -like function, in which sense our algorithm more closely resembles AggreVaTeD by Sun et al.
While a recurrent policy can be easily incorporated in AggreVaTeD, we cannot use a policy to evaluate actions.
This is due to the fact that we would either have to evaluate all actions in a state, which is computationally infeasible, or we would have to give up on taking actions that are not in the most recent version of the search fringe, which would degrade the performance (see Section 4).
Path Heuristic with Imitation Learning
Training objective .
With the aim of minimizing | CLOSE | after search, our goal is to train a parameterized heuristic function h θ : Ψ × V × V −→ R to predict ground-truth node distances h ∗ and use h θ within a greedy best-ﬁrst policy π θ at test time.
More speciﬁcally, we assume access to a distribution over graphs P G , a start-goal node distribution P v sg ( · | G ) , and a time horizon T .
Moreover, we assume a joint state-history distribution s, ψ ∼ P s ( · | G , t, π θ , v s , v g ) , where P s represents the probability our search being in state s , at time 0 ≤ t ≤ T on graph G with pathﬁnding problem ( v s , v g ) , with a greedy best-ﬁrst search policy π θ using heuristic h θ .
Hence, our goal can be summarized as minimizing the following objective:
Obtain hyperparameters T , β 0 , N , m , t τ ;
Initialize D ← ∅ , h θ 1 ; for i = 1 , . . .
, N do Sample G ∼ P G ;
Sample v s , v g ∼ P v sg ;
Set β ← β i 0 ;
Set mixture policy π mix ← (1 − β ) ∗ π θ i + β ∗ π ∗ ;
Collect m trajectories τ ij as follows; for j = 1 , . . .
, m do
Sample t ∼ U (0 , ..., T − t τ ) ;
Roll-in t time steps of π θ i to obtain z t and new state s t =
( CLOSE 0 , OPEN 0 , REST 0 ) ;
Roll-out trajectory τ ij as follows; for k = 1 , . .
, t τ do
Update s t
+ k − 1 using π mix to get new state s t + k and new fringe state OPEN k ;
Obtain new fringe nodes V new =
OPEN k \ OPEN k − 1 ;
Update trajectory τ ij ← τ ij ∪ { ( V new , h ∗ ( s t + k , V new , v g )) } ;
Update dataset D ← D ∪ { ( τ ij , z t ) } or D ∪ { ( τ ij , 0) } ;
Train h
θ i using TBTT on each τ ∈ D to get h
θ
i +1 ; return best performing h θ i on validation ;
[Equation]
[Equation]
OPEN
[Equation]
OPEN
[Equation]
Before we describe the algorithm that can be used to minimize L , we rewrite h θ to include a memory digest component ( z t ), which represents an embedding of ψ at time step t .
Hence, h θ becomes h θ : R d × O × V × V −→ R , where d is the dimensionality of our memory’s embedding space.
As opposed to previous methods [1], z t allows us to automatically extract relevant features for heuristic computations and concurrently reduce the computational complexity of the heuristic function.
Further, as shown in [1], if we would use h θ to evaluate all actions in a state (i.e., recalculate the heuristic values of all nodes in OPEN), we would need a squared reduction in the number of expanded nodes compared with BFS for PHIL to bring performance beneﬁts over BFS, which however may not be possible on all datasets.
Hence, we constrain the heuristic only to evaluate new OPEN nodes which we obtain after moving a node to CLOSE, calling the set of new fringe nodes V new after each expansion.
In practice, the policy π θ yields an algorithm equivalent to greedy best-ﬁrst search, with the heuristic function replaced by h θ .
4.1 Learning algorithm & architecture
Imitation learning algorithm .
In Algorithm 1, we present the pseudo-code of the IL algorithm used to train our heuristic models (Figure 3).
The high-level idea of our algorithm is that we aggregate trajectories of search traces (i.e., sequences of new fringe nodes) and use truncated backpropagation through time to optimize h θ after each data-collection step.
In particular, after sampling a graph
G and a search problem v s , v g , we use our greedy learned policy π θ induced by h θ to roll-in for t ∼ U (0 , . . .
, T − t τ ) expansions, where T is the episode time horizon, and t τ is the roll-out length.
From our roll-in, we obtain a new state s = ( CLOSE 0 , OPEN 0 , REST 0 ) , and an initial memory state z t .
After our roll-in, we roll-out for t τ steps using our mixture policy π mix , which is obtained by probabilistically blending π θ and the greedy best-ﬁrst policy induced by the oracle heuristic π ∗ .
In a roll-out, we collect sequences of new fringe nodes, together with their ground-truth distances to the goal v g , given by h ∗ .
Once the roll-out is complete, we append the obtained trajectory and the initial state for the following optimization using backpropagation through time.
Further analysis on the trade-offs between using rolled-in states z t or zeroed-out states for training can be found in the supplementary material.
Note that we could also use supervised learning-based approaches to sample a ﬁxed dataset of ( v s , v g , h ∗ ( s, v s , v g ) ) 3-tuples and train a model to predict node distances conditioned on their features.
However, our experiments in Section 5 demonstrate that ignoring the non-i.i.d.
nature of heuristic search negatively impacts model performance, with supervised learning-based methods performing up to 40 × worse.
Algorithm Obtain x i , x j ( j ∈ N i ) , e ij , x g z t ; x i ← f ( x i , x g , D EUC ( x i , x g ) , D COS ( x i , x g ) ); x j ← f ( x j , x g , D EUC ( x j , x g ) , D COS ( x j , x g ) ); g i ← φ ( x i , ⊕ j ∈N i γ ( x i , x j , e ij )) ; g (cid:48)
i , z i,t +1 ← GRU ( g i , z t ) ; z t +1 ← z
i,t +1 ; ˆ h i ← MLP ( g (cid:48) i , x g ); return ˆ h
i , z t +1 ;
Recurrent GNN architecture.
In each forward pass, h θ obtains a set of new fringe nodes V new , the goal node v g , and the memory z t at time step t .
We represent each node in V new using its features x i ∈ R D v , and likewise the goal node v g using its features x g ∈ R D v .
Further, for each i ∈ V new , we uniformly sample an n ∈ N ≥ 0 bounded set of nodes present in the 1-hop neighborhood of i , calling this set
N i , with |N i | ≤ n .
This sampling step produces a set of neighboring node features, where each j ∈ N i has features x j ∈ R D v , and corresponding edge features e ij ∈ R D e .
h θ forward pass.
Algorithm 2 presents a single forward pass of h θ .
The forward pass outputs predicted distances of the new fringe nodes to the goal
ˆ h i , together with an updated memory digest z t +1 .
In Algorithm 2, f , φ , γ , GRU[45], MLP are each parameterised differentiable functions, with φ, γ representing the update and message functions [46] of a graph neural network, respectively.
In our forward pass, using the function f , we ﬁrst project x i , x j into a node embedding space, together with the goal features x g , and their Euclidean ( D EUC ) and cosine distances ( D COS ).
After that, using a 1 -layer GNN, we perform a single convolution over each x i and the corresponding neighborhood N i , to obtain g i .
The speciﬁc GNN choice is a design decision left to the practitioner, and further analysis of GNN choices can be found in Appendix D. Our graph convolution processing step allows us to easily incorporate edge features and work with variable sizes of N i .
After the graph convolution, we apply the GRU module over each embedding g i to obtain hidden states z i,t +1 , and new embeddings g (cid:48) i .
We compute the sample mean of z i,t +1 for each node i ∈ V new to obtain a new hidden state z t +1 , and process g (cid:48)
i with x g using an MLP to compute the distances between the graph nodes.
The intuitive explanation for using history embeddings is to address the partial observability of the problem.
PHIL does not have access to the full graph because of time complexity concerns.
The history embeddings provide a mechanism for keeping track of the belief over the full state of the graph during search.
Further, the GNN allows for easily incorporating local neighborhoods and edge features.
Please refer to Appendix D where we discuss the effects of our design choices.
Permutation invariant V new embedding.
There is a trade-off between processing new fringe nodes in batch, as in Algorithm 2, and processing them sequentially.
Namely, when we process the nodes in batch, we do not use the in-batch observations to predict batch node values, which means that z t is slightly outdated.
On the other hand, in PHIL, batch processing allows us to compute the heuristic values of all v ∈ V new in parallel on a GPU and preserves the memory’s permutation invariance with respect to nodes in V new .
That is, because our observations are nodes & edges of a graph, the respective observation ordering usually does not contain inductive biases useful for predictions, which means that we can apply a permutation invariant operator such as the mean of all new states z i,t +1 to obtain an aggregated updated state.
This approach provides additional scalability as we can process values in parallel and PHIL does not have to infer permutation invariance in V new from data.
Runtime complexity .
Since ∀ i ∈ V new : |N i | ≤ n , Algorithm 2 together with neighborhood sampling runs in up to nc 1 + ( n + 1) c
2 operations per each node i ∈ V new , which is O (1) with respect to the size of the graph.
Here, c 1 is the maximal number of operations associated with evaluating a node, such as performing robot collision checks in dynamically constructed graphs, and c 2 is the maximal count of total model operations (e.g., f & γ operations) on the node set { i } ∪ N i .
Note that for this analysis, we assume that c 1 is bounded.
In general, we expect to learn a better search heuristic with increasing n , but in some use cases, c 1 may dominate overall complexity, which means the hyperparameter n is helpful for practitioners to tune trade-offs between constant factors and search effort minimization.
Experiments
In our experiments, we evaluate PHIL both on benchmark heuristic learning datasets [1] (Section 5.1) as well on a diverse set of graph datasets (Section 5.2).
Finally, we show that PHIL can be applied to efﬁcient planning in the context of drone ﬂight (Section 5.3).
Our main goal is to assess how PHIL compares to baseline methods in terms of necessary expansions before the goal node is reached.
Please refer to the supplementary material for information about baselines, an ablation study, and additional experiment details.
5.1 Heuristic search in grids
In Section 5.1, we evaluate PHIL on 8 , 200 × 200 8-connected grid graph-based datasets by Bhardwaj et al.
These datasets present challenging obstacle conﬁgurations for naive greedy planning heuristics, especially when v s is in the bottom-left of the grid, and v g in the top-right.
Each dataset contains 200 training graphs, 70 validation graphs, and 100 test graphs.
Example graphs from each dataset can be found in Table 1.
We train PHIL with a hyperparameter conﬁguration of T = 128 , t τ = 32 , β 0 = 0 .
7 , n = 8 , and using rolled-in z t states as initial states for training.
We use a 3-layer MLP of width 128 with
LeakyReLU activations, followed by a DeeperGCN [47] graph convolution with softmax aggregation.
Our memory’s embedding dimensionality is 64 .
The node features are 2D grid coordinates.
See
Appendix C for an overview of our baselines and datasets.
Note that although using positional representations [48] might be useful for this search problem, it is not scalable as the graph size increases (we refer the reader to Appendix A for more details).
Discussion.
As we can see in Table 1, PHIL outperforms the best baseline (S A IL) on all datasets, with an average reduction of explored nodes before v g is found of 58 .
Qualitatively, observing
Figure 5, we can attribute these results to PHIL’s ability to reduce the redundancy in explored nodes during a search.
Further, PHIL is also capable of escaping local minima , which is illustrated in Figure 4.
However, note that we occasionally observe failure cases in practice, where PHIL gets stuck in a bug trap-like structure.
We discuss possible remedies and opportunities for future work in the supplementary material.
Runtime & convergence speed .
PHIL converges in up to N = 36 iterations, with m = 1 , t τ =(i.e., after observing less than N ∗ t τ ∗ max ( |V new | )
≈ 9 , 216 shortest path distances, where we
[Table]
According to ﬁgures reported in [1], this is approximately 5 × less data than it takes for S A IL to converge.
[Figure]
5.2 Search in real-life graphs of different structures
In this experiment, our goal is to demonstrate the general applicability of PHIL to various graphs.
We train PHIL on 4 different groups of graph datasets: citation networks, biological networks, abstract syntax trees (ASTs), and road networks.
We use the same graph for citation networks and road networks for training and evaluation, and we use 100 random v s , v g pairs for testing.
In the case of biological networks and ASTs, we usually have train/validation/test splits of 80 / 10 / 10 , and in the case of the OGB [49] datasets, we use the provided splits.
Similarly as in Section 5.1, our MLP has four layers of width 128 with LeakyReLU
activations
and we use a DeeperGCN [47] graph convolution with softmax aggregation.
The utilized node and edge features are the provided features in each dataset, except for a few minor modiﬁcations which are discussed in Appendix A & Appendix C. We train an MLP of depth 5 and width 256 using supervised learning (SL) for our learning-based baseline method.
Discussion .
The results presented in Table 2 suggest that PHIL can learn superior search heuristics compared with baseline methods, outperforming top baselines per dataset in terms of visited nodes
[Table]
during a search by 13 . 4% on average.
Two datasets where PHIL fell short compared to other baselines are the OGBG-Molhiv and OGBG-Code2 datasets.
The OGBG-Code2 dataset adopts a project split [55] and OGBG-Mohliv adopts a scaffold split [56], both of which ensure that graphs of different structure are present in the training & test sets.
Although PHIL improved upon uninformed search (BFS) in the OGB datasets, structural graph consistency is explicitly discouraged in the above-mentioned OGBG splits.
Without the OGBG datasets, PHIL improves on the top baselines per dataset by 19 .
5% on average, and upon the Euclidean node feature heuristic ( h euc ) by 20 . 4% .
Note that we trained PHIL up to N = 60 iterations, which means that it only encountered a small subset of the pathﬁnding problems in the single graph setting, which means that PHIL had to generalize to learn useful heuristics.
Even in Cora, the |D| = 1 dataset with least number of nodes, PHIL observed roughly 6 , 000 node distances during training, which is less than 0 .
2% of total distances in the Cora graph.
5.3 Planning for drone ﬂight
In our ﬁnal experiment, we use PHIL to plan collisionfree paths in a practical drone ﬂight use case within an indoor environment.
We built our environment using the
CoppeliaSim simulator [57], and the Ivy framework [58].
Figure 6 presents the environment which we refer to as room adversarial in Table 3.
For more detail about each environment, please refer to the supplementary material.
We discretize the environments into 3D grid graphs of size 50 × 50 × 25 , and randomly remove 5 sub-graphs of size 5 × 5 × 5 both during training and testing, this way simulating real-life planning scenarios with random obstacles.
The hyperparameter conﬁguration and the speciﬁc architecture we utilize are equivalent to Section 5.1, but with n = 4 .
Likewise, the node features are 3D grid coordinates, and the baselines include supervised learning (SL), h euc , A*, and BFS, similarly as in Sections 5.1, 5.2.
In Table 3 we report the ratio of expanded nodes with respect to h euc .
Video demo .
We provide a video demonstration of PHIL running in room adversarial : https: //cutt.ly/eniu5ax .
[Table]
performance-wise to the optimal number of expansions.
Discussion .
As we can observe in Table 3, PHIL outperforms all baselines in both environments.
Interestingly, PHIL expands only approximately 0 .
3% more nodes in the simple room than least possible and 4 .
9% more in the adversarial room case.
The same ﬁgures for the greedy method ( h euc ) are 27 .
8% and 17 .
2% , respectively.
These results indicate that PHIL is capable of learning planning strategies that are close to optimal in both simple and adversarial graphs, while the performance of naive heuristics degrades.
5.4 Runtime Analysis
We summarize test run-times of different approaches in Appendix G. PHIL runs 57 .
9% faster than
BFWS and 32 .
2% faster than S A IL, and not much slower than traditional A* ( 34 .
and h man ( 18 . 3% ).
Although Neural A* is 71 . 0% faster than PHIL due to the fact that it casts the whole search process into matrix operations on images, it cannot be employed in a generic search setting.
Conclusion
We consider the problem of learning to search for feasible paths in graphs efﬁciently.
We propose a model and a training procedure to learn search heuristics that can be easily deployed across diverse graphs, with tuneable trade-off parameters between constant factors and performance.
Our results demonstrate that PHIL outperforms current state-of-the-art approaches and can be applied to various graphs with practical use cases.