  The next location recommendation is at the core of various location-based
applications. Current state-of-the-art models have attempted to solve spatial
sparsity with hierarchical gridding and model temporal relation with explicit
time intervals, while some vital questions remain unsolved. Non-adjacent
locations and non-consecutive visits provide non-trivial correlations for
understanding a user's behavior but were rarely considered. To aggregate all
relevant visits from user trajectory and recall the most plausible candidates
from weighted representations, here we propose a Spatio-Temporal Attention
Network (STAN) for location recommendation. STAN explicitly exploits relative
spatiotemporal information of all the check-ins with self-attention layers
along the trajectory. This improvement allows a point-to-point interaction
between non-adjacent locations and non-consecutive check-ins with explicit
spatiotemporal effect. STAN uses a bi-layer attention architecture that firstly
aggregates spatiotemporal correlation within user trajectory and then recalls
the target with consideration of personalized item frequency (PIF). By
visualization, we show that STAN is in line with the above intuition.
Experimental results unequivocally show that our model outperforms the existing
state-of-the-art methods by 9-17%.
