Video recommendation method, device, electronic device and readable storage medium
By using matrix decomposition algorithm in the video recommendation system to extract hidden features of video and users, and combining explicit features for dimensionality reduction processing, the recommendation accuracy problem caused by data sparseness is solved, and more efficient video recommendation is achieved.
Patent Information
- Application Number
- CN202011293697.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-11-18
- Publication Date
- 2025-03-07
- Estimated Expiration
- 2040-11-18
AI Technical Summary
Due to data sparseness, the accuracy of movie recommendations is affected.
By obtaining the sample video score set, the matrix decomposition algorithm is used to extract the hidden features of the video and the user, and combined with explicit features for dimensionality reduction, and finally recommend videos to the user through rating prediction.
By optimizing the dimensionality reduction algorithm and combining explicit features, we can effectively deal with data sparseness problems and improve the accuracy of video recommendations.
Smart Images

Figure CN112380389B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of multimedia information processing, and in particular to a video recommendation method, a video recommendation method, a device, an electronic device and a readable storage medium. Background Art
[0002] At present, the Internet has abundant video content resources, and the demand for helping users to filter out videos that they are interested in or need from the abundant video resources is becoming increasingly prominent. The recommendation system is an effective way to solve this demand, and the recommendation algorithm is the key to the realization of the recommendation system function. At present, the mainstream successful recommendation scheme is the recommendation scheme based on the collaborative filtering algorithm. Although the collaborative filtering algorithm has achieved brilliant achievements, there are still many problems to be solved, such as data sparsity. Due to the large number of movies available for users to watch on the Internet and the variety of types, most users have only watched a small part of the movies, resulting in data sparsity in the user's movie rating matrix, and the data sparsity problem will seriously affect the accuracy of movie recommendations. Summary of the invention
[0003] The purpose of this application is to solve at least one of the above technical defects. The technical solution adopted by this application is as follows:
[0004] In a first aspect, an embodiment of the present application discloses a video recommendation method, the method comprising:
[0005] Obtain a sample video rating set; wherein the sample video rating set is a rating data matrix R of the sample video set by the rating user;
[0006] Processing the sample video rating set to obtain a sample video hidden feature matrix A and a rating user hidden feature matrix B respectively;
[0007] Obtain sample video display features and rating user display features respectively;
[0008] According to the matrices A and B, the obtained sample video display features and rating user display features are processed into a sample video display feature matrix C and a rating user display feature matrix D respectively;
[0009] According to a preset processing strategy, the matrix C and the matrix D are processed to obtain a matrix G;
[0010] Ratings of all videos are predicted according to the matrix G, and videos are recommended to target users according to the predicted ratings.
[0011] Optionally, the sample video rating set is a rating matrix table in the MovieLens 1M dataset.
[0012] Further, the processing of the sample video rating set to obtain the sample video hidden feature matrix A and the rating user hidden feature matrix B respectively includes:
[0013] The matrix R is decomposed using the MF matrix decomposition algorithm to obtain the sample video hidden feature matrix A and the rating user hidden feature matrix B;
[0014] where R∈R N×M , where N is the number of users and M is the number of movies;
[0015] A∈A K×M ; B∈B N×K ; where K represents the number of hidden feature dimensions.
[0016] Furthermore, respectively obtaining the sample video display features and the rating user display features includes: respectively parsing the rating user display features and the sample video display features from the user information and video information text of the MovieLens1M data set.
[0017] Further, the processing of the obtained sample video display features and rating user display features into a sample video display feature matrix C and a rating user display feature matrix D respectively according to the matrices A and B includes:
[0018] The obtained sample video display features and rating user display features are processed into a sample video display feature matrix C and a rating user display feature matrix D; wherein,
[0019] The sample video display feature matrix C∈C I×M ; Where I is the number of sample video display feature dimensions;
[0020] The rating user display feature matrix D∈D N×J ; Where J is the number of feature dimensions displayed by the rating user.
[0021] Further, the processing of the matrix C and the matrix D according to a preset processing strategy to obtain the matrix G includes:
[0022] The LR linear regression algorithm is used to reduce the dimensions of matrix C and matrix D to obtain matrix E and matrix F respectively; where matrix E∈E H×M , F∈F N×H , where H <I,H<J;
[0023] Multiplying matrix E and matrix F gives matrix G.
[0024] In a second aspect, an embodiment of the present application provides a video recommendation device, the device comprising: an interface module, a processing module, a prediction module and a recommendation module; wherein:
[0025] The interface module is used to obtain a sample video rating set; wherein the sample video rating set is a rating data matrix R of the sample video set by the rating user;
[0026] The processing module is used to process the sample video rating set to respectively obtain a sample video hidden feature matrix A and a rating user hidden feature matrix B;
[0027] The interface module is also used to obtain sample video display features and rating user display features respectively;
[0028] The processing module is used to process the obtained sample video display features and rating user display features into a sample video display feature matrix C and a rating user display feature matrix D according to the matrices A and B respectively;
[0029] The processing module is further used to process the matrix C and the matrix D according to a preset processing strategy to obtain a matrix G;
[0030] The prediction module is used to predict the scores of all videos according to the matrix G;
[0031] The recommendation module is used to recommend videos to target users based on the rating prediction results.
[0032] Optionally, the sample video rating set acquired by the interface module is a rating matrix table in the MovieLens 1M dataset.
[0033] In a third aspect, an embodiment of the present application provides an electronic device, including a processor and a memory;
[0034] The memory is used to store operation instructions;
[0035] The processor is used to execute the method described in any of the above embodiments by calling the operation instruction.
[0036] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the method described in any of the above embodiments is implemented.
[0037] The beneficial effect of the present application is based on optimizing the dimensionality reduction algorithm, specifically using two dimensionality reduction methods to perform secondary dimensionality reduction on the sample video rating set matrix, and adding the user's explicit feature quantization to the recommendation process, so as to better cope with data sparsity, make full use of user information, and improve the accuracy of recommendations. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in describing the embodiments of the present application are briefly introduced below.
[0039] Figure 1 A flowchart of a video recommendation method provided in an embodiment of the present application;
[0040] Figure 2 A schematic diagram of a video recommendation device provided in an embodiment of the present application;
[0041] Figure 3 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0042] The embodiments of the present application are described in detail below, and examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present application, and cannot be interpreted as limiting the present invention.
[0043] Those skilled in the art can understand that, unless otherwise stated, the singular forms "one", "an", "said" and "the" used herein may also include plural forms, and the "first", "second", etc., are only used to distinguish and define objects for the purpose of introducing the scheme clearly, and do not limit the objects themselves. Of course, the objects defined by "first" and "second" may be the same terminal, device, user, etc., or the same type of terminal, device and user. It should be further understood that the term "comprising" used in the specification of the present application refers to the presence of the features, integers, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or groups thereof. The term "and / or" used herein includes all or any unit and all combinations of one or more associated listed items.
[0044] In addition, it should be understood that in the embodiments of the present application, "at least one" refers to one or more, and "plurality" refers to two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone, where A and B can be singular or plural. The character " / " generally indicates that the previous and next associated objects are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single items or plural items. For example, at least one of a, b or c can represent: a, b, c, a and b, a and c, b and c, or a, b and c, where a, b, c can be single or multiple.
[0045] In order to make the objectives, technical solutions and advantages of the present application clearer, the implementation methods of the present application will be further described in detail below with reference to the accompanying drawings.
[0046] The following introduces some concepts, terms or devices that may be used in the following embodiments or used to assist in explaining the technical solutions of the embodiments:
[0047] The MovieLens 1M dataset contains 1 million ratings from 6,000 users on 4,000 movies. It is divided into three tables: ratings, user information, and movie information. After extracting the data from the zip file, you can read each table into a pandas DataFrame object using pandas.read_table.
[0048] Spark is a distributed, memory-based iterative computing framework. Of course, it can also perform iterative computing based on disk. Spark is an iterative computing framework based on memory. The data it processes can come from any storage medium, such as: relational database, local file system, distributed storage, network socket byte stream, etc.
[0049] The MF (Matrix Factorization) algorithm combines the characteristics of collaborative filtering, latent semantic analysis, and supervised learning. Combined with the ease of implementation and high scalability of matrix decomposition, it has become a very classic algorithm in the recommendation field.
[0050] The technical solution of the present application and how the technical solution of the present application solves the above-mentioned technical problems are described in detail below with specific embodiments. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present application will be described below in conjunction with the accompanying drawings.
[0051] The technical solution of the present application and how the technical solution of the present application solves the above-mentioned technical problems are described in detail below with specific embodiments. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present application will be described below in conjunction with the accompanying drawings.
[0052] Figure 1 A schematic diagram of a video recommendation process provided by an embodiment of the present application is shown. Figure 1 As shown, the method may mainly include:
[0053] S101, obtaining a sample video rating set; wherein the sample video rating set is a rating data matrix R of the sample video set by the rating user; wherein R∈R N×M , where N is the number of users and M is the number of movies;
[0054] In the embodiment of the present application, the sample video rating set is a rating matrix table in the MovieLens 1M dataset.
[0055] S102, processing the sample video rating set to obtain a sample video hidden feature matrix A and a rating user hidden feature matrix B respectively;
[0056] Specifically, the processing of the sample video rating set to obtain the sample video hidden feature matrix A and the rating user hidden feature matrix B respectively includes: using the MF matrix decomposition algorithm to decompose the matrix R to obtain the sample video hidden feature matrix A and the rating user hidden feature matrix B, where A∈A K×M ; B∈B N×K ; where K represents the number of hidden feature dimensions.
[0057] S103, respectively obtaining sample video display features and rating user display features;
[0058] Specifically, the rating user display features and sample video display features are parsed from the user information and video information text of the MovieLens 1M dataset. The user display features include but are not limited to the user's gender, age, occupation and other dimensions. The video display features include but are not limited to various video classification standards and specific types under the standards, such as horror, action, romance, etc. Introducing display features can achieve better recommendation results.
[0059] S104, according to the matrices A and B, processing the obtained sample video display features and rating user display features into a sample video display feature matrix C and a rating user display feature matrix D respectively;
[0060] In the embodiment of the present application, the obtained sample video display features and rating user display features are processed into a sample video display feature matrix C and a rating user display feature matrix D; wherein the sample video display feature matrix C∈C I×M ; Where I is the number of sample video display feature dimensions; the rating user display feature matrix D∈D N×J ; where J is the number of feature dimensions displayed by the rated user. This application combines these explicit features with the implicit feature matrix decomposed from the MF matrix to improve the recommendation accuracy.
[0061] S105, processing the matrix C and the matrix D according to a preset processing strategy to obtain a matrix G;
[0062] Specifically, according to the preset processing strategy, the processing process of the matrix C and the matrix D is as follows: First, use the LR linear regression algorithm to perform dimensionality reduction processing on the matrix C and the matrix D respectively to obtain the matrix E and the matrix F; where the matrix E ∈ E H×M , F ∈ F N ×H , where H < I, H < J; Secondly, multiply the matrix E and the matrix F to obtain the matrix G.
[0063] S106. Perform score prediction on all videos according to the matrix G and recommend videos to the target user according to the score prediction result.
[0064] In the embodiment of the present application, the matrix G realizes the preset score result for all video resources in the resource library, so that high-score videos or movies that meet the user's type can be recommended to the user according to the obtained video prediction score value and the user type. Of course, the recommendation rule can accept the user's custom modification.
[0065] Based on Figure 1 the video recommendation method shown, on the other hand, the embodiment of the present application provides a video recommendation device, and the device is as Figure 2 shown, and the device may include: a 201 interface module, a 202 processing module, a 203 prediction module, and a 204 recommendation module; where
[0066] The 201 interface module is used to obtain a sample video score set; where the sample video score set is a score data matrix R of the scoring user for the sample video set;
[0067] The 202 processing module is used to process the sample video score set to obtain a sample video hidden feature matrix A and a scoring user hidden feature matrix B respectively;
[0068] The 201 interface module is further used to obtain a sample video display feature and a scoring user display feature respectively;
[0069] The 202 processing module is used to process the obtained sample video display feature and the scoring user display feature into a sample video display feature matrix C and a scoring user display feature matrix D respectively according to the matrices A and B;
[0070] The 202 processing module is further used to process the matrix C and the matrix D according to the preset processing strategy and obtain the matrix G;
[0071] The 203 prediction module is used to perform score prediction on all videos according to the matrix G;
[0072] The 204 recommendation module is used to recommend videos to the target user according to the score prediction result.
[0073] Optionally, the sample video rating set acquired by the interface module 201 is a rating matrix table in the MovieLens 1M data set.
[0074] It can be understood that the above-mentioned components of the video recommendation device in this embodiment have the function of realizing Figure 1 The functions of the corresponding steps of the method in the embodiment shown in . The function can be implemented by hardware, or by hardware executing the corresponding software. The hardware or software includes one or more modules or systems corresponding to the above functions. The above modules and systems can be software and / or hardware, and the above modules and systems can be implemented separately or integrated with multiple modules and systems. For the functional description of the above modules and systems, please refer to Figure 1 The corresponding description of the method in the embodiment shown in , therefore, the beneficial effects that can be achieved can refer to the beneficial effects of the corresponding method provided above, which will not be repeated here.
[0075] It is understood that the structure illustrated in the embodiment of the present invention does not constitute a specific limitation on the specific structure of the video recommendation device. In other embodiments of the present application, the video recommendation device may include more or fewer components than shown in the figure, or combine some components, or split some components, or arrange the components differently. The components shown in the figure may be implemented in hardware, software, or a combination of software and hardware.
[0076] An embodiment of the present application provides an electronic device, including a processor and a memory;
[0077] A memory, used for storing operation instructions;
[0078] The processor is used to execute the video recommendation method provided in any embodiment of the present application by calling an operation instruction.
[0079] As an example, Figure 3 A schematic diagram of the structure of an electronic device applicable to the embodiment of the present application is shown. Figure 3 As shown, the electronic device 300 includes: a processor 301 and a memory 303. Among them, the processor 301 and the memory 303 are connected, such as being connected through a bus 302. Optionally, the electronic device 300 may also include a transceiver 304. It should be noted that in actual applications, the transceiver 304 is not limited to one. It is understandable that the structure illustrated in the embodiment of the present invention does not constitute a specific limitation on the specific structure of the electronic device 300. In other embodiments of the present application, the electronic device 300 may include more or fewer components than shown in the figure, or combine certain components, or split certain components, or arrange the components differently. The illustrated components may be implemented in hardware, software, or a combination of software and hardware. Optionally, the electronic device may also include a display screen 305 for displaying images, or receiving user operation instructions when necessary.
[0080] The processor 301 is applied in the embodiment of the present application to implement the method shown in the above method embodiment. The transceiver 304 may include a receiver and a transmitter. The transceiver 304 is applied in the embodiment of the present application to implement the function of the electronic device of the embodiment of the present application communicating with other devices when executed.
[0081] Processor 301 may be a CPU (Central Processing Unit), a general purpose processor, a DSP (Digital Signal Processor), an ASIC (Application Specific Integrated Circuit), an FPGA (Field Programmable Gate Array) or other programmable logic devices, transistor logic devices, hardware components or any combination thereof. It may implement or execute various exemplary logic blocks, modules and circuits described in conjunction with the disclosure of this application. Processor 301 may also be a combination that implements computing functions, such as a combination of one or more microprocessors, a combination of a DSP and a microprocessor, etc.
[0082] The processor 301 may also include one or more processing units, for example, the processor 301 may include an application processor (AP), a modem processor, a graphics processor (GPU), an image signal processor (ISP), a controller, a memory, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural network processor (NPU). Among them, different processing units may be independent devices or integrated into one or more processors. Among them, the controller may be the nerve center and command center of the electronic device 300. The controller may generate an operation control signal according to the instruction opcode and the timing signal to complete the control of fetching and executing instructions. A memory may also be set in the processor 301 for storing instructions and data. In some embodiments, the memory in the processor 301 is a high-speed cache memory. The memory may store instructions or data that the processor 301 has just used or circulated. If the processor 301 needs to use the instruction or data again, it may be directly called from the memory. Repeated access is avoided, the waiting time of the processor 301 is reduced, and the efficiency of the system is improved.
[0083] The processor 301 can run the video recommendation method provided in the embodiment of the present application to reduce the user's operation complexity, improve the intelligence of the terminal device, and enhance the user experience. The processor 301 can include different devices. For example, when the CPU and GPU are integrated, the CPU and GPU can cooperate to execute the video recommendation method provided in the embodiment of the present application. For example, part of the algorithm in the video recommendation method is executed by the CPU, and the other part of the algorithm is executed by the GPU to obtain faster processing efficiency.
[0084] The bus 302 may include a path to transmit information between the above components. The bus 302 may be a PCI (Peripheral Component Interconnect) bus or an EISA (Extended Industry Standard Architecture) bus. The bus 302 may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 3 Only one thick line is used in the diagram, but this does not mean that there is only one bus or only one type of bus.
[0085] The memory 303 may be a ROM (Read Only Memory) or other types of static storage devices that can store static information and instructions, a RAM (Random Access Memory) or other types of dynamic storage devices that can store information and instructions, or an EEPROM (Electrically Erasable Programmable Read Only Memory), a CD-ROM (Compact Disc Read Only Memory), or may include a high-speed random access memory, or may include a non-volatile memory, such as at least one disk storage device, a flash memory device, a universal flash storage (UFS), or other optical disk storage, optical disk storage (including compressed optical disk, laser disk, optical disk, digital versatile disk, Blu-ray disk, etc.), a disk storage medium or other magnetic storage device, or any other medium that can be used to carry or store the desired program code in the form of instructions or data structures and can be accessed by a computer, but is not limited to this.
[0086] Optionally, the memory 303 is used to store application code for executing the solution of the present application, and the execution is controlled by the processor 301. The processor 301 is used to execute the application code stored in the memory 303 to implement the video recommendation method provided in any embodiment of the present application.
[0087] The memory 303 can be used to store computer executable program codes, which include instructions. The processor 301 executes various functional applications and data processing of the electronic device 300 by running the instructions stored in the memory 303. The memory 303 may include a program storage area and a data storage area. Among them, the program storage area may store the code of the operating system, application program, etc. The data storage area may store data created during the use of the electronic device 300 (such as images, videos, etc. collected by the camera application), etc.
[0088] The memory 303 may also store one or more computer programs corresponding to the video recommendation method provided in the embodiment of the present application. The one or more computer programs are stored in the above-mentioned memory 303 and are configured to be executed by the one or more processors 301. The one or more computer programs include instructions, and the above-mentioned instructions can be used to execute each step in the above-mentioned corresponding embodiment.
[0089] Of course, the code of the video recommendation method provided in the embodiment of the present application can also be stored in an external memory. In this case, the processor 301 can run the code of the video recommendation method stored in the external memory through the external memory interface, and the processor 301 can control the running video recommendation process.
[0090] The display screen 305 includes a display panel. The display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode or an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), Miniled, MicroLed, Micro-oLed, a quantum dot light-emitting diode (QLED), etc. In some embodiments, the electronic device 300 may include 1 or N display screens 305, where N is a positive integer greater than 1. The display screen 305 can be used to display information input by a user or information provided to a user and various graphical user interfaces (GUI). For example, the display screen 305 can display photos, videos, web pages, or files.
[0091] The electronic device provided in the embodiment of the present application is applicable to any embodiment of the above method. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding method provided above, which will not be repeated here.
[0092] An embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored. When the program is executed by a processor, the video recommendation method shown in the above method embodiment is implemented.
[0093] The computer-readable storage medium provided in the embodiment of the present application is applicable to any embodiment of the above-mentioned method. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding method provided above, which will not be repeated here.
[0094] The embodiment of the present application also provides a computer program product, which, when executed on a computer, enables the computer to execute the above-mentioned related steps to implement the method in the above-mentioned embodiment. The computer program product provided in the embodiment of the present application is applicable to any embodiment of the above-mentioned method, and therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding method provided above, which will not be repeated here.
[0095] The video recommendation scheme disclosed in the above embodiment of the present application is through obtaining a sample video rating set; wherein the sample video rating set is a rating data matrix R of the scoring user for the sample video set; processing the sample video rating set to obtain a sample video hidden feature matrix A and a scoring user hidden feature matrix B respectively; obtaining sample video display features and scoring user display features respectively; according to the matrices A and B, processing the obtained sample video display features and scoring user display features into a sample video display feature matrix C and a scoring user display feature matrix D respectively; according to a preset processing strategy, processing the matrix C and matrix D to obtain a matrix G; according to the matrix G, predicting the ratings of all videos and recommending videos to the target user according to the rating prediction results. The present application is based on an optimized dimensionality reduction algorithm, specifically using two dimensionality reduction methods to perform secondary dimensionality reduction on the matrix of the sample video rating set, and adding the user's explicit feature quantization to the recommendation process, so as to better cope with data sparsity, make full use of user information, and improve the accuracy of recommendations.
[0096] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of modules or units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another device, or some features can be discarded or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0097] The units described as separate components may or may not be physically separated, and the components shown as units may be one physical unit or multiple physical units, that is, they may be located in one place or distributed in multiple different places. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.
[0098] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0099] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solution of the embodiment of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium, including several instructions to enable a device (which can be a single-chip microcomputer, chip, etc.) or a processor (processor) to perform all or part of the steps of the various embodiments of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read only memory (ROM), random access memory (RAM), disk or optical disk and other media that can store program code.
[0100] It should be understood that, although the steps in the flowchart of the accompanying drawings are displayed in sequence as indicated by the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least a part of the steps in the flowchart of the accompanying drawings may include multiple sub-steps or multiple stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and their execution order is not necessarily sequential, but can be executed in turn or alternately with other steps or at least a part of the sub-steps or stages of other steps.
[0101] The above contents are only specific implementation methods of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, and can also make some improvements and modifications. These changes, substitutions, improvements and modifications should also be considered to be included in the protection scope of the present application. Therefore, the protection scope of the present application shall be based on the protection scope of the claims.
Claims
1. A video recommendation method, characterized in that: The method comprises: Obtain a sample video rating set; wherein the sample video rating set is a rating data matrix R of the sample video set by the rating user; Processing the sample video rating set to obtain a sample video hidden feature matrix A and a rating user hidden feature matrix B respectively includes: decomposing the matrix R using an MF matrix decomposition algorithm to obtain a sample video hidden feature matrix A and a rating user hidden feature matrix B; Obtain sample video display features and rating user display features respectively; According to the matrices A and B, the obtained sample video display features and rating user display features are processed into a sample video display feature matrix C and a rating user display feature matrix D, respectively, including: after the sample video display features and the rating user display features are digitized, they are combined with the matrices A and B obtained by MF matrix decomposition; According to a preset processing strategy, the matrix C and the matrix D are processed to obtain the matrix G, including: using the LR linear regression algorithm to perform dimensionality reduction processing on the matrix C and the matrix D to obtain the matrix E and the matrix F respectively; multiplying the matrix E and the matrix F to obtain the matrix G; Ratings of all videos are predicted according to the matrix G, and videos are recommended to target users according to the results of the rating prediction.
2. The video recommendation method according to claim 1, characterized in that: The sample video rating set is a rating matrix table in the MovieLens 1M dataset.
3. The video recommendation method according to claim 1, characterized in that: Said , where N is the number of users and M is the number of movies; ; B ; where K represents the number of hidden feature dimensions.
4. The video recommendation method according to claim 3, characterized in that: Obtaining sample video display features and rating user display features respectively includes: The rating user display features and sample video display features are parsed from the user information and video information text of the MovieLens 1M dataset respectively.
5. The video recommendation method according to claim 1 or 4, characterized in that: The step of processing the obtained sample video display features and rating user display features into a sample video display feature matrix C and a rating user display feature matrix D respectively according to the matrices A and B comprises: The obtained sample video display features and rating user display features are processed into a sample video display feature matrix C and a rating user display feature matrix D; wherein, The sample video shows the characteristic matrix ; Where I is the number of sample video display feature dimensions, and M is the number of movies; The rating user displays the feature matrix ; Where J is the number of feature dimensions displayed by the rating users, and N is the number of users.
6. The video recommendation method according to claim 1, characterized in that: The matrix E , F , where H , H , I is the number of display feature dimensions of sample videos, J is the number of display feature dimensions of rated users, M is the number of movies, and N is the number of users.
7. A video recommendation device, characterized in that: The device comprises: an interface module, a processing module, a prediction module and a recommendation module; wherein, The interface module is used to obtain a sample video rating set; wherein the sample video rating set is a rating data matrix R of the sample video set by the rating user; The processing module is used to process the sample video rating set to obtain the sample video hidden feature matrix A and the rating user hidden feature matrix B respectively, including: decomposing the matrix R using the MF matrix decomposition algorithm to obtain the sample video hidden feature matrix A and the rating user hidden feature matrix B; The interface module is also used to obtain sample video display features and rating user display features respectively; The processing module is used to process the obtained sample video display features and rating user display features into a sample video display feature matrix C and a rating user display feature matrix D according to the matrices A and B, respectively, including: after the sample video display features and the rating user display features are digitized, they are combined with the matrices A and B obtained by MF matrix decomposition; The processing module is further used to process the matrix C and the matrix D according to a preset processing strategy to obtain a matrix G, including: using the LR linear regression algorithm to perform dimensionality reduction processing on the matrix C and the matrix D to obtain a matrix E and a matrix F respectively; multiplying the matrix E and the matrix F to obtain the matrix G; The prediction module is used to predict the scores of all videos according to the matrix G; The recommendation module is used to recommend videos to target users based on the results of the rating prediction.
8. The video recommendation device according to claim 7, characterized in that: The sample video rating set is a rating matrix table in the MovieLens 1M dataset.
9. An electronic device, characterized in that: including a processor and a memory; The memory is used to store operation instructions; The processor is used to execute the method according to any one of claims 1 to 6 by calling the operation instruction.
10. A computer-readable storage medium, characterized in that: The storage medium stores a computer program, and when the computer program is executed by a processor, the method according to any one of claims 1 to 6 is implemented.