CN110708285A - Flow monitoring method, device, medium and electronic equipment - Google Patents
Flow monitoring method, device, medium and electronic equipment Download PDFInfo
- Publication number
- CN110708285A CN110708285A CN201910818633.6A CN201910818633A CN110708285A CN 110708285 A CN110708285 A CN 110708285A CN 201910818633 A CN201910818633 A CN 201910818633A CN 110708285 A CN110708285 A CN 110708285A
- Authority
- CN
- China
- Prior art keywords
- item
- feature
- characteristic
- discrete
- sample data
- 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.)
- Granted
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L63/00—Network architectures or network communication protocols for network security
- H04L63/14—Network architectures or network communication protocols for network security for detecting or protecting against malicious traffic
- H04L63/1408—Network architectures or network communication protocols for network security for detecting or protecting against malicious traffic by monitoring network traffic
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/08—Learning methods
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Computing Systems (AREA)
- Biophysics (AREA)
- General Physics & Mathematics (AREA)
- Computational Linguistics (AREA)
- Data Mining & Analysis (AREA)
- Evolutionary Computation (AREA)
- General Health & Medical Sciences (AREA)
- Molecular Biology (AREA)
- Artificial Intelligence (AREA)
- Life Sciences & Earth Sciences (AREA)
- Biomedical Technology (AREA)
- Mathematical Physics (AREA)
- Software Systems (AREA)
- Health & Medical Sciences (AREA)
- Computer Security & Cryptography (AREA)
- Computer Hardware Design (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Traffic Control Systems (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
The invention relates to the field of data processing, and discloses a traffic monitoring method, a traffic monitoring device, a traffic monitoring medium and electronic equipment based on an abnormal traffic identification model. The method comprises the following steps: acquiring flow sample data; for each continuous characteristic item, carrying out box separation on characteristic values corresponding to all flow sample data corresponding to the continuous characteristic item, and converting the continuous characteristic item into a discrete characteristic item; calculating an information gain value and/or a kini coefficient of the discrete type characteristic item based on the discrete type characteristic item corresponding to the flow sample data and a predicted value corresponding to the predicted item; acquiring a target discrete type feature item according to the information gain value and/or the kini coefficient of the discrete type feature item, and taking the flow sample data and the feature value corresponding to the target discrete type feature item as data of a training model; and monitoring the flow by using a model trained based on the data. According to the method, the effectiveness of the acquired data is improved, and the performance of the model and the accuracy of flow monitoring by using the model are improved.
Description
Technical Field
The present disclosure relates to the field of data processing, and in particular, to a method, an apparatus, a medium, and an electronic device for monitoring traffic based on an abnormal traffic recognition model.
Background
With the development of machine learning and artificial intelligence, machine learning models are more and more widely applied, for example, in the aspect of flow monitoring, machine learning models are also useful, and an abnormal flow identification model can be obtained by training the machine learning models, and then the abnormal flow identification model is used for identifying abnormal flow, so that the purpose of flow monitoring is achieved. However, training of the abnormal traffic recognition model depends heavily on data, the training of the abnormal traffic recognition model requires targeted acquisition of data besides a large amount of traffic sample data, and if the acquired data used for training the model is not suitable for training the abnormal traffic recognition model, the performance of the trained abnormal traffic recognition model may be low, how to acquire effective data to train the abnormal traffic recognition model improves the performance of the trained abnormal traffic recognition model, and further improves the effect of monitoring traffic by using the model, which is a problem to be solved urgently in the art.
Disclosure of Invention
In order to solve the technical problems in the related art, the present disclosure provides a traffic monitoring method, device, medium, and electronic device based on an abnormal traffic recognition model.
According to an aspect of the present application, there is provided a traffic monitoring method based on an abnormal traffic recognition model, the method including:
acquiring a plurality of flow sample data, wherein each flow sample data comprises a predicted value corresponding to a predicted item and a characteristic value corresponding to at least one characteristic item in a preset characteristic item set, the preset characteristic item set comprises a plurality of characteristic items, the characteristic value corresponding to each characteristic item is a discrete value or a continuous value, the characteristic item with the corresponding characteristic value being the discrete value is a discrete characteristic item, the characteristic item with the corresponding characteristic value being the continuous value is a continuous characteristic item, and the predicted value corresponding to the predicted item indicates whether the flow sample data is abnormal flow;
performing box separation processing on a characteristic value corresponding to each flow sample data corresponding to each continuous characteristic item to convert the continuous characteristic item into a discrete characteristic item, wherein a box to which each flow sample data obtained after the box separation processing belongs is a characteristic value corresponding to the discrete characteristic item converted from the continuous characteristic item;
calculating an information gain value and/or a kini coefficient of each discrete type characteristic item based on the discrete type characteristic item corresponding to each flow sample data and a predicted value corresponding to the predicted item;
screening target discrete type characteristic items from the discrete type characteristic items according to the information gain values and/or the kini coefficients of the discrete type characteristic items, and taking characteristic values of the flow sample data corresponding to the target discrete type characteristic items as data for training an abnormal flow identification model;
and monitoring the target flow by using an abnormal flow identification model formed based on the data training so as to obtain the abnormal flow.
According to another aspect of the present application, there is provided a traffic monitoring apparatus based on an abnormal traffic identification model, the apparatus including:
the acquisition module is configured to acquire a plurality of flow sample data, each flow sample data comprises a predicted value corresponding to a predicted item and a feature value corresponding to at least one feature item in a preset feature item set, the preset feature item set comprises a plurality of feature items, the feature value corresponding to each feature item is a discrete value or a continuous value, the feature item with the corresponding feature value being the discrete value is a discrete feature item, the feature item with the corresponding feature value being the continuous value is a continuous feature item, and the predicted value corresponding to the predicted item indicates whether the flow sample data is abnormal flow;
the system comprises a binning module, a filtering module and a processing module, wherein the binning module is configured to bin feature values corresponding to flow sample data corresponding to each continuous feature item so as to convert the continuous feature items into discrete feature items, and a bin to which each flow sample data obtained after binning belongs is a feature value corresponding to the discrete feature item converted from the continuous feature items;
the calculation module is configured to calculate an information gain value and/or a kini coefficient of each discrete type feature item based on the discrete type feature item corresponding to each flow sample data and a predicted value corresponding to the predicted item;
the data acquisition module is configured to screen a target discrete type feature item from the discrete type feature items according to the information gain value and/or the kini coefficient of each discrete type feature item, and use the feature value corresponding to each flow sample data and the target discrete type feature item as data for training an abnormal flow identification model;
and the monitoring module is configured to monitor the target traffic by using an abnormal traffic recognition model formed based on the data training so as to obtain abnormal traffic.
According to another aspect of the present application, there is provided a computer readable program medium storing computer program instructions which, when executed by a computer, cause the computer to perform the method as previously described.
According to another aspect of the present application, there is provided an electronic device including:
a processor;
a memory having computer readable instructions stored thereon which, when executed by the processor, implement the method as previously described.
The technical scheme provided by the embodiment of the invention can have the following beneficial effects: for the traffic monitoring method based on the abnormal traffic identification model provided by the invention, the method comprises the following steps: acquiring a plurality of flow sample data, wherein each flow sample data comprises a predicted value corresponding to a predicted item and a characteristic value corresponding to at least one characteristic item in a preset characteristic item set, the preset characteristic item set comprises a plurality of characteristic items, the characteristic value corresponding to each characteristic item is a discrete value or a continuous value, the characteristic item with the corresponding characteristic value being the discrete value is a discrete characteristic item, the characteristic item with the corresponding characteristic value being the continuous value is a continuous characteristic item, and the predicted value corresponding to the predicted item indicates whether the flow sample data is abnormal flow; performing box separation processing on a characteristic value corresponding to each flow sample data corresponding to each continuous characteristic item to convert the continuous characteristic item into a discrete characteristic item, wherein a box to which each flow sample data obtained after the box separation processing belongs is a characteristic value corresponding to the discrete characteristic item converted from the continuous characteristic item; calculating an information gain value and/or a kini coefficient of each discrete type characteristic item based on the discrete type characteristic item corresponding to each flow sample data and a predicted value corresponding to the predicted item; screening target discrete type characteristic items from the discrete type characteristic items according to the information gain values and/or the kini coefficients of the discrete type characteristic items, and taking characteristic values of the flow sample data corresponding to the target discrete type characteristic items as data for training an abnormal flow identification model; and monitoring the target flow by using an abnormal flow identification model formed based on the data training so as to obtain the abnormal flow.
Under the method, after flow sample data containing discrete characteristic items and/or continuous characteristic items are obtained, discrete characteristic items are obtained by carrying out box separation on the continuous characteristic items, then target discrete characteristic items are obtained according to information gain values and/or kini coefficients of the discrete characteristic items, and characteristic values corresponding to the target discrete characteristic items are used as data for training an abnormal flow identification model, so that the obtained target discrete characteristic items are more suitable for training the abnormal flow identification model, the effectiveness of the obtained flow data for training the abnormal flow identification model is improved, meanwhile, when the obtained target discrete characteristic items are used for training the abnormal flow identification model, overfitting can be avoided, the performance of the trained abnormal flow identification model can be improved, when the abnormal flow identification model trained by using the obtained data is used for flow monitoring, the accuracy of monitoring the abnormal flow can be improved, and the monitoring effect of the abnormal flow is further improved.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the invention, as claimed.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and together with the description, serve to explain the principles of the invention.
FIG. 1 is a system architecture diagram illustrating a traffic monitoring method based on an abnormal traffic identification model in accordance with an exemplary embodiment;
FIG. 2 is a flow diagram illustrating a method of traffic monitoring based on an abnormal traffic identification model in accordance with an exemplary embodiment;
FIG. 3 is a detailed flow diagram of step 220 according to one embodiment shown in a corresponding embodiment in FIG. 2;
FIG. 4 is a flowchart illustrating steps preceding step 250 and details of step 250 according to one embodiment shown in a corresponding embodiment in FIG. 2;
FIG. 5 is a flowchart detailing step 230 according to one embodiment shown in a corresponding embodiment in FIG. 4;
FIG. 6 is a block diagram illustrating an abnormal traffic identification model based traffic monitoring apparatus in accordance with an exemplary embodiment;
FIG. 7 is a block diagram illustrating an example of an electronic device for implementing the abnormal traffic identification model-based traffic monitoring method described above, according to an example embodiment;
fig. 8 is a computer-readable storage medium for implementing the abnormal traffic identification model-based traffic monitoring method according to an exemplary embodiment.
Detailed Description
Reference will now be made in detail to the exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present invention. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the invention, as detailed in the appended claims.
Furthermore, the drawings are merely schematic illustrations of the present disclosure and are not necessarily drawn to scale. The same reference numerals in the drawings denote the same or similar parts, and thus their repetitive description will be omitted. Some of the block diagrams shown in the figures are functional entities and do not necessarily correspond to physically or logically separate entities.
The disclosure firstly provides a flow monitoring method based on an abnormal flow identification model. The traffic monitoring method based on the abnormal traffic identification model refers to the method for monitoring traffic by using the abnormal traffic identification model. The model refers to a machine learning model, and may include various types, such as a decision tree model, a logistic regression model, a support vector machine, and the like. The training machine learning model needs to acquire data, the data refers to information about objects organized according to a certain form, an abnormal traffic recognition model needs to be established, data used for training the abnormal traffic recognition model needs to be acquired for model training, and the type of the acquired data is generally traffic data. Training an abnormal traffic recognition model refers to training any type of model to be a model capable of handling an abnormal traffic recognition task. The abnormal flow identification model is trained in a process of determining parameters of the abnormal flow identification model, and the abnormal flow identification model-based flow monitoring method provided by the disclosure can be used for firstly acquiring data for training the abnormal flow identification model, then training the abnormal flow identification model by using the acquired data, and finally obtaining the abnormal flow identification model, so that the abnormal flow identification model is used for realizing effective monitoring on flow.
The method disclosed by the invention can be fixed to various terminals, such as any equipment or equipment set with an operation processing function and a communication function, such as a server, a physical infrastructure of cloud computing, a smart phone, a tablet computer, a desktop computer, a notebook computer, an iPad, a PDA (Personal Digital Assistant, abbreviated as palmtop computer) self-service terminal and the like.
Fig. 1 is a system architecture diagram illustrating a traffic monitoring method based on an abnormal traffic identification model according to an exemplary embodiment. As shown in fig. 1, the system includes a server 110, a plurality of terminals 120, and a database 130, in the embodiment shown in fig. 1, the implementing terminal of the present disclosure is the server 110, the plurality of terminals 120 and the database 130 can communicate with the server 110 through a communication link, each terminal 120 consumes traffic when accessing the server 110 through the communication link, and after receiving an access request sent by the terminal 120, a large-traffic or illegal-traffic server 110, which may cause an abnormality when accessing the server 110, of each terminal 120 may record traffic data according to a traffic situation when accessing each terminal, and then send the traffic data to the database 130 connected thereto for storage. The traffic data recorded and stored by the server 110 into the database 130 may not all satisfy the requirement of training the abnormal traffic recognition model, as required for a specific application purpose or demand purpose, and data suitable for training the abnormal traffic recognition model needs to be selected from the traffic data for the abnormal traffic recognition model training, and when the traffic monitoring method based on the abnormal traffic recognition model provided by the present disclosure is executed in the implementation terminal-server 110 in the present embodiment, the traffic data suitable for the training of the abnormal traffic recognition model can be obtained from the database 130, and the training of the abnormal traffic recognition model using the data can make the trained model have better monitoring effect, therefore, when the trained abnormal traffic identification model running on the server 110 monitors the traffic of each terminal, higher accuracy of monitoring the abnormal traffic can be ensured.
It should be noted that fig. 1 is only one embodiment of the present disclosure, and although in the embodiment shown in fig. 1, traffic originates from each terminal, and the server records and summarizes the corresponding traffic data from each terminal into the database, and the trained abnormal traffic identification model is fixed on the server, in practical applications, the traffic data may be generated and exist in various manners, for example, the traffic data may be a data packet forwarded by other terminals, one data packet may include a plurality of traffic data, the obtained traffic data may also be stored in a local or other terminal, and the trained abnormal traffic identification model may also be fixed on various terminals. The present disclosure is not intended to be limited thereby, nor should the scope of the present disclosure be limited thereby.
Fig. 2 is a flow chart illustrating a method for traffic monitoring based on an abnormal traffic identification model according to an exemplary embodiment. As shown in fig. 2, the method comprises the following steps:
Each flow sample data comprises a predicted value corresponding to a predicted item and a feature value corresponding to at least one feature item in a preset feature item set, the preset feature item set comprises a plurality of feature items, the feature value corresponding to each feature item is a discrete value or a continuous value, the feature item with the corresponding feature value being the discrete value is a discrete feature item, the feature item with the corresponding feature value being the continuous value is a continuous feature item, and the predicted value corresponding to the predicted item indicates whether the flow sample data is abnormal flow.
The flow sample data can be data related to a main body generating the access flow in any dimension, and one flow sample data also contains data of a labeling result of whether the flow sample data is abnormal flow. The prediction item is an attribute to be predicted by training the abnormal flow recognition model, namely an attribute corresponding to the labeling result, and can also be called as a label or a dependent variable; the predicted value corresponding to the predicted item is the value of the predicted item, namely the value of the labeled result. The characteristic item is an attribute or a characteristic representing one dimension of the flow sample data, and the characteristic value is a value of the attribute or the characteristic and is an independent variable.
For example, the traffic sample data may be such that the predicted item is an abnormal traffic judgment, the predicted value corresponding to the predicted item is a tag of whether one traffic sample data is an abnormal traffic feature item, the feature item may be an IP address, a WI-FI name, the number of times of accessing the same IP address, the number of account numbers accessed by the same IP address, the number of IP addresses requested to be accessed in a predetermined time period, the number of combinations of the same IP address and the WI-FI name, and the like, and the feature value corresponding to each feature item is a corresponding value of each feature item, where values corresponding to feature items such as the number of times of accessing the same IP address, the number of account numbers accessed by the same IP address, the number of IP addresses requested to be accessed in a predetermined time period, the number of combinations of the same IP address and the WI-FI name, and the like are various and continuous values, and the number of times of accessing the same IP address may be 1, and the number of, 2. 3, 4, etc., so that the characteristic values corresponding to the characteristic items are continuous values, and the corresponding characteristic items are continuous characteristic items; the values of the feature items, such as the IP address and the WI-FI name, are discrete values, for example, the values of the WI-FI name may be a preset character string, and the values of the feature items have no obvious continuity, so that the values corresponding to the feature items are discrete values, and the feature items are discrete feature items.
In one embodiment, a predicted value corresponding to a prediction term included in each of the traffic sample data is "0" or "1", where "0" represents that the traffic sample data is not abnormal traffic, and "1" represents that the traffic sample data is abnormal traffic.
In one embodiment, the predicted value corresponding to the prediction item included in each of the traffic sample data is yes or no, and the yes or no may be correspondingly converted into "1" or "0" when the model is trained.
The number of the feature items corresponding to the feature value included in each flow sample data may be the same as or different from the number of the feature items included in the preset feature item set, and the number and the type of the feature items corresponding to the feature value included in each flow sample data may be the same as or different from each other.
In one embodiment, each of the traffic sample data includes a feature value corresponding to each feature item in a preset feature item set.
In one embodiment, the obtaining a plurality of traffic sample data includes: acquiring original flow sample data; performing data cleaning on the original flow sample data to filter abnormal data in the original flow sample data, wherein the abnormal data comprises a missing value and/or an outlier; and acquiring a plurality of flow sample data from the original flow sample data subjected to data cleaning.
The missing value refers to the absence of a value corresponding to a feature item of the traffic sample data, and the outlier refers to the deviation of the value corresponding to the feature item of the traffic sample data from a normal level, for example, if the feature item of one traffic sample data is a WI-FI name and the value of the feature item is NULL (NULL), the value is the outlier.
In one embodiment, outliers in the original traffic sample data are filtered out by:
for each continuous characteristic item, sorting the characteristic values corresponding to the continuous characteristic items contained in each flow sample data from small to large;
and filtering the flow sample data of which the eigenvalue corresponding to the contained continuous type eigenvalue is less than the 2.5 th percentile or greater than the 97.5 th percentile as an outlier according to the sorting.
And step 220, performing box separation processing on the characteristic value corresponding to each flow sample data corresponding to each continuous characteristic item so as to convert the continuous characteristic item into a discrete characteristic item, wherein the box to which each flow sample data obtained after the box separation processing belongs is the characteristic value corresponding to the discrete characteristic item converted from the continuous characteristic item.
The binning refers to a process of performing segmentation processing on the feature values corresponding to one continuous feature item.
In one embodiment, a Classification and Regression Trees (CART) algorithm or a chi-square binning algorithm is used to bin feature values corresponding to each flow sample data corresponding to the continuous feature.
In an embodiment, for each continuous type feature item, performing binning processing on a feature value corresponding to each traffic sample data corresponding to the continuous type feature item to convert the continuous type feature item into a discrete type feature item includes:
for each continuous characteristic item, sorting the characteristic values corresponding to the continuous characteristic items in the flow sample data from large to small; selecting the characteristic values corresponding to a preset number of sample data to be divided into one box from the characteristic value which is sorted at the top and corresponds to the continuous characteristic item according to the sorting, and marking the flow sample data which is subjected to the box division as selected; and starting from the feature values which are not marked as selected and are sequenced in the top flow sample data and correspond to the continuous feature item, selecting a preset number of feature values corresponding to the continuous feature item each time according to the sequence, dividing the feature values into a box, marking the classified feature values corresponding to the continuous feature item as selected until all the feature values corresponding to the continuous feature item are marked as selected, wherein when the number of the feature values which are not marked as selected and correspond to the continuous feature item is less than the preset number, dividing all the feature values which are not marked as selected and correspond to the continuous feature item into a box.
The present embodiment is advantageous in that the number of feature values corresponding to the continuous type feature items divided into each bin is made approximately the same, and the balance of binning is improved.
In an embodiment, for each continuous type feature item, performing binning processing on a feature value corresponding to each traffic sample data corresponding to the continuous type feature item to convert the continuous type feature item into a discrete type feature item includes:
for each continuous characteristic item, acquiring a section division reference value of the continuous characteristic item and the maximum value of the characteristic value corresponding to the continuous characteristic item in each flow sample data, wherein the section division reference value is less than or equal to the minimum value of the characteristic value corresponding to the continuous characteristic item in each flow sample data;
for each continuous characteristic item, averagely dividing a section between a section division reference value of the continuous characteristic item and the maximum value of the characteristic value corresponding to the continuous characteristic item in each flow sample data into a preset number of characteristic value sections;
and for each continuous characteristic item, for each flow sample data, according to a characteristic value interval to which the characteristic value corresponding to the continuous characteristic item in the flow sample data belongs, performing box separation on the characteristic value in the flow sample data corresponding to the continuous characteristic item, wherein the characteristic value interval to which the characteristic value corresponding to the continuous characteristic item belongs is the same as the characteristic value interval of the flow sample data.
The advantage of this embodiment is that the difference between the eigenvalues of the flow sample data classified into the same bin is not too large, and the correlation between the bins and the difference between the eigenvalues of the flow sample data is improved.
In an embodiment, for each continuous type feature item, performing binning processing on a feature value corresponding to each traffic sample data corresponding to the continuous type feature item to convert the continuous type feature item into a discrete type feature item includes:
for each continuous characteristic item, sorting the characteristic values corresponding to the continuous characteristic items in the flow sample data from large to small; selecting the characteristic values corresponding to the preset number of flow sample data according to the sorting from the characteristic values corresponding to the continuous characteristic items sorted at the top; when the difference value between the maximum value and the minimum value in the characteristic values corresponding to the selected flow sample data is larger than a preset difference value threshold value corresponding to the continuous characteristic item, dividing the characteristic value corresponding to the flow sample data of which the difference value between the maximum value and the characteristic value corresponding to the selected flow sample data is smaller than or equal to the preset difference value threshold value corresponding to the continuous characteristic item into a box, and marking the flow sample data which is subjected to box division as selected; when the difference value between the maximum value and the minimum value in the characteristic values corresponding to the selected flow sample data is less than or equal to the preset difference value threshold value corresponding to the continuous characteristic item, dividing the characteristic values corresponding to all the selected flow sample data into a box, and marking the flow sample data which is subjected to box division as selected; selecting a preset number of feature values corresponding to the continuous feature item each time according to the sorting from feature values which are not marked as selected and are sorted at the top and correspond to the continuous feature item, and selecting feature values corresponding to the continuous feature item according to a difference value between a maximum value and a minimum value in the selected feature values corresponding to the continuous feature item, wherein when a difference value between the maximum value and the minimum value in the selected feature values corresponding to the flow sample data and the continuous feature item is greater than a preset difference threshold value corresponding to the continuous feature item, the feature values corresponding to the flow sample data of which the difference value between the maximum value and the characteristic value is less than or equal to the preset difference threshold value corresponding to the continuous feature item are divided into a box, and the feature values corresponding to the flow sample data which are divided into the boxes are marked as selected, when the difference value between the maximum value and the minimum value in the feature values corresponding to the selected flow sample data is less than or equal to the preset difference threshold value corresponding to the continuous feature item, dividing the feature values corresponding to all the selected flow sample data into a box, and marking the feature values corresponding to the flow sample data which is subjected to box division as selected until all the flow sample data is marked as selected, wherein when the number of the flow sample data which is not marked as selected is less than the preset number, dividing all the flow sample data which is not marked as selected into a box.
The method has the advantages that the difference between the characteristic values corresponding to the continuous characteristic items in the same separated box and the quantity of the characteristic values corresponding to the continuous characteristic items in the separated box are balanced and considered, and the characteristic values are more reasonably divided by separating the box.
And 250, calculating an information gain value and/or a kini coefficient of each discrete type characteristic item based on the discrete type characteristic item corresponding to each flow sample data and a predicted value corresponding to the predicted item.
The information gain and the Gini coefficient are important indexes for measuring the purity of data. The information gain is to select the expected information needed by the division according to a certain independent variable, and the smaller the expected information is, the higher the purity of the division is. Information gain can also be defined as how much information a feature (variable) can bring to a classification, the more information it brings, the more important the variable is. The kini coefficient can reflect the division purity of a plurality of flow sample data divided by discrete characteristic items.
In one embodiment, the information gain value for each discrete feature is calculated using the following equation:
calculating the information entropy of the whole acquired multiple flow sample data by using the following formula:
wherein D is the acquired multiple flow sample data, pkThe ratio of the number of the flow sample data with the predicted value corresponding to the k-th prediction item to the number of all the acquired flow sample dataK is the number of types of predicted values corresponding to all predicted items in the acquired flow sample data;
calculating the information gain of the discrete type characteristic item b by using the following formula based on the information entropy of the acquired multiple flow sample data as a whole:
wherein D isNAnd the flow sample data of the Nth value containing the discrete characteristic item b in the plurality of flow sample data is obtained.
In one embodiment, the kini coefficient of the discrete feature term b is calculated using the following formula:
wherein D is the acquired multiple flow sample data, pkThe ratio of the number of flow sample data with a predicted value corresponding to the kth prediction item to the number of all acquired flow sample data, k is the number of types of predicted values corresponding to all prediction items in the acquired flow sample data, DNAnd the flow sample data of the Nth value containing the discrete characteristic item b in the plurality of flow sample data is obtained.
By calculating the information gain value and the kini coefficient of each discrete feature item and taking the calculation result as the screening standard of the discrete feature items, the simplification of the quantity of the discrete feature items is realized, so that the reserved feature items have better correlation with the prediction items, and finally obtained data are more suitable for training an abnormal flow identification model.
And 260, screening target discrete type characteristic items from the discrete type characteristic items according to the information gain values and/or the kini coefficients of the discrete type characteristic items, and taking characteristic values of the flow sample data corresponding to the target discrete type characteristic items as data for training the abnormal flow identification model.
In one embodiment, screening out a target discrete type feature item from each discrete type feature item according to the information gain value and/or the kini coefficient of each discrete type feature item comprises:
and acquiring a discrete characteristic item of which the information gain value is greater than a preset information gain value threshold value or the kini coefficient is less than a preset kini coefficient threshold value as a target discrete characteristic item.
In one embodiment, the screening out the target discrete type feature item from the discrete type feature items according to the information gain value and/or the kini coefficient of each discrete type feature item includes:
screening initial characteristic items from the discrete characteristic items according to the information gain value and/or the kini coefficient of each discrete characteristic item;
repeatedly executing the initial characteristic item screening step to obtain an initial characteristic item set until the repetition times reach a first preset number, wherein the initial characteristic item screening step comprises the following steps of:
establishing a random forest by using a feature item set formed by the initial feature items, wherein the feature set comprises a plurality of initial feature items, the random forest comprises a plurality of decision trees, and each decision tree comprises a plurality of initial feature items;
for each initial feature item, determining the importance degree of the initial feature item in each decision tree, and determining the importance degree of the initial feature item in the random forest based on the importance degree of the initial feature item in each decision tree;
arranging the initial feature items according to the order of the importance degrees from high to low, and acquiring a second predetermined number of initial feature items which are ranked in the front as an initial feature item set;
and taking the intersection of all the initial feature item sets as a target discrete feature item.
In this embodiment, on the basis of obtaining the initial feature item according to the information gain value and/or the kini coefficient of each discrete feature item, the random forest is used again to obtain the target discrete feature item, so that the finally obtained target discrete feature item is more suitable for training the abnormal traffic recognition model, and thus the trained abnormal traffic recognition model can more accurately recognize abnormal traffic.
In one embodiment, the determining, for each initial feature item, the importance degree of the initial feature item in each decision tree includes:
aiming at each decision tree, acquiring the variation quantity of the Gini index of each node corresponding to each initial characteristic item before and after branching in the decision tree;
for each decision tree, for each initial feature item, obtaining the sum of variation amounts of the kini indexes before and after the branch in the decision tree, which is obtained for each node of the initial feature item, as the importance degree of the initial feature item in the decision tree;
the determining the importance degree of the initial feature item in the random forest based on the importance degree of the initial feature item in each decision tree comprises the following steps:
and taking the average value of the importance degrees of the initial feature item in each decision tree as the importance degree of the initial feature item in the random forest.
In one embodiment, after screening a target discrete feature item from each discrete feature item according to the information gain value and/or the kini coefficient of each discrete feature item, and using a feature value of each flow sample data corresponding to the target discrete feature item as data for training an abnormal flow identification model, the method further includes:
and inputting the obtained data of the training abnormal flow recognition model into a logistic regression model to train and form an abnormal flow recognition model.
And 270, monitoring the target flow by using an abnormal flow identification model formed based on the data training to obtain the abnormal flow.
After the abnormal flow recognition model is trained by using the acquired data, the abnormal flow recognition model can be used for monitoring the flow.
In summary, according to the method for acquiring data of the training abnormal traffic recognition model shown in the embodiment of fig. 2, the acquired target discrete type feature item is more suitable for training the machine learning model, so that the effectiveness of the acquired data for training the abnormal traffic recognition model is improved, and when the acquired data is used for training the abnormal traffic recognition model, the performance of the trained abnormal traffic recognition model can be improved, so that the traffic monitoring precision and the traffic monitoring effect of the trained abnormal traffic recognition model are improved.
Fig. 3 is a detailed flowchart of step 220 according to one embodiment shown in a corresponding embodiment of fig. 2. As shown in fig. 3, step 220 includes the following steps:
step 221, for each continuous type feature item, clustering feature values corresponding to the continuous type feature item in each flow sample data to divide the feature values corresponding to the continuous type feature item into a plurality of classes.
In one embodiment, a DBSCAN (Density-Based Clustering with Noise) algorithm is used to cluster feature values corresponding to the continuum feature term in each traffic sample data to divide the feature values corresponding to the continuum feature term into a plurality of classes.
Step 222, for each continuous type feature item, performing binning processing on the feature values corresponding to the traffic sample data corresponding to the continuous type feature item according to a plurality of classes into which the feature values corresponding to the continuous type feature item are divided, so as to convert the continuous type feature item into a discrete type feature item.
In one embodiment, the eigenvalues corresponding to the continuous type eigenvalues in the traffic sample data classified into one class are classified into one bin.
In an embodiment, for each continuous type feature item, performing binning processing on feature values corresponding to each traffic sample data corresponding to the continuous type feature item according to a plurality of classes into which the feature values corresponding to the continuous type feature item are divided includes:
for each continuous characteristic item, sorting each class into which the characteristic values corresponding to the continuous characteristic item are divided according to the average value of the characteristic values corresponding to the continuous characteristic item in the class from small to large;
repeatedly executing the step of binning until each class passes the binning, wherein the step of binning comprises the following steps:
starting from the top-ranked class, judging whether the number of characteristic values contained in each class is larger than a preset number threshold value or not for each class which is not subjected to binning;
if so, dividing the class into one box, and marking the class as the divided box;
if not, starting from the class, obtaining a class which is not marked as a classified box at each time according to the sorting, judging whether the sum of the number of the characteristic values contained in all the obtained classes which are not marked as the classified box is larger than a preset number threshold value, and if so, dividing the obtained characteristic values contained in all the obtained classes which are not marked as the classified box into one box.
The method has the advantages that the characteristic values corresponding to the flow sample data are subjected to binning processing in a clustering mode, so that the binning result can reasonably divide the characteristic values corresponding to the flow sample data, and the effectiveness of the acquired data for training the abnormal flow identification model can be improved.
Fig. 4 is a flowchart illustrating steps preceding step 250 and details of step 250 according to an embodiment illustrated in a corresponding embodiment of fig. 2. As shown in fig. 4, the method comprises the following steps:
and step 230, clustering each discrete feature item to divide each discrete feature item into a plurality of clusters.
Clustering refers to the process of classifying discrete feature items.
In one embodiment, as shown in fig. 5, step 230 may specifically include the following steps:
in step 231, the pearson correlation coefficient between each pair of discrete features in each discrete feature is determined.
The pearson correlation coefficient is a coefficient used to measure the degree of correlation between two variables.
In one embodiment, the pearson correlation coefficient between each pair of discrete feature terms is calculated using the following formula:
wherein x is a first discrete feature term, y is a second discrete feature term, xiIs the i-th eigenvalue, y, of the first discrete eigenvalueiIs the ith eigenvalue of the second discrete eigenvalue.
And step 232, clustering each discrete feature item by using the pearson correlation coefficient so as to divide each discrete feature item into a plurality of clusters.
In one embodiment, the clustering the discrete feature items by using the pearson correlation coefficient to divide the discrete feature items into a plurality of clusters includes:
repeatedly executing the intra-cluster reference item obtaining step until no item with the Pearson correlation coefficient of the reference item smaller than a preset Pearson correlation coefficient threshold exists, and classifying the obtained marked reference items into a cluster, wherein the intra-cluster reference item obtaining step comprises the following steps:
acquiring an unmarked discrete type feature item, and marking the discrete type feature item as an initial intra-cluster reference item;
acquiring a term of which the Pearson correlation coefficient with the reference term is smaller than a preset Pearson correlation coefficient threshold;
canceling the mark of the reference item, marking the obtained item as the reference item, obtaining an item of which the Pearson correlation coefficient with the reference item is smaller than a preset Pearson correlation coefficient threshold value, canceling the mark of the reference item at the latest time and marking the obtained item as the reference item again;
and acquiring an unmarked discrete type feature item again, marking the discrete type feature item as an initial intra-cluster reference item, and repeatedly executing the intra-cluster reference item acquisition step until the unmarked discrete type feature item does not exist.
in one embodiment, for each cluster, any one discrete feature is taken as the target discrete feature.
And 250', calculating an information gain value and/or a kini coefficient of each discrete type characteristic item based on the target discrete type characteristic item corresponding to each flow sample data and the predicted value corresponding to the predicted item.
In summary, the advantage of the embodiment corresponding to fig. 4 is that the discrete feature items are classified into a plurality of clusters according to the clustering, and then the target discrete feature item is selected according to the cluster obtained by clustering, so that the dimension reduction processing on the feature items is realized, the effectiveness of the obtained discrete feature items is improved under the condition that the information amount is not significantly reduced, the effectiveness of the data for training the abnormal traffic identification model obtained according to the obtained discrete feature items can be improved, the performance of the abnormal traffic monitoring model trained by using the data can be improved, and the accuracy and the effect of traffic monitoring can be improved.
The disclosure also provides a flow monitoring device based on the abnormal flow identification model, and the following is an embodiment of the device disclosed herein.
FIG. 6 is a block diagram illustrating an abnormal traffic identification model based traffic monitoring apparatus according to an exemplary embodiment. As shown in fig. 6, the apparatus 600 includes:
an obtaining module 610, configured to obtain a plurality of flow sample data, where each flow sample data includes a predicted value corresponding to a predicted item and a feature value corresponding to at least one feature item in a preset feature item set, the preset feature item set includes a plurality of feature items, and the feature value corresponding to each feature item is a discrete value or a continuous value, where the feature item whose corresponding feature value is a discrete feature item, the feature item whose corresponding feature value is a continuous feature item, and the predicted value corresponding to the predicted item indicates whether the flow sample data is an abnormal flow;
a binning module 620 configured to perform binning processing on a feature value corresponding to each flow sample data corresponding to each continuous feature item so as to convert the continuous feature item into a discrete feature item, where a bin to which each flow sample data obtained after the binning processing belongs is a feature value corresponding to the discrete feature item into which the continuous feature item is converted;
a calculating module 630, configured to calculate an information gain value and/or a kini coefficient of each discrete type feature item based on the discrete type feature item corresponding to each flow sample data and a predicted value corresponding to the predicted item;
the data acquisition module 640 is configured to screen a target discrete type feature item from the discrete type feature items according to the information gain value and/or the kini coefficient of each discrete type feature item, and use a feature value corresponding to each flow sample data and the target discrete type feature item as data for training an abnormal flow identification model;
and the monitoring module 650 monitors the target traffic by using an abnormal traffic recognition model formed based on the data training to obtain abnormal traffic.
According to a third aspect of the present disclosure, an electronic device capable of implementing the abnormal traffic identification model-based traffic monitoring method is also provided.
As will be appreciated by one skilled in the art, aspects of the present invention may be embodied as a system, method or program product. Thus, various aspects of the invention may be embodied in the form of: an entirely hardware embodiment, an entirely software embodiment (including firmware, microcode, etc.) or an embodiment combining hardware and software aspects that may all generally be referred to herein as a "circuit," module "or" system.
An electronic device 700 according to this embodiment of the invention is described below with reference to fig. 7. The electronic device 700 shown in fig. 7 is only an example and should not bring any limitation to the functions and the scope of use of the embodiments of the present invention.
As shown in fig. 7, electronic device 700 is embodied in the form of a general purpose computing device. The components of the electronic device 700 may include, but are not limited to: the at least one processing unit 710, the at least one memory unit 720, and a bus 730 that couples various system components including the memory unit 720 and the processing unit 710.
Wherein the storage unit stores program code that can be executed by the processing unit 710 such that the processing unit 710 performs the steps according to various exemplary embodiments of the present invention described in the section "example methods" above in this specification.
The storage unit 720 may include readable media in the form of volatile memory units, such as a random access memory unit (RAM)721 and/or a cache memory unit 722, and may further include a read only memory unit (ROM) 723.
The memory unit 720 may also include programs/utilities 724 having a set (at least one) of program modules 725, such program modules 725 including, but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which, or some combination thereof, may comprise an implementation of a network environment.
The electronic device 700 may also communicate with one or more external devices 900 (e.g., keyboard, pointing device, bluetooth device, etc.), with one or more devices that enable a user to interact with the electronic device 700, and/or with any devices (e.g., router, modem, etc.) that enable the electronic device 700 to communicate with one or more other computing devices. Such communication may occur via an input/output (I/O) interface 750. Also, the electronic device 700 may communicate with one or more networks (e.g., a Local Area Network (LAN), a Wide Area Network (WAN), and/or a public network such as the internet) via the network adapter 760. As shown, the network adapter 760 communicates with the other modules of the electronic device 700 via the bus 730. It should be appreciated that although not shown in the figures, other hardware and/or software modules may be used in conjunction with the electronic device 700, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, among others.
Through the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein may be implemented by software, or by software in combination with necessary hardware. Therefore, the technical solution according to the embodiments of the present disclosure may be embodied in the form of a software product, which may be stored in a non-volatile storage medium (which may be a CD-ROM, a usb disk, a removable hard disk, etc.) or on a network, and includes several instructions to enable a computing device (which may be a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the embodiments of the present disclosure.
According to a fourth aspect of the present disclosure, there is also provided a computer-readable storage medium having stored thereon a program product capable of implementing the above-mentioned method of the present specification. In some possible embodiments, aspects of the invention may also be implemented in the form of a program product comprising program code means for causing a terminal device to carry out the steps according to various exemplary embodiments of the invention described in the above section "exemplary methods" of the present description, when said program product is run on the terminal device.
Referring to fig. 8, a program product 800 for implementing the above method according to an embodiment of the present invention is described, which may employ a portable compact disc read only memory (CD-ROM) and include program code, and may be run on a terminal device, such as a personal computer. However, the program product of the present invention is not limited in this regard and, in the present document, a readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
The program product may employ any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the readable storage medium include: an electrical connection having one or more wires, a portable disk, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
A computer readable signal medium may include a propagated data signal with readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A readable signal medium may also be any readable medium that is not a readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device.
Program code embodied on a readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
Program code for carrying out operations for aspects of the present invention may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computing device, partly on the user's device, as a stand-alone software package, partly on the user's computing device and partly on a remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external computing device (e.g., through the internet using an internet service provider).
Furthermore, the above-described figures are merely schematic illustrations of processes involved in methods according to exemplary embodiments of the invention, and are not intended to be limiting. It will be readily understood that the processes shown in the above figures are not intended to indicate or limit the chronological order of the processes. In addition, it is also readily understood that these processes may be performed synchronously or asynchronously, e.g., in multiple modules.
It will be understood that the invention is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the invention is limited only by the appended claims.
Claims (10)
1. A flow monitoring method based on an abnormal flow identification model is characterized by comprising the following steps:
acquiring a plurality of flow sample data, wherein each flow sample data comprises a predicted value corresponding to a predicted item and a characteristic value corresponding to at least one characteristic item in a preset characteristic item set, the preset characteristic item set comprises a plurality of characteristic items, the characteristic value corresponding to each characteristic item is a discrete value or a continuous value, the characteristic item with the corresponding characteristic value being the discrete value is a discrete characteristic item, the characteristic item with the corresponding characteristic value being the continuous value is a continuous characteristic item, and the predicted value corresponding to the predicted item indicates whether the flow sample data is abnormal flow;
performing box separation processing on a characteristic value corresponding to each flow sample data corresponding to each continuous characteristic item to convert the continuous characteristic item into a discrete characteristic item, wherein a box to which each flow sample data obtained after the box separation processing belongs is a characteristic value corresponding to the discrete characteristic item converted from the continuous characteristic item;
calculating an information gain value and/or a kini coefficient of each discrete type characteristic item based on the discrete type characteristic item corresponding to each flow sample data and a predicted value corresponding to the predicted item;
screening target discrete type characteristic items from the discrete type characteristic items according to the information gain values and/or the kini coefficients of the discrete type characteristic items, and taking characteristic values of the flow sample data corresponding to the target discrete type characteristic items as data for training an abnormal flow identification model;
and monitoring the target flow by using an abnormal flow identification model formed based on the data training so as to obtain the abnormal flow.
2. The method of claim 1, wherein said obtaining a plurality of traffic sample data comprises:
acquiring original flow sample data;
performing data cleaning on the original flow sample data to filter abnormal data in the original flow sample data, wherein the abnormal data comprises a missing value and/or an outlier;
and acquiring a plurality of flow sample data from the original flow sample data subjected to data cleaning.
3. The method of claim 1, wherein the binning the eigenvalues corresponding to the traffic sample data corresponding to each continuous type eigenvalue to convert the continuous type eigenvalue into a discrete type eigenvalue comprises:
clustering the characteristic values corresponding to the continuous characteristic items in the flow sample data aiming at each continuous characteristic item so as to divide the characteristic values corresponding to the continuous characteristic items into a plurality of classes;
and for each continuous characteristic item, according to a plurality of classes into which the characteristic value corresponding to the continuous characteristic item is divided, performing box separation processing on the characteristic value corresponding to each flow sample data corresponding to the continuous characteristic item so as to convert the continuous characteristic item into a discrete characteristic item.
4. The method according to any one of claims 1 to 3, wherein before calculating the information gain value and/or the kini coefficient of each discrete feature item based on the discrete feature item corresponding to each flow sample data and the predicted value corresponding to the prediction item, the method further comprises:
clustering each discrete type feature item to divide each discrete type feature item into a plurality of clusters;
determining a target discrete type characteristic item in each discrete type characteristic item according to the clusters divided by each discrete type characteristic item;
the calculating an information gain value and/or a kini coefficient of each discrete type feature item based on the discrete type feature item corresponding to each flow sample data and a predicted value corresponding to the predicted item includes:
and calculating the information gain value and/or the kini coefficient of each discrete type characteristic item based on the target discrete type characteristic item corresponding to each flow sample data and the predicted value corresponding to the predicted item.
5. The method of claim 4, wherein clustering each discrete feature to divide each discrete feature into a plurality of clusters comprises:
determining a Pearson correlation coefficient between each pair of discrete feature items in each discrete feature item;
and clustering each discrete feature item by utilizing the Pearson correlation coefficient so as to divide each discrete feature item into a plurality of clusters.
6. The method according to claim 1, wherein the screening out the target discrete type feature item from each discrete type feature item according to the information gain value and/or the kini coefficient of each discrete type feature item comprises:
screening initial characteristic items from the discrete characteristic items according to the information gain value and/or the kini coefficient of each discrete characteristic item;
repeatedly executing the initial characteristic item screening step to obtain an initial characteristic item set until the repetition times reach a first preset number, wherein the initial characteristic item screening step comprises the following steps of:
establishing a random forest by using a feature item set formed by the initial feature items, wherein the feature set comprises a plurality of initial feature items, the random forest comprises a plurality of decision trees, and each decision tree comprises a plurality of initial feature items;
for each initial feature item, determining the importance degree of the initial feature item in each decision tree, and determining the importance degree of the initial feature item in the random forest based on the importance degree of the initial feature item in each decision tree;
arranging the initial feature items according to the order of the importance degrees from high to low, and acquiring a second predetermined number of initial feature items which are ranked in the front as an initial feature item set;
and taking the intersection of all the initial feature item sets as a target discrete feature item.
7. The method according to claim 1, wherein after screening out a target discrete type feature item from each discrete type feature item according to the information gain value and/or the kini coefficient of each discrete type feature item, and using the feature value of each flow sample data corresponding to the target discrete type feature item as data for training an abnormal flow recognition model, the method further comprises:
and inputting the obtained data of the training abnormal flow recognition model into a logistic regression model to train and form an abnormal flow recognition model.
8. A traffic monitoring apparatus based on an abnormal traffic recognition model, the apparatus comprising:
the acquisition module is configured to acquire a plurality of flow sample data, each flow sample data comprises a predicted value corresponding to a predicted item and a feature value corresponding to at least one feature item in a preset feature item set, the preset feature item set comprises a plurality of feature items, the feature value corresponding to each feature item is a discrete value or a continuous value, the feature item with the corresponding feature value being the discrete value is a discrete feature item, the feature item with the corresponding feature value being the continuous value is a continuous feature item, and the predicted value corresponding to the predicted item indicates whether the flow sample data is abnormal flow;
the system comprises a binning module, a filtering module and a processing module, wherein the binning module is configured to bin feature values corresponding to flow sample data corresponding to each continuous feature item so as to convert the continuous feature items into discrete feature items, and a bin to which each flow sample data obtained after binning belongs is a feature value corresponding to the discrete feature item converted from the continuous feature items;
the calculation module is configured to calculate an information gain value and/or a kini coefficient of each discrete type feature item based on the discrete type feature item corresponding to each flow sample data and a predicted value corresponding to the predicted item;
the data acquisition module is configured to screen a target discrete type feature item from the discrete type feature items according to the information gain value and/or the kini coefficient of each discrete type feature item, and use the feature value corresponding to each flow sample data and the target discrete type feature item as data for training an abnormal flow identification model;
and the monitoring module is configured to monitor the target traffic by using an abnormal traffic recognition model formed based on the data training so as to obtain abnormal traffic.
9. A computer-readable program medium, characterized in that it stores computer program instructions which, when executed by a computer, cause the computer to perform the method according to any one of claims 1 to 7.
10. An electronic device, characterized in that the electronic device comprises:
a processor;
a memory having stored thereon computer readable instructions which, when executed by the processor, implement the method of any of claims 1 to 7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910818633.6A CN110708285B (en) | 2019-08-30 | 2019-08-30 | Flow monitoring method, device, medium and electronic equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910818633.6A CN110708285B (en) | 2019-08-30 | 2019-08-30 | Flow monitoring method, device, medium and electronic equipment |
Publications (2)
Publication Number | Publication Date |
---|---|
CN110708285A true CN110708285A (en) | 2020-01-17 |
CN110708285B CN110708285B (en) | 2022-04-29 |
Family
ID=69194241
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910818633.6A Active CN110708285B (en) | 2019-08-30 | 2019-08-30 | Flow monitoring method, device, medium and electronic equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN110708285B (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111310652A (en) * | 2020-02-13 | 2020-06-19 | 平安科技(深圳)有限公司 | Flow identification method and system based on classification regression dual-domain model |
CN112819034A (en) * | 2021-01-12 | 2021-05-18 | 平安科技(深圳)有限公司 | Data binning threshold calculation method and device, computer equipment and storage medium |
CN113409092A (en) * | 2021-07-12 | 2021-09-17 | 上海明略人工智能(集团)有限公司 | Abnormal feature information extraction method, system, electronic device and medium |
CN114297454A (en) * | 2021-12-30 | 2022-04-08 | 医渡云(北京)技术有限公司 | Method and device for discretizing features, electronic equipment and computer readable medium |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20150379430A1 (en) * | 2014-06-30 | 2015-12-31 | Amazon Technologies, Inc. | Efficient duplicate detection for machine learning data sets |
CN107871166A (en) * | 2016-09-27 | 2018-04-03 | 第四范式(北京)技术有限公司 | For the characteristic processing method and characteristics processing system of machine learning |
CN108021984A (en) * | 2016-11-01 | 2018-05-11 | 第四范式(北京)技术有限公司 | Determine the method and system of the feature importance of machine learning sample |
CN109241418A (en) * | 2018-08-22 | 2019-01-18 | 中国平安人寿保险股份有限公司 | Abnormal user recognition methods and device, equipment, medium based on random forest |
CN109408583A (en) * | 2018-09-25 | 2019-03-01 | 平安科技(深圳)有限公司 | Data processing method and device, computer readable storage medium, electronic equipment |
-
2019
- 2019-08-30 CN CN201910818633.6A patent/CN110708285B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20150379430A1 (en) * | 2014-06-30 | 2015-12-31 | Amazon Technologies, Inc. | Efficient duplicate detection for machine learning data sets |
CN107871166A (en) * | 2016-09-27 | 2018-04-03 | 第四范式(北京)技术有限公司 | For the characteristic processing method and characteristics processing system of machine learning |
CN108021984A (en) * | 2016-11-01 | 2018-05-11 | 第四范式(北京)技术有限公司 | Determine the method and system of the feature importance of machine learning sample |
CN109241418A (en) * | 2018-08-22 | 2019-01-18 | 中国平安人寿保险股份有限公司 | Abnormal user recognition methods and device, equipment, medium based on random forest |
CN109408583A (en) * | 2018-09-25 | 2019-03-01 | 平安科技(深圳)有限公司 | Data processing method and device, computer readable storage medium, electronic equipment |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111310652A (en) * | 2020-02-13 | 2020-06-19 | 平安科技(深圳)有限公司 | Flow identification method and system based on classification regression dual-domain model |
CN111310652B (en) * | 2020-02-13 | 2023-07-25 | 平安科技(深圳)有限公司 | Flow identification method and system based on classification regression double-domain model |
CN112819034A (en) * | 2021-01-12 | 2021-05-18 | 平安科技(深圳)有限公司 | Data binning threshold calculation method and device, computer equipment and storage medium |
CN113409092A (en) * | 2021-07-12 | 2021-09-17 | 上海明略人工智能(集团)有限公司 | Abnormal feature information extraction method, system, electronic device and medium |
CN113409092B (en) * | 2021-07-12 | 2024-03-26 | 上海明略人工智能(集团)有限公司 | Abnormal feature information extraction method, system, electronic equipment and medium |
CN114297454A (en) * | 2021-12-30 | 2022-04-08 | 医渡云(北京)技术有限公司 | Method and device for discretizing features, electronic equipment and computer readable medium |
Also Published As
Publication number | Publication date |
---|---|
CN110708285B (en) | 2022-04-29 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN110708285B (en) | Flow monitoring method, device, medium and electronic equipment | |
AU2020385264B2 (en) | Fusing multimodal data using recurrent neural networks | |
CN110995459B (en) | Abnormal object identification method, device, medium and electronic equipment | |
CN108629358B (en) | Object class prediction method and device | |
CN113704389A (en) | Data evaluation method and device, computer equipment and storage medium | |
CN112883990A (en) | Data classification method and device, computer storage medium and electronic equipment | |
CN115423040A (en) | User portrait identification method and AI system of interactive marketing platform | |
CN112784157A (en) | Training method of behavior prediction model, behavior prediction method, device and equipment | |
US11593700B1 (en) | Network-accessible service for exploration of machine learning models and results | |
CN112685374B (en) | Log classification method and device and electronic equipment | |
CN110909768B (en) | Method and device for acquiring marked data | |
US11783221B2 (en) | Data exposure for transparency in artificial intelligence | |
CN113139381B (en) | Unbalanced sample classification method, unbalanced sample classification device, electronic equipment and storage medium | |
CN113220994B (en) | User personalized information recommendation method based on target object enhanced representation | |
CN104598485B (en) | The method and apparatus for handling database table | |
CN116361567B (en) | Data processing method and system applied to cloud office | |
CN112905885A (en) | Method, apparatus, device, medium, and program product for recommending resources to a user | |
CN110879821A (en) | Method, device, equipment and storage medium for generating rating card model derivative label | |
CN116863116A (en) | Image recognition method, device, equipment and medium based on artificial intelligence | |
US11675856B2 (en) | Product features map | |
CN115017385A (en) | Article searching method, device, equipment and storage medium | |
CN113297479A (en) | User portrait generation method and device and electronic equipment | |
CN114528378A (en) | Text classification method and device, electronic equipment and storage medium | |
CN112906723A (en) | Feature selection method and device | |
CN118395232B (en) | Digital service resource optimized storage method and system |
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 | ||
GR01 | Patent grant | ||
GR01 | Patent grant |