[go: up one dir, main page]

CN115099326A - Behavior prediction method, device, equipment and storage medium based on artificial intelligence - Google Patents

Behavior prediction method, device, equipment and storage medium based on artificial intelligence Download PDF

Info

Publication number
CN115099326A
CN115099326A CN202210699251.8A CN202210699251A CN115099326A CN 115099326 A CN115099326 A CN 115099326A CN 202210699251 A CN202210699251 A CN 202210699251A CN 115099326 A CN115099326 A CN 115099326A
Authority
CN
China
Prior art keywords
feature
behavior
refueling
prediction
user
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210699251.8A
Other languages
Chinese (zh)
Inventor
李雨洁
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ping An Property and Casualty Insurance Company of China Ltd
Original Assignee
Ping An Property and Casualty Insurance Company of China Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ping An Property and Casualty Insurance Company of China Ltd filed Critical Ping An Property and Casualty Insurance Company of China Ltd
Priority to CN202210699251.8A priority Critical patent/CN115099326A/en
Publication of CN115099326A publication Critical patent/CN115099326A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/02Marketing; Price estimation or determination; Fundraising
    • G06Q30/0201Market modelling; Market analysis; Collecting market data
    • G06Q30/0202Market predictions or forecasting for commercial activities

Landscapes

  • Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Theoretical Computer Science (AREA)
  • Strategic Management (AREA)
  • Finance (AREA)
  • Physics & Mathematics (AREA)
  • Development Economics (AREA)
  • Accounting & Taxation (AREA)
  • Entrepreneurship & Innovation (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Biophysics (AREA)
  • Biomedical Technology (AREA)
  • General Engineering & Computer Science (AREA)
  • Molecular Biology (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • General Health & Medical Sciences (AREA)
  • Computational Linguistics (AREA)
  • Evolutionary Computation (AREA)
  • Computing Systems (AREA)
  • Artificial Intelligence (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Health & Medical Sciences (AREA)
  • Game Theory and Decision Science (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • General Business, Economics & Management (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The embodiment of the application belongs to the field of artificial intelligence, and relates to a behavior prediction method based on artificial intelligence, which comprises the following steps: acquiring user behavior data of a target user within a preset time period; performing characteristic construction on the user behavior data to generate a refueling behavior characteristic; the method comprises the steps of screening the refueling behavior characteristics based on a principal component analysis algorithm to obtain first characteristics, and screening the refueling behavior characteristics based on a preset characteristic selection algorithm to obtain second characteristics; determining a target fueling behavior characteristic based on the first characteristic and the second characteristic; and predicting the target refueling characteristic through the prediction model to generate a refueling behavior prediction result corresponding to the target user. The application also provides a behavior prediction device based on artificial intelligence, computer equipment and a storage medium. In addition, the application also relates to a block chain technology, and the refueling behavior prediction result can be stored in the block chain. The method and the device improve the processing efficiency and accuracy of the prediction of the refueling behavior intention of the user.

Description

基于人工智能的行为预测方法、装置、设备及存储介质Behavior prediction method, device, equipment and storage medium based on artificial intelligence

技术领域technical field

本申请涉及人工智能技术领域,尤其涉及基于人工智能的行为预测方法、装置、设备及存储介质。The present application relates to the technical field of artificial intelligence, and in particular, to a method, apparatus, device and storage medium for behavior prediction based on artificial intelligence.

背景技术Background technique

随着互联网技术的高速发展,越来越多的用户行为数据被记录了下来,大量的线上线下数据为纷繁的应用带来了可能。对于广大车主用户的加油服务的刚性需求,当下出现了一些智能类的汽车类应用,通过在应用内引入预付费、无感加油的全新加油模式,让车主可以畅享车生活,为车主节省了相当可观的出行成本。为了打造更好的加油服务,现有的营销业务员会对汽车类应用内的关于加油服务的用户历史行为数据进行人工深入分析,根据车主用户的服务偏好或服务意愿,来人工预测出车主用户未来的加油意向,并通过给不同类别的车主用户发券,引导车主用户进入平台享受服务,以提升用户的忠诚度和服务体验来实现高效营销。然而,由于用户历史行为数据会随着时间累积变得越来越多,采用现有的人工预测车主用户未来的加油意向的处理方式需要耗费较多的人力物力,处理效率较低,且无法保证预测结果的准确性。With the rapid development of Internet technology, more and more user behavior data has been recorded, and a large amount of online and offline data has brought possibilities for numerous applications. In response to the rigid demand for refueling services of car owners and users, some smart car applications have appeared. By introducing a new refueling mode of prepaid and non-inductive refueling in the application, car owners can enjoy their car life and save money for car owners. Considerable travel costs. In order to create a better refueling service, the existing marketing salesmen will conduct in-depth manual analysis of the historical user behavior data of the refueling service in the automotive application, and manually predict the car owner and user according to the service preference or service willingness of the car owner and user. Refueling intention in the future, and by issuing coupons to different types of car owners and users, guide car owners and users to enter the platform to enjoy services, so as to improve user loyalty and service experience to achieve efficient marketing. However, since the user's historical behavior data will become more and more accumulated over time, the existing processing method of manually predicting the future refueling intention of the car owner and user requires a lot of manpower and material resources, the processing efficiency is low, and there is no guarantee The accuracy of the forecast results.

发明内容SUMMARY OF THE INVENTION

本申请实施例的目的在于提出一种基于人工智能的行为预测方法、装置、计算机设备及存储介质,以解决现有的人工预测车主用户未来的加油意向的处理方式需要耗费较多的人力物力,处理效率较低,且无法保证预测结果的准确性的问题。The purpose of the embodiments of the present application is to propose a behavior prediction method, device, computer equipment and storage medium based on artificial intelligence, so as to solve the problem that the existing processing method of manually predicting the future refueling intention of vehicle owners and users requires a lot of manpower and material resources, The processing efficiency is low, and the accuracy of the prediction results cannot be guaranteed.

为了解决上述技术问题,本申请实施例提供一种基于人工智能的行为预测方法,采用了如下所述的技术方案:In order to solve the above-mentioned technical problems, the embodiment of the present application provides a behavior prediction method based on artificial intelligence, and adopts the following technical solutions:

获取目标用户在预设时间段内的用户行为数据;Obtain user behavior data of target users within a preset time period;

对所述用户行为数据进行特征构建处理,基于所述用户行为数据生成加油行为特征;其中,所述加油行为特征的数量包括多个;Perform feature construction processing on the user behavior data, and generate fueling behavior features based on the user behavior data; wherein, the number of the fueling behavior features includes multiple;

基于主成分分析算法对所述加油行为特征进行筛选处理得到第一特征,以及基于预设的特征选取算法对所述加油行为特征进行筛选处理得到第二特征;The first feature is obtained by screening the refueling behavior feature based on a principal component analysis algorithm, and the second feature is obtained by screening the refueling behavior feature based on a preset feature selection algorithm;

基于所述第一特征与所述第二特征确定出与所述用户行为数据对应的目标加油行为特征;determining a target fueling behavior feature corresponding to the user behavior data based on the first feature and the second feature;

将所述目标加油行为特征输入至预设的预测模型内,通过所述预测模型对所述目标加油特征进行预测处理,生成与所述目标用户对应的加油行为预测结果。The target refueling behavior feature is input into a preset prediction model, and prediction processing is performed on the target refueling feature through the prediction model to generate a refueling behavior prediction result corresponding to the target user.

进一步的,所述基于主成分分析算法对所述加油行为特征进行筛选处理得到第一特征的步骤,具体包括:Further, the step of screening the refueling behavior feature based on the principal component analysis algorithm to obtain the first feature specifically includes:

基于所述加油行为特征构建相关系数矩阵;constructing a correlation coefficient matrix based on the refueling behavior feature;

基于所述主成分分析算法对所述相关系数矩阵进行降维处理,得到多个主成分;Perform dimensionality reduction processing on the correlation coefficient matrix based on the principal component analysis algorithm to obtain a plurality of principal components;

计算每个所述主成分的方差贡献率,将所有所述方差贡献率按照从大到小的顺序进行排序,并依次累加直至超过预设的累加方差贡献率阈值;Calculate the variance contribution rate of each of the principal components, sort all the variance contribution rates in descending order, and accumulate them in turn until exceeding the preset cumulative variance contribution rate threshold;

从所有所述方差贡献率中筛选出与累加处理对应的指定主成分,并将所述指定主成分对应的特征作为所述第一特征。A designated principal component corresponding to the accumulation process is selected from all the variance contribution rates, and the feature corresponding to the designated principal component is used as the first feature.

进一步的,所述基于所述第一特征与所述第二特征确定出与所述用户行为数据对应的目标加油行为特征的步骤,具体包括:Further, the step of determining the target fueling behavior feature corresponding to the user behavior data based on the first feature and the second feature specifically includes:

对所述第一特征与所述第二特征进行合并处理,得到对应的特征集合;Merging the first feature and the second feature to obtain a corresponding feature set;

对所述特征集合中的所有特征进行匹配处理,获取所述特征集合中重复出现的第三特征;Perform matching processing on all the features in the feature set, and obtain a third feature that appears repeatedly in the feature set;

将所述第三特征作为所述目标加油行为特征。The third feature is used as the target fueling behavior feature.

进一步的,所述预测模型包括输入层、LSTM层、全连接层与输出层,所述将所述目标加油行为特征输入至预设的预测模型内,通过所述预测模型对所述目标加油特征进行预测处理,生成与所述目标用户对应的加油行为预测结果的步骤,具体包括:Further, the prediction model includes an input layer, an LSTM layer, a fully connected layer and an output layer, and the target fueling behavior feature is input into a preset prediction model, and the target fueling feature is analyzed by the prediction model. The steps of performing prediction processing to generate a prediction result of refueling behavior corresponding to the target user specifically include:

将所述目标加油行为特征输入至所述预测模型的输入层内,通过所述输入层生成与所述目标加油行为特征对应的输出矩阵;Inputting the target refueling behavior feature into an input layer of the prediction model, and generating an output matrix corresponding to the target refueling behavior feature through the input layer;

将所述输出矩阵输入至所述预测模型的LSTM层内,通过所述LSTM层生成与所述输出矩阵对应的输出向量;Inputting the output matrix into the LSTM layer of the prediction model, and generating an output vector corresponding to the output matrix through the LSTM layer;

将所述输出向量输入至所述预测模型的全连接层内,基于所述全连接层内的预设激活函数生成与所述输出向量对应的预测分类结果;inputting the output vector into a fully connected layer of the prediction model, and generating a prediction classification result corresponding to the output vector based on a preset activation function in the fully connected layer;

将所述预测分类结果输入至所述预测模型的输出层内,通过所述输出层输出所述预测分类结果,并将所述预测分类结果作为与所述目标用户对应的加油行为预测结果。The prediction classification result is input into the output layer of the prediction model, the prediction classification result is output through the output layer, and the prediction classification result is used as the refueling behavior prediction result corresponding to the target user.

进一步的,在所述将所述目标加油行为特征输入至预设的预测模型,通过所述预测模型对所述目标加油特征进行预测处理,生成与所述目标用户对应的加油行为预测结果的步骤之前,还包括:Further, in the step of inputting the target refueling behavior feature into a preset prediction model, performing prediction processing on the target refueling feature through the prediction model, and generating a refueling behavior prediction result corresponding to the target user. Before, also included:

获取预先收集的加油样本数据;Obtain pre-collected fueling sample data;

按照预设比例将所述加油样本数据划分为训练集与测试集;Divide the refueling sample data into a training set and a test set according to a preset ratio;

获取预先构建的初始预测模型;Get a pre-built initial prediction model;

基于随机梯度下降算法,使用所述训练集对所述初始预测模型进行训练,得到训练后的初始预测模型;Based on the stochastic gradient descent algorithm, use the training set to train the initial prediction model to obtain a trained initial prediction model;

使用所述测试集对所述训练后的初始预测模型进行验证;Validating the trained initial prediction model using the test set;

若所述训练后的初始预测模型通过验证,将所述训练后的初始预测模型作为所述预测模型。If the trained initial prediction model passes the verification, the trained initial prediction model is used as the prediction model.

进一步的,所述使用所述测试集对所述训练后的初始预测模型进行验证,并判断是否验证通过的步骤,具体包括:Further, the step of using the test set to verify the trained initial prediction model and judging whether the verification passes, specifically includes:

获取所述测试集;其中,所述测试集包括多个测试数据,以及与各所述测试数据分别对应的分类信息;obtaining the test set; wherein, the test set includes a plurality of test data, and classification information corresponding to each of the test data respectively;

将所述测试数据输入至所述训练后的初始预测模型内,获取所述训练后的初始预测模型输出的与各所述测试数据分别对应的第一预测分类结果;Inputting the test data into the initial prediction model after training, and obtaining the first prediction classification result output by the initial prediction model after training and corresponding to each of the test data respectively;

基于所述分类信息,确定出所有所述第一预测分类结果中预测正确的第二预测分类结果;determining, based on the classification information, a second prediction classification result that is correctly predicted among all the first prediction classification results;

计算所述第二预测分类结果与所述第一预测分类结果的商值;calculating the quotient of the second predicted classification result and the first predicted classification result;

判断所述商值是否大于预设阈值;judging whether the quotient is greater than a preset threshold;

若大于所述预设阈值,判定所述训练后的初始预测模型通过验证,否则判定所述训练后的初始预测模型未通过验证。If it is greater than the preset threshold, it is determined that the trained initial prediction model has passed the verification; otherwise, it is determined that the trained initial prediction model has not passed the verification.

进一步的,所述获取目标用户在预设时间段内的用户行为数据的步骤,具体包括:Further, the step of acquiring the user behavior data of the target user within a preset time period specifically includes:

获取在所述预设时间段内的页面用户行为数据,以及获取所述目标用户的用户信息;Acquiring page user behavior data within the preset time period, and acquiring user information of the target user;

基于所述用户信息,从所述页面用户行为数据内筛选出与所述用户信息对应的指定页面用户行为数据;Based on the user information, filter out the user behavior data of the specified page corresponding to the user information from the page user behavior data;

对所述指定页面用户行为数据进行预处理,得到所述用户行为数据。The user behavior data of the specified page is preprocessed to obtain the user behavior data.

为了解决上述技术问题,本申请实施例还提供一种基于人工智能的行为预测装置,采用了如下所述的技术方案:In order to solve the above-mentioned technical problems, the embodiment of the present application also provides a behavior prediction device based on artificial intelligence, which adopts the following technical solutions:

第一获取模块,用于获取目标用户在预设时间段内的用户行为数据;a first acquisition module, used to acquire user behavior data of the target user within a preset time period;

第一生成模块,用于对所述用户行为数据进行特征构建处理,基于所述用户行为数据生成加油行为特征;其中,所述加油行为特征的数量包括多个;a first generating module, configured to perform feature construction processing on the user behavior data, and generate refueling behavior features based on the user behavior data; wherein, the number of refueling behavior features includes multiple;

处理模块,用于基于主成分分析算法对所述加油行为特征进行筛选处理得到第一特征,以及基于预设的特征选取算法对所述加油行为特征进行筛选处理得到第二特征;a processing module, configured to perform a screening process on the refueling behavior feature based on a principal component analysis algorithm to obtain a first feature, and perform a screening process on the refueling behavior feature based on a preset feature selection algorithm to obtain a second feature;

第一确定模块,用于基于所述第一特征与所述第二特征确定出与所述用户行为数据对应的目标加油行为特征;a first determining module, configured to determine a target refueling behavior feature corresponding to the user behavior data based on the first feature and the second feature;

第二生成模块,用于将所述目标加油行为特征输入至预设的预测模型内,通过所述预测模型对所述目标加油特征进行预测处理,生成与所述目标用户对应的加油行为预测结果。The second generating module is configured to input the target fueling behavior feature into a preset prediction model, perform prediction processing on the target fueling feature through the prediction model, and generate a fueling behavior prediction result corresponding to the target user .

为了解决上述技术问题,本申请实施例还提供一种计算机设备,采用了如下所述的技术方案:In order to solve the above-mentioned technical problems, the embodiment of the present application also provides a computer device, which adopts the following technical solutions:

获取目标用户在预设时间段内的用户行为数据;Obtain user behavior data of target users within a preset time period;

对所述用户行为数据进行特征构建处理,基于所述用户行为数据生成加油行为特征;其中,所述加油行为特征的数量包括多个;Perform feature construction processing on the user behavior data, and generate fueling behavior features based on the user behavior data; wherein, the number of the fueling behavior features includes multiple;

基于主成分分析算法对所述加油行为特征进行筛选处理得到第一特征,以及基于预设的特征选取算法对所述加油行为特征进行筛选处理得到第二特征;The first feature is obtained by screening the refueling behavior feature based on a principal component analysis algorithm, and the second feature is obtained by screening the refueling behavior feature based on a preset feature selection algorithm;

基于所述第一特征与所述第二特征确定出与所述用户行为数据对应的目标加油行为特征;determining a target fueling behavior feature corresponding to the user behavior data based on the first feature and the second feature;

将所述目标加油行为特征输入至预设的预测模型内,通过所述预测模型对所述目标加油特征进行预测处理,生成与所述目标用户对应的加油行为预测结果。The target refueling behavior feature is input into a preset prediction model, and prediction processing is performed on the target refueling feature through the prediction model to generate a refueling behavior prediction result corresponding to the target user.

为了解决上述技术问题,本申请实施例还提供一种计算机可读存储介质,采用了如下所述的技术方案:In order to solve the above technical problems, the embodiments of the present application also provide a computer-readable storage medium, which adopts the following technical solutions:

获取目标用户在预设时间段内的用户行为数据;Obtain user behavior data of target users within a preset time period;

对所述用户行为数据进行特征构建处理,基于所述用户行为数据生成加油行为特征;其中,所述加油行为特征的数量包括多个;Perform feature construction processing on the user behavior data, and generate fueling behavior features based on the user behavior data; wherein, the number of the fueling behavior features includes multiple;

基于主成分分析算法对所述加油行为特征进行筛选处理得到第一特征,以及基于预设的特征选取算法对所述加油行为特征进行筛选处理得到第二特征;The first feature is obtained by screening the refueling behavior feature based on a principal component analysis algorithm, and the second feature is obtained by screening the refueling behavior feature based on a preset feature selection algorithm;

基于所述第一特征与所述第二特征确定出与所述用户行为数据对应的目标加油行为特征;determining a target fueling behavior feature corresponding to the user behavior data based on the first feature and the second feature;

将所述目标加油行为特征输入至预设的预测模型内,通过所述预测模型对所述目标加油特征进行预测处理,生成与所述目标用户对应的加油行为预测结果。The target refueling behavior feature is input into a preset prediction model, and prediction processing is performed on the target refueling feature through the prediction model to generate a refueling behavior prediction result corresponding to the target user.

与现有技术相比,本申请实施例主要有以下有益效果:Compared with the prior art, the embodiments of the present application mainly have the following beneficial effects:

在获取到目标用户在预设时间段内的用户行为数据后,会先对用户行为数据进行特征构建处理,基于用户行为数据生成加油行为特征,然后基于主成分分析算法对加油行为特征进行筛选处理得到第一特征,以及基于预设的特征选取算法对加油行为特征进行筛选处理得到第二特征,之后基于第一特征与第二特征确定出与用户行为数据对应的目标加油行为特征,最后将目标加油行为特征输入至预设的预测模型内,通过预测模型对目标加油特征进行预测处理,生成与目标用户对应的加油行为预测结果。本申请通过利用预测模型对目标用户对应的目标加油行为特征进行预测处理,可以实现快速准确地生成与目标用户对应的加油行为预测结果,有效提高对于目标用户的加油行为意向预测的处理效率与准确性。After obtaining the user behavior data of the target user within the preset time period, the user behavior data will be constructed and processed first, and the refueling behavior features will be generated based on the user behavior data, and then the refueling behavior features will be screened based on the principal component analysis algorithm. The first feature is obtained, and the refueling behavior feature is screened based on the preset feature selection algorithm to obtain the second feature, and then the target refueling behavior feature corresponding to the user behavior data is determined based on the first feature and the second feature, and finally the target refueling behavior feature is determined. The refueling behavior feature is input into a preset prediction model, and the target refueling feature is predicted through the prediction model to generate a refueling behavior prediction result corresponding to the target user. In the present application, by using the prediction model to predict and process the target refueling behavior characteristics corresponding to the target user, the prediction result of the refueling behavior corresponding to the target user can be quickly and accurately generated, and the processing efficiency and accuracy of the prediction of the refueling behavior intention of the target user can be effectively improved. sex.

附图说明Description of drawings

为了更清楚地说明本申请中的方案,下面将对本申请实施例描述中所需要使用的附图作一个简单介绍,显而易见地,下面描述中的附图是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to illustrate the solutions in the present application more clearly, the following will briefly introduce the accompanying drawings used in the description of the embodiments of the present application. For those of ordinary skill, other drawings can also be obtained from these drawings without any creative effort.

图1是本申请可以应用于其中的示例性系统架构图;FIG. 1 is an exemplary system architecture diagram to which the present application can be applied;

图2根据本申请的基于人工智能的行为预测方法的一个实施例的流程图;2 is a flowchart of an embodiment of the artificial intelligence-based behavior prediction method according to the present application;

图3是根据本申请的基于人工智能的行为预测装置的一个实施例的结构示意图;3 is a schematic structural diagram of an embodiment of an artificial intelligence-based behavior prediction device according to the present application;

图4是根据本申请的计算机设备的一个实施例的结构示意图。FIG. 4 is a schematic structural diagram of an embodiment of a computer device according to the present application.

具体实施方式Detailed ways

除非另有定义,本文所使用的所有的技术和科学术语与属于本申请的技术领域的技术人员通常理解的含义相同;本文中在申请的说明书中所使用的术语只是为了描述具体的实施例的目的,不是旨在于限制本申请;本申请的说明书和权利要求书及上述附图说明中的术语“包括”和“具有”以及它们的任何变形,意图在于覆盖不排他的包含。本申请的说明书和权利要求书或上述附图中的术语“第一”、“第二”等是用于区别不同对象,而不是用于描述特定顺序。Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the technical field of this application; the terms used herein in the specification of the application are for the purpose of describing specific embodiments only It is not intended to limit the application; the terms "comprising" and "having" and any variations thereof in the description and claims of this application and the above description of the drawings are intended to cover non-exclusive inclusion. The terms "first", "second" and the like in the description and claims of the present application or the above drawings are used to distinguish different objects, rather than to describe a specific order.

在本文中提及“实施例”意味着,结合实施例描述的特定特征、结构或特性可以包含在本申请的至少一个实施例中。在说明书中的各个位置出现该短语并不一定均是指相同的实施例,也不是与其它实施例互斥的独立的或备选的实施例。本领域技术人员显式地和隐式地理解的是,本文所描述的实施例可以与其它实施例相结合。Reference herein to an "embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the present application. The appearances of the phrase in various places in the specification are not necessarily all referring to the same embodiment, nor a separate or alternative embodiment that is mutually exclusive of other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.

为了使本技术领域的人员更好地理解本申请方案,下面将结合附图,对本申请实施例中的技术方案进行清楚、完整地描述。In order to make those skilled in the art better understand the solutions of the present application, the technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the accompanying drawings.

如图1所示,系统架构100可以包括终端设备101、102、103,网络104和服务器105。网络104用以在终端设备101、102、103和服务器105之间提供通信链路的介质。网络104可以包括各种连接类型,例如有线、无线通信链路或者光纤电缆等等。As shown in FIG. 1 , the system architecture 100 may include terminal devices 101 , 102 , and 103 , a network 104 and a server 105 . The network 104 is a medium used to provide a communication link between the terminal devices 101 , 102 , 103 and the server 105 . The network 104 may include various connection types, such as wired, wireless communication links, or fiber optic cables, among others.

用户可以使用终端设备101、102、103通过网络104与服务器105交互,以接收或发送消息等。终端设备101、102、103上可以安装有各种通讯客户端应用,例如网页浏览器应用、购物类应用、搜索类应用、即时通信工具、邮箱客户端、社交平台软件等。The user can use the terminal devices 101, 102, 103 to interact with the server 105 through the network 104 to receive or send messages and the like. Various communication client applications may be installed on the terminal devices 101 , 102 and 103 , such as web browser applications, shopping applications, search applications, instant messaging tools, email clients, social platform software, and the like.

终端设备101、102、103可以是具有显示屏并且支持网页浏览的各种电子设备,包括但不限于智能手机、平板电脑、电子书阅读器、MP3播放器(Moving PictureExpertsGroup Audio Layer III,动态影像专家压缩标准音频层面3)、MP4(MovingPictureExperts Group Audio Layer IV,动态影像专家压缩标准音频层面4)播放器、膝上型便携计算机和台式计算机等等。The terminal devices 101, 102, and 103 may be various electronic devices that have a display screen and support web browsing, including but not limited to smart phones, tablet computers, e-book readers, MP3 players (Moving Picture Experts Group Audio Layer III, moving picture experts). Compression Standard Audio Layer 3), MP4 (Moving PictureExperts Group Audio Layer IV, Moving Picture Experts Compression Standard Audio Layer 4) Players, Laptops and Desktops, etc.

服务器105可以是提供各种服务的服务器,例如对终端设备101、102、103上显示的页面提供支持的后台服务器。The server 105 may be a server that provides various services, such as a background server that provides support for the pages displayed on the terminal devices 101 , 102 , and 103 .

需要说明的是,本申请实施例所提供的基于人工智能的行为预测方法一般由服务器/终端设备执行,相应地,基于人工智能的行为预测装置一般设置于服务器/终端设备中。It should be noted that the artificial intelligence-based behavior prediction method provided in the embodiments of the present application is generally executed by a server/terminal device, and accordingly, an artificial intelligence-based behavior prediction apparatus is generally set in the server/terminal device.

应该理解,图1中的终端设备、网络和服务器的数目仅仅是示意性的。根据实现需要,可以具有任意数目的终端设备、网络和服务器。It should be understood that the numbers of terminal devices, networks and servers in FIG. 1 are merely illustrative. There can be any number of terminal devices, networks and servers according to implementation needs.

继续参考图2,示出了根据本申请的基于人工智能的行为预测方法的一个实施例的流程图。所述的基于人工智能的行为预测方法,包括以下步骤:Continuing to refer to FIG. 2 , a flowchart of one embodiment of the artificial intelligence-based behavior prediction method according to the present application is shown. The artificial intelligence-based behavior prediction method includes the following steps:

步骤S201,获取目标用户在预设时间段内的用户行为数据。Step S201, acquiring user behavior data of a target user within a preset time period.

在本实施例中,基于人工智能的行为预测方法运行于其上的电子设备(例如图1所示的服务器/终端设备)。需要指出的是,上述无线连接方式可以包括但不限于3G/4G/5G连接、WiFi连接、蓝牙连接、WiMAX连接、Zigbee连接、UWB(ultra wideband)连接、以及其他现在已知或将来开发的无线连接方式。In this embodiment, the electronic device (for example, the server/terminal device shown in FIG. 1 ) on which the artificial intelligence-based behavior prediction method runs. It should be pointed out that the above wireless connection methods may include, but are not limited to, 3G/4G/5G connection, WiFi connection, Bluetooth connection, WiMAX connection, Zigbee connection, UWB (ultra wideband) connection, and other wireless connections now known or developed in the future. connection method.

在本实施例中,可以通过查询与用户的加油行为相关的加油服务网页内用户的加油服务数据来得到目标用户在预设时间段内的用户行为数据。对于预设时间段不作具体限定,可根据实际使用需求进行设置,例如可设为距离当前时间的前半年。具体的,获取目标用户在预设时间段内的用户行为数据的过程可包括:先获取在预设时间段内的页面用户行为数据,以及获取目标用户的用户信息;然后从页面用户行为数据内筛选出与用户信息对应的指定页面用户行为数据;后续对指定页面用户行为数据进行预处理,得到与目标用户对应的用户行为数据。In this embodiment, the user behavior data of the target user within a preset time period can be obtained by querying the user's refueling service data in the refueling service webpage related to the user's refueling behavior. The preset time period is not specifically limited, and can be set according to actual usage requirements, for example, it can be set as the first half year from the current time. Specifically, the process of acquiring the user behavior data of the target user within the preset time period may include: first acquiring the page user behavior data within the preset time period, and acquiring the user information of the target user; The user behavior data of the designated page corresponding to the user information is filtered out; the user behavior data of the designated page is subsequently preprocessed to obtain the user behavior data corresponding to the target user.

步骤S202,对所述用户行为数据进行特征构建处理,基于所述用户行为数据生成加油行为特征;其中,所述加油行为特征的数量包括多个。Step S202: Perform feature construction on the user behavior data, and generate fueling behavior features based on the user behavior data; wherein the number of fueling behavior features includes multiple.

在本实施例中,可以通过特征工程来对用户行为数据进行特征构建以生成相应的加油行为特征。其中,加油行为特征至少包括用户基础特征、加油时序行为特征和累计行为特征。用户基础特征:描述用户的个人信息,主要包括用户编号、用户年龄、用户会员等级、用户类型(新用户、老用户)等;加油时序行为特征:表示用户在一段时间内发生行为的统计分析,至少包括用户平均加油时间间隔、观测窗口内最后一次加油距离考察时间窗口的天数、用户在观测窗口内发生各种行为的次数/天数,行为包括点击、浏览、优惠券、下单;累计行为特征:表示用户在过去n天内发生行为的统计分析,至少包括用户在距离考察时间窗口前n天内各种行为的转化率。由于对得到的用户行为数据进行特征提取的时候既考虑了时序行为特征,又考虑了累计行为特征,有效增加了数据维度的多样性,以使得基于对于加油行为特征的模型预测处理可以保证后续生成的目标用户的加油行为预测结果的准确性。In this embodiment, the user behavior data can be characterized by feature engineering to generate corresponding fueling behavior features. The refueling behavior features at least include user basic features, refueling sequence behavior features, and cumulative behavior features. User basic characteristics: describe the user's personal information, mainly including user ID, user age, user membership level, user type (new user, old user), etc.; refueling sequence behavior characteristics: indicating the statistical analysis of the user's behavior over a period of time, At least include the user's average refueling time interval, the number of days in the observation window from the last refueling to the inspection time window, and the number of times/days the user has performed various behaviors in the observation window, including clicks, browsing, coupons, and placing orders; cumulative behavior characteristics : Represents the statistical analysis of the user's behavior in the past n days, including at least the conversion rate of the user's various behaviors in the n days before the inspection time window. Since the feature extraction of the obtained user behavior data takes into account both the time series behavior characteristics and the cumulative behavior characteristics, the diversity of the data dimension is effectively increased, so that the model prediction processing based on the characteristics of the refueling behavior can ensure the subsequent generation. The accuracy of the prediction results of the target user's refueling behavior.

步骤S203,基于主成分分析算法对所述加油行为特征进行筛选处理得到第一特征,以及基于预设的特征选取算法对所述加油行为特征进行筛选处理得到第二特征。Step S203 , screening the refueling behavior feature based on a principal component analysis algorithm to obtain a first feature, and performing a screening process on the refueling behavior feature based on a preset feature selection algorithm to obtain a second feature.

在本实施例中,对于上述基于主成分分析算法对所述加油行为特征进行筛选处理得到第一特征的具体实施过程,本申请将在后续的具体实施例中对此进行进一步的细节描述,在此不作过多阐述。另外,上述特征选取算法可根据实际需求来确定,优选为用于去除数据集合包含的所有原始特征中的冗余特征的算法。具体的,该特征选取算法为mRMR(Max-Relevanceand Min-Redundancy,最大相关和最小冗余算法)算法,通过采用mRMR算法对所有加油行为特征进行特征提取,可以使得模型输入与模型输出相关性最大,模型输入之间冗余性最小,进而可以令后续的预测模型在进行对于目标加油行为特征的预测处理时能够具有更好的预测精度。In this embodiment, for the above-mentioned specific implementation process of screening the refueling behavior feature based on the principal component analysis algorithm to obtain the first feature, the present application will describe this in further detail in the subsequent specific embodiments. This will not go into too much detail. In addition, the above feature selection algorithm can be determined according to actual requirements, and is preferably an algorithm for removing redundant features from all original features included in the data set. Specifically, the feature selection algorithm is the mRMR (Max-Relevance and Min-Redundancy) algorithm. By using the mRMR algorithm to extract features of all fueling behavior features, the model input and model output can be most correlated. , the redundancy between the model inputs is minimal, so that the subsequent prediction model can have better prediction accuracy when performing prediction processing on the characteristics of the target refueling behavior.

步骤S204,基于所述第一特征与所述第二特征确定出与所述用户行为数据对应的目标加油行为特征。Step S204, determining a target fueling behavior feature corresponding to the user behavior data based on the first feature and the second feature.

在本实施例中,生成目标加油行为特征的过程具体可包括:先对第一特征与第二特征进行合并处理,得到对应的特征集合;再对所述特征集合中的所有特征进行匹配处理,获取特征集合中重复出现的第三特征,并将得到的第三特征作为目标加油行为特征。本实施例通过对得到的第一特征与第二特征进行合并匹配处理以生成所需的目标加油行为特征,由于得到的目标加油行为特征保留了与加油预测处理的相关性更强的特征,这样可以有效删除特征空间中的噪声数据,减小饱和度识别建模误差,并且可以减小噪声对模型的干扰作用。以及还能降低算法复杂度,由于输入数据维数的降低,有利于减少后续的预测模型进行预测处理所需的时间,有效提高预测模型的预测处理效率。In this embodiment, the process of generating the target refueling behavior feature may specifically include: firstly combining the first feature and the second feature to obtain a corresponding feature set; and then performing matching processing on all the features in the feature set, Obtain the third feature that appears repeatedly in the feature set, and use the obtained third feature as the target refueling behavior feature. In this embodiment, the obtained first feature and the second feature are combined and matched to generate the required target refueling behavior feature, because the obtained target refueling behavior feature retains the feature that is more relevant to the refueling prediction process, so It can effectively delete the noise data in the feature space, reduce the saturation recognition modeling error, and reduce the interference effect of noise on the model. And it can also reduce the complexity of the algorithm. Due to the reduction of the dimension of the input data, it is beneficial to reduce the time required for the subsequent prediction model to perform prediction processing, and effectively improve the prediction processing efficiency of the prediction model.

步骤S205,将所述目标加油行为特征输入至预设的预测模型内,通过所述预测模型对所述目标加油特征进行预测处理,生成与所述目标用户对应的加油行为预测结果。Step S205, inputting the target refueling behavior feature into a preset prediction model, and performing prediction processing on the target refueling feature through the prediction model to generate a refueling behavior prediction result corresponding to the target user.

在本实施例中,预测模型为基于预先收集的加油样本数据对预先构建的LSTM网络模型进行训练生成的。使用该预测模型能够智能地对输入的与用户行为数据对应的目标加油行为特征进行预测处理,从而得到与目标用户对应的加油行为预测结果。另外,加油行为预测结果可包括具有加油意向或不具有加油意向。进一步地,当通过预测模型预测出目标用户具有加油意向时,会智能地获取实时的加油信息与用户通讯信息,并会基于用户通讯信息将加油信息推送给目标用户,使得目标用户可以及时了解到现在的加油信息,提高了目标用户的使用体验。In this embodiment, the prediction model is generated by training a pre-built LSTM network model based on pre-collected fueling sample data. Using the prediction model can intelligently perform prediction processing on the input target refueling behavior characteristics corresponding to the user behavior data, so as to obtain the refueling behavior prediction result corresponding to the target user. In addition, the refueling behavior prediction result may include having the refueling intention or not having the refueling intention. Further, when it is predicted that the target user has the intention to refuel through the prediction model, the real-time refueling information and user communication information will be intelligently obtained, and the refueling information will be pushed to the target user based on the user communication information, so that the target user can know in time. The current refueling information improves the experience of target users.

本申请在获取到目标用户在预设时间段内的用户行为数据后,会先对用户行为数据进行特征构建处理,基于用户行为数据生成加油行为特征,然后基于主成分分析算法对加油行为特征进行筛选处理得到第一特征,以及基于预设的特征选取算法对加油行为特征进行筛选处理得到第二特征,之后基于第一特征与第二特征确定出与用户行为数据对应的目标加油行为特征,最后将目标加油行为特征输入至预设的预测模型内,通过预测模型对目标加油特征进行预测处理,生成与目标用户对应的加油行为预测结果。本申请通过利用预测模型对目标用户对应的目标加油行为特征进行预测处理,可以实现快速准确地生成与目标用户对应的加油行为预测结果,有效提高对于目标用户的加油行为意向预测的处理效率与准确性。After obtaining the user behavior data of the target user within a preset time period, the application will first perform feature construction processing on the user behavior data, generate the refueling behavior feature based on the user behavior data, and then perform the refueling behavior feature based on the principal component analysis algorithm. The screening process obtains the first feature, and the refueling behavior feature is screened based on the preset feature selection algorithm to obtain the second feature, and then the target refueling behavior feature corresponding to the user behavior data is determined based on the first feature and the second feature, and finally The target refueling behavior feature is input into a preset prediction model, and the target refueling feature is predicted through the prediction model to generate a refueling behavior prediction result corresponding to the target user. In the present application, by using the prediction model to predict and process the target refueling behavior characteristics corresponding to the target user, the prediction result of the refueling behavior corresponding to the target user can be quickly and accurately generated, and the processing efficiency and accuracy of the prediction of the refueling behavior intention of the target user can be effectively improved. sex.

在一些可选的实现方式中,步骤S203中的基于主成分分析算法对所述加油行为特征进行筛选处理得到第一特征,包括以下步骤:In some optional implementations, in step S203, the first feature is obtained by screening the refueling behavior feature based on a principal component analysis algorithm, including the following steps:

基于所述加油行为特征构建相关系数矩阵。A correlation coefficient matrix is constructed based on the refueling behavior characteristics.

在本实施例中,构建生成的相关系数矩阵的特征方程为|R-aIp|=0。In this embodiment, the characteristic equation for constructing the generated correlation coefficient matrix is |R-aI p |=0.

基于所述主成分分析算法对所述相关系数矩阵进行降维处理,得到多个主成分。Dimension reduction processing is performed on the correlation coefficient matrix based on the principal component analysis algorithm to obtain a plurality of principal components.

在本实施例中,通过使用主成分分析算法对相关系数矩阵进行降维处理以选出相应的多个主成分的过程包括:求解上述相关系数矩阵的特征方程|R-aIp|=0,计算特征根a,再将求解得到的特征根a代入方程|R-aIp|x=0,计算特征向量x,其中,R表示相关系数矩阵,Ip表示单位矩阵,每个特征向量x代表一个主成分。In this embodiment, the process of performing dimension reduction processing on the correlation coefficient matrix by using the principal component analysis algorithm to select a plurality of corresponding principal components includes: solving the characteristic equation of the above correlation coefficient matrix |R-aI p |=0, Calculate the characteristic root a, then substitute the obtained characteristic root a into the equation |R-aI p |x=0, and calculate the eigenvector x, where R represents the correlation coefficient matrix, I p represents the identity matrix, and each eigenvector x represents a principal component.

计算每个所述主成分的方差贡献率,将所有所述方差贡献率按照从大到小的顺序进行排序,并依次累加直至超过预设的累加方差贡献率阈值。Calculate the variance contribution rate of each of the principal components, sort all the variance contribution rates in descending order, and accumulate them in sequence until a preset cumulative variance contribution rate threshold is exceeded.

在本实施例中,方差贡献率为某一特征向量的特征值除以所有特征向量的特征值的和所得到的比值,方差贡献率代表了该维度下蕴含的信息量的比例。另外,对上述累加方差贡献率阈值的取值不作具体限定,可根据实际需求进行设置,例如可设为0.99。In this embodiment, the variance contribution rate is a ratio obtained by dividing the eigenvalue of a certain eigenvector by the sum of the eigenvalues of all eigenvectors, and the variance contribution rate represents the ratio of the amount of information contained in this dimension. In addition, the value of the above-mentioned threshold value of the cumulative variance contribution rate is not specifically limited, and can be set according to actual needs, for example, it can be set to 0.99.

从所有所述方差贡献率中筛选出与累加处理对应的指定主成分,并将所述指定主成分对应的特征作为所述第一特征。A designated principal component corresponding to the accumulation process is selected from all the variance contribution rates, and the feature corresponding to the designated principal component is used as the first feature.

在本实施例中,在将所有方差贡献率按照从大到小的顺序进行排序后,经过累加计算得出排序前5个的主成分的和值出现了首次大于该累加方差贡献率阈值的情形时,则会将该排序前5个的主成分所对应的特征作为第一特征。In this embodiment, after all variance contribution rates are sorted in descending order, it is found that the sum of the top five principal components is greater than the cumulative variance contribution rate threshold for the first time through cumulative calculation. , the features corresponding to the top 5 principal components of the ranking will be used as the first features.

本申请通过使用主成分分析法可以快速地从构建得到的全部加油行为特征中快速的筛选出第一特征,有利于后续可以根据该第一特征来准确地生成最终的目标加油行为特征,有效的保证了生成的目标加油行为特征的准确性与合理性。By using the principal component analysis method, the present application can quickly screen out the first feature from all the constructed fueling behavior features, which is conducive to the subsequent generation of the final target fueling behavior feature according to the first feature, effectively The accuracy and rationality of the generated target refueling behavior features are guaranteed.

在本实施例的一些可选的实现方式中,步骤S204包括以下步骤:In some optional implementations of this embodiment, step S204 includes the following steps:

对所述第一特征与所述第二特征进行合并处理,得到对应的特征集合。The first feature and the second feature are combined to obtain a corresponding feature set.

在本实施例中,合并处理是指将第一特征与第二特征进行合并汇总,从而得到包含第一特征与第二特征的特征集合。In this embodiment, the merging process refers to merging and summarizing the first feature and the second feature, so as to obtain a feature set including the first feature and the second feature.

对所述特征集合中的所有特征进行匹配处理,获取所述特征集合中重复出现的第三特征。Perform matching processing on all the features in the feature set to obtain a third feature that appears repeatedly in the feature set.

在本实施例中,匹配处理可以指相似度计算处理,通过计算任意两个特征之间的相似度,如果计算得到的相似度大于预设的相似度阈值,则判定该两个特征为相互匹配的特征,即该两个特征属于在特征集合中重复出现的同一个特征。另外,对于所述相似度阈值的取值不作限定,可根据实际需求进行设置。In this embodiment, the matching process may refer to the similarity calculation process. By calculating the similarity between any two features, if the calculated similarity is greater than a preset similarity threshold, it is determined that the two features match each other. feature, that is, the two features belong to the same feature that appears repeatedly in the feature set. In addition, the value of the similarity threshold is not limited, and can be set according to actual requirements.

将所述第三特征作为所述目标加油行为特征。The third feature is used as the target fueling behavior feature.

本申请在使用主成分分析算法对加油行为特征进行筛选处理得到第一特征,以及使用预设的特征选取算法对加油行为特征进行筛选处理得到第二特征后,通过对第一特征与第二特征进行进一步的合并匹配处理以最终确定出与用户行为数据对应的目标加油行为特征,有效地确保了生成的目标加油行为特征的准确性与有效性。In the present application, after using the principal component analysis algorithm to screen the refueling behavior features to obtain the first feature, and using the preset feature selection algorithm to screen the refueling behavior features to obtain the second feature, the first feature and the second feature are analyzed by comparing the first feature and the second feature. Further merging and matching processing is performed to finally determine the target refueling behavior feature corresponding to the user behavior data, which effectively ensures the accuracy and validity of the generated target refueling behavior feature.

在一些可选的实现方式中,所述预测模型包括输入层、LSTM层、全连接层与输出层,步骤S205包括以下步骤:In some optional implementations, the prediction model includes an input layer, an LSTM layer, a fully connected layer, and an output layer, and step S205 includes the following steps:

将所述目标加油行为特征输入至所述预测模型的输入层内,通过所述输入层生成与所述目标加油行为特征对应的输出矩阵。The target fueling behavior feature is input into the input layer of the prediction model, and an output matrix corresponding to the target fueling behavior feature is generated through the input layer.

在本实施例中,预测模型的第一层为输入层,输入层用于数据分集并转换格式。通过输入层生成的输出矩阵为将目标加油行为特征进行重构处理后得到预设格式的输出矩阵。该预设格式可根据实际需求进行设置,例如为3D格式(samples,time_steps,input_dim),其中,samples表示样本数量,time_steps表示时间步长,input_dim表示每一个时间步上的维度。In this embodiment, the first layer of the prediction model is the input layer, and the input layer is used for data diversity and format conversion. The output matrix generated by the input layer is an output matrix in a preset format obtained by reconstructing the characteristics of the target fueling behavior. The preset format can be set according to actual requirements, such as a 3D format (samples, time_steps, input_dim), where samples represents the number of samples, time_steps represents the time step, and input_dim represents the dimension on each time step.

将所述输出矩阵输入至所述预测模型的LSTM层内,通过所述LSTM层生成与所述输出矩阵对应的输出向量。The output matrix is input into the LSTM layer of the prediction model, and an output vector corresponding to the output matrix is generated through the LSTM layer.

在本实施例中,LSTM层通过门机制来控制流过单元的信息,门机制包括输入门、遗忘门、输出门。其中,输入门用于确定需要更新的信息;遗忘门用于控制从存储状态丢弃/继续保存前一时刻的信息,即通过输入门和遗忘门更新存储状态;输出门用于确定存储状态中输出信息。In this embodiment, the LSTM layer controls the information flowing through the unit through a gate mechanism, and the gate mechanism includes an input gate, a forget gate, and an output gate. Among them, the input gate is used to determine the information that needs to be updated; the forget gate is used to control discarding/continue to save the information at the previous moment from the storage state, that is, the storage state is updated through the input gate and the forget gate; the output gate is used to determine the output in the storage state information.

将所述输出向量输入至所述预测模型的全连接层内,基于所述全连接层内的预设激活函数生成与所述输出向量对应的预测分类结果。The output vector is input into a fully connected layer of the prediction model, and a prediction classification result corresponding to the output vector is generated based on a preset activation function in the fully connected layer.

在本实施例中,全连接层的每个节点与前一层的所有节点相连,经过全连接层的输出为:xi=f(∑wij*gj+bi),其中,xi为全连接层中第i个神经元输出,gj为前一层第j个神经元,wij为连接权值,bi为全连接层中第i个神经元阈值,f为激活函数。具体的,可使用softmax函数作为全连接层的激活函数,softmax函数可以对输出值进行归一化操作,把所有输出值都转化为概率,所有概率值加起来等于1。In this embodiment, each node of the fully connected layer is connected to all nodes of the previous layer, and the output through the fully connected layer is: x i =f(∑w ij *g j +b i ), where x i is the output of the ith neuron in the fully connected layer, gj is the jth neuron in the previous layer, w ij is the connection weight, b i is the threshold of the ith neuron in the fully connected layer, and f is the activation function. Specifically, the softmax function can be used as the activation function of the fully connected layer. The softmax function can normalize the output values, convert all the output values into probabilities, and the sum of all the probability values is equal to 1.

将所述预测分类结果输入至所述预测模型的输出层内,通过所述输出层输出所述预测分类结果,并将所述预测分类结果作为与所述目标用户对应的加油行为预测结果。The prediction classification result is input into the output layer of the prediction model, the prediction classification result is output through the output layer, and the prediction classification result is used as the refueling behavior prediction result corresponding to the target user.

本申请通过使用训练生成的预测模型可以基于对输入的目标加油行为特征进行相应的预测处理,以实现快速准确地生成与目标用户对应的加油行为预测结果,有效提高对于目标用户的加油行为意向预测的处理智能性。The present application can perform corresponding prediction processing based on the input target refueling behavior characteristics by using the prediction model generated by training, so as to realize the rapid and accurate generation of the refueling behavior prediction result corresponding to the target user, and effectively improve the refueling behavior intention prediction for the target user. processing intelligence.

在一些可选的实现方式中,在步骤S205之前,上述电子设备还可以执行以下步骤:In some optional implementations, before step S205, the above-mentioned electronic device may further perform the following steps:

获取预先收集的加油样本数据。Obtain pre-collected fueling sample data.

在本实施例中,加油样本数据可以通过抓取相关的加油服务网页内用户的加油服务数据来得到。In this embodiment, the refueling sample data can be obtained by crawling the refueling service data of the user in the relevant refueling service webpage.

按照预设比例将所述加油样本数据划分为训练集与测试集。The refueling sample data is divided into a training set and a test set according to a preset ratio.

在本实施例中,可以从加油样本数据中随机抽取出预设比例的数据作为训练集,再将加油样本数据中剩余的其他数据作为测试集。另外,对于上述预设比例不作具体限定,可根据实际需求进行设定,举例地,预设比例可设为70%,即可从上述加油样本数据中随机抽取出70%的数据作为训练集,并将上述加油样本数据中剩余的30%的数据作为测试集。另外,在基于训练集与测试集对初始预测模型进行模型训练的过程之前,还会基于上述的主成分分析算法与预设的特征选取算法对训练集与测试集进行相应的特征提取处理,具体的过程可参照前述对于加油行为特征的特征提取过程,在此不做过多阐述。本实施例通过对训练集与测试集进行特征提取处理,可以降低模型的输入数据维数,可以减少初始预测模型的训练时间,并且构建初始预测模型的复杂度也会降低,有效地提高了初始预测模型的构建效率。In this embodiment, a preset proportion of data may be randomly selected from the fueling sample data as a training set, and other data remaining in the fueling sample data may be used as a test set. In addition, the above preset ratio is not specifically limited, and can be set according to actual needs. For example, the preset ratio can be set to 70%, and 70% of the data can be randomly selected from the above refueling sample data as a training set. The remaining 30% of the above refueling sample data is used as the test set. In addition, before the model training process of the initial prediction model based on the training set and the test set, the corresponding feature extraction processing will be performed on the training set and the test set based on the above-mentioned principal component analysis algorithm and the preset feature selection algorithm. For the process, refer to the aforementioned feature extraction process for refueling behavior features, which will not be elaborated here. In this embodiment, by performing feature extraction processing on the training set and the test set, the input data dimension of the model can be reduced, the training time of the initial prediction model can be reduced, and the complexity of constructing the initial prediction model can also be reduced, which effectively improves the initial Predictive model building efficiency.

获取预先构建的初始预测模型。Get a pre-built initial prediction model.

在本实施例中,预先定义和构建初始预测模型,该初始预测模型为由输入层、LSTM层、全连接层与输出层构成的LSTM网络模型,通过设置网格内部参数,并调整网络内部参数。LSTM网络模型采集的数据经过输入层的格式转换后,传输至LSTM层进行LSTM网络训练,经过全连接层后,由输出层输出分类结果。另外,调整网络内部参数,按照设定值调整学习率和迭代次数,获取输入权重、循环权重和偏差,并分别利用门激活函数和状态激活函数调整对应的传入门、遗忘门、被选门和输出门的参数。In this embodiment, an initial prediction model is pre-defined and constructed, and the initial prediction model is an LSTM network model composed of an input layer, an LSTM layer, a fully connected layer and an output layer. By setting the internal parameters of the grid, and adjusting the internal parameters of the network . After the data collected by the LSTM network model is converted into the format of the input layer, it is transmitted to the LSTM layer for LSTM network training. After the fully connected layer, the output layer outputs the classification results. In addition, adjust the internal parameters of the network, adjust the learning rate and the number of iterations according to the set value, obtain the input weight, cycle weight and deviation, and use the gate activation function and state activation function to adjust the corresponding incoming gate, forget gate, selected gate and Parameters for the output gate.

基于随机梯度下降算法,使用所述训练集对所述初始预测模型进行训练,得到训练后的初始预测模型。Based on the stochastic gradient descent algorithm, the initial prediction model is trained using the training set to obtain a trained initial prediction model.

在本实施例中,上述训练集包括多个训练数据以及与各训练数据分别对应的分类标签信息。通过将训练数据作为初始预测模型的输入,与各训练数据分别对应的分类标签信息作为初始预测模型的输出,采用随机梯度下降算法不断地对上述初始预测模型进行训练,以使损失函数达到预期值,从而可以生成训练后的初始预测模型。另外,随机梯度下降法就是随机取样一些训练数据,替代整个训练集,如果样本量很大的情况(例如几十万),那么可能只用其中几万条或者几千条的样本,就已经迭代到最优解了,可以有效地提高模型的训练速度。以及,使用上述随机梯度下降法进行对于初始预测模型的训练流程可参照现有的模型训练流程,在此不再赘述。In this embodiment, the above-mentioned training set includes a plurality of training data and classification label information corresponding to each training data. By using the training data as the input of the initial prediction model, and the classification label information corresponding to each training data as the output of the initial prediction model, the stochastic gradient descent algorithm is used to continuously train the above-mentioned initial prediction model, so that the loss function reaches the expected value. , so that an initial predictive model after training can be generated. In addition, the stochastic gradient descent method is to randomly sample some training data to replace the entire training set. If the sample size is large (such as hundreds of thousands), then only tens of thousands or thousands of samples may be used, and it has been iterated. When the optimal solution is reached, the training speed of the model can be effectively improved. And, for the training process of the initial prediction model using the above-mentioned stochastic gradient descent method, reference may be made to the existing model training process, which will not be repeated here.

使用所述测试集对所述训练后的初始预测模型进行验证。The trained initial prediction model is validated using the test set.

在本实施例中,可通过将测试集输入至训练后的初始预测模型,并计算与该测试集对应的预测准确率,如果预测准确率大于预设的准确率阈值,则判定训练后的初始预测模型通过验证,而如果预测准确率不大于该准确率阈值,则判定训练后的初始预测模型未通过验证。另外,对于上述准确率阈值的取值不作具体限定,可根据实际需求进行设定。In this embodiment, the test set can be input into the initial prediction model after training, and the prediction accuracy rate corresponding to the test set can be calculated. If the prediction accuracy rate is greater than the preset accuracy rate threshold, it is determined that the training initial The prediction model passes the validation, and if the prediction accuracy is not greater than the accuracy threshold, it is determined that the trained initial prediction model fails the validation. In addition, the value of the above-mentioned accuracy threshold is not specifically limited, and can be set according to actual requirements.

若所述训练后的初始预测模型通过验证,将所述训练后的初始预测模型作为所述预测模型。If the trained initial prediction model passes the verification, the trained initial prediction model is used as the prediction model.

本实施例中,在得到了预测模型后,还可将该预测模型存储至区块链网络,以通过使用区块链来对训练生成的上述预测模型进行存储和管理,从而实现有效地保证上述预测模型的安全性与不可篡改性。In this embodiment, after the prediction model is obtained, the prediction model can also be stored in the blockchain network, so that the above-mentioned prediction model generated by training can be stored and managed by using the blockchain, so as to effectively ensure the above-mentioned prediction model. Security and Immutability of Predictive Models.

本申请通过基于随机梯度下降算法,使用预先收集的加油样本数据来快速地训练生成所需的预测模型,使得后续可以使用该预测模型智能地对输入的与用户行为数据对应的目标加油行为特征进行预测处理,从而得到与目标用户对应的加油行为预测结果,提高了对于目标用户的加油预测的处理效率与处理智能性。The present application uses the pre-collected fueling sample data to quickly train and generate the required prediction model based on the stochastic gradient descent algorithm, so that the prediction model can be used to intelligently perform the inputted target fueling behavior characteristics corresponding to the user behavior data. Prediction processing, thereby obtaining the prediction result of the refueling behavior corresponding to the target user, and improving the processing efficiency and processing intelligence of the refueling prediction for the target user.

在本实施例的一些可选的实现方式中,上述使用所述测试集对所述训练后的初始预测模型进行验证,包括以下步骤:In some optional implementations of this embodiment, the above-mentioned use of the test set to verify the initial prediction model after training includes the following steps:

获取所述测试集;其中,所述测试集包括多个测试数据,以及与各所述测试数据分别对应的分类信息。Acquire the test set; wherein, the test set includes a plurality of test data and classification information corresponding to each of the test data respectively.

在本实施例中,上述测试集可基于上述加油样本数据集生成。In this embodiment, the above-mentioned test set may be generated based on the above-mentioned refueling sample data set.

将所述测试数据输入至所述训练后的初始预测模型内,获取所述训练后的初始预测模型输出的与各所述测试数据分别对应的第一预测分类结果。The test data is input into the initial prediction model after training, and the first prediction classification result output by the initial prediction model after training and corresponding to each of the test data is obtained.

基于所述分类信息,确定出所有所述第一预测分类结果中预测正确的第二预测分类结果。Based on the classification information, a correctly predicted second predicted classification result among all the first predicted classification results is determined.

在本实施例中,预测正确的第二预测分类结果是指所有第一预测分类结果中与相对应的测试数据的分类信息相同的预测分类结果。In this embodiment, the correctly predicted second predicted classification result refers to the predicted classification result that is the same as the classification information of the corresponding test data among all the first predicted classification results.

计算所述第二预测分类结果与所述第一预测分类结果的商值。A quotient of the second predicted classification result and the first predicted classification result is calculated.

判断所述商值是否大于预设阈值。It is judged whether the quotient value is greater than a preset threshold.

在本实施例中,对于上述预设阈值的取值不作具体限定,可根据实际需求进行设定。In this embodiment, the value of the above-mentioned preset threshold is not specifically limited, and can be set according to actual needs.

若大于所述预设阈值,判定所述训练后的初始预测模型通过验证,否则判定所述训练后的初始预测模型未通过验证。If it is greater than the preset threshold, it is determined that the trained initial prediction model has passed the verification; otherwise, it is determined that the trained initial prediction model has not passed the verification.

本申请在得到了训练后的初始预测模型后,会进一步使用测试集对该训练后的初始预测模型进行验证,并只有在该训练后的初始预测模型通过验证时,后续才会将该训练后的初始预测模型作为预测模型,保证了得到的预测模型的准确性。并且后续可以使用该预测模型智能地对输入的与用户行为数据对应的目标加油行为特征进行预测处理,从而得到与目标用户对应的加油行为预测结果,提高了对于目标用户的加油预测的处理效率与处理智能性。After obtaining the initial prediction model after training, the application will further use the test set to verify the initial prediction model after training, and only when the initial prediction model after training passes the verification, will the training The initial prediction model of , as the prediction model, ensures the accuracy of the obtained prediction model. And in the future, the prediction model can be used to intelligently predict and process the input target refueling behavior characteristics corresponding to the user behavior data, so as to obtain the refueling behavior prediction result corresponding to the target user, and improve the processing efficiency of the refueling prediction for the target user. Handling intelligence.

在本实施例的一些可选的实现方式中,步骤S201包括以下步骤:In some optional implementations of this embodiment, step S201 includes the following steps:

获取在所述预设时间段内的页面用户行为数据,以及获取所述目标用户的用户信息。Acquire page user behavior data within the preset time period, and acquire user information of the target user.

在本实施例中,页面用户行为数据可指加油服务网页内包含的所有用户的用户行为数据。用户信息可包括目标用户的用户姓名或用户id。In this embodiment, the page user behavior data may refer to the user behavior data of all users contained in the refueling service webpage. User information may include the user name or user id of the target user.

基于所述用户信息,从所述页面用户行为数据内筛选出与所述用户信息对应的指定页面用户行为数据。Based on the user information, the user behavior data of the specified page corresponding to the user information is filtered out from the page user behavior data.

在本实施例中,根据用户信息,可以从得到的页面用户行为数据中筛选出与用户信息匹配的目标用户的用户行为数据,即指定页面用户行为数据。In this embodiment, according to the user information, the user behavior data of the target user that matches the user information, that is, the user behavior data of the specified page, can be filtered from the obtained page user behavior data.

对所述指定页面用户行为数据进行预处理,得到所述用户行为数据。The user behavior data of the specified page is preprocessed to obtain the user behavior data.

在本实施例中,预处理包括数据清洗及数据归一化处理。其中,在对获得的指定页面用户行为数据进行数据清洗时,可使用python中pandas包dropna方法去除因格式或采集错误产生的错误数据和空值,按日期进行排序,完成数据清洗过程,以得到处理后的用户行为数据。同时,由于初始的指定页面用户行为数据中,不同的输入变量之间数值大小以及量纲不同,因此在后续进行的网络训练前需要对数据进行归一化处理,即把处理后的用户行为数据中的所有数据都转化为[0,1]范围内,具体函数形式为:x=x-xmin/xmax-xmin,其中xmax为样本最大值,xmin为样本最小值。进一步地,上述预处理还可包括过滤噪声值与填补缺失值等处理。In this embodiment, the preprocessing includes data cleaning and data normalization. Among them, when data cleaning is performed on the obtained user behavior data of the specified page, the dropna method in the pandas package in python can be used to remove erroneous data and null values caused by format or collection errors, sort by date, and complete the data cleaning process to obtain Processed user behavior data. At the same time, since in the initial specified page user behavior data, the numerical values and dimensions of different input variables are different, so the data needs to be normalized before subsequent network training, that is, the processed user behavior data All data in are converted into the range of [0,1], the specific function form is: x=x-xmin/xmax-xmin, where xmax is the maximum value of the sample, and xmin is the minimum value of the sample. Further, the above-mentioned preprocessing may also include processing such as filtering noise values and filling in missing values.

本申请通过对页面用户行为数据进行相关的预处理,进而可以准确地生成相应的用户行为数据,有利于后续可以使用预测模型对该用户行为数据进行预测处理,以实现快速智能地生成目标用户的加油行为预测结果。The present application can accurately generate the corresponding user behavior data by performing relevant preprocessing on the page user behavior data, which is conducive to the subsequent prediction processing of the user behavior data by using a prediction model, so as to realize the rapid and intelligent generation of the target user's behavior data. Refueling behavior prediction results.

需要强调的是,为进一步保证上述加油行为预测结果的私密和安全性,上述加油行为预测结果还可以存储于一区块链的节点中。It should be emphasized that, in order to further ensure the privacy and security of the above prediction result of refueling behavior, the above prediction result of refueling behavior can also be stored in a node of a blockchain.

本申请所指区块链是分布式数据存储、点对点传输、共识机制、加密算法等计算机技术的新型应用模式。区块链(Blockchain),本质上是一个去中心化的数据库,是一串使用密码学方法相关联产生的数据块,每一个数据块中包含了一批次网络交易的信息,用于验证其信息的有效性(防伪)和生成下一个区块。区块链可以包括区块链底层平台、平台产品服务层以及应用服务层等。The blockchain referred to in this application is a new application mode of computer technologies such as distributed data storage, point-to-point transmission, consensus mechanism, and encryption algorithm. Blockchain, essentially a decentralized database, is a series of data blocks associated with cryptographic methods. Each data block contains a batch of network transaction information to verify its Validity of information (anti-counterfeiting) and generation of the next block. The blockchain can include the underlying platform of the blockchain, the platform product service layer, and the application service layer.

本申请实施例可以基于人工智能技术对相关的数据进行获取和处理。其中,人工智能(Artificial Intelligence,AI)是利用数字计算机或者数字计算机控制的机器模拟、延伸和扩展人的智能,感知环境、获取知识并使用知识获得最佳结果的理论、方法、技术及应用系统。The embodiments of the present application may acquire and process related data based on artificial intelligence technology. Among them, artificial intelligence (AI) is a theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results. .

人工智能基础技术一般包括如传感器、专用人工智能芯片、云计算、分布式存储、大数据处理技术、操作/交互系统、机电一体化等技术。人工智能软件技术主要包括计算机视觉技术、机器人技术、生物识别技术、语音处理技术、自然语言处理技术以及机器学习/深度学习等几大方向。The basic technologies of artificial intelligence generally include technologies such as sensors, special artificial intelligence chips, cloud computing, distributed storage, big data processing technology, operation/interaction systems, and mechatronics. Artificial intelligence software technology mainly includes computer vision technology, robotics technology, biometrics technology, speech processing technology, natural language processing technology, and machine learning/deep learning.

本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机可读指令来指令相关的硬件来完成,该计算机可读指令可存储于一计算机可读取存储介质中,该程序在执行时,可包括如上述各方法的实施例的流程。其中,前述的存储介质可为磁碟、光盘、只读存储记忆体(Read-Only Memory,ROM)等非易失性存储介质,或随机存储记忆体(Random Access Memory,RAM)等。Those of ordinary skill in the art can understand that all or part of the processes in the methods of the above embodiments can be implemented by instructing relevant hardware through computer-readable instructions, and the computer-readable instructions can be stored in a computer-readable storage medium. , when the program is executed, it may include the processes of the foregoing method embodiments. The aforementioned storage medium may be a non-volatile storage medium such as a magnetic disk, an optical disk, a read-only memory (Read-Only Memory, ROM), or a random access memory (Random Access Memory, RAM).

应该理解的是,虽然附图的流程图中的各个步骤按照箭头的指示依次显示,但是这些步骤并不是必然按照箭头指示的顺序依次执行。除非本文中有明确的说明,这些步骤的执行并没有严格的顺序限制,其可以以其他的顺序执行。而且,附图的流程图中的至少一部分步骤可以包括多个子步骤或者多个阶段,这些子步骤或者阶段并不必然是在同一时刻执行完成,而是可以在不同的时刻执行,其执行顺序也不必然是依次进行,而是可以与其他步骤或者其他步骤的子步骤或者阶段的至少一部分轮流或者交替地执行。It should be understood that although the various steps in the flowchart of the accompanying drawings are sequentially shown in the order indicated by the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless explicitly stated herein, the execution of these steps is not strictly limited to the order and may be performed in other orders. Moreover, at least a part of the steps in the flowchart of the accompanying drawings may include multiple sub-steps or multiple stages, and these sub-steps or stages are not necessarily executed at the same time, but may be executed at different times, and the execution sequence is also It does not have to be performed sequentially, but may be performed alternately or alternately with other steps or at least a portion of sub-steps or stages of other steps.

进一步参考图3,作为对上述图2所示方法的实现,本申请提供了一种基于人工智能的行为预测装置的一个实施例,该装置实施例与图2所示的方法实施例相对应,该装置具体可以应用于各种电子设备中。Further referring to FIG. 3 , as an implementation of the method shown in FIG. 2 above, the present application provides an embodiment of a behavior prediction device based on artificial intelligence, and the device embodiment corresponds to the method embodiment shown in FIG. 2 , Specifically, the device can be applied to various electronic devices.

如图3所示,本实施例所述的基于人工智能的行为预测装置300包括:第一获取模块301、第一生成模块302、处理模块303、第一确定模块304以及第二生成模块305。其中:As shown in FIG. 3 , the artificial intelligence-based behavior prediction apparatus 300 in this embodiment includes: a first acquisition module 301 , a first generation module 302 , a processing module 303 , a first determination module 304 , and a second generation module 305 . in:

第一获取模块301,用于获取目标用户在预设时间段内的用户行为数据;The first obtaining module 301 is used to obtain the user behavior data of the target user within a preset time period;

第一生成模块302,用于对所述用户行为数据进行特征构建处理,基于所述用户行为数据生成加油行为特征;其中,所述加油行为特征的数量包括多个;A first generating module 302, configured to perform feature construction processing on the user behavior data, and generate fueling behavior features based on the user behavior data; wherein, the number of the fueling behavior features includes multiple;

处理模块303,用于基于主成分分析算法对所述加油行为特征进行筛选处理得到第一特征,以及基于预设的特征选取算法对所述加油行为特征进行筛选处理得到第二特征;A processing module 303, configured to perform screening processing on the refueling behavior feature based on a principal component analysis algorithm to obtain a first feature, and perform screening processing on the refueling behavior feature based on a preset feature selection algorithm to obtain a second feature;

第一确定模块304,用于基于所述第一特征与所述第二特征确定出与所述用户行为数据对应的目标加油行为特征;a first determining module 304, configured to determine a target fueling behavior feature corresponding to the user behavior data based on the first feature and the second feature;

第二生成模块305,用于将所述目标加油行为特征输入至预设的预测模型内,通过所述预测模型对所述目标加油特征进行预测处理,生成与所述目标用户对应的加油行为预测结果。The second generating module 305 is configured to input the target refueling behavior feature into a preset prediction model, perform prediction processing on the target refueling feature through the prediction model, and generate a refueling behavior prediction corresponding to the target user result.

在本实施例中,上述模块或单元分别用于执行的操作与前述实施方式的基于人工智能的行为预测方法的步骤一一对应,在此不再赘述。In this embodiment, the operations performed by the above modules or units respectively correspond to the steps of the artificial intelligence-based behavior prediction method in the foregoing embodiment, which will not be repeated here.

在本实施例的一些可选的实现方式中,处理模块303包括:In some optional implementations of this embodiment, the processing module 303 includes:

生成子模块,用于基于所述加油行为特征构建相关系数矩阵;generating a submodule for constructing a correlation coefficient matrix based on the refueling behavior feature;

第一处理子模块,用于基于所述主成分分析算法对所述相关系数矩阵进行降维处理,得到多个主成分;a first processing submodule, configured to perform dimensionality reduction processing on the correlation coefficient matrix based on the principal component analysis algorithm to obtain a plurality of principal components;

第二处理子模块,用于计算每个所述主成分的方差贡献率,将所有所述方差贡献率按照从大到小的顺序进行排序,并依次累加直至超过预设的累加方差贡献率阈值;The second processing sub-module is configured to calculate the variance contribution rate of each principal component, sort all the variance contribution rates in descending order, and accumulate them in sequence until exceeding the preset cumulative variance contribution rate threshold ;

第一确定子模块,用于从所有所述方差贡献率中筛选出与累加处理对应的指定主成分,并将所述指定主成分对应的特征作为所述第一特征。The first determination sub-module is configured to screen out a specified principal component corresponding to the accumulation process from all the variance contribution rates, and use the feature corresponding to the specified principal component as the first feature.

在本实施例中,上述模块或单元分别用于执行的操作与前述实施方式的基于人工智能的行为预测方法的步骤一一对应,在此不再赘述。In this embodiment, the operations performed by the above modules or units respectively correspond to the steps of the artificial intelligence-based behavior prediction method in the foregoing embodiment, which will not be repeated here.

在本实施例的一些可选的实现方式中,第一确定模块304包括:In some optional implementations of this embodiment, the first determining module 304 includes:

第三处理子模块,用于对所述第一特征与所述第二特征进行合并处理,得到对应的特征集合;a third processing sub-module, configured to perform merging processing on the first feature and the second feature to obtain a corresponding feature set;

第四处理子模块,用于对所述特征集合中的所有特征进行匹配处理,获取所述特征集合中重复出现的第三特征;a fourth processing submodule, configured to perform matching processing on all the features in the feature set, and obtain a third feature that appears repeatedly in the feature set;

第二确定子模块,用于将所述第三特征作为所述目标加油行为特征。The second determination submodule is configured to use the third feature as the target refueling behavior feature.

本实施例中,上述模块或单元分别用于执行的操作与前述实施方式的基于人工智能的行为预测方法的步骤一一对应,在此不再赘述。In this embodiment, the operations performed by the above modules or units respectively correspond to the steps of the artificial intelligence-based behavior prediction method in the foregoing embodiment, and details are not described herein again.

在本实施例的一些可选的实现方式中,所述预测模型包括输入层、LSTM层、全连接层与输出层,第二生成模块305包括:In some optional implementations of this embodiment, the prediction model includes an input layer, an LSTM layer, a fully connected layer, and an output layer, and the second generation module 305 includes:

第一生成子模块,用于将所述目标加油行为特征输入至所述预测模型的输入层内,通过所述输入层生成与所述目标加油行为特征对应的输出矩阵;a first generating submodule, configured to input the target fueling behavior feature into an input layer of the prediction model, and generate an output matrix corresponding to the target fueling behavior feature through the input layer;

第二生成子模块,用于将所述输出矩阵输入至所述预测模型的LSTM层内,通过所述LSTM层生成与所述输出矩阵对应的输出向量;a second generating submodule, configured to input the output matrix into the LSTM layer of the prediction model, and generate an output vector corresponding to the output matrix through the LSTM layer;

第三生成子模块,用于将所述输出向量输入至所述预测模型的全连接层内,基于所述全连接层内的预设激活函数生成与所述输出向量对应的预测分类结果;a third generating submodule, configured to input the output vector into a fully connected layer of the prediction model, and generate a prediction classification result corresponding to the output vector based on a preset activation function in the fully connected layer;

第三确定子模块,用于将所述预测分类结果输入至所述预测模型的输出层内,通过所述输出层输出所述预测分类结果,并将所述预测分类结果作为与所述目标用户对应的加油行为预测结果。The third determination sub-module is configured to input the predicted classification result into the output layer of the prediction model, output the predicted classification result through the output layer, and use the predicted classification result as the target user The corresponding prediction result of refueling behavior.

在本实施例中,上述模块或单元分别用于执行的操作与前述实施方式的基于人工智能的行为预测方法的步骤一一对应,在此不再赘述。In this embodiment, the operations performed by the above modules or units respectively correspond to the steps of the artificial intelligence-based behavior prediction method in the foregoing embodiment, which will not be repeated here.

在本实施例的一些可选的实现方式中,基于人工智能的行为预测装置还包括:In some optional implementations of this embodiment, the artificial intelligence-based behavior prediction apparatus further includes:

第二获取模块,用于获取预先收集的加油样本数据;The second acquisition module is used for acquiring pre-collected fueling sample data;

划分模块,用于按照预设比例将所述加油样本数据划分为训练集与测试集;a dividing module, configured to divide the refueling sample data into a training set and a test set according to a preset ratio;

第三获取模块,用于获取预先构建的初始预测模型;The third acquisition module is used to acquire the pre-built initial prediction model;

训练模块,用于基于随机梯度下降算法,使用所述训练集对所述初始预测模型进行训练,得到训练后的初始预测模型;A training module for training the initial prediction model by using the training set based on the stochastic gradient descent algorithm to obtain the initial prediction model after training;

验证模块,用于使用所述测试集对所述训练后的初始预测模型进行验证;a verification module, configured to use the test set to verify the trained initial prediction model;

第二确定模块,用于若所述训练后的初始预测模型通过验证,将所述训练后的初始预测模型作为所述预测模型。The second determination module is configured to use the trained initial prediction model as the prediction model if the trained initial prediction model passes the verification.

在本实施例中,上述模块或单元分别用于执行的操作与前述实施方式的基于人工智能的行为预测方法的步骤一一对应,在此不再赘述。In this embodiment, the operations performed by the above modules or units respectively correspond to the steps of the artificial intelligence-based behavior prediction method in the foregoing embodiment, which will not be repeated here.

在本实施例的一些可选的实现方式中,验证模块,包括:In some optional implementations of this embodiment, the verification module includes:

第一获取子模块,用于获取所述测试集;其中,所述测试集包括多个测试数据,以及与各所述测试数据分别对应的分类信息;a first acquisition submodule, configured to acquire the test set; wherein, the test set includes a plurality of test data and classification information corresponding to each of the test data respectively;

第二获取子模块,用于将所述测试数据输入至所述训练后的初始预测模型内,获取所述训练后的初始预测模型输出的与各所述测试数据分别对应的第一预测分类结果;The second obtaining sub-module is configured to input the test data into the initial prediction model after training, and obtain the first prediction classification result corresponding to each test data output by the initial prediction model after training ;

第四确定子模块,用于基于所述分类信息,确定出所有所述第一预测分类结果中预测正确的第二预测分类结果;a fourth determination submodule, configured to determine, based on the classification information, a second prediction classification result that is correctly predicted among all the first prediction classification results;

计算子模块,用于计算所述第二预测分类结果与所述第一预测分类结果的商值;a calculation submodule for calculating the quotient of the second predicted classification result and the first predicted classification result;

判断子模块,用于判断所述商值是否大于预设阈值;a judging submodule for judging whether the quotient is greater than a preset threshold;

判定子模块,用于若大于所述预设阈值,判定所述训练后的初始预测模型通过验证,否则判定所述训练后的初始预测模型未通过验证。A determination sub-module, configured to determine that the trained initial prediction model passes the verification if it is greater than the preset threshold, otherwise the trained initial prediction model fails the verification.

在本实施例中,上述模块或单元分别用于执行的操作与前述实施方式的基于人工智能的行为预测方法的步骤一一对应,在此不再赘述。In this embodiment, the operations performed by the above modules or units respectively correspond to the steps of the artificial intelligence-based behavior prediction method in the foregoing embodiment, which will not be repeated here.

在本实施例的一些可选的实现方式中,第一获取模块301包括:In some optional implementations of this embodiment, the first obtaining module 301 includes:

第三获取子模块,用于获取在所述预设时间段内的页面用户行为数据,以及获取所述目标用户的用户信息;a third acquisition sub-module, configured to acquire page user behavior data within the preset time period, and acquire user information of the target user;

筛选子模块,用于基于所述用户信息,从所述页面用户行为数据内筛选出与所述用户信息对应的指定页面用户行为数据;A screening submodule, configured to screen out the user behavior data of the specified page corresponding to the user information from the page user behavior data based on the user information;

第五处理子模块,用于子模块,用于对所述指定页面用户行为数据进行预处理,得到所述用户行为数据。The fifth processing submodule is used for the submodule, and is used for preprocessing the user behavior data of the specified page to obtain the user behavior data.

在本实施例中,上述模块或单元分别用于执行的操作与前述实施方式的基于人工智能的行为预测方法的步骤一一对应,在此不再赘述。In this embodiment, the operations performed by the above modules or units respectively correspond to the steps of the artificial intelligence-based behavior prediction method in the foregoing embodiment, which will not be repeated here.

为解决上述技术问题,本申请实施例还提供计算机设备。具体请参阅图4,图4为本实施例计算机设备基本结构框图。To solve the above technical problems, the embodiments of the present application also provide computer equipment. Please refer to FIG. 4 for details. FIG. 4 is a block diagram of a basic structure of a computer device according to this embodiment.

所述计算机设备4包括通过系统总线相互通信连接存储器41、处理器42、网络接口43。需要指出的是,图中仅示出了具有组件41-43的计算机设备4,但是应理解的是,并不要求实施所有示出的组件,可以替代的实施更多或者更少的组件。其中,本技术领域技术人员可以理解,这里的计算机设备是一种能够按照事先设定或存储的指令,自动进行数值计算和/或信息处理的设备,其硬件包括但不限于微处理器、专用集成电路(ApplicationSpecific Integrated Circuit,ASIC)、可编程门阵列(Field-Programmable GateArray,FPGA)、数字处理器(Digital Signal Processor,DSP)、嵌入式设备等。The computer device 4 includes a memory 41, a processor 42, and a network interface 43 that communicate with each other through a system bus. It should be noted that only the computer device 4 with components 41-43 is shown in the figure, but it should be understood that it is not required to implement all of the shown components, and more or less components may be implemented instead. Among them, those skilled in the art can understand that the computer device here is a device that can automatically perform numerical calculation and/or information processing according to pre-set or stored instructions, and its hardware includes but is not limited to microprocessors, special-purpose Integrated circuit (ApplicationSpecific Integrated Circuit, ASIC), programmable gate array (Field-Programmable GateArray, FPGA), digital processor (Digital Signal Processor, DSP), embedded equipment, etc.

所述计算机设备可以是桌上型计算机、笔记本、掌上电脑及云端服务器等计算设备。所述计算机设备可以与用户通过键盘、鼠标、遥控器、触摸板或声控设备等方式进行人机交互。The computer equipment may be a desktop computer, a notebook computer, a palmtop computer, a cloud server and other computing equipment. The computer device can perform human-computer interaction with the user through a keyboard, a mouse, a remote control, a touch pad or a voice control device.

所述存储器41至少包括一种类型的可读存储介质,所述可读存储介质包括闪存、硬盘、多媒体卡、卡型存储器(例如,SD或DX存储器等)、随机访问存储器(RAM)、静态随机访问存储器(SRAM)、只读存储器(ROM)、电可擦除可编程只读存储器(EEPROM)、可编程只读存储器(PROM)、磁性存储器、磁盘、光盘等。在一些实施例中,所述存储器41可以是所述计算机设备4的内部存储单元,例如该计算机设备4的硬盘或内存。在另一些实施例中,所述存储器41也可以是所述计算机设备4的外部存储设备,例如该计算机设备4上配备的插接式硬盘,智能存储卡(Smart Media Card,SMC),安全数字(Secure Digital,SD)卡,闪存卡(FlashCard)等。当然,所述存储器41还可以既包括所述计算机设备4的内部存储单元也包括其外部存储设备。本实施例中,所述存储器41通常用于存储安装于所述计算机设备4的操作系统和各类应用软件,例如基于人工智能的行为预测方法的计算机可读指令等。此外,所述存储器41还可以用于暂时地存储已经输出或者将要输出的各类数据。The memory 41 includes at least one type of readable storage medium, and the readable storage medium includes flash memory, hard disk, multimedia card, card-type memory (for example, SD or DX memory, etc.), random access memory (RAM), static Random Access Memory (SRAM), Read Only Memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), Programmable Read Only Memory (PROM), Magnetic Memory, Magnetic Disk, Optical Disk, etc. In some embodiments, the memory 41 may be an internal storage unit of the computer device 4 , such as a hard disk or a memory of the computer device 4 . In other embodiments, the memory 41 may also be an external storage device of the computer device 4 , such as a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, flash memory card (FlashCard) and so on. Of course, the memory 41 may also include both the internal storage unit of the computer device 4 and its external storage device. In this embodiment, the memory 41 is generally used to store the operating system and various application software installed on the computer device 4 , such as computer-readable instructions for a behavior prediction method based on artificial intelligence. In addition, the memory 41 can also be used to temporarily store various types of data that have been output or will be output.

所述处理器42在一些实施例中可以是中央处理器(Central Processing Unit,CPU)、控制器、微控制器、微处理器、或其他数据处理芯片。该处理器42通常用于控制所述计算机设备4的总体操作。本实施例中,所述处理器42用于运行所述存储器41中存储的计算机可读指令或者处理数据,例如运行所述基于人工智能的行为预测方法的计算机可读指令。The processor 42 may be a central processing unit (Central Processing Unit, CPU), a controller, a microcontroller, a microprocessor, or other data processing chips in some embodiments. This processor 42 is typically used to control the overall operation of the computer device 4 . In this embodiment, the processor 42 is configured to execute computer-readable instructions stored in the memory 41 or process data, for example, computer-readable instructions for executing the artificial intelligence-based behavior prediction method.

所述网络接口43可包括无线网络接口或有线网络接口,该网络接口43通常用于在所述计算机设备4与其他电子设备之间建立通信连接。The network interface 43 may include a wireless network interface or a wired network interface, and the network interface 43 is generally used to establish a communication connection between the computer device 4 and other electronic devices.

与现有技术相比,本申请实施例主要有以下有益效果:Compared with the prior art, the embodiments of the present application mainly have the following beneficial effects:

本申请实施例中,在获取到目标用户在预设时间段内的用户行为数据后,会先对用户行为数据进行特征构建处理,基于用户行为数据生成加油行为特征,然后基于主成分分析算法对加油行为特征进行筛选处理得到第一特征,以及基于预设的特征选取算法对加油行为特征进行筛选处理得到第二特征,之后基于第一特征与第二特征确定出与用户行为数据对应的目标加油行为特征,最后将目标加油行为特征输入至预设的预测模型内,通过预测模型对目标加油特征进行预测处理,生成与目标用户对应的加油行为预测结果。本申请通过利用预测模型对目标用户对应的目标加油行为特征进行预测处理,可以实现快速准确地生成与目标用户对应的加油行为预测结果,有效提高对目标用户的加油行为意向预测的处理效率与准确性。In the embodiment of the present application, after acquiring the user behavior data of the target user within the preset time period, the user behavior data will be characterized firstly, and the refueling behavior feature will be generated based on the user behavior data, and then based on the principal component analysis algorithm The refueling behavior feature is screened to obtain the first feature, and the refueling behavior feature is screened based on the preset feature selection algorithm to obtain the second feature, and then the target refueling corresponding to the user behavior data is determined based on the first feature and the second feature. Finally, the target refueling behavior characteristics are input into the preset prediction model, and the target refueling characteristics are predicted and processed through the prediction model, and the refueling behavior prediction results corresponding to the target users are generated. In the present application, by using the prediction model to predict and process the characteristics of the target refueling behavior corresponding to the target user, the prediction result of the refueling behavior corresponding to the target user can be quickly and accurately generated, and the processing efficiency and accuracy of the prediction of the refueling behavior intention of the target user can be effectively improved. sex.

本申请还提供了另一种实施方式,即提供一种计算机可读存储介质,所述计算机可读存储介质存储有计算机可读指令,所述计算机可读指令可被至少一个处理器执行,以使所述至少一个处理器执行如上述的基于人工智能的行为预测方法的步骤。The present application also provides another embodiment, that is, to provide a computer-readable storage medium, where the computer-readable storage medium stores computer-readable instructions, and the computer-readable instructions can be executed by at least one processor to The at least one processor is caused to perform the steps of the artificial intelligence-based behavior prediction method as described above.

与现有技术相比,本申请实施例主要有以下有益效果:Compared with the prior art, the embodiments of the present application mainly have the following beneficial effects:

本申请实施例中,在获取到目标用户在预设时间段内的用户行为数据后,会先对用户行为数据进行特征构建处理,基于用户行为数据生成加油行为特征,然后基于主成分分析算法对加油行为特征进行筛选处理得到第一特征,以及基于预设的特征选取算法对加油行为特征进行筛选处理得到第二特征,之后基于第一特征与第二特征确定出与用户行为数据对应的目标加油行为特征,最后将目标加油行为特征输入至预设的预测模型内,通过预测模型对目标加油特征进行预测处理,生成与目标用户对应的加油行为预测结果。本申请通过利用预测模型对目标用户对应的目标加油行为特征进行预测处理,可以实现快速准确地生成与目标用户对应的加油行为预测结果,有效提高对目标用户的加油行为意向预测的处理效率与准确性。In the embodiment of the present application, after acquiring the user behavior data of the target user within the preset time period, the user behavior data will be characterized firstly, and the refueling behavior feature will be generated based on the user behavior data, and then based on the principal component analysis algorithm The refueling behavior feature is screened to obtain the first feature, and the refueling behavior feature is screened based on the preset feature selection algorithm to obtain the second feature, and then the target refueling corresponding to the user behavior data is determined based on the first feature and the second feature. Finally, the target refueling behavior characteristics are input into the preset prediction model, and the target refueling characteristics are predicted and processed through the prediction model, and the refueling behavior prediction results corresponding to the target users are generated. In the present application, by using the prediction model to predict and process the characteristics of the target refueling behavior corresponding to the target user, the prediction result of the refueling behavior corresponding to the target user can be quickly and accurately generated, and the processing efficiency and accuracy of the prediction of the refueling behavior intention of the target user can be effectively improved. sex.

通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端设备(可以是手机,计算机,服务器,空调器,或者网络设备等)执行本申请各个实施例所述的方法。From the description of the above embodiments, those skilled in the art can clearly understand that the method of the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course can also be implemented by hardware, but in many cases the former is better implementation. Based on this understanding, the technical solution of the present application can be embodied in the form of a software product in essence or in a part that contributes to the prior art, and the computer software product is stored in a storage medium (such as ROM/RAM, magnetic disk, CD-ROM), including several instructions to make a terminal device (which may be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) execute the methods described in the various embodiments of this application.

显然,以上所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例,附图中给出了本申请的较佳实施例,但并不限制本申请的专利范围。本申请可以以许多不同的形式来实现,相反地,提供这些实施例的目的是使对本申请的公开内容的理解更加透彻全面。尽管参照前述实施例对本申请进行了详细的说明,对于本领域的技术人员来而言,其依然可以对前述各具体实施方式所记载的技术方案进行修改,或者对其中部分技术特征进行等效替换。凡是利用本申请说明书及附图内容所做的等效结构,直接或间接运用在其他相关的技术领域,均同理在本申请专利保护范围之内。Obviously, the above-described embodiments are only a part of the embodiments of the present application, rather than all of the embodiments. The accompanying drawings show the preferred embodiments of the present application, but do not limit the scope of the patent of the present application. This application may be embodied in many different forms, rather these embodiments are provided so that a thorough and complete understanding of the disclosure of this application is provided. Although the present application has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing specific embodiments, or perform equivalent replacements for some of the technical features. . Any equivalent structure made by using the contents of the description and drawings of the present application, which is directly or indirectly used in other related technical fields, is also within the scope of protection of the patent of the present application.

Claims (10)

1.一种基于人工智能的行为预测方法,其特征在于,包括下述步骤:1. a kind of behavior prediction method based on artificial intelligence, is characterized in that, comprises the following steps: 获取目标用户在预设时间段内的用户行为数据;Obtain user behavior data of target users within a preset time period; 对所述用户行为数据进行特征构建处理,基于所述用户行为数据生成加油行为特征;其中,所述加油行为特征的数量包括多个;Perform feature construction processing on the user behavior data, and generate fueling behavior features based on the user behavior data; wherein, the number of the fueling behavior features includes multiple; 基于主成分分析算法对所述加油行为特征进行筛选处理得到第一特征,以及基于预设的特征选取算法对所述加油行为特征进行筛选处理得到第二特征;The first feature is obtained by screening the refueling behavior feature based on a principal component analysis algorithm, and the second feature is obtained by screening the refueling behavior feature based on a preset feature selection algorithm; 基于所述第一特征与所述第二特征确定出与所述用户行为数据对应的目标加油行为特征;determining a target fueling behavior feature corresponding to the user behavior data based on the first feature and the second feature; 将所述目标加油行为特征输入至预设的预测模型内,通过所述预测模型对所述目标加油特征进行预测处理,生成与所述目标用户对应的加油行为预测结果。The target refueling behavior feature is input into a preset prediction model, and prediction processing is performed on the target refueling feature through the prediction model to generate a refueling behavior prediction result corresponding to the target user. 2.根据权利要求1所述的基于人工智能的行为预测方法,其特征在于,所述基于主成分分析算法对所述加油行为特征进行筛选处理得到第一特征的步骤,具体包括:2. The behavior prediction method based on artificial intelligence according to claim 1, is characterized in that, the step that the described refueling behavior feature is screened and processed based on principal component analysis algorithm to obtain the first feature, specifically comprises: 基于所述加油行为特征构建相关系数矩阵;constructing a correlation coefficient matrix based on the refueling behavior feature; 基于所述主成分分析算法对所述相关系数矩阵进行降维处理,得到多个主成分;Perform dimensionality reduction processing on the correlation coefficient matrix based on the principal component analysis algorithm to obtain a plurality of principal components; 计算每个所述主成分的方差贡献率,将所有所述方差贡献率按照从大到小的顺序进行排序,并依次累加直至超过预设的累加方差贡献率阈值;Calculate the variance contribution rate of each of the principal components, sort all the variance contribution rates in descending order, and accumulate them in turn until exceeding the preset cumulative variance contribution rate threshold; 从所有所述方差贡献率中筛选出与累加处理对应的指定主成分,并将所述指定主成分对应的特征作为所述第一特征。A designated principal component corresponding to the accumulation process is selected from all the variance contribution rates, and the feature corresponding to the designated principal component is used as the first feature. 3.根据权利要求1所述的基于人工智能的行为预测方法,其特征在于,所述基于所述第一特征与所述第二特征确定出与所述用户行为数据对应的目标加油行为特征的步骤,具体包括:3 . The behavior prediction method based on artificial intelligence according to claim 1 , wherein the method of determining the target refueling behavior feature corresponding to the user behavior data based on the first feature and the second feature. 4 . steps, including: 对所述第一特征与所述第二特征进行合并处理,得到对应的特征集合;Merging the first feature and the second feature to obtain a corresponding feature set; 对所述特征集合中的所有特征进行匹配处理,获取所述特征集合中重复出现的第三特征;Perform matching processing on all the features in the feature set, and obtain a third feature that appears repeatedly in the feature set; 将所述第三特征作为所述目标加油行为特征。The third feature is used as the target fueling behavior feature. 4.根据权利要求1所述的基于人工智能的行为预测方法,其特征在于,所述预测模型包括输入层、LSTM层、全连接层与输出层,所述将所述目标加油行为特征输入至预设的预测模型内,通过所述预测模型对所述目标加油特征进行预测处理,生成与所述目标用户对应的加油行为预测结果的步骤,具体包括:4. The behavior prediction method based on artificial intelligence according to claim 1, wherein the prediction model comprises an input layer, an LSTM layer, a fully connected layer and an output layer, and the target refueling behavior feature is input into a In the preset prediction model, the prediction process is performed on the target fueling feature through the prediction model, and the steps of generating a fueling behavior prediction result corresponding to the target user specifically include: 将所述目标加油行为特征输入至所述预测模型的输入层内,通过所述输入层生成与所述目标加油行为特征对应的输出矩阵;Inputting the target refueling behavior feature into an input layer of the prediction model, and generating an output matrix corresponding to the target refueling behavior feature through the input layer; 将所述输出矩阵输入至所述预测模型的LSTM层内,通过所述LSTM层生成与所述输出矩阵对应的输出向量;Inputting the output matrix into the LSTM layer of the prediction model, and generating an output vector corresponding to the output matrix through the LSTM layer; 将所述输出向量输入至所述预测模型的全连接层内,基于所述全连接层内的预设激活函数生成与所述输出向量对应的预测分类结果;inputting the output vector into a fully connected layer of the prediction model, and generating a prediction classification result corresponding to the output vector based on a preset activation function in the fully connected layer; 将所述预测分类结果输入至所述预测模型的输出层内,通过所述输出层输出所述预测分类结果,并将所述预测分类结果作为与所述目标用户对应的加油行为预测结果。The prediction classification result is input into the output layer of the prediction model, the prediction classification result is output through the output layer, and the prediction classification result is used as the refueling behavior prediction result corresponding to the target user. 5.根据权利要求1所述的基于人工智能的行为预测方法,其特征在于,在所述将所述目标加油行为特征输入至预设的预测模型,通过所述预测模型对所述目标加油特征进行预测处理,生成与所述目标用户对应的加油行为预测结果的步骤之前,还包括:5. The behavior prediction method based on artificial intelligence according to claim 1, characterized in that, in the described target refueling behavior feature input into a preset prediction model, the target refueling feature is analyzed by the prediction model. Before the step of performing prediction processing and generating the prediction result of the refueling behavior corresponding to the target user, the method further includes: 获取预先收集的加油样本数据;Obtain pre-collected fueling sample data; 按照预设比例将所述加油样本数据划分为训练集与测试集;Divide the refueling sample data into a training set and a test set according to a preset ratio; 获取预先构建的初始预测模型;Get a pre-built initial prediction model; 基于随机梯度下降算法,使用所述训练集对所述初始预测模型进行训练,得到训练后的初始预测模型;Based on the stochastic gradient descent algorithm, use the training set to train the initial prediction model to obtain a trained initial prediction model; 使用所述测试集对所述训练后的初始预测模型进行验证;Validating the trained initial prediction model using the test set; 若所述训练后的初始预测模型通过验证,将所述训练后的初始预测模型作为所述预测模型。If the trained initial prediction model passes the verification, the trained initial prediction model is used as the prediction model. 6.根据权利要求5所述的基于人工智能的行为预测方法,其特征在于,所述使用所述测试集对所述训练后的初始预测模型进行验证,并判断是否验证通过的步骤,具体包括:6. The artificial intelligence-based behavior prediction method according to claim 5, wherein the step of using the test set to verify the initial prediction model after the training, and judging whether the verification passes, specifically includes : 获取所述测试集;其中,所述测试集包括多个测试数据,以及与各所述测试数据分别对应的分类信息;obtaining the test set; wherein, the test set includes a plurality of test data, and classification information corresponding to each of the test data respectively; 将所述测试数据输入至所述训练后的初始预测模型内,获取所述训练后的初始预测模型输出的与各所述测试数据分别对应的第一预测分类结果;Inputting the test data into the initial prediction model after training, and obtaining the first prediction classification result output by the initial prediction model after training and corresponding to each of the test data respectively; 基于所述分类信息,确定出所有所述第一预测分类结果中预测正确的第二预测分类结果;determining, based on the classification information, a second prediction classification result that is correctly predicted among all the first prediction classification results; 计算所述第二预测分类结果与所述第一预测分类结果的商值;calculating the quotient of the second predicted classification result and the first predicted classification result; 判断所述商值是否大于预设阈值;judging whether the quotient value is greater than a preset threshold; 若大于所述预设阈值,判定所述训练后的初始预测模型通过验证,否则判定所述训练后的初始预测模型未通过验证。If it is greater than the preset threshold, it is determined that the trained initial prediction model has passed the verification; otherwise, it is determined that the trained initial prediction model has not passed the verification. 7.根据权利要求1所述的基于人工智能的行为预测方法,其特征在于,所述获取目标用户在预设时间段内的用户行为数据的步骤,具体包括:7. The artificial intelligence-based behavior prediction method according to claim 1, wherein the step of obtaining the user behavior data of the target user in a preset time period specifically includes: 获取在所述预设时间段内的页面用户行为数据,以及获取所述目标用户的用户信息;Acquiring page user behavior data within the preset time period, and acquiring user information of the target user; 基于所述用户信息,从所述页面用户行为数据内筛选出与所述用户信息对应的指定页面用户行为数据;Based on the user information, filter out the user behavior data of the specified page corresponding to the user information from the page user behavior data; 对所述指定页面用户行为数据进行预处理,得到所述用户行为数据。The user behavior data of the specified page is preprocessed to obtain the user behavior data. 8.一种基于人工智能的行为预测装置,其特征在于,包括:8. A behavior prediction device based on artificial intelligence, characterized in that, comprising: 第一获取模块,用于获取目标用户在预设时间段内的用户行为数据;a first acquisition module, used to acquire user behavior data of the target user within a preset time period; 第一生成模块,用于对所述用户行为数据进行特征构建处理,基于所述用户行为数据生成加油行为特征;其中,所述加油行为特征的数量包括多个;a first generating module, configured to perform feature construction processing on the user behavior data, and generate refueling behavior features based on the user behavior data; wherein, the number of refueling behavior features includes multiple; 处理模块,用于基于主成分分析算法对所述加油行为特征进行筛选处理得到第一特征,以及基于预设的特征选取算法对所述加油行为特征进行筛选处理得到第二特征;a processing module, configured to perform a screening process on the refueling behavior feature based on a principal component analysis algorithm to obtain a first feature, and perform a screening process on the refueling behavior feature based on a preset feature selection algorithm to obtain a second feature; 第一确定模块,用于基于所述第一特征与所述第二特征确定出与所述用户行为数据对应的目标加油行为特征;a first determining module, configured to determine a target refueling behavior feature corresponding to the user behavior data based on the first feature and the second feature; 第二生成模块,用于将所述目标加油行为特征输入至预设的预测模型内,通过所述预测模型对所述目标加油特征进行预测处理,生成与所述目标用户对应的加油行为预测结果。The second generation module is configured to input the target fueling behavior feature into a preset prediction model, perform prediction processing on the target fueling feature through the prediction model, and generate a fueling behavior prediction result corresponding to the target user . 9.一种计算机设备,包括存储器和处理器,所述存储器中存储有计算机可读指令,所述处理器执行所述计算机可读指令时实现如权利要求1至7中任一项所述的基于人工智能的行为预测方法的步骤。9. A computer device comprising a memory and a processor, wherein computer-readable instructions are stored in the memory, the processor implementing the computer-readable instructions as claimed in any one of claims 1 to 7 when the processor executes the computer-readable instructions Steps of an artificial intelligence-based approach to behavior prediction. 10.一种计算机可读存储介质,其特征在于,所述计算机可读存储介质上存储有计算机可读指令,所述计算机可读指令被处理器执行时实现如权利要求1至7中任一项所述的基于人工智能的行为预测方法的步骤。10. A computer-readable storage medium, wherein computer-readable instructions are stored on the computer-readable storage medium, and when the computer-readable instructions are executed by a processor, any one of claims 1 to 7 is implemented. The steps of the artificial intelligence-based behavior prediction method described in item.
CN202210699251.8A 2022-06-20 2022-06-20 Behavior prediction method, device, equipment and storage medium based on artificial intelligence Pending CN115099326A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210699251.8A CN115099326A (en) 2022-06-20 2022-06-20 Behavior prediction method, device, equipment and storage medium based on artificial intelligence

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210699251.8A CN115099326A (en) 2022-06-20 2022-06-20 Behavior prediction method, device, equipment and storage medium based on artificial intelligence

Publications (1)

Publication Number Publication Date
CN115099326A true CN115099326A (en) 2022-09-23

Family

ID=83291464

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210699251.8A Pending CN115099326A (en) 2022-06-20 2022-06-20 Behavior prediction method, device, equipment and storage medium based on artificial intelligence

Country Status (1)

Country Link
CN (1) CN115099326A (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115309737A (en) * 2022-10-11 2022-11-08 深圳市明源云客电子商务有限公司 Visitor intention analysis method, system, terminal device and readable storage medium
CN116204879A (en) * 2022-12-30 2023-06-02 之江实验室 Malicious file detection method and device, electronic device and storage medium
CN117336326A (en) * 2023-11-01 2024-01-02 深圳市正业玖坤信息技术有限公司 Data collection and analysis methods, devices, equipment and storage media for the Industrial Internet of Things
CN118964394A (en) * 2024-10-16 2024-11-15 江苏环迅信息科技有限公司 A potential customer analysis and mining method and system
CN119904343A (en) * 2025-04-02 2025-04-29 深圳市筑泰防务智能科技有限公司 A management system for safety management and on-the-job performance of outsiders and a management method thereof

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109461025A (en) * 2018-10-23 2019-03-12 国网湖南省电力公司节能管理分公司 A kind of electric energy substitution potential customers' prediction technique based on machine learning
CN109711860A (en) * 2018-11-12 2019-05-03 平安科技(深圳)有限公司 Prediction technique and device, storage medium, the computer equipment of user behavior
CN113642600A (en) * 2021-06-29 2021-11-12 桂林电子科技大学 Driving behavior feature extraction method based on mRMR algorithm and principal component analysis
CN113919510A (en) * 2021-11-01 2022-01-11 上海勃池信息技术有限公司 Sample feature selection method, device, equipment and medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109461025A (en) * 2018-10-23 2019-03-12 国网湖南省电力公司节能管理分公司 A kind of electric energy substitution potential customers' prediction technique based on machine learning
CN109711860A (en) * 2018-11-12 2019-05-03 平安科技(深圳)有限公司 Prediction technique and device, storage medium, the computer equipment of user behavior
CN113642600A (en) * 2021-06-29 2021-11-12 桂林电子科技大学 Driving behavior feature extraction method based on mRMR algorithm and principal component analysis
CN113919510A (en) * 2021-11-01 2022-01-11 上海勃池信息技术有限公司 Sample feature selection method, device, equipment and medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
孙占锋等: "《Python程序设计实践指导》", 28 February 2022, 中国铁道出版社有限公司, pages: 145 *

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115309737A (en) * 2022-10-11 2022-11-08 深圳市明源云客电子商务有限公司 Visitor intention analysis method, system, terminal device and readable storage medium
CN116204879A (en) * 2022-12-30 2023-06-02 之江实验室 Malicious file detection method and device, electronic device and storage medium
CN116204879B (en) * 2022-12-30 2023-12-05 之江实验室 Malicious file detection method and device, electronic device and storage medium
CN117336326A (en) * 2023-11-01 2024-01-02 深圳市正业玖坤信息技术有限公司 Data collection and analysis methods, devices, equipment and storage media for the Industrial Internet of Things
CN117336326B (en) * 2023-11-01 2024-07-02 深圳市正业玖坤信息技术有限公司 Data collection and analysis method, device, equipment and storage medium for industrial Internet of Things
CN118964394A (en) * 2024-10-16 2024-11-15 江苏环迅信息科技有限公司 A potential customer analysis and mining method and system
CN119904343A (en) * 2025-04-02 2025-04-29 深圳市筑泰防务智能科技有限公司 A management system for safety management and on-the-job performance of outsiders and a management method thereof

Similar Documents

Publication Publication Date Title
CN115099326A (en) Behavior prediction method, device, equipment and storage medium based on artificial intelligence
CN113011895A (en) Associated account sample screening method, device and equipment and computer storage medium
CN112995414B (en) Behavior quality inspection method, device, equipment and storage medium based on voice call
CN112529477A (en) Credit evaluation variable screening method, device, computer equipment and storage medium
CN116843483A (en) Vehicle insurance claim settlement method, device, computer equipment and storage medium
CN112417886A (en) Intention entity information extraction method and device, computer equipment and storage medium
CN116777646A (en) Artificial intelligence-based risk identification method, apparatus, device and storage medium
CN117611352A (en) Vehicle insurance claim processing method, device, computer equipment and storage medium
CN117078406A (en) Customer loss early warning method and device, computer equipment and storage medium
CN117172632B (en) Enterprise abnormal behavior detection method, device, equipment and storage medium
CN117350461B (en) Enterprise abnormal behavior early warning method, system, computer equipment and storage medium
CN113780806A (en) Broker matching method, device, equipment and storage medium based on decision tree
CN116402625B (en) Customer evaluation method, apparatus, computer device and storage medium
CN116340864B (en) Model drift detection method, device, equipment and storage medium thereof
CN114742643B (en) A model interpretable method for detecting interactive features in the field of financial risk control
CN113902032B (en) Business data processing method, device, computer equipment and storage medium
CN116756147A (en) A data classification method, device, computer equipment and storage medium
CN117235633A (en) Institutional classification methods, devices, computer equipment and storage media
CN116308468A (en) Client object classification method, device, computer equipment and storage medium
CN116628137A (en) Data analysis method, device, equipment and storage medium based on artificial intelligence
CN115392361A (en) Intelligent sorting method and device, computer equipment and storage medium
CN121144924A (en) A list classification method, apparatus, equipment and medium
CN119180714A (en) Vehicle insurance claim processing method, device, equipment and medium based on artificial intelligence
CN117407750A (en) Metadata-based data quality monitoring method, device, equipment and storage medium
CN117874518A (en) Insurance fraud prediction method, device, equipment and medium based on artificial intelligence

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20220923

RJ01 Rejection of invention patent application after publication