With the advent of the Web 3.0 era, the number and types of data in the network have sharply increased, and the application scenarios of recommendation algorithms have also been expanded to a certain extent. Location recommendation has gradually become one of the popular application scenarios in recommendation algorithms. Traditional recommendation algorithms not only ignore the time attribute of data when recommending information to users, but also blindly pursue the recommendation accuracy, which will cause certain "information cocoon room" problems. Therefore, this article treats user historical data as a time series and proposes a LSTM-DNN model based on the bidirectional DTW algorithm. Firstly, in response to the issue of different users consuming different amounts of information, this article proposes a bidirectional DTW algorithm to calculate the similarities between different users. Secondly, this article supplements the user dataset from three perspectives: "utilization" of information, "exploration", and spatiotemporal attributes of data, which alleviates the problem of data sparsity and cold start in the dataset to a certain extent. Moreover, it effectively enhances the diversity of recommendation results. Finally, this paper constructs a LSTM-DNN neural network to dynamically obtain user interests and preferences, and proposes a new metric CSSD to measure the diversity of algorithm recommendation results. Experiments have shown that the model effectively enhances the diversity of recommendation results while ensuring recommendation accuracy.