A downsampling method based on heat sorting
Through the down-sampling method based on popularity ranking, sample selection is optimized, which solves the problem of media assets in the recommendation business being concentrated on popular media assets, improves the accuracy and diversity of the recommendation model, and achieves the effectiveness of the recommendation business.
Patent Information
- Application Number
- CN202210115896.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-02-07
- Publication Date
- 2024-08-23
- Estimated Expiration
- 2042-02-07
AI Technical Summary
The existing down-sampling method in the recommendation business results in the concentration of media assets in a small number of popular media assets, which cannot effectively play the function of the recommendation business, especially when there is a long tail effect.
A downsampling method based on popularity ranking is adopted. By obtaining negative sample and positive sample sets that meet the preset conditions, the popularity promotion function and the popularity suppression function are used for sampling respectively. After merging, the sample selection is optimized to avoid the limitation of sampling rate for word frequency calculation.
By preferentially selecting popular items as negative samples and non-popular items as positive samples, the construction accuracy of the recommendation model is improved, enabling the recommendation business to recommend diversified media assets more effectively, and avoiding the need for sample resampling by the supervision model.
Smart Images

Figure CN114491268B
Abstract
Description
Technical Field
[0001] The present application relates to the field of data processing, and in particular to a downsampling method based on heat sorting. Background Art
[0002] When providing recommendation services, terminal devices rely on pre-trained recommendation models, and the training of recommendation models depends on the construction of training samples. To a certain extent, the quality of samples determines the upper limit of the ranking model, so training samples need to be carefully selected. We call the process of sample selection "downsampling".
[0003] At present, downsampling is mainly achieved by suppressing popular words. The mainstream method is inspired by word2vec downsampling - word frequency represents the popularity of a word, and the sampling rate of the word is calculated based on the word frequency. In natural language, the vocabulary is generally in the millions, and the frequency of each word does not have an obvious long-tail distribution. Therefore, "calculating the sampling rate of the word based on the word frequency" is applicable in the field of natural language processing (NLP).
[0004] However, for recommendation services, there is generally a long-tail effect in users' behavior towards samples, that is, a small number of popular samples contribute most of the clicks, which will cause the media resources recommended by the recommendation service to be concentrated in a small number of popular media resources, and the recommendation service cannot exert its effectiveness. Summary of the invention
[0005] The present application provides a downsampling method based on popularity sorting, which solves the problem that the media resources recommended by the recommendation service are concentrated on a small number of popular media resources.
[0006] In a first aspect, the present application provides a downsampling method based on heat sorting, the method comprising: obtaining a first negative sample set that meets a first preset condition, and performing heat boost sampling on the first negative sample set according to a heat boost function; the first preset condition is used to characterize that the exposed individual has not been clicked within a first preset time; obtaining a second negative sample set that meets a second preset condition, and performing random downsampling on the second negative sample set; the second preset condition is used to characterize that the individual meets the first preset condition and is continuously exposed within a second preset time; obtaining a positive sample set that meets a third preset condition, and performing heat suppression sampling on the positive sample set according to a heat suppression function; merging the first negative sample set, the second negative sample set, and the positive sample set.
[0007] In some embodiments, the input of the heat promotion function and the heat suppression function is the heat of the individual, and the heat is the ranking position of the individual after the overall click volume is sorted from small to large; as the heat increases, the sampling probability output by the heat promotion function becomes greater; as the heat increases, the sampling probability output by the heat suppression function becomes smaller.
[0008] In some embodiments, the heat boost function is:
[0009]
[0010] Among them, rank i Represented as item i The sampling probability of item i It is expressed as the individual in the population sorted from small to large according to the number of clicks, and the individual corresponding to the i-th ranking is rank i =i.
[0011] In some embodiments, the heat suppression function is:
[0012]
[0013] Here, n refers to the number of individuals in the population.
[0014] In some embodiments, f=x α , α∈(0,1), then:
[0015]
[0016]
[0017] In some embodiments, according to the heat suppression function plus the random perturbation random(), the positive samples are sorted in reverse order and the topN are taken.
[0018] In some embodiments, according to the heat boosting function plus the random perturbation random(), the negative samples are sorted in reverse order and the topN are taken.
[0019] On the second aspect, the present application provides a recommendation method based on a recommendation model, and the recommendation method includes: generating a recommendation model by applying the aforementioned downsampling method based on heat sorting; receiving user click data, which refers to the user's click data on media assets collected by a terminal device; calculating the heat of the media assets based on the click data; based on the heat of the media assets, sampling samples based on the aforementioned heat-based downsampling method to complete sample engineering actions; generating a recommendation model based on sample engineering and feature engineering; when receiving a user request sent by the engine, requesting the recommendation model to sort the media assets, and sending the sorted media asset information to the terminal device.
[0020] In some embodiments, behavior data of users clicking on recommended media assets is received, and sample data in the sample project is updated based on the behavior data.
[0021] In a third aspect, the present application provides a display device, the display device includes a recommendation service, and the recommendation service applies the aforementioned downsampling method based on heat sorting.
[0022] From the above embodiments, it can be seen that the downsampling method based on heat sorting provided by the present application selects the sorted samples by sorting individuals based on heat, inputting the heat suppression function or heat promotion function according to the sorting results; and obtaining negative samples by giving priority to selecting popular items and obtaining positive samples by giving priority to selecting non-popular items, so that the construction of the recommendation model is more accurate and the recommendation service can exert its effectiveness. The present application does not require a supervisory model to resample samples, and is technologically advanced. BRIEF DESCRIPTION OF THE DRAWINGS
[0023] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0024] Figure 1 A display interface showing a display device recommendation service is shown;
[0025] Figure 2 The current downsampling probability function of word2vec is shown;
[0026] Figure 3 A schematic flow chart of a downsampling method based on heat sorting according to some embodiments is shown;
[0027] Figure 4 A schematic flow chart of a downsampling method based on heat sorting according to some embodiments is shown;
[0028] Figure 5 A schematic diagram of a heat suppression function based on heat ranking according to some embodiments is shown;
[0029] Figure 6 A schematic diagram of a heat promotion function based on heat sorting according to some embodiments is shown;
[0030] Figure 7 A schematic diagram showing the sample size and the total number corresponding to the sampling probability based on heat sorting according to some embodiments;
[0031] Figure 8 A schematic flow chart of a recommendation method based on a recommendation model according to some embodiments is shown. DETAILED DESCRIPTION
[0032] In order to make the purpose and implementation method of the present application clearer, the exemplary implementation method of the present application will be clearly and completely described below in conjunction with the drawings in the exemplary embodiments of the present application. Obviously, the described exemplary embodiments are only part of the embodiments of the present application, rather than all the embodiments.
[0033] It should be noted that the brief description of terms in this application is only for the convenience of understanding the embodiments described below, and is not intended to limit the embodiments of this application. Unless otherwise specified, these terms should be understood according to their common and usual meanings.
[0034] The terms "first", "second", "third", etc. in the specification and claims of this application and the above drawings are used to distinguish similar or similar objects or entities, and do not necessarily mean to limit a specific order or sequence, unless otherwise noted. It should be understood that the terms used in this way can be interchangeable under appropriate circumstances.
[0035] The terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover but not exclude inclusion, for example, a product or device comprising a list of components is not necessarily limited to all the components expressly listed but may include other components not expressly listed or inherent to such product or device.
[0036] The term "module" refers to any known or later developed hardware, software, firmware, artificial intelligence, fuzzy logic, or combination of hardware and / or software code that is capable of performing the functions associated with that element.
[0037] Figure 1 The display interface of the display device recommendation service is shown. Figure 1 As shown, when the user turns on the display device, a specific scene will be displayed on the display interface of the display device. The scene includes some controls that can be triggered by user clicks, such as "Recommendation" and "Guess you like". When the user selects "Recommendation" and "Guess you like" in turn, the display device will request the corresponding media data from the server, and display the media data returned from the server in the scene, such as returning the media of "Nezha's Story", "Feng Mou Bang", "Feng Shen Mou Bang", "Xi Mou Mou Sequel", "Bao Mou Mou Prequel" and "Xi Mou Mou Sequel", and display the links of the aforementioned media in the form of pictures and texts on the display interface for users to select.
[0038] Then, when the user selects "Recommend" and "Guess You Like" in turn, how to determine which media data the display device should request becomes a technical problem that needs to be solved for the display device to provide recommendation services. Usually, the recommendation model is trained and then the user's personalized recommended media data is confirmed through the recommendation model.
[0039] The training of the aforementioned recommendation model depends on the construction of training samples. To a certain extent, the sample quality determines the upper limit of the ranking model. Therefore, sample selection is necessary. We call the sample selection process "downsampling". The "downsampling" of display devices usually involves recording user behavior in the background of the display device and suppressing popular words to obtain training samples. The existing "downsampling" is inspired by the downsampling of word2vec. The sampling probability of the word is calculated based on the word frequency, where the word frequency indicates the popularity of a word, and the recommended media asset data is determined based on the word frequency. The specific calculation method is as follows: For the word w i , and its occurrence probability in the entire corpus is z(w i ), define the sampling probability of this word:
[0040]
[0041] Among them, P(w i ) is an unbounded function on (0, 1]. P(w i ) fluctuates greatly around 0; P(w i ) is close to 1, P(w i ) hardly changes. In this case, in order to make P(w i ) takes values in [0, 1], for P(w i ) is truncated, which makes the sampling function no longer smooth.
[0042] Figure 2 The current downsampling probability function of word2vec is shown. Figure 2 As shown in the figure, the protruding part in the middle of the downsampling probability function is called the "head"; the relatively flat parts on both sides are called the "tail". From the perspective of people's needs, most of the demands will be concentrated in the head, which we can call popular, while the demands distributed in the tail are personalized, scattered and small-scale demands. This part of differentiated and small demands will form a long "tail" on the demand curve, and the so-called long tail effect lies in its quantity. Adding up all the non-popular markets will form a market larger than the popular market. Using the aforementioned sampling probability function, the sampling probability of popular items is large, and the head effect will cause the recommendation to be concentrated on a small amount of popular media information. The aforementioned long tail effect and head effect will cause the failure of the recommendation business.
[0043] In order to solve the problem in the aforementioned recommendation scenario that the long tail effect of popular data causes the recommendation to be concentrated on a small amount of popular media information, the present application makes the recommendation service more reasonable by changing the construction method of training samples.
[0044] For the convenience of description, the definitions of "population", "individual", "sample" and "sample size" are explained below: "population" is the set of all individuals (data) under study, which is usually composed of some individuals under study, such as a set composed of multiple words; "individual" generally refers to a biological individual or a specific subject in a group, such as each word in the aforementioned set is an individual; "sample" is a part of the individuals observed or investigated; "sample size" refers to the number of units contained in a sample, generally represented by n.
[0045] Figure 3 FIG. 1 is a flow chart of a downsampling method based on heat sorting according to some embodiments. Figure 3 As shown, the present application provides a downsampling method based on heat sorting, the method comprising: obtaining a first negative sample set that meets a first preset condition, and performing heat boost sampling on the first negative sample set according to a heat boost function; the first preset condition is used to characterize that the exposed individual has not been clicked within a first preset time; obtaining a second negative sample set that meets a second preset condition, and performing random downsampling on the second negative sample set; the second preset condition is used to characterize that the individual meets the first preset condition and is continuously exposed within a second preset time; obtaining a positive sample set that meets a third preset condition, and performing heat suppression sampling on the positive sample set according to a heat suppression function; merging the first negative sample set, the second negative sample set, and the positive sample set.
[0046] For example, Figure 4As shown, the exposed media data are obtained, and the set consisting of these exposed media data is recorded as set S. When the first preset condition refers to "the exposed media data has not been clicked in the past 90 days", it is determined whether each media data in the set S has not been clicked in the past 90 days. If it has not been clicked, the media data meets the first preset condition, and the media data is included in the first negative sample set; if it has been clicked, the media data does not meet the first preset condition, and the media data is discarded, that is, the media data is not included in the first negative sample set. After all the media asset data in set S are judged, on the one hand, the media asset data in the first negative sample set are sampled for heat boosting; on the other hand, it is judged whether the media asset data in the first negative sample set meets the second preset condition. When the second preset condition refers to "the number of exposure days of the media asset data in the past 15 days exceeds 7 days", it is judged whether the exposure days of each media asset data in the first negative sample set in the past 15 days exceed 7 days. If it exceeds 7 days, the media asset data is included in the second negative sample set; if the exposure days do not exceed 7 days, the media asset data, that is, the media asset data is not included in the second negative sample set. The media asset data of the second negative sample set is randomly downsampled. The first negative sample set that has been sampled for heat boosting and the second negative sample set that has been sampled for random downsampling are combined and recorded as set P. The clicked media asset data are obtained, and the set consisting of these clicked media asset data is recorded as set Q. When the third preset condition refers to "the viewing time is greater than 5 seconds", it is determined whether the viewing time of the media asset data in set Q is greater than 5 seconds. If the viewing time is greater than 5 seconds, the media asset data is included in the positive sample set; if the viewing time is less than or equal to 5 seconds, the media asset data is discarded, that is, the media asset data is not included in the positive sample set; according to the heat suppression function, the positive sample set is heat suppressed and sampled, and the positive sample set after heat suppression sampling is recorded as set R. Set P and set R are merged.
[0047] In some embodiments, the present application provides a downsampling method based on heat ranking, wherein "according to the heat promotion function, the first negative sample set is subjected to heat promotion sampling" and "according to the heat suppression function, the positive sample set is subjected to heat suppression sampling", a sampling probability about heat is constructed: different from the prior art, the present application does not calculate the sampling rate of the word based on the word frequency, but sorts the click rate of the word as the heat of the individual item. The input of the heat promotion function and the heat suppression function is the heat of the individual, and the heat is the ranking position of the individual after the overall click volume is sorted from small to large; as the heat increases, the sampling probability output by the heat promotion function increases; as the heat increases, the sampling probability output by the heat suppression function decreases.
[0048] In some embodiments, the heat boost function is:
[0049]
[0050] Among them, rank i Represented as item i The sampling probability of item i It is expressed as the individual in the population sorted from small to large according to the number of clicks, and the individual corresponding to the i-th ranking is rank i =i.
[0051] In some embodiments, the heat suppression function is:
[0052]
[0053] Here, n refers to the number of individuals in the population.
[0054] For example, the total is a set consisting of n words; the click data of each word on the day is obtained; the click volume of each word is sorted in reverse order, for example: c1>c2>…>c n , the i-th click volume C i The corresponding word item i Define its sampling probability rank i =i.
[0055] In some embodiments, f=x α , α∈(0,1), then:
[0056]
[0057]
[0058] If α>1, lift and down will decrease (increase) the ranking value faster. In the recommendation service of terminal devices, α∈(0,1) is usually used. At this time, lift is used to increase the popularity of negative samples: for items that are exposed but not clicked, the more popular the item is, the higher the sampling rate is; down is used to suppress the popularity of positive samples: for clicked items, the less popular the item is, the higher the sampling rate is. For positive samples, the more popular the item, the lower the sampling rate should be, because the more popular the item is, the worse the sample is; for negative samples, the more popular the sample is and the less clicked the sample is, the better, because this can show that the user really does not like the item.
[0059] In some embodiments, according to the heat suppression function plus the random disturbance random(), the positive samples are sorted in reverse order and the topN are taken as the positive sample sampling result.
[0060] In some embodiments, according to the heat boost function plus random perturbation random(), the negative samples are sorted in reverse order and the topN are taken. This is the sampling based on the heat boost, and the result is recorded as negl. Another part of the negative samples comes from the rules: exposures that have been exposed for multiple times but not clicked belong to negative samples. The amount of data in this part is also large. At this time, random sampling is used to take the topN, and the result is recorded as neg2. The union of negl and neg2 is taken as the final negative sample sampling result.
[0061] In some embodiments, according to the heat suppression function and the heat promotion function, the number of sampled records is controlled, and a relaxation factor is added, so that a specified number of samples can be obtained.
[0062] As can be seen from the above embodiments, this application sorts individuals based on popularity, inputs a popularity suppression function or a popularity promotion function according to the sorting results, and selects the sorted samples; negative samples are obtained by giving priority to selecting popular items, and positive samples are obtained by giving priority to selecting non-popular items, so that the construction of the recommendation model is more accurate and the recommendation service can exert its effectiveness. This application does not require a supervisory model to resample samples, and is technologically advanced.
[0063] The following uses the positive sample heat suppression as an example to illustrate the effect of sampling rate on sample size in conjunction with the accompanying figures.
[0064] like Figure 5 and Figure 6 As shown, according to the definition of sampling rate, for a click volume of {c i} click log, c i Arrange in reverse order. If α = 1, the sample size is
[0065]
[0066] in, For {c i} in ascending order. Using numerical simulation, if {c i} obeys the uniform distribution of [1, N] (N is the maximum item click volume), then
[0067]
[0068] Figure 7 FIG. 4 shows a schematic diagram of sample size and population size corresponding to sampling probability based on heat sorting according to some embodiments. Figure 7 As shown, the sample size is the logarithmic level of the population, which is the impact of downsampling based on heat sorting on the sample size.
[0069] Based on the sampling method based on heat sorting described in the above embodiment, samples are obtained and a corresponding recommendation model is trained using the samples. When the samples are "data of users clicking on media assets", the corresponding recommendation model can be used to provide media asset recommendation services.
[0070] Figure 8 FIG. 1 is a flow chart of a recommendation method based on a recommendation model according to some embodiments. Figure 8 As shown, the present application provides a method based on media asset recommendation, the method comprising: receiving user click data, the user click data refers to the user click data on the media asset collected by the terminal device; calculating the media asset heat according to the click data; sampling the samples based on the aforementioned heat-based downsampling method according to the media asset heat to complete the sample engineering action; generating a recommendation model based on the sample engineering and feature engineering; when receiving a user request sent by the engine, requesting the recommendation model to sort the media asset, and sending the sorted media asset information to the terminal device.
[0071] For a newly enabled terminal device, the background of the terminal device has not recorded the data of user operations. Therefore, the necessary sample information for generating the recommendation model is missing. The startup action of the terminal device is called a cold start. During a cold start, the information recommended by the terminal device can be preset recommended content. These preset recommended contents can be determined according to the region served by the terminal device, and this application does not limit this. The user's click behavior on the terminal device after startup is recorded in the background by the terminal device and sent to the recommendation system by the terminal device as sample information. Among them, the sample information may include click information of media data, viewing information of media data, and data information of media data exposed within a certain time threshold. The recommendation system receives these sample information, which is used as the basis for generating the recommendation model, recorded as the population A, as a sample project. On the one hand, the recommendation system sorts each sample in the population A from small to large according to the total number of clicks, and takes the corresponding ranking of the sample as the heat of the sample as a feature project. On the other hand, a first negative sample set that meets the first preset condition is obtained, and the first negative sample set is subjected to heat-enhancing sampling according to the heat-enhancing function; the first preset condition is used to characterize that the exposed individual has not been clicked within the first preset time; a second negative sample set that meets the second preset condition is obtained, and the second negative sample set is randomly downsampled; the second preset condition is used to characterize that the individual meets the first preset condition and is continuously exposed within the second preset time; a positive sample set that meets the third preset condition is obtained, and the positive sample set is subjected to heat-suppressing sampling according to the heat-suppressing function. Among them, "according to the heat-enhancing function, the first negative sample set is subjected to heat-enhancing sampling" means: the heat corresponding to each sample in the first negative sample set (i.e., the ranking of the number of clicks corresponding to the sample) is input into the heat-enhancing function to obtain the sampling probability corresponding to the sample; "according to the heat-suppressing function, the positive sample set is subjected to heat-suppressing sampling" means: the heat corresponding to each sample in the positive sample set (i.e., the ranking of the number of clicks corresponding to the sample) is input into the heat-suppressing function to obtain the sampling probability corresponding to the sample.
[0072] In the above example, the first preset condition, the heat promotion function, the second preset condition and the heat suppression function can be found in the above embodiment and will not be described in detail here.
[0073] Furthermore, the first negative sample set after heat promotion sampling and the second negative sample set after random downsampling are merged, recorded as set P; the positive sample set after heat suppression sampling is recorded as set R; and set P and set R are merged. The merged set P and set R are used as training samples for the recommendation model. This application selects the sorted samples by sorting individuals based on heat, inputting the heat suppression function or the heat promotion function according to the sorting results; and obtaining negative samples by giving priority to hot items and obtaining positive samples by giving priority to non-hot items, so that the construction of the recommendation model is more accurate and the recommendation service can exert its effectiveness.
[0074] In this way, after the recommendation model is generated, when the user makes a request, the backend of the terminal device sends a request to the recommendation system. After the recommendation system receives the request, its recall layer sends the media that the user is interested in to the terminal device according to the recommendation model for the user to choose. The recommendation system usually needs to make recommendations from millions of heterogeneous items. Using complex recommendation algorithms directly on millions of candidate sets often introduces unbearable time costs. Therefore, industrial-grade comprehensive recommendation systems generally consist of two modules: recall (matching) and ranking (ranking). The recall module is responsible for quickly retrieving candidates for recommended media information from millions of data, and the ranking module is responsible for accurately sorting these recalled media information to obtain the final recommendation results.
[0075] In some embodiments, the behavior data of users clicking on recommended media assets is received, and the sample data in the sample project is updated based on the behavior data. Exemplarily, the click-through rate of each sample after the update is re-sorted, and the heat corresponding to each sample is updated based on the sorting result. On the other hand, the first negative sample set that meets the first preset condition is re-acquired, and the first negative sample set is subjected to heat-enhanced sampling according to the heat-enhanced function; the first preset condition is used to characterize that the exposed individual has not been clicked within the first preset time; the second negative sample set that meets the second preset condition is obtained, and the second negative sample set is randomly downsampled; the second preset condition is used to characterize that the individual meets the first preset condition and is continuously exposed within the second preset time; the positive sample set that meets the third preset condition is obtained, and the positive sample set is subjected to heat-suppressed sampling according to the heat-suppressed function. Among them, "according to the heat promotion function, the first negative sample set is subjected to heat promotion sampling" means: the heat corresponding to each sample in the first negative sample set (that is, the click volume ranking position corresponding to the sample) is input into the heat promotion function to obtain the sampling probability corresponding to the sample; "according to the heat suppression function, the positive sample set is subjected to heat suppression sampling" means: the heat corresponding to each sample in the positive sample set (that is, the click volume ranking position corresponding to the sample) is input into the heat suppression function to obtain the sampling probability corresponding to the sample.
[0076] The present application provides a display device, the display device includes a recommendation service, and the recommendation service applies the above-mentioned downsampling method based on heat sorting. The specific implementation of the recommendation service can be referred to the above-mentioned embodiment, and will not be repeated here.
[0077] An embodiment of the present application also provides a chip connected to a memory or including a memory, and used to read and execute a software program stored in the memory, and a method provided by an embodiment of the present application.
[0078] The present application embodiment also provides a computer program product, which includes one or more computer program instructions. When the computer loads and executes the computer program instructions, the process or function according to the above-mentioned various embodiments of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network or other programmable device. When it runs on a computer, the computer executes the method provided by the embodiment of the present application.
[0079] In this embodiment, a computer-readable storage medium is also provided, and the computer-readable storage medium can store computer program instructions. When the program instructions are executed, all steps of the image processing method of the above embodiments of the present application can be implemented. The computer-readable storage medium includes a disk, an optical disk, a read-only storage memory ROM or a random access memory RAM, etc.
[0080] In the above embodiments, all or part of the embodiments may be implemented by software, hardware, firmware or any combination thereof. When implemented by software, all or part of the embodiments may be implemented in the form of a computer program product, which is not limited in this embodiment.
[0081] It is also known to those skilled in the art that the various illustrative logical blocks and steps listed in this application can be implemented by electronic hardware, computer software, or a combination of the two. Whether such functions are implemented by hardware or software depends on the specific application and the design requirements of the entire system. Those skilled in the art can use various methods to implement the functions for each specific application, but such implementation should not be understood as exceeding the scope of protection of this application.
[0082] The various illustrative logic units and circuits described in this application can be implemented or operated by a general-purpose processor, a digital signal processor, an application-specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic, discrete hardware components, or any combination of the above. The general-purpose processor can be a microprocessor, and optionally, the general-purpose processor can also be any conventional processor, controller, microcontroller or state machine. The processor can also be implemented by a combination of computing devices, such as a digital signal processor and a microprocessor, a plurality of microprocessors, one or more microprocessors in conjunction with a digital signal processor core, or any other similar configuration.
[0083] The steps of the method or algorithm described in this application can be directly embedded in hardware, a software unit executed by a processor, or a combination of the two. The software unit can be stored in a RAM memory, a flash memory, a ROM memory, an EPROM memory, an EEPROM memory, a register, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium in the art. Exemplarily, the storage medium can be connected to the processor so that the processor can read information from the storage medium and can write information to the storage medium. Optionally, the storage medium can also be integrated into the processor. The processor and the storage medium can be arranged in an ASIC, and the ASIC can be arranged in a UE. Optionally, the processor and the storage medium can also be arranged in different components in the UE.
[0084] It should be understood that in various embodiments of the present application, the size of the serial number of each process does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the present application.
[0085] In addition, the terms "first", "second", "third", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments described herein can be implemented in an order other than that illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0086] Those skilled in the art can clearly understand that the technology in the embodiments of the present application can be implemented by means of software plus a necessary general hardware platform. Based on this understanding, the technical solution in the embodiments of the present application is essentially or the part that contributes to the prior art can be embodied in the form of a software product, which can be stored in a storage medium such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods of each embodiment of the present application or some parts of the embodiments.
[0087] In this specification, the same or similar parts between the various embodiments can be referred to each other. In particular, for the network device / node or apparatus, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the description in the method embodiment.
[0088] The above implementation modes of the present application do not constitute a limitation on the protection scope of the present application.
Claims
1. A downsampling method based on heat sorting, characterized in that: include: Acquire a first set of negative samples that meet a first preset condition, and perform heat boosting sampling on the first set of negative samples according to a heat boosting function; The first preset condition is used to indicate that the exposed individual has not been clicked within the first preset time; the heat promotion function is: Among them, rank i Represented as item i The sampling probability of item i It is expressed as the individual in the population sorted from small to large according to the number of clicks, and the individual corresponding to the i-th ranking is rank i =i; Acquire a second set of negative samples that meet a second preset condition, and randomly downsample the second set of negative samples; the second preset condition is used to indicate that the individual meets the first preset condition and is continuously exposed within a second preset time; A positive sample set meeting the third preset condition is obtained, and heat suppression sampling is performed on the positive sample set according to a heat suppression function; the heat suppression function is: Among them, n refers to the number of individuals in the population; The first negative sample set, the second negative sample set, and the positive sample set are merged.
2. The downsampling method based on heat sorting according to claim 1, characterized in that: The input of the popularity promotion function and the popularity suppression function is the popularity of the individual, and the popularity is the ranking of the individual after the overall click volume is sorted from small to large; As the heat increases, the sampling probability output by the heat enhancement function becomes greater; As the heat increases, the sampling probability output by the heat suppression function becomes smaller.
3. The downsampling method based on heat sorting according to claim 2, characterized in that: f = x α , α∈(0,1), then:
4. The downsampling method based on heat sorting according to claim 1, characterized in that: According to the heat suppression function plus random perturbation random(), the positive samples are sorted in reverse order and the topN are taken.
5. The downsampling method based on heat sorting according to claim 1, characterized in that: According to the heat boosting function plus random perturbation random(), the negative samples are sorted in reverse order and the topN are taken.
6. A media resource recommendation method, characterized in that: The generation of the recommendation model applies the downsampling method based on heat sorting described in any one of claims 1 to 5, including: Receive user click data, which refers to the user click data on media assets collected by the terminal device; calculate the popularity of the media assets based on the click data; sample the samples based on the media asset popularity based on the aforementioned downsampling method based on the popularity to complete the sample engineering action; generate a recommendation model based on sample engineering and feature engineering; when receiving a user request sent by the engine, request the recommendation model to sort the media assets and send the sorted media asset information to the terminal device.
7. The media resource recommendation method according to claim 6, characterized in that: Also includes: Accepting behavior data of a user clicking on the recommended media asset, and updating sample data in the sample project according to the behavior data.
8. A display device, characterized in that: Including recommendation business, the recommendation business applies the downsampling method based on heat sorting as described in any one of the preceding claims 1-5.
