Prediction Method, Related Device and Storage Medium for Media Resource Lifecycle
By obtaining the basic attributes and online indicators of media resources in the content distribution network, drawing a survival curve and using prediction models, the efficiency and basis problems of traditional cleaning methods are solved, and accurate prediction and management optimization of the media resource life cycle is achieved.
Patent Information
- Application Number
- CN202111572183.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-21
- Publication Date
- 2025-08-05
- Estimated Expiration
- 2041-12-21
AI Technical Summary
In traditional content distribution networks, the cleaning method of media resources lacks efficiency and basis, resulting in space waste and management difficulties. The passive cleaning method of cache nodes is not economical, and valuable resources may be cleaned.
By obtaining the basic attributes and online indicators of media resources in the database, drawing a survival curve to determine the life cycle expectation value of key events, using the life cycle prediction model to accurately predict, and actively clean up based on the prediction results.
It realizes accurate prediction of the life cycle of media resources, improves resource management efficiency, reduces space waste, optimizes bandwidth usage, and ensures the retention of valuable resources.
Smart Images

Figure CN114238669B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to a method for predicting a media resource life cycle, a related device, and a storage medium. Background Art
[0002] In traditional content delivery networks (CDNs), media resources on source sites are usually manually removed from the shelves for cleaning. The content elimination method for cache nodes is generally: Least Recently Used (LRU) or Least Frequently Used (FRU), that is, passive elimination. When resources are not used for a long time or storage space is insufficient, media resources that have not been accessed for a long time are cleared.
[0003] Caching recently accessed resources. The main problem with this approach is that manual cleanup of media resources at the source site is both inefficient and lacks rationale, often leading to long periods of neglect, wasting space and increasing the difficulty of media asset management. Furthermore, cache nodes use a passive cleanup method. Even for unpopular or time-sensitive media resources, a large amount of bandwidth is consumed back to the source, consuming significant storage space and processing, making it uneconomical. Meanwhile, media resources with the potential to become popular again may be discarded due to long periods of inactivity. Summary of the Invention
[0004] In view of this, the present application provides a method, related device and storage medium for predicting the life cycle of a media resource, which can accurately predict the life cycle of a media resource, so that subsequent processing can be performed based on the prediction results.
[0005] In a first aspect, the present application provides a method for predicting a media resource lifecycle, comprising:
[0006] For each media resource, obtain the basic attributes of the media resource from the database and extract the online indicators of the media resource within a preset time period from the log data;
[0007] For each key event of the media resource, determining the expected life cycle value of the key event according to a survival curve corresponding to the type of the key event; wherein the survival curve is drawn by the survival rate and the survival time;
[0008] The expected life cycle values of all the key events, the online indicators and the basic attributes are input into the life cycle prediction model, and the predicted life cycle of the media resource is output; wherein, the life cycle prediction model is obtained by training a regression model with a training sample set; the training sample set includes: relevant information of at least one training sample media resource; the relevant information of the training sample media resource includes: basic information of the training sample media resource, online indicators of the training sample media resource, expected life cycle values of all the key events of the training sample media resource and the actual life cycle of the training sample media resource.
[0009] Optionally, the method for drawing the survival curve includes:
[0010] For each data dimension in the database, randomly select media resources in the data dimension as sample media resources;
[0011] Dividing the sample media resources into an observation group and a control group based on whether a key event to be observed occurs;
[0012] Calculating the survival time of the sample media resources of the observation group and the sample media resources of the control group respectively, and obtaining the distribution characteristics of the life time after the occurrence of the key event to be observed;
[0013] Based on the length of life, the survival rate at each time point is estimated;
[0014] A survival curve is drawn using the life time and the survival rate.
[0015] Optionally, the method for predicting the media resource life cycle further includes:
[0016] The survival rate of each of the sample media resources is tested using the survival rate and the standard error of the survival rate to obtain a test result; wherein the test result is whether there is a difference.
[0017] Optionally, the method for predicting the media resource life cycle further includes:
[0018] The life cycle length of the media resource whose life cycle has ended is updated and stored in the database; wherein the media resource whose life cycle has ended is a media resource that has not been accessed within a preset time.
[0019] Optionally, the method for constructing the life cycle prediction model includes:
[0020] Constructing a training sample set; wherein the training sample set includes: relevant information of at least one training sample media resource; the relevant information of the training sample media resource includes: basic information of the training sample media resource, online indicators of the training sample media resource, life cycle expected values of all key events of the training sample media resource, and the actual life cycle of the training sample media resource;
[0021] For each training sample media resource in the training sample set, inputting relevant information of the training sample media resource into a regression model to obtain a predicted life cycle of the training sample media resource;
[0022] The error between the predicted life cycle of the training sample media resource and the actual life cycle of the training sample media resource is used to continuously adjust the parameters in the regression model until the error between the predicted life cycle of the training sample media resource and the actual life cycle of the training sample media resource after adjustment meets the preset convergence condition, and the adjusted regression model is determined as the life cycle prediction model.
[0023] Optionally, after inputting the expected lifecycle values of all the key events, the online indicators, and the basic attributes into a lifecycle prediction model and outputting the predicted lifecycle of the media resource, the method further includes:
[0024] Determining whether the predicted life cycle of the media resource is greater than a life cycle threshold;
[0025] If it is determined that the predicted life cycle of the media resource is not greater than the life cycle threshold, the media resource is actively cleaned up.
[0026] Optionally, the method for predicting the media resource life cycle further includes:
[0027] Receive and respond to user management instructions for target media resources; wherein, the target media resources are media resources with a predicted life cycle greater than a life cycle threshold; the management instructions are divided into preheating, retention, cleaning and pushing.
[0028] A second aspect of the present application provides a device for predicting a media resource lifecycle, comprising:
[0029] An acquisition unit, configured to acquire, for each media resource, basic attributes of the media resource from a database and extract online indicators of the media resource within a preset time period from log data;
[0030] a determining unit configured to determine, for each critical event of the media resource, an expected life cycle value of the critical event according to a survival curve corresponding to the type of the critical event; wherein the survival curve is drawn by a survival rate and a survival time;
[0031] An input unit is used to input the expected life cycle values of all the key events, the online indicators and the basic attributes into a life cycle prediction model, and output the predicted life cycle of the media resource; wherein, the life cycle prediction model is obtained by training a regression model with a training sample set; the training sample set includes: relevant information of at least one training sample media resource; the relevant information of the training sample media resource includes: basic information of the training sample media resource, online indicators of the training sample media resource, expected life cycle values of all the key events of the training sample media resource and the actual life cycle of the training sample media resource.
[0032] Optionally, the survival curve drawing unit includes:
[0033] An extraction unit, configured to randomly extract media resources from each data dimension in the database as sample media resources;
[0034] a division unit, configured to divide the sample media resources into an observation group and a control group based on whether a key event to be observed occurs;
[0035] A calculation unit, configured to respectively calculate the survival time of the sample media resources of the observation group and the sample media resources of the control group, and obtain the distribution characteristics of the life time after the occurrence of the key event to be observed;
[0036] an estimating unit, configured to estimate the survival rate at each time point according to the length of the life span;
[0037] A drawing subunit is used to draw a survival curve using the life time and the survival rate.
[0038] Optionally, the media resource life cycle prediction device further includes:
[0039] The testing unit is configured to test the survival rate of each of the sample media resources using the survival rate and the standard error of the survival rate to obtain a test result; wherein the test result is whether there is a difference.
[0040] Optionally, the media resource life cycle prediction device further includes:
[0041] The updating unit is used to update the life cycle length of the media resource whose life cycle has ended and store it in the database; wherein the media resource whose life cycle has ended is a media resource that has not been accessed within a preset time.
[0042] Optionally, the construction unit of the life cycle prediction model includes:
[0043] A construction unit is configured to construct a training sample set; wherein the training sample set includes: relevant information of at least one training sample media resource; the relevant information of the training sample media resource includes: basic information of the training sample media resource, online indicators of the training sample media resource, life cycle expected values of all key events of the training sample media resource, and the actual life cycle of the training sample media resource;
[0044] A second input unit is configured to input relevant information of each training sample media resource in the training sample set into a regression model to obtain a predicted life cycle of the training sample media resource;
[0045] A training unit is used to continuously adjust the parameters in the regression model by utilizing the error between the predicted life cycle of the training sample media resource and the actual life cycle of the training sample media resource, until the error between the adjusted predicted life cycle of the training sample media resource and the actual life cycle of the training sample media resource meets a preset convergence condition, and the adjusted regression model is determined as a life cycle prediction model.
[0046] Optionally, the media resource life cycle prediction device further includes:
[0047] a judging unit, configured to judge whether the predicted life cycle of the media resource is greater than a life cycle threshold;
[0048] The cleaning unit is configured to actively clean up the media resource if the judging unit determines that the predicted life cycle of the media resource is not greater than a life cycle threshold.
[0049] Optionally, the media resource life cycle prediction device further includes:
[0050] The response unit is used to receive and respond to the user's management instructions for the target media resource; wherein the target media resource is a media resource with a predicted life cycle greater than a life cycle threshold; the management instructions are divided into preheating, retention, cleaning and pushing.
[0051] A third aspect of the present application provides an electronic device, including:
[0052] one or more processors;
[0053] a storage device having one or more programs stored thereon;
[0054] When the one or more programs are executed by the one or more processors, the one or more processors implement the method for predicting the media resource life cycle as described in any one of the first aspects.
[0055] A fourth aspect of the present application provides a computer storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the method for predicting the life cycle of a media resource as described in any one of the first aspects is implemented.
[0056] As can be seen from the above scheme, the present application provides a method for predicting the life cycle of a media resource, a related device and a storage medium. The method for predicting the life cycle of a media resource includes: first, for each media resource, obtaining the basic attributes of the media resource in a database and extracting the online indicators of the media resource within a preset time period from the log data; then, for each key event of the media resource, determining the expected life cycle value of the key event according to the survival curve corresponding to the type of the key event; wherein the survival curve is drawn by the survival rate and the survival time; then, inputting the expected life cycle values of all the key events, the online indicators and the basic attributes into a life cycle prediction model, and outputting the predicted life cycle of the media resource; wherein the life cycle prediction model is obtained by training a regression model with a training sample set; the training sample set includes: relevant information of at least one training sample media resource; the relevant information of the training sample media resource includes: basic information of the training sample media resource, online indicators of the training sample media resource, expected life cycle values of all the key events of the training sample media resource and the actual life cycle of the training sample media resource. In this way, accurate prediction of the life cycle of the media resource is achieved, and subsequent processing can be performed according to the prediction results. BRIEF DESCRIPTION OF THE DRAWINGS
[0057] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are merely embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without any creative work.
[0058] Figure 1 A specific flow chart of a method for predicting a media resource life cycle provided in an embodiment of the present application;
[0059] Figure 2A flowchart of a method for drawing a survival curve provided in another embodiment of the present application;
[0060] Figure 3 A flowchart of a method for constructing a life cycle prediction model provided in another embodiment of the present application;
[0061] Figure 4 A schematic diagram of a device for predicting a media resource lifecycle provided in another embodiment of the present application;
[0062] Figure 5 A schematic diagram of an electronic device for implementing a method for predicting a media resource lifecycle according to another embodiment of the present application. DETAILED DESCRIPTION
[0063] The following will be combined with the drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are only part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.
[0064] It should be noted that the concepts of "first", "second", etc. mentioned in this application are only used to distinguish different devices, modules or units, and are not used to limit the order or interdependence of the functions performed by these devices, modules or units. The terms "include", "comprise" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device that includes a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "including a..." do not exclude the presence of other identical elements in the process, method, article or device that includes the elements.
[0065] The present application embodiment provides a method for predicting the life cycle of a media resource. Figure 1 As shown, the specific steps include:
[0066] S101 : For each media resource, basic attributes of the media resource are obtained from a database, and online indicators of the media resource within a preset time period are extracted from log data.
[0067] Basic attributes include, but are not limited to, content type (news, film, animation), character design (actors, hosts), and subject matter (children, seniors, women). These attributes are not limited here. Online metrics include, but are not limited to, various operational indicators within the most recent time period, such as the number of visits, visit intervals, visit duration, and resource duration within the time period. These are also not limited here. Preset time periods (e.g., 1 week, 3 days, 1 month, etc.) are set and modified by technical personnel or authorized personnel and are not limited here.
[0068] It's understandable that the extracted online metrics aren't limited to just one type of metric; rather, they represent a summary of these metrics. During the summary process, if you're training a lifecycle prediction model, you need to collect data strictly at the time of training. If you're using a lifecycle prediction model for regression prediction of media resources, you need to use data at the predicted time.
[0069] S102: For each key event of the media resource, determine the expected life cycle value of the key event according to the survival curve corresponding to the type of the key event.
[0070] Among them, the survival curve is drawn by survival rate and survival time.
[0071] Specifically, the expected value of the lifespan is calculated based on the survival time and its corresponding survival rate. This calculation is based on the expectation algorithm in statistics, which multiplies the value by the corresponding probability and then accumulates the results. For example, if the probability of winning 1,000 yuan in a lottery is 1%, and the probability of winning 100 yuan is 10%, then the expected value per draw is 1,000 * 1% + 100 * 10% = 20 yuan.
[0072] Optionally, in another embodiment of the application, an implementation of the method for drawing a survival curve is as follows: Figure 2 Shown, including:
[0073] S201 : For each data dimension in the database, randomly select media resources in the data dimension as sample media resources.
[0074] S202. Divide the sample media resources into an observation group and a control group based on whether a key event to be observed occurs.
[0075] Among them, the key events to be observed may be, but are not limited to, the leading actor of a certain drama winning an award, a certain drama undergoing a film remake, etc., which are not limited here.
[0076] In other words, media resources where the key event to be observed has occurred are used as the observation group, and media resources where the key event to be observed has not occurred are used as the control group. The observation group has changes, while the control group has not. For example, let's take the case of a film remake as the key event to be observed. If you now need to convert an old film from black and white to color, but you don't know the effect of the conversion, you can use the performance of similar films that have undergone the same operation and films that have not undergone the same operation in the same time period as data references. The former is the observation group, and the latter is the control group. Through analysis, we can determine whether this operation has an impact on the life cycle and the extent of the impact. The key events themselves are preset, but they will also be continuously supplemented according to actual circumstances.
[0077] S203: Calculate the survival time of the sample media resources of the observation group and the sample media resources of the control group respectively, and obtain the distribution characteristics of the life time after the key event to be observed occurs.
[0078] The survival time is the number of days from the time of death minus the time of the key event (key event to be observed). The time of the key event is, for example, the time when the transcoding is reset and put online in the above example.
[0079] By counting the survival time according to the date, we can obtain the distribution characteristics of the life time after the key event to be observed.
[0080] S204. Estimate the survival rate at each time point based on the length of life.
[0081] Estimation means calculating the distribution of samples. Let's re-encode the above example: if there are 100 samples in the observation group, 70 of them survive for more than 100 days, so the 100-day survival rate is 70%. Forty of them survive for more than 200 days, so the 200-day survival rate is 40%.
[0082] S205. Draw a survival curve using life time and survival rate.
[0083] The survival curve may be, but is not limited to, a curve with the survival rate as the vertical axis and the survival time as the horizontal axis, which is not limited here.
[0084] It should be noted that the survival time corresponding to a survival rate of 50% on the survival curve is the median survival time.
[0085] Optionally, in another embodiment of the present application, an implementation of the method for predicting the media resource lifecycle further includes:
[0086] The survival rate of each sample media resource is tested through the survival rate and the standard error of the survival rate to obtain the test results.
[0087] The test result is whether there is a difference.
[0088] It should be noted that standard error = standard deviation / square root of N. It is used to measure the degree of dispersion of the sampling distribution of numbers and the scale of the sampling error of the mean, reflecting the variation between sample means.
[0089] Specifically, if there is no difference between the survival curve of the control group and the survival curve of the observation group, it means that the event has no effect on the life cycle.
[0090] It should also be noted that the test methods can include, but are not limited to, the Log-rank test and the Breslow test, which are not specified here. The Log-rank test is used to compare the independence of the data represented by two curves. Its theoretical basis is the hypergeometric distribution and Lyapunov's central limit theorem. If the survival status of the samples in the observation group and the control group is independent of the total sample, then the number of survivors in the observation group will follow a hypergeometric distribution. Breslow added a weight parameter to the Log-rank test.
[0091] S103: Input the expected life cycle values, online indicators, and basic attributes of all key events into the life cycle prediction model, and output the predicted life cycle of the media resource.
[0092] Among them, the life cycle prediction model is obtained by training the regression model with a training sample set; the training sample set includes: relevant information of at least one training sample media resource; the relevant information of the training sample media resource includes: basic information of the training sample media resource, online indicators of the training sample media resource, life cycle expected values of all key events of the training sample media resource, and the actual life cycle of the training sample media resource.
[0093] It should be noted that in general, when calculating survival time, we only need to consider a single factor and can directly use the survival curve to calculate the regression model. If multiple key events occur simultaneously, the proportional hazards regression model (COX regression model) will be used. The COX regression model can attribute multiple key factors.
[0094] It's important to note that there are many key events, such as the launch of a new format or content trending on search results. Each key event generates an expected lifecycle value. Changes to this key event are calculated only once; otherwise, the initial value is used. For example, if analysis suggests the expected lifecycle is 100 days without a new code release, but 10 days with a new code release, the default value is 100 days. This expectation is updated only when a new code is released, not with each calculation.
[0095] Optionally, in another embodiment of the present application, an implementation of the method for predicting the media resource lifecycle further includes:
[0096] The life cycle length of the media resources whose life cycle has ended is updated and stored in the database.
[0097] The media resources whose life cycle has ended are media resources that have not been accessed within a preset time.
[0098] It should be noted that the preset time is set and changed by technical personnel or relevant authorized personnel and is not limited here.
[0099] Optionally, in another embodiment of the present application, an implementation method of a method for constructing a life cycle prediction model is as follows: Figure 3 As shown, including:
[0100] S301: Construct a training sample set.
[0101] Among them, the training sample set includes: relevant information of at least one training sample media resource; the relevant information of the training sample media resource includes: basic information of the training sample media resource, online indicators of the training sample media resource, life cycle expectations of all key events of the training sample media resource, and the actual life cycle of the training sample media resource.
[0102] It is understandable that the training sample set should include relevant information of at least one training sample media resource for multiple training of the regression model.
[0103] Specifically, we read relevant information about the training sample media resources from the database, including all tags related to media resources with a known lifecycle (death time minus the number of days from the training data time), including but not limited to (due to the large number of tags involved and the model being regularly updated, the tags will become richer): media type, content type, related people, generation time, bitrate, resolution, etc. We extract the corresponding daily resource operation logs from the log data and calculate the operation data for a time period (usually one week).
[0104] S302 : For each training sample media resource in the training sample set, input relevant information of the training sample media resource into a regression model to obtain a predicted life cycle of the training sample media resource.
[0105] S303: Determine whether the error between the predicted life cycle of the training sample media resource and the actual life cycle of the training sample media resource meets a convergence condition.
[0106] The convergence conditions are set and changed by technical personnel, authorized personnel, etc., and are not limited here.
[0107] Specifically, if it is determined that the error between the predicted life cycle of the training sample media resource and the actual life cycle of the training sample media resource meets the convergence condition, step S304 is executed; if it is determined that the error between the predicted life cycle of the training sample media resource and the actual life cycle of the training sample media resource does not meet the convergence condition, step S305 is executed.
[0108] S304: Determine the regression model as a life cycle prediction model.
[0109] S305: Adjust the parameters in the regression model.
[0110] Taking the ligthGBM model as an example, the parameters that need to be adjusted between model outputs include num_leaves, min_data_in_leaf, max_depth, feature_fraction, max_bin, learning_rate, num_iterations, num_leaves, bagging_fraction, bagging_freq, min_split_gain, etc., which are not detailed here. The ligthGBM is a random forest model, so its parameters are more than just related to concepts such as trees and leaves. num_leaves: the number of leaves, used to solve the problem of model overfitting; min_data_in_leaf: the minimum amount of data on a leaf, which can be used to deal with overfitting; max_depth: the depth of the tree model; feature_fraction: the proportion of randomly selected features in each iteration, used to speed up training; max_bin: the maximum number of feature groups, which controls training accuracy; learning_rate: the learning rate, which controls training accuracy and speed; num_iterations: the number of iterations, that is, the number of trees, which controls learning progress and overfitting; bagging_fraction: randomly selects part of the data without resampling to control overfitting; bagging_freq: the number of bagging, which controls overfitting; min_split_gain: the minimum gain of splitting.
[0111] It should be noted that in the specific implementation process of this application, it is not limited to modifying the model using the preset convergence conditions, and a certain maximum number of iterations can also be set to train the model, which is not limited here.
[0112] It is understandable that in the specific implementation process of this application, as the data will gradually become richer, the model needs to be retrained regularly.
[0113] Optionally, in another embodiment of the present application, after obtaining the predicted lifecycle of the media resource, an implementation of the method for predicting the lifecycle of the media resource further includes:
[0114] Determine whether the predicted lifecycle of the media resource is greater than the lifecycle threshold.
[0115] Specifically, if it is determined that the predicted life cycle of a media resource is not greater than the life cycle threshold, the media resource can be directly cleaned up proactively, or the user's instructions can be waited for, which is not specified here; similarly, if it is determined that the predicted life cycle of a media resource is greater than the life cycle threshold, the media resource can be processed according to a preset processing method, or the user's instructions can be waited for, which is not specified here.
[0116] Optionally, in another embodiment of the present application, an implementation of the method for predicting the media resource lifecycle further includes:
[0117] Receive and respond to user management instructions for target media resources.
[0118] The target media resource is a media resource whose predicted life cycle is greater than the life cycle threshold; the management instructions are divided into preheating, retention, cleaning, pushing, etc., which are not limited here.
[0119] As can be seen from the above scheme, the present application provides a method for predicting the life cycle of a media resource: first, for each media resource, the basic attributes of the media resource are obtained in the database and the online indicators of the media resource within a preset time period are extracted from the log data; then, for each key event of the media resource, the expected life cycle value of the key event is determined according to the survival curve corresponding to the type of the key event; wherein the survival curve is drawn by the survival rate and the survival time; then the expected life cycle value, online indicators and basic attributes of all key events are input into the life cycle prediction model, and the predicted life cycle of the media resource is output; wherein the life cycle prediction model is obtained by training the regression model with a training sample set; the training sample set includes: relevant information of at least one training sample media resource; the relevant information of the training sample media resource includes: basic information of the training sample media resource, online indicators of the training sample media resource, expected life cycle values of all key events of the training sample media resource and the actual life cycle of the training sample media resource. In this way, accurate prediction of the life cycle of the media resource can be achieved, and subsequent processing can be performed based on the prediction results.
[0120] Another embodiment of the present application provides a device for predicting the life cycle of a media resource, such as Figure 4 As shown, specifically including:
[0121] The acquisition unit 401 is configured to acquire, for each media resource, basic attributes of the media resource from a database and extract online indicators of the media resource within a preset time period from log data.
[0122] The determining unit 402 is configured to determine, for each key event of the media resource, an expected life cycle value of the key event according to a survival curve corresponding to the type of the key event; wherein the survival curve is drawn by a survival rate and a survival time.
[0123] The input unit 403 is used to input the expected life cycle values, online indicators and basic attributes of all key events into the life cycle prediction model, and output the predicted life cycle of the media resource.
[0124] Among them, the life cycle prediction model is obtained by training the regression model with a training sample set; the training sample set includes: relevant information of at least one training sample media resource; the relevant information of the training sample media resource includes: basic information of the training sample media resource, online indicators of the training sample media resource, life cycle expected values of all key events of the training sample media resource, and the actual life cycle of the training sample media resource.
[0125] For the specific working process of the units disclosed in the above embodiments of the present application, please refer to the corresponding method embodiments, such as Figure 1As shown, no further details are given here.
[0126] Optionally, in another embodiment of the present application, an implementation of a unit for drawing a survival curve includes:
[0127] The extraction unit is used to randomly extract media resources from each data dimension in the database as sample media resources.
[0128] The division unit is used to divide the sample media resources into an observation group and a control group based on whether the key event to be observed occurs.
[0129] The calculation unit is used to calculate the survival time of the sample media resources of the observation group and the sample media resources of the control group respectively, and obtain the distribution characteristics of the life time after the key event to be observed occurs.
[0130] The estimation unit is used to estimate the survival rate at each time point based on the length of life.
[0131] The drawing subunit is used to draw survival curves using life time and survival rate.
[0132] For the specific working process of the units disclosed in the above embodiments of the present application, please refer to the corresponding method embodiments, such as Figure 2 As shown, no further details are given here.
[0133] Optionally, in another embodiment of the present application, an implementation of the media resource lifecycle prediction device further includes:
[0134] The testing unit is used to test the survival rate of each sample media resource through the survival rate and the standard error of the survival rate to obtain a test result.
[0135] The test result is whether there is a difference.
[0136] The specific working process of the units disclosed in the above embodiments of this application can be found in the corresponding method embodiments and will not be repeated here.
[0137] Optionally, in another embodiment of the present application, an implementation of the media resource lifecycle prediction device further includes:
[0138] The updating unit is used to update the life cycle length of the media resource whose life cycle has ended and store it in the database.
[0139] The media resources whose life cycle has ended are media resources that have not been accessed within a preset time.
[0140] The specific working process of the units disclosed in the above embodiments of this application can be found in the corresponding method embodiments and will not be repeated here.
[0141] Optionally, in another embodiment of the application, an implementation of a construction unit of a life cycle prediction model includes:
[0142] Construction unit, used to construct training sample set.
[0143] Among them, the training sample set includes: relevant information of at least one training sample media resource; the relevant information of the training sample media resource includes: basic information of the training sample media resource, online indicators of the training sample media resource, life cycle expectations of all key events of the training sample media resource, and the actual life cycle of the training sample media resource.
[0144] The second input unit is configured to input relevant information of each training sample media resource in the training sample set into the regression model to obtain a predicted life cycle of the training sample media resource.
[0145] The training unit is used to continuously adjust the parameters in the regression model by using the error between the predicted life cycle of the training sample media resource and the actual life cycle of the training sample media resource, until the error between the predicted life cycle of the adjusted training sample media resource and the actual life cycle of the training sample media resource meets the preset convergence condition, and the adjusted regression model is determined as the life cycle prediction model.
[0146] For the specific working process of the units disclosed in the above embodiments of the present application, please refer to the corresponding method embodiments, such as Figure 3 As shown, no further details are given here.
[0147] Optionally, in another embodiment of the present application, an implementation of the media resource lifecycle prediction device further includes:
[0148] The judgment unit is used to judge whether the predicted life cycle of the media resource is greater than the life cycle threshold.
[0149] The cleaning unit is configured to actively clean up the media resource if the judging unit determines that the predicted life cycle of the media resource is not greater than the life cycle threshold.
[0150] The specific working process of the units disclosed in the above embodiments of this application can be found in the corresponding method embodiments and will not be repeated here.
[0151] Optionally, in another embodiment of the present application, an implementation of the media resource lifecycle prediction device further includes:
[0152] The response unit is used to receive and respond to the user's management instructions for the target media resource.
[0153] The target media resource is a media resource whose predicted life cycle is greater than a life cycle threshold; the management instructions are divided into preheating, retention, cleaning, and pushing.
[0154] The specific working process of the units disclosed in the above embodiments of this application can be found in the corresponding method embodiments and will not be repeated here.
[0155] As can be seen from the above scheme, the present application provides a device for predicting the life cycle of a media resource: first, an acquisition unit 401 obtains the basic attributes of the media resource from a database and extracts the online indicators of the media resource within a preset time period from log data for each media resource; then, a determination unit 402 determines the expected life cycle value of each key event of the media resource based on the survival curve corresponding to the type of the key event; wherein the survival curve is drawn by the survival rate and the survival time; an input unit 403 inputs the expected life cycle values, online indicators, and basic attributes of all key events into a life cycle prediction model, and outputs a predicted life cycle of the media resource; wherein the life cycle prediction model is obtained by training a regression model with a training sample set; the training sample set includes: relevant information of at least one training sample media resource; the relevant information of the training sample media resource includes: basic information of the training sample media resource, online indicators of the training sample media resource, expected life cycle values of all key events of the training sample media resource, and the actual life cycle of the training sample media resource. In this way, accurate prediction of the media resource life cycle is achieved, and subsequent processing can be performed based on the prediction results.
[0156] Another embodiment of the present application provides an electronic device, such as Figure 5 As shown, including:
[0157] One or more processors 501 .
[0158] The storage device 502 stores one or more programs.
[0159] When the one or more programs are executed by the one or more processors 501 , the one or more processors 501 implement the method for predicting the life cycle of a media resource as described in any one of the above embodiments.
[0160] Another embodiment of the present application provides a computer storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the method for predicting the life cycle of a media resource as described in any one of the above embodiments is implemented.
[0161] In the above embodiments disclosed in this application, it should be understood that the disclosed devices and methods can also be implemented in other ways. The device and method embodiments described above are merely illustrative. For example, the flowcharts and block diagrams in the accompanying drawings show the possible architectures, functions and operations of the devices, methods and computer program products according to multiple embodiments of the present disclosure. In this regard, each box in the flowchart or block diagram can represent a module, program segment or part of the code, and the module, program segment or part of the code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in an order different from that marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flowchart, and the combination of boxes in the block diagram and / or flowchart, can be implemented using a dedicated hardware-based system that performs the specified function or action, or can be implemented using a combination of dedicated hardware and computer instructions.
[0162] In addition, the functional modules in each embodiment of the present disclosure can be integrated together to form an independent part, or each module can exist separately, or two or more modules can be integrated to form an independent part. If the function is implemented in the form of a software functional module and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present disclosure is essentially or the part that contributes to the prior art or the part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for enabling a computer device (which can be a personal computer, a live broadcast device, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present disclosure. The aforementioned storage medium includes various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.
[0163] The present application is capable of being implemented or used by those skilled in the art. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application is not limited to the embodiments shown herein, but is intended to be embodied in the widest possible manner consistent with the principles and novel features disclosed herein.
Claims
1. A method for predicting the life cycle of a media resource, characterized in that: include: For each media resource, obtain the basic attributes of the media resource from the database and extract the online indicators of the media resource within a preset time period from the log data; For each key event of the media resource, determining the expected life cycle value of the key event according to the survival curve corresponding to the key event; wherein the survival curve is drawn by the survival rate and the survival time; The expected lifecycle values of all the key events, the online indicators, and the basic attributes are input into a lifecycle prediction model, and the predicted lifecycle of the media resource is output; wherein the lifecycle prediction model is obtained by training a regression model with a training sample set; the training sample set includes: relevant information of at least one training sample media resource; the relevant information of the training sample media resource includes: basic information of the training sample media resource, online indicators of the training sample media resource, expected lifecycle values of all the key events of the training sample media resource, and the actual lifecycle of the training sample media resource; The method for drawing the survival curve comprises: For each data dimension in the database, randomly select media resources in the data dimension as sample media resources; The sample media resources are divided into an observation group and a control group based on whether the key event to be observed has occurred; the observation group is the media resources in which the key event to be observed has occurred; the control group is the media resources in which the key event to be observed has not occurred; Calculating the survival time of the sample media resources of the observation group and the sample media resources of the control group respectively, and statistically analyzing the survival time by date to obtain the distribution characteristics of life time after the occurrence of the key event to be observed; the survival time is the number of days from the time of death minus the time of the key event; Based on the length of life, the survival rate at each time point is estimated; A survival curve is drawn using the life time and the survival rate.
2. The prediction method according to claim 1, characterized in that Also includes: The survival rate of each of the sample media resources is tested using the survival rate and the standard error of the survival rate to obtain a test result; wherein the test result is whether there is a difference.
3. The prediction method according to claim 1, wherein: Also includes: The life cycle length of the media resource whose life cycle has ended is updated and stored in the database; wherein the media resource whose life cycle has ended is a media resource that has not been accessed within a preset time.
4. The prediction method according to claim 1, wherein: The method for constructing the life cycle prediction model includes: Constructing a training sample set; wherein the training sample set includes: relevant information of at least one training sample media resource; the relevant information of the training sample media resource includes: basic information of the training sample media resource, online indicators of the training sample media resource, life cycle expected values of all key events of the training sample media resource, and the actual life cycle of the training sample media resource; For each training sample media resource in the training sample set, inputting relevant information of the training sample media resource into a regression model to obtain a predicted life cycle of the training sample media resource; The error between the predicted life cycle of the training sample media resource and the actual life cycle of the training sample media resource is used to continuously adjust the parameters in the regression model until the error between the predicted life cycle of the training sample media resource and the actual life cycle of the training sample media resource after adjustment meets the preset convergence condition, and the adjusted regression model is determined as the life cycle prediction model.
5. The prediction method according to claim 1, wherein: After inputting the expected lifecycle values of all the key events, the online indicators, and the basic attributes into the lifecycle prediction model and outputting the predicted lifecycle of the media resource, the method further includes: Determining whether the predicted life cycle of the media resource is greater than a life cycle threshold; If it is determined that the predicted life cycle of the media resource is not greater than the life cycle threshold, the media resource is actively cleaned up.
6. The prediction method according to claim 5, characterized in that Also includes: Receive and respond to user management instructions for target media resources; wherein, the target media resources are media resources with a predicted life cycle greater than a life cycle threshold; the management instructions are divided into preheating, retention, cleaning and pushing.
7. A device for predicting the life cycle of a media resource, characterized in that: include: An acquisition unit, configured to acquire, for each media resource, basic attributes of the media resource from a database and extract online indicators of the media resource within a preset time period from log data; a determining unit configured to determine, for each key event of the media resource, an expected life cycle value of the key event according to a survival curve corresponding to the key event; wherein the survival curve is drawn by a survival rate and a survival time; An input unit is configured to input the lifecycle expected values of all the key events, the online indicators, and the basic attributes into a lifecycle prediction model, and output a predicted lifecycle of the media resource; wherein the lifecycle prediction model is obtained by training a regression model with a training sample set; the training sample set includes: relevant information of at least one training sample media resource; the relevant information of the training sample media resource includes: basic information of the training sample media resource, online indicators of the training sample media resource, lifecycle expected values of all the key events of the training sample media resource, and the actual lifecycle of the training sample media resource; An extraction unit, configured to randomly extract media resources from each data dimension in the database as sample media resources; a dividing unit, configured to divide the sample media resources into an observation group and a control group based on whether a key event to be observed has occurred; the observation group is the media resources in which the key event to be observed has occurred; and the control group is the media resources in which the key event to be observed has not occurred; a calculation unit, configured to respectively calculate the survival time of the sample media resources of the observation group and the sample media resources of the control group, and to perform statistics on the survival time by date to obtain a distribution characteristic of life time after the occurrence of the key event to be observed; the survival time is the number of days from the time of death minus the time of the key event; an estimating unit, configured to estimate the survival rate at each time point according to the length of the life span; A drawing subunit is used to draw a survival curve using the life time and the survival rate.
8. An electronic device, characterized in that: include: one or more processors; a storage device having one or more programs stored thereon; When the one or more programs are executed by the one or more processors, the one or more processors implement the method for predicting the media resource lifecycle according to any one of claims 1 to 6.
9. A computer storage medium, characterized in that A computer program is stored thereon, wherein when the computer program is executed by a processor, the method for predicting the media resource life cycle as claimed in any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Model construction and data life cycle prediction method, device and equipment
CN110032750A
Method and device for generating lifetime prediction model, and storage medium
CN113782092A