# Optimization of Digital Recommendation Service System for Tourist Attractions Based on Personalized Recommendation Algorithm

Authors: Yue Wang; Zhaoxiang Qin; Jun Tang; Wei Zhang
Journal: Journal of Function Spaces
 (2022)

---

## Abstract

With the deepening of tourists’ demand for tourism services, the personalization of online tourists has gradually become an application of personalized recommendation technology. According to the application requirements of personalized scenic spot recommendation, this paper uses social networks and Bayesian networks to fully mine the matching degree between users and scenic spots for personalized recommendation. Add social network factors to the recommendation of tourist attractions, and fully tap the social network relationship between users. First, the users are clustered by the coupling bidirectional clustering algorithm. Then, DBSCAN (density-based noise application spatial clustering) algorithm is used to cluster scenic spots. Finally, two stable user sets and scenic spot sets are applied to the personalized recommendation algorithm to predict the user’s next upcoming scenic spot. The algorithm is compared with some traditional algorithms in the dataset. The algorithm deals with the similarity of user attributes and user behavior and uses content-based algorithm to deal with the relationship between scenic spots; com datasets have better performance.


---

## Body

## 1. Introduction

With the development of the national economy, people’s demand for tourism is becoming more and more strong. The rise of various tourism websites provides users with a platform to understand the destination scenic spots and arrange their itineraries. With the rapid popularity of smartphones and growing online tourism experience sharing platforms, tourists are increasingly inclined to decide what to visit in real time, rather than making detailed travel plans in advance. In the face of the uncertainty of user needs, how to combine the current actual state of users to make dynamic and personalized scenic spot recommendation for users has become an urgent problem to be solved in the tourism recommendation research. However, with the increasing amount of data, the problem of information overload on travel websites also becomes more and more serious. Therefore, providing a personalized travel recommendation system is very critical for travel websites and users. The Internet continues to penetrate into people’s lives; coupled with the smart devices and wireless communication technology, people can access the Internet more conveniently and quickly. As shown in Figure1, according to the survey [1], my country increases every year according to a certain proportion [2]. The network has become increasingly diversified. Categories are usually applied to website design, such as the hao123 website, which helps users to quickly find the website they need [3]. The emergence of search engines makes it convenient for users to find the required information by searching for keywords, but sometimes users cannot accurately describe their needs, making it difficult for the system to distinguish the needs of users, and the recommendation system was born. From an objective understanding, search engines and recommendation systems have their own strengths in helping users filter information, which greatly facilitates users [4]. Search engine allows users to find the information they need by searching keywords. However, search engines need users to actively provide accurate keywords to find information. Therefore, it cannot solve many other needs of users. For example, when users cannot find keywords that accurately describe their needs, search engines cannot do anything about it. Like search engines, recommendation system is also a tool to help users quickly find useful information. Unlike search engines, recommendation systems do not require users to provide clear requirements but model users’ interests by analyzing users’ historical behavior, so as to actively recommend information to users that can meet their interests and needs. Therefore, in a sense, recommendation system and search engine are two complementary tools for users. The search engine meets the active search needs of users when they have a clear purpose.Figure 1
Number of the Internet users and Internet penetration rate.The task of recommendation system is to contact users and information. On the one hand, it helps users find valuable information for themselves; on the other hand, it allows information to be displayed in front of users who are interested in it, so as to achieve a win-win situation between information consumers and information producers. A recommender system is a software designed to help users quickly discover useful information, in which the user’s historical behavior provides the necessary information for interest modeling, which is convenient for predicting the user’s preferences so that the information that meets the requirements can be actively recommended to the user [5]. In recent years, due to the characteristics of recommendation systems that facilitate users to filter information, the application scope of recommendation systems has been expanding, from product recommendation, to news recommendation, music recommendation, etc. [6]. As shown in Figure 2, the analysis data of the tourism industry in 2015 shows that the number of tourists is increasing every year, which promotes this date to become a new application hotspot of the recommendation system. There are relatively complete websites recommended for tourist attractions in China, such as Tongcheng (http://Travel.com/ and http://Ctrip.com/), which bring convenience to users’ travel [7].Figure 2
The number of international tourists from 2004 to 2014.By analyzing the tourist attraction recommendation services of major websites at home and abroad, most of the recommendation methods focus on packaged services, lacking personalized, social, and real-time services [8]. According to a survey by the China Internet Network Information Center, a relatively high proportion of citizens use social networking sites to upload photos, post logs, and upload videos, as shown in Figure 3 [9].Figure 3
Netizens use the functions of social networking sites.


## 2. Related Work

At present, should meet the preferences of users in many aspects, the development of personalized tourist attractions recommendation has become the general trend.The recommended tourist attractions are more in line with the personalized needs of users [10]. Starting from the development history of foreign tourist attractions, Shaik et al. [11] made an intuitive in-depth analysis of the domestic and foreign tourism industry structure. Singh et al. [12] proposed the CityVoyager store recommendation system, which is a relatively novel and practical recommendation system, which mainly evaluates the user’s preferences, thus laying the foundation for the recommendation of tourist attractions. Masaki [13] proposed to use location as a key factor to design an enhanced collaborative filtering system that can recommend personalized restaurant services to users, verifying the role of location-based services. Motia and Reddy [14] proposed the HGSM framework, which provides information for calculating the similarity of the user’s geographic space by mining information from the user’s geographic location history and the hierarchical attributes of the geographic space, and explores the relationship between users and users of intimacy and the association between users and geographic locations to address their interests and hobbies.When tourists are in unfamiliar tourist locations, Ayswarya et al. [15] and others used Bayesian network and AHP to provide personalized recommendation services. First, they used the information related to tourist attractions on travel websites to build a tourist ontology tree to store tourist attractions. Shimizu et al. [16] summarized some systems and technologies related to travel recommendation before 2009 and proposed a recommendation system in the mobile environment. Pradhan et al. [17] extracted the rating data of tourist attractions on tourism websites in order to construct a user-attraction matrix and then make final recommendations for tourist attractions.


## 3. Methods

### 3.1. Personalized Attractions Recommendation Algorithm Based on Social Networks

A complete tourism recommendation system should provide a complete set of personalized tourism recommendation programs, which is divided into two steps: scenic spot recommendation and path planning. For scenic spot recommendation, existing recommendation algorithms such as collaborative filtering and content-based and social network-based methods such as single data source are difficult to describe users' dynamic interests. The existing research generally regards it as TSP problem and NP hard problem, so most of them adopt heuristic algorithm. However, in tourism planning, only the length of the turnover path between scenic spots, the user time limit, and the opening time limit are usually considered. This chapter presents a social network (based on the social network with personalized tourist attraction recommendation, ptar). The purpose is to predict the next possible scenic spots for users and give real-time recommendations, which is different from the traditional recommendation algorithm. The algorithm processing steps are to first cluster users and attractions and replace the user and attractions matrix in the personalized rule-based algorithm proposed by Ma et al. [18] with the results obtained by clustering. Tourism planning is an applied science. At present, there is no perfect theoretical system of tourism planning. International discussions on tourism planning theory are often scattered. The main problems are as follows: (1) the theories and norms of urban planning and regional planning have replaced tourism planning. The standardization of scenic spot planning has replaced the tourism area planning, and there is little research on the theory and method of tourism planning itself. (2) There is little systematic thinking about the theory of tourism planning, and there is no systematic research on the ideological methods and models of tourism planning. (3) The concept system of tourism planning is not standardized, and the understanding of tourism and its related concepts is even far from satisfactory.For the above problems, this paper proposes a personalized travel recommendation system framework based on knowledge graph and user footprint. First, establish a knowledge map of the attractions, The knowledge map includes scenic introduction, comments, time, and other information, It provides data support for scenic spot recommendation and path planning; next, personalized scenic attraction recommendations through a deep interest evolution network. The model uses recurrent neural network and adds attention mechanism to describe the diversity and dynamic change of user interests. The model input mainly includes the scenic spot sequence in the user's footprint and the scenic spots to be recommended. Input information of scenic spots can be obtained through knowledge map, including scenic spot ID, scenic spot tag, comment tag, scenic spot introduction, and nearby scenic spots. Finally, the user’s own travel days, the opening time of the scenic spot, the travel time of the scenic spot, and other factors are added to the fitness function. Appropriate heuristic algorithm is adopted for reasonable path planning.As shown in Figure4, the algorithm based on user data and social data is described as follows: First, users are processed, and users in certain locations are clustered together according to their preferences and geographic location information. Use the coupled bidirectional clustering algorithm to cluster users into a suitable category. Secondly, the scenic spots are processed. The frame processing is shown in Figure 5.Figure 4
Recommendation algorithm for personalized tourist attractions based on social network.Figure 5
Algorithm processing frame diagram.From previous research work, it can be concluded that clustering users is generally used to improve the recommendation accuracy by obtaining “appropriate” friend groups. The coupled two-way clustering algorithm (CTWC) is used to cluster the dataset, which has been verified in the literature [19].The scenic spot asPc; then, the scenic spot category is replaced. The quality of the clustering results is related to the dataset selected during the experiment, especially the prefiltering requirements for the scenic spots in the dataset. Therefore, the tourist attractions selected in this paper must have more than 3 users who have traveled to the scenic spots to avoid data collection.The introduction of DBSCAN clustering algorithm is shown in Section 2.5. The date of scenic spot are shown in Table1.Table 1
Clustering results of photo attractions with geographic information.
Clustering parametersAttractionsClustering resultsEps (km)MinPtsGreat WallTiananmen SquareSummer palaceWater cubeNumber of categoriesNoise rate (%)0.51030035023002405563.7020150312210021322271.883011728612561861476.3011057056027653507046.292040052024603212358.603026049814862461563.0231072470062034205022.322068066850793852930.943064862348623431837.06This paper introduces the friend relationship in the social network into the tourist research. A social network-based (PTAR) is proposed, which fully considers friends in social network relationships and friends with similar interests. According to the personalized rule algorithm, this paper defines the following objective function:(1)minU,PLT,Uc,Pc=12∑i=1m∑k=1nIikTik−UicTPkc+β2∑i=1m∑f∈Fisk,fUic−UfcF2+λ12UcF2+λ22PcF2.T represents the user-spots matrix, Uic represents the user 𝑖’s scenic spot set, and Pkc represents the scenic spot k set. Iik is an indicator function; if the user Uic gives the attraction Pkc action, then Iik=1; otherwise, Iik=0. 𝑇𝑖𝑘 represents the number of photos, the user Uic gives to the scenic spot Pkc, Uic and Ufc represent the user vector, Pkc represents the scenic spot vector, and F2 represents the Frobenius norm. α and β represent the added social network information, and α>0, and β>0. Lk,f represents degree of correlation between the scenic spot Pkc and the user Ufc; if the user acts on the scenic spot, it indicates that the correlation between the two is relatively high, and the user Ufc has a high degree of correlation to the user Uic. The contribution is relatively small; si,f represents the relationship between the user Uic, si,f is a greater difference between users, that is Uic and Ufc, the greater the difference between users. The last two terms are a regularization term, in order to avoid overfitting of the objective function.


### 3.2. Experiment Evaluation Index of Evaluation Recommendation Algorithm

In this paper, quantitative description is used, and the prediction accuracy is selected to measure the ability of a recommendation algorithm. Different research directions use different evaluation indicators. The accuracy of the general forecast is represented as calculated in the following formulas:(2)MAE=1T∑u,i∈TRui−Rul¯,(3)RMSE=1T∑u,i∈TRui−Rul¯2.In Formulas (2) and (3), Rui is real rating u, Rui is the item i obtained i through the recommendation algorithm, and T is test sets.The prediction accuracy of Top-N recommendations is generally measured by precision and recall; letu represent the list of recommended actions on the training set, and Tu represent the list of actions on the test set. The formulas for calculating the recall rate (Recall) and the precision rate (Precision) of the recommended results are as follows:
(4)Recall=∑uϵURu∩Tu∑uϵUTu,Precision=∑u∈URu∩Tu∑u∈URu.In the experiment,R represents the scenic spots actually visited by the user, and the recommendation result generated by the personalized scenic spot recommendation algorithm represented by T. It is recommended to use the TopK method for the final result, that is, the length of the recommended result is a fixed value K, so for a given K value, the calculation formulas of precision and recall are as follows:
(5)Precision@K=Recall@K=R∩TK.


### 3.3. Personalized Attraction Recommendation Algorithm Based on Bayesian Network Learning

It is a graph whose operations involve knowledge related to probability [20], often using probability as a way to predict the relationship between two. It is a typical Bayesian network diagram. From this, it can be seen that if the probability of X3 is calculated, it needs to rely on X1 and X2, which involves probability problems. The following is a brief introduction to Bayesian probability.The Bayesian formula is a conditional probability formula, such asPA∣B, which represents the probability of A when the condition of B occurs. The calculation formula is shown in Formula (6), where PA,B represents the probability that A and B occur at the same time; the calculation formulas of PA∣B and PB∣A can be obtained as follows:
(6)PAB=PA,BPB,(7)PBA=PA,BPA.The formula for calculating the Bayesian posterior probability after processing is as follows:(8)PAB=PAPBAPB.Bayes’ theorem, often used in computing the likelihood of conditional probabilities, quantifies the relationship between the two. For example, letX be a data primitive with n attribute values x1,x2,⋯xn; for the classification problem, Bayes’ theorem provides a method consisting of PH, PX, and PX∣H; similar to Equation (9), the formula is
(9)PHX=PXHPHPX.Bayesian is each feature in a special set. And from the knowledge of probability, whenA and B are independent of each other, PAB=PAPB. The formula for calculating is
(10)PXH=∏k=1nPxkH=Px1HPx2H⋯PxnH.User preference model is a very challenging problem in information system. At present, it mainly deals with the automatic discovery of user preferences and uses the model. As personalization and recommendation services become increasingly popular on the Internet and e-commerce, it is becoming more and more important to understand user preferences. Intelligent information system can analyze what users need and predict the products that users will choose in the future. On the basis of users’ different preferences, the intelligent system can recommend products of interest to each user and provide personalized services. In the stage of predicting user preference, it is necessary for liking item, and probability the user liking the item can be presented in a probabilistic manner. Finally, users are recommended according to the probability. The specific process of inferring scenic spots for users is as follows.First, define user sets and sights sets, and define users asU=u1,u2,⋯un, representing n users, where uii∈n represents user feature vectors (basic user attributes), including user statistics information (user label (sex) and gender (uSex), age (uAge)), position (uLocation), and sign-in time (uTime), that is, <uId,uAge,uSex,uLocation,uTime> indicate a user feature vector. Then, by calculating the probability that the scenic spot is recommended to the user, this probability is called the recommendation degree. Finally, according to this probability, it is determined whether the scenic spot is worth recommending to the user. The recommendation degree is obtained by improving Formula (11), that is, the calculation formula of the recommendation degree recommended by the scenic spot to the user is as follows:
(11)Paiuj=PaiPujaiPuj.Definition the similarity between attributes of user demographic, namelySimu,k, and its is:
(12)Simfu,k=Nfu∩NfkNfu∪Nfk.(13)Simbu,k=∑a∈Cu,kNsuaNska∑a∈CuNsua2∑a∈CkNSka2.DefinitionSiu,k is as follows:
(14)Simu,k=bSimbu,k+1−bSimfu,k.


## 3.1. Personalized Attractions Recommendation Algorithm Based on Social Networks

A complete tourism recommendation system should provide a complete set of personalized tourism recommendation programs, which is divided into two steps: scenic spot recommendation and path planning. For scenic spot recommendation, existing recommendation algorithms such as collaborative filtering and content-based and social network-based methods such as single data source are difficult to describe users' dynamic interests. The existing research generally regards it as TSP problem and NP hard problem, so most of them adopt heuristic algorithm. However, in tourism planning, only the length of the turnover path between scenic spots, the user time limit, and the opening time limit are usually considered. This chapter presents a social network (based on the social network with personalized tourist attraction recommendation, ptar). The purpose is to predict the next possible scenic spots for users and give real-time recommendations, which is different from the traditional recommendation algorithm. The algorithm processing steps are to first cluster users and attractions and replace the user and attractions matrix in the personalized rule-based algorithm proposed by Ma et al. [18] with the results obtained by clustering. Tourism planning is an applied science. At present, there is no perfect theoretical system of tourism planning. International discussions on tourism planning theory are often scattered. The main problems are as follows: (1) the theories and norms of urban planning and regional planning have replaced tourism planning. The standardization of scenic spot planning has replaced the tourism area planning, and there is little research on the theory and method of tourism planning itself. (2) There is little systematic thinking about the theory of tourism planning, and there is no systematic research on the ideological methods and models of tourism planning. (3) The concept system of tourism planning is not standardized, and the understanding of tourism and its related concepts is even far from satisfactory.For the above problems, this paper proposes a personalized travel recommendation system framework based on knowledge graph and user footprint. First, establish a knowledge map of the attractions, The knowledge map includes scenic introduction, comments, time, and other information, It provides data support for scenic spot recommendation and path planning; next, personalized scenic attraction recommendations through a deep interest evolution network. The model uses recurrent neural network and adds attention mechanism to describe the diversity and dynamic change of user interests. The model input mainly includes the scenic spot sequence in the user's footprint and the scenic spots to be recommended. Input information of scenic spots can be obtained through knowledge map, including scenic spot ID, scenic spot tag, comment tag, scenic spot introduction, and nearby scenic spots. Finally, the user’s own travel days, the opening time of the scenic spot, the travel time of the scenic spot, and other factors are added to the fitness function. Appropriate heuristic algorithm is adopted for reasonable path planning.As shown in Figure4, the algorithm based on user data and social data is described as follows: First, users are processed, and users in certain locations are clustered together according to their preferences and geographic location information. Use the coupled bidirectional clustering algorithm to cluster users into a suitable category. Secondly, the scenic spots are processed. The frame processing is shown in Figure 5.Figure 4
Recommendation algorithm for personalized tourist attractions based on social network.Figure 5
Algorithm processing frame diagram.From previous research work, it can be concluded that clustering users is generally used to improve the recommendation accuracy by obtaining “appropriate” friend groups. The coupled two-way clustering algorithm (CTWC) is used to cluster the dataset, which has been verified in the literature [19].The scenic spot asPc; then, the scenic spot category is replaced. The quality of the clustering results is related to the dataset selected during the experiment, especially the prefiltering requirements for the scenic spots in the dataset. Therefore, the tourist attractions selected in this paper must have more than 3 users who have traveled to the scenic spots to avoid data collection.The introduction of DBSCAN clustering algorithm is shown in Section 2.5. The date of scenic spot are shown in Table1.Table 1
Clustering results of photo attractions with geographic information.
Clustering parametersAttractionsClustering resultsEps (km)MinPtsGreat WallTiananmen SquareSummer palaceWater cubeNumber of categoriesNoise rate (%)0.51030035023002405563.7020150312210021322271.883011728612561861476.3011057056027653507046.292040052024603212358.603026049814862461563.0231072470062034205022.322068066850793852930.943064862348623431837.06This paper introduces the friend relationship in the social network into the tourist research. A social network-based (PTAR) is proposed, which fully considers friends in social network relationships and friends with similar interests. According to the personalized rule algorithm, this paper defines the following objective function:(1)minU,PLT,Uc,Pc=12∑i=1m∑k=1nIikTik−UicTPkc+β2∑i=1m∑f∈Fisk,fUic−UfcF2+λ12UcF2+λ22PcF2.T represents the user-spots matrix, Uic represents the user 𝑖’s scenic spot set, and Pkc represents the scenic spot k set. Iik is an indicator function; if the user Uic gives the attraction Pkc action, then Iik=1; otherwise, Iik=0. 𝑇𝑖𝑘 represents the number of photos, the user Uic gives to the scenic spot Pkc, Uic and Ufc represent the user vector, Pkc represents the scenic spot vector, and F2 represents the Frobenius norm. α and β represent the added social network information, and α>0, and β>0. Lk,f represents degree of correlation between the scenic spot Pkc and the user Ufc; if the user acts on the scenic spot, it indicates that the correlation between the two is relatively high, and the user Ufc has a high degree of correlation to the user Uic. The contribution is relatively small; si,f represents the relationship between the user Uic, si,f is a greater difference between users, that is Uic and Ufc, the greater the difference between users. The last two terms are a regularization term, in order to avoid overfitting of the objective function.


## 3.2. Experiment Evaluation Index of Evaluation Recommendation Algorithm

In this paper, quantitative description is used, and the prediction accuracy is selected to measure the ability of a recommendation algorithm. Different research directions use different evaluation indicators. The accuracy of the general forecast is represented as calculated in the following formulas:(2)MAE=1T∑u,i∈TRui−Rul¯,(3)RMSE=1T∑u,i∈TRui−Rul¯2.In Formulas (2) and (3), Rui is real rating u, Rui is the item i obtained i through the recommendation algorithm, and T is test sets.The prediction accuracy of Top-N recommendations is generally measured by precision and recall; letu represent the list of recommended actions on the training set, and Tu represent the list of actions on the test set. The formulas for calculating the recall rate (Recall) and the precision rate (Precision) of the recommended results are as follows:
(4)Recall=∑uϵURu∩Tu∑uϵUTu,Precision=∑u∈URu∩Tu∑u∈URu.In the experiment,R represents the scenic spots actually visited by the user, and the recommendation result generated by the personalized scenic spot recommendation algorithm represented by T. It is recommended to use the TopK method for the final result, that is, the length of the recommended result is a fixed value K, so for a given K value, the calculation formulas of precision and recall are as follows:
(5)Precision@K=Recall@K=R∩TK.


## 3.3. Personalized Attraction Recommendation Algorithm Based on Bayesian Network Learning

It is a graph whose operations involve knowledge related to probability [20], often using probability as a way to predict the relationship between two. It is a typical Bayesian network diagram. From this, it can be seen that if the probability of X3 is calculated, it needs to rely on X1 and X2, which involves probability problems. The following is a brief introduction to Bayesian probability.The Bayesian formula is a conditional probability formula, such asPA∣B, which represents the probability of A when the condition of B occurs. The calculation formula is shown in Formula (6), where PA,B represents the probability that A and B occur at the same time; the calculation formulas of PA∣B and PB∣A can be obtained as follows:
(6)PAB=PA,BPB,(7)PBA=PA,BPA.The formula for calculating the Bayesian posterior probability after processing is as follows:(8)PAB=PAPBAPB.Bayes’ theorem, often used in computing the likelihood of conditional probabilities, quantifies the relationship between the two. For example, letX be a data primitive with n attribute values x1,x2,⋯xn; for the classification problem, Bayes’ theorem provides a method consisting of PH, PX, and PX∣H; similar to Equation (9), the formula is
(9)PHX=PXHPHPX.Bayesian is each feature in a special set. And from the knowledge of probability, whenA and B are independent of each other, PAB=PAPB. The formula for calculating is
(10)PXH=∏k=1nPxkH=Px1HPx2H⋯PxnH.User preference model is a very challenging problem in information system. At present, it mainly deals with the automatic discovery of user preferences and uses the model. As personalization and recommendation services become increasingly popular on the Internet and e-commerce, it is becoming more and more important to understand user preferences. Intelligent information system can analyze what users need and predict the products that users will choose in the future. On the basis of users’ different preferences, the intelligent system can recommend products of interest to each user and provide personalized services. In the stage of predicting user preference, it is necessary for liking item, and probability the user liking the item can be presented in a probabilistic manner. Finally, users are recommended according to the probability. The specific process of inferring scenic spots for users is as follows.First, define user sets and sights sets, and define users asU=u1,u2,⋯un, representing n users, where uii∈n represents user feature vectors (basic user attributes), including user statistics information (user label (sex) and gender (uSex), age (uAge)), position (uLocation), and sign-in time (uTime), that is, <uId,uAge,uSex,uLocation,uTime> indicate a user feature vector. Then, by calculating the probability that the scenic spot is recommended to the user, this probability is called the recommendation degree. Finally, according to this probability, it is determined whether the scenic spot is worth recommending to the user. The recommendation degree is obtained by improving Formula (11), that is, the calculation formula of the recommendation degree recommended by the scenic spot to the user is as follows:
(11)Paiuj=PaiPujaiPuj.Definition the similarity between attributes of user demographic, namelySimu,k, and its is:
(12)Simfu,k=Nfu∩NfkNfu∪Nfk.(13)Simbu,k=∑a∈Cu,kNsuaNska∑a∈CuNsua2∑a∈CkNSka2.DefinitionSiu,k is as follows:
(14)Simu,k=bSimbu,k+1−bSimfu,k.


## 4. Simulation and Results

### 4.1. Empirical Analysis of Recommendation Algorithms

The effect of these parameters on the experiment is discussed below.(1)
The parametersα and βaffect the calculation under different sparsity. Of course, training sets with different degrees of sparsity have different effects on α and β on MAE and RMSE. Since α generally has the same trend of error as β, this paper only considers the parameterα alone (follow in Figures 6 and Figure 7)Figure 6
The effect ofα on the mean absolute error under different sparsity.Figure 7
The effect ofα on the root mean square error under different sparsity.From Figures6 and 7, at the beginning, with the increase of α, MAE and RMSE have been decreasing (accuracy increases), but when α increases to a certain extent, MAE and RMSE increase again (accuracy decreases).The initial step of the framework is users. The main step is to use the friend, and tag information regularization term finally merges the user’s friend relationship and tag information to obtain the final recommendation. Forα and β in this method is friend and label information should be included in the proposed method. Ultimately, one should find a suitable value to balance. In the experiment, the trend change of the effect only affects the prediction accuracy of the experiment. Probability is an important index reflecting risk and uncertainty. Probability estimation has trend effect and will affect decision-making. The trend of the change of probability estimation and the trend of unilateral probability estimation reveal the influence of the trend effect of probability estimation on individual judgment, decision-making behavior, and irrational decision-making bias. Set the dimension of the space to 30, and the meaning of Precision@1 is accuracy of the recommended number of 1. The result is shown in Figure 8.Figure 8
Influence of parameterα on Precision@1.From Figures8 and 9, as α increases, the accuracy gradually increases, and the recommendation accuracy also increases, but when the parameter α increases to 0.01, the accuracy decreases. Therefore, the value of α is finally set to 0.01 to predict the accuracy of the recommendation results.Figure 9
Influence of dimension of feature space on Precision@1.In a dimensionality, in this experiment, the values of the parametersα and β were set to 0.01 according to the above experiments. Select the dimension=30,50,80,100,120, respectively, to verify the effectiveness of the method. In this way, in order for the algorithm to converge quickly, the learning rate is reduced by 10%. To verify the effectiveness of the contextual attention module, we compare the impact of each contextual module on the performance of the model separately. As shown in Tables 2 and 3, the BGMF model is a model without user context and POI context, MANC-U is a model with a user context module on the BGMF model, and MANC-U is based on BGMF with interest point context model. It can be observed from table: (1) On both datasets, MANC outperforms MANC-P and MANC-U, mainly because MANC and POI neighborhood context. (2) MANC-U and MANC-P are higher than and BGMF in all four evaluation indicators. For example, in ranking top-10, MANC-U achieves 20.8% accuracy improvement over BGMF on Gowalla dataset, while MANC-P achieves 19.2% accuracy improvement over BGMF on Gowalla dataset.Table 2
Recommendation results for different contexts under the Gowalla dataset.
Precision@10Recall@10NDCG@10MSP@10BGMF0.077270.079280.076040.03736MANC-U0.083720.112790.071680.02538MANC_P0.082450.113570.017040.06144MANC0.084220.121350.072310.06373Table 3
Recommendation results of different contexts under Yelp dataset.
Precision@10Recall@10NDCG@10MSP@10BGMF0.042520.064210.033060.03348MANC-U0.053750.073830.022710.03301MANC_P0.053630.073210.034740.03487MANC0.054590.075180.023020.03401Through the analysis of the parameters in the objective function, it is known that whenα and β to 0.01, the efficiency τis set to 0.5, the dimension is set to 80, andγ is set to 0.8; the objective function in the algorithm can reach the optimal solution. For rationality of each parameter setting in PTAR, we compares the performance of PTAR with the traditional collaborative filtering scenic spot recommendation algorithm, the collaborative filtering method based on the appropriate time of the scenic spot, and the tag-based scenic spot recommendation algorithm. The number of recommended accuracy rates is set to 1, 3, and 5 (Precision@1, Precision@3, and Precision@5), and Recall@5 represents the recall rate when the user recommends 5 scenic spots. The experimental results are shown in Figure 10. U-cf stands for user-based collaborative filtering recommendation algorithm. Ptlr (personalized travel location recommendation) represents a collaborative filtering method based on the appropriate time of the scenic spot, and a label based stands for algorithm. Among them, the user-based filtering recommendation algorithm (U-CF) calculates the user’s preference for scenic spots. The formula is as follows:
(15)pu,i=∑v∈Nusu,vfv,i.Figure 10
Comparison of algorithm accuracy.In Figure10, the horizontal axis P@1, P@3, and P@5 represent Precision@1, Precision@3, and Precision@5. This recommended accuracy. It can be clearly seen that the performance of the PTAR algorithm is obvious. It performs better than previous methods, and the recommendation accuracy rate is higher. From Precision@1, Precision@3, and Precision@5, it can be found that the recommendation accuracy rate of the tourist attraction about social network is very different because the number of recommendations. And the smaller the parts of recommendations, the higher the recommendation accuracy rate. So, setting a reasonable number of recommendations is crucial for algorithm research in future work.


## 4.1. Empirical Analysis of Recommendation Algorithms

The effect of these parameters on the experiment is discussed below.(1)
The parametersα and βaffect the calculation under different sparsity. Of course, training sets with different degrees of sparsity have different effects on α and β on MAE and RMSE. Since α generally has the same trend of error as β, this paper only considers the parameterα alone (follow in Figures 6 and Figure 7)Figure 6
The effect ofα on the mean absolute error under different sparsity.Figure 7
The effect ofα on the root mean square error under different sparsity.From Figures6 and 7, at the beginning, with the increase of α, MAE and RMSE have been decreasing (accuracy increases), but when α increases to a certain extent, MAE and RMSE increase again (accuracy decreases).The initial step of the framework is users. The main step is to use the friend, and tag information regularization term finally merges the user’s friend relationship and tag information to obtain the final recommendation. Forα and β in this method is friend and label information should be included in the proposed method. Ultimately, one should find a suitable value to balance. In the experiment, the trend change of the effect only affects the prediction accuracy of the experiment. Probability is an important index reflecting risk and uncertainty. Probability estimation has trend effect and will affect decision-making. The trend of the change of probability estimation and the trend of unilateral probability estimation reveal the influence of the trend effect of probability estimation on individual judgment, decision-making behavior, and irrational decision-making bias. Set the dimension of the space to 30, and the meaning of Precision@1 is accuracy of the recommended number of 1. The result is shown in Figure 8.Figure 8
Influence of parameterα on Precision@1.From Figures8 and 9, as α increases, the accuracy gradually increases, and the recommendation accuracy also increases, but when the parameter α increases to 0.01, the accuracy decreases. Therefore, the value of α is finally set to 0.01 to predict the accuracy of the recommendation results.Figure 9
Influence of dimension of feature space on Precision@1.In a dimensionality, in this experiment, the values of the parametersα and β were set to 0.01 according to the above experiments. Select the dimension=30,50,80,100,120, respectively, to verify the effectiveness of the method. In this way, in order for the algorithm to converge quickly, the learning rate is reduced by 10%. To verify the effectiveness of the contextual attention module, we compare the impact of each contextual module on the performance of the model separately. As shown in Tables 2 and 3, the BGMF model is a model without user context and POI context, MANC-U is a model with a user context module on the BGMF model, and MANC-U is based on BGMF with interest point context model. It can be observed from table: (1) On both datasets, MANC outperforms MANC-P and MANC-U, mainly because MANC and POI neighborhood context. (2) MANC-U and MANC-P are higher than and BGMF in all four evaluation indicators. For example, in ranking top-10, MANC-U achieves 20.8% accuracy improvement over BGMF on Gowalla dataset, while MANC-P achieves 19.2% accuracy improvement over BGMF on Gowalla dataset.Table 2
Recommendation results for different contexts under the Gowalla dataset.
Precision@10Recall@10NDCG@10MSP@10BGMF0.077270.079280.076040.03736MANC-U0.083720.112790.071680.02538MANC_P0.082450.113570.017040.06144MANC0.084220.121350.072310.06373Table 3
Recommendation results of different contexts under Yelp dataset.
Precision@10Recall@10NDCG@10MSP@10BGMF0.042520.064210.033060.03348MANC-U0.053750.073830.022710.03301MANC_P0.053630.073210.034740.03487MANC0.054590.075180.023020.03401Through the analysis of the parameters in the objective function, it is known that whenα and β to 0.01, the efficiency τis set to 0.5, the dimension is set to 80, andγ is set to 0.8; the objective function in the algorithm can reach the optimal solution. For rationality of each parameter setting in PTAR, we compares the performance of PTAR with the traditional collaborative filtering scenic spot recommendation algorithm, the collaborative filtering method based on the appropriate time of the scenic spot, and the tag-based scenic spot recommendation algorithm. The number of recommended accuracy rates is set to 1, 3, and 5 (Precision@1, Precision@3, and Precision@5), and Recall@5 represents the recall rate when the user recommends 5 scenic spots. The experimental results are shown in Figure 10. U-cf stands for user-based collaborative filtering recommendation algorithm. Ptlr (personalized travel location recommendation) represents a collaborative filtering method based on the appropriate time of the scenic spot, and a label based stands for algorithm. Among them, the user-based filtering recommendation algorithm (U-CF) calculates the user’s preference for scenic spots. The formula is as follows:
(15)pu,i=∑v∈Nusu,vfv,i.Figure 10
Comparison of algorithm accuracy.In Figure10, the horizontal axis P@1, P@3, and P@5 represent Precision@1, Precision@3, and Precision@5. This recommended accuracy. It can be clearly seen that the performance of the PTAR algorithm is obvious. It performs better than previous methods, and the recommendation accuracy rate is higher. From Precision@1, Precision@3, and Precision@5, it can be found that the recommendation accuracy rate of the tourist attraction about social network is very different because the number of recommendations. And the smaller the parts of recommendations, the higher the recommendation accuracy rate. So, setting a reasonable number of recommendations is crucial for algorithm research in future work.


## 5. Conclusion

The focus of this paper is on the research algorithm of tourist attractions. In order to meet the needs of tourists’ personalized attractions to the greatest extent, this paper has done the following main research work:(1)
Propose an algorithm based on social network: Firstly analyze the challenges faced by the recommendation method of it based on location social network; then use the algorithm for users and attractions, respectively, and use the coupled bidirectional clustering algorithm for users. The DBSCAN algorithm is used for scenic spots; finally, it is applied to the personalized rule algorithm to predict scenic spots and recommend tourist attractions to users. We need to verify the accuracy of the recommendation, and this algorithm is compared with some traditional algorithms, so this experimental results tell that this algorithm has a higher recommendation accuracy(2)
We have a better prediction for tourist attractions that they are most likely to visit next, for the tourist attractions algorithm by proposed by this paper; this is based on Bayesian learning. Use algorithms and demographic methods to process users. Then, the content-based method is used to process the data of scenic spots and initially build a model. This has been verified in the collection. For us to solve some problems, it has better advantages for new users and new attractionsHowever, the research still has some limitations. For a category variable feature in the test set, if it is not seen in the training set, the probability is 0, and the prediction function fails. Naive Bayes has the assumption of distribution independence, but in real life, these predictors are difficult to be completely independent. Therefore, future research needs to analyze the shortcomings of the algorithm.



---

*Source: 1191419-2022-09-12.xml*