Page layout method, device, equipment and storage medium
By acquiring multiple target multimedia and page regions, and combining machine learning models and attention mechanisms, a page layout that conforms to the user's browsing pattern is generated, solving the problem of low user experience in existing technologies and achieving higher user satisfaction.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-04-29
- Publication Date
- 2026-03-20
AI Technical Summary
Existing page layout methods cannot meet the diverse browsing patterns of users, resulting in a poor user experience.
By acquiring multiple target multimedia resources and multiple page regions within a preset-sized page space, a target page is generated. Combining machine learning models and attention mechanisms, the page adaptively learns the user's browsing patterns and dynamically adjusts the display area of candidate content.
It improves the conformity of page layout, enhances user experience, adapts to different users' browsing habits and interaction methods, and improves user satisfaction.
Smart Images

Figure CN114996601B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present disclosure relates to the field of information technology, and in particular, to a page layout method and device, an electronic device, and a storage medium. BACKGROUND
[0002] With the continuous development of technology, users can install various different application programs on terminals. The application programs can provide user pages for users, so that users can browse content or perform operations on the user pages.
[0003] However, the inventors of the present application have found that the page layout of the current user interface has certain irrationality, resulting in low user experience. SUMMARY
[0004] To solve the above technical problems or at least partially solve the above technical problems, the present disclosure provides a page layout method, device, equipment and storage medium. The method of the embodiment can conform to different browsing modes of users. Thus, the user experience is improved.
[0005] In a first aspect, the present disclosure provides a page layout method, comprising:
[0006] obtaining a plurality of target multimedia;
[0007] generating a target page according to the plurality of target multimedia and a plurality of page regions in a page space of a preset size, the target page comprising the plurality of page regions, and each page region in the target page comprising one target multimedia.
[0008] In a second aspect, the present disclosure provides a page layout device, comprising:
[0009] an obtaining module configured to obtain a plurality of target multimedia;
[0010] a generating module configured to generate a target page according to the plurality of target multimedia and a plurality of page regions in a page space of a preset size, the target page comprising the plurality of page regions, and each page region in the target page comprising one target multimedia.
[0011] In a third aspect, the present disclosure provides an electronic device, comprising:
[0012] a memory;
[0013] a processor; and
[0014] a computer program;
[0015] The computer program is stored in the memory and is configured to be executed by the processor to implement the method of the first aspect.
[0016] In a fourth aspect, the embodiments of the present disclosure provide a computer readable storage medium, which stores a computer program. The computer program is executed by a processor to implement the method in the first aspect.
[0017] The page layout method, device, equipment and storage medium provided by the embodiments of the present disclosure can generate a target page through a plurality of target multimedia and a plurality of page regions in a page space of a preset size. In the generation process, not only the target multimedia to be displayed is selected from the plurality of target multimedia, but also the page region corresponding to the selected target multimedia, i.e., the display region of the target multimedia, is determined. Compared with the list-type page layout in the prior art, the method of the embodiments can meet different browsing modes of users. Therefore, the user experience is improved. BRIEF DESCRIPTION OF DRAWINGS
[0018] The accompanying drawings, which are incorporated herein and constitute part of the specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the present disclosure.
[0019] In order to more clearly illustrate the technical solutions in the embodiments of the present disclosure or the prior art, the accompanying drawings needed to be used in the embodiments or the prior art description will be briefly introduced. Obviously, for those skilled in the art, other drawings can also be obtained based on these drawings without creative labor.
[0020] Figure 1 A page layout method in the prior art;
[0021] Figure 2 Another page layout method in the prior art;
[0022] Figure 3 A page layout method flowchart provided by the embodiments of the present disclosure;
[0023] Figure 4 A schematic diagram of an application scenario provided by the embodiments of the present disclosure;
[0024] Figure 5 A page layout method flowchart provided by another embodiment of the present disclosure;
[0025] Figure 6 A page layout method flowchart provided by another embodiment of the present disclosure;
[0026] Figure 7 A schematic diagram of each region in candidate content and a target page provided by another embodiment of the present disclosure;
[0027] Figure 8 A page layout method flowchart provided by another embodiment of the present disclosure;
[0028] Figure 9 A page layout method flowchart provided for another embodiment of the present disclosure;
[0029] Figure 10 An internal structure and processing flow of a first model provided for another embodiment of the present disclosure;
[0030] Figure 11 A page layout method flowchart provided for another embodiment of the present disclosure;
[0031] Figure 12 A flowchart of evaluating a sample page by a second model provided for another embodiment of the present disclosure;
[0032] Figure 13 A page layout method flowchart provided for another embodiment of the present disclosure;
[0033] Figure 14 A schematic diagram of a second model training process provided for another embodiment of the present disclosure;
[0034] Figure 15 A structural schematic diagram of a page layout apparatus provided for an embodiment of the present disclosure;
[0035] Figure 16 A structural schematic diagram of an electronic device embodiment provided for an embodiment of the present disclosure. DETAILED DESCRIPTION
[0036] In order to enable a person skilled in the art to more clearly understand the above-mentioned purposes, features and advantages of the present disclosure, the schemes of the present disclosure will be further described below. It should be noted that the embodiments of the present disclosure and the features in the embodiments can be combined with each other without conflict.
[0037] In the following description, many specific details are set forth in order to fully understand the present disclosure, but the present disclosure can also be implemented in other ways different from those described herein; obviously, the embodiments in the specification are only some of the embodiments of the present disclosure, not all the embodiments.
[0038] The content on the modern network, including news, commodity information, etc., is extremely rich and huge. When a search recommendation engine shows content to a user, it filters the content to be shown to the user from a large number of candidate sets, and further shows the content on a web page or a mobile phone screen. The result display of the existing search recommendation engine is very simple, for example, the click rate of the content is counted, and the content is sorted in descending order of the click rate. The basic assumption of this display method is that the user browses the content from top to bottom, for example, the content at the top is the information that the user wants.
[0039] The current search recommendation engine can obtain different types of content from different content channels, such as pictures, videos, commodity cards, advertisement cards, etc., and lay these different types of content flat in the page, that is, the content in the page is heterogeneous. These heterogeneous contents exist in the category of repetition, or there are differences in price, or the color matching does not conform to the aesthetics. And different users have different browsing habits, page areas of interest, and content of interest, and user interaction has changed, for example, users may be attracted by colorful pictures. That is, in the case of heterogeneous page content, users may no longer browse the content from top to bottom as before. Therefore, the traditional list-type page layout may not meet the needs of users. Therefore, how to reasonably arrange the page layout has a great influence on improving the user's satisfaction with the recommended content. Therefore, how to design a reasonable two-dimensional page layout for these heterogeneous contents is increasingly important for search recommendation engines.
[0040] However, some page layout methods in the prior art have certain irrationality, resulting in low user experience. For example, Figure 1 Fig. 1 shows a page layout method in the prior art. The decoder (Decoder) can be specifically an inverse convolution network, which can be denoted as Actor. Through the inverse convolution network, the entire page layout can be generated end-to-end. The specific method is: after encoding the candidate set composed of candidate contents and the positions of each region in the page, the inverse convolution network is used to generate a hidden vector in each region (cell) of the page. The page can be a two-dimensional plane page. For example, Figure 1 In the formula, S can represent the encoding result obtained after encoding the candidate set composed of candidate contents and the positions of each region in the page. e1, e2, …, e M-1 , e M are hidden vectors generated by the inverse convolution network in each region (cell) of the page. For example, taking e1 as an example, a candidate content can be selected from the candidate set, and the selection method can be to find the nearest content vector to e1 using the nearest neighbor method. The candidate content corresponding to the content vector can be used as the content displayed in the region corresponding to e1. For example Figure 1 E1, E2, …, E M-1 , E M are content vectors corresponding to each region. In the process of training the inverse convolution network, gradient descent can be used to optimize according to the feedback information of the user on the page layout. For example Figure 1 As shown in Fig. 1, E1, E2, …, E M-1 , E MThe corresponding content layout is obtained in the corresponding area, and the page layout is further displayed to the user, and the user can feed back the page layout, wherein r represents the feedback information of the user. The disadvantage of this method is that the page layout is generated once, which may not meet the user's needs.
[0041] Figure 2 Another prior art page layout method is shown. Wherein, x <1> , x <2> , …, x <tx>< / tx> respectively represent candidate content, a <0> represents the initial parameter. Specifically, the encoder encodes the candidate content as a sequence, and then the decoder selects the candidate content one by one, wherein y <1> , y <2> , …, y <ty>< / ty> respectively represent the decoded candidate content. Further, the display list is generated according to the preset rule, for example, from top to bottom. The disadvantage of this method is that the list type page layout is more suitable for users who browse from top to bottom, but cannot adapt to users with other browsing modes.
[0042] To solve the above problems, the present embodiment provides a page layout method, which will be introduced below in combination with specific embodiments.
[0043] Figure 3 The page layout method provided by the present embodiment is shown in the flowchart. The method can be executed by a page layout device, which can be realized by software and / or hardware. The device can be configured in an electronic device, such as a server or a terminal, wherein the terminal specifically includes a mobile phone, a computer or a tablet computer, etc. In addition, the page layout method provided by the present embodiment can be applied to the application scenario as shown in Figure 4 The application scenario includes a terminal 41 and a server 42. In one possible implementation, the server 42 can execute the page layout method and send the generated target page to the terminal 41, and the terminal 41 displays the target page. In another possible implementation, the terminal 41 can execute the page layout method and display the target page after generating the target page. The server 42 will be described below as an example. As shown in Figure 3 The specific steps of the method are as follows:
[0044] S301, obtaining a plurality of target multimedia.
[0045] For example, the terminal 41 can display a user interface, which can include a search box. When a user inputs search content in the search box, the terminal 41 can generate a search request according to the search content, and send the search request to the server 42. The server 42 can obtain one or more target multimedia matching the search request according to the search request. The target multimedia can be commodity information, advertisement information, etc. In addition, the target multimedia in the embodiments of the present disclosure can be text, picture, voice, video, etc.
[0046] Specifically, the server 42 can locally store a large amount of multimedia information. The server 42 can obtain one or more target multimedia matching the search request from the large amount of local multimedia information according to the search request. Alternatively, the server 42 can obtain one or more target multimedia matching the search request from other network devices or databases according to the search request.
[0047] S302, generating a target page according to the plurality of target multimedia and a plurality of page regions in a page space of a preset size, the target page including the plurality of page regions, and each page region in the target page including one target multimedia.
[0048] For example Figure 5 The candidate content 1, the candidate content 2, …, and the candidate content N shown in the figure are the plurality of target multimedia obtained by the server 42. In addition, the embodiments can also set the page space of the preset size according to the application scenarios to which the page layout method is applicable, such as Figure 5 As shown in the figure, the page space is a 3*3 space, that is, the page space includes 9 page regions. It can be understood that 3*3 is only an example, and the embodiments do not limit the preset size.
[0049] The page layout method described in the embodiments can be specifically a page layout algorithm as shown in Figure 5 Specifically, the N candidate contents and the 9 page regions in the page space can be used as inputs of the page layout algorithm. The page layout algorithm can select one candidate content from the N candidate contents each time, and determine the page region corresponding to the selected candidate content. For example Figure 5The order shown indicates that the page layout algorithm selects candidate content 3 for the first time, candidate content 1 for the second time, candidate content 2 for the third time, and so on. Assume that the page layout algorithm determines that the page area corresponding to candidate content 3 is the middle area shown in the human-computer interaction diagram when selecting candidate content 3, and determines that the page area corresponding to candidate content 1 is the left side of the middle area when selecting candidate content 1, and so on. After each of the nine page areas has corresponding candidate content, a target page is generated based on these nine page areas and the candidate content corresponding to each page area. This target page can be as follows: Figure 5 The page layout is shown. Specifically, the target page includes the nine page areas, and each page area in the target page includes one candidate content. In some embodiments, such as Figure 5 The order of the displayed content reflects the user's level of interest in the candidate content. For example, selecting candidate content 3 first indicates the user's highest level of interest in it, while selecting candidate content 1 second indicates the user's next level of interest, and so on. Additionally, as... Figure 5 The human-computer interaction shown can reflect the user's level of interest in a particular area of the page. For example, the darker the color of the page area, the more interested the user is, and vice versa.
[0050] Furthermore, it is understood that the target page described in this embodiment can be displayed entirely in the display component of terminal 41, or the target page can be resized and then displayed entirely in the display component of terminal 41. Alternatively, a portion of the target page can be displayed in the display component first, and then terminal 41 can display the remaining page area in the display component based on the user's swiping operation on the target page. For example, when terminal 41 receives the target page, it can display the first and second rows of the target page in the display component, and then display the third row in the display component based on the user's vertical or horizontal swiping operation on the target page. In other words, the target page can be displayed entirely in the display component at once, or displayed in batches.
[0051] This embodiment generates a target page by using multiple target multimedia resources and multiple page regions within a preset page space. During the generation process, not only is the target multimedia resource to be displayed selected from the multiple target multimedia resources, but the corresponding page region for the selected target multimedia resource, i.e., the display area of that target multimedia resource, is also determined. Compared to the list-style page layout in the prior art, the method of this embodiment can accommodate different user browsing modes, thereby improving the user experience.
[0052] Optionally, after generating a target page based on the plurality of target multimedia and multiple page regions in a preset-sized page space, the method further includes: updating the target page based on the evaluation information of the evaluator on the target page.
[0053] For example, when the page layout algorithm outputs the target page, that is... Figure 5 After the page layout is shown, an evaluator can evaluate it, providing feedback. This evaluation can then be fed back to the page layout algorithm, allowing the algorithm to regenerate and update the target page to better suit the user's browsing patterns. Alternatively, the algorithm can use the evaluation to optimize subsequent target page generation processes, ensuring that later generated pages better align with the user's browsing habits.
[0054] In this embodiment, an evaluator is used to evaluate the target page generated by the page layout algorithm. This evaluation information can guide the page layout algorithm to generate a target page that better matches the user's browsing pattern, thereby improving the accuracy of the page layout algorithm.
[0055] Figure 6 A flowchart illustrating a page layout method according to another embodiment of this disclosure. Figure 6 As shown, the method includes the following steps:
[0056] S601, Acquire multiple target multimedia.
[0057] Specifically, the implementation methods and underlying principles of S601 and S301 are the same, and will not be elaborated here.
[0058] S602. Select one target multimedia from the unselected target multimedia among the plurality of target multimedia, and determine the page area corresponding to the target multimedia selected each time. The target multimedia selected in the previous time and the page area corresponding to the target multimedia selected in the previous time will affect the target multimedia selected in the current time and the page area corresponding to the target multimedia selected in the current time.
[0059] For example, server 42 can... Figure 5 One candidate content is selected from the N candidate contents shown, and the selected candidate content can be different each time. Specifically, in order to ensure that the selected candidate content is different each time, one candidate content can be selected from the unselected candidate content among the N candidate contents each time. At the same time as selecting a candidate content, the page area corresponding to the candidate content can also be determined, that is, the placement area or position of the candidate content on the target page.
[0060] For example, when the server 42 performs the first selection, since the N candidate contents do not include the candidate content that has been selected, the server 42 can select one candidate content from the N candidate contents as the first selected candidate content, for example, the first selected candidate content is the candidate content 3. Meanwhile, the server 42 determines that the page area corresponding to the candidate content 3 is the middle area shown by the human-computer interaction. When the server 42 performs the second selection, the N candidate contents except the candidate content 3 are unselected candidate contents, at this time, the server 42 can select one candidate content from the unselected candidate contents as the second selected candidate content, for example, the second selected candidate content is the candidate content 1, and meanwhile, the server 42 determines that the page area corresponding to the candidate content 1 is the left area of the middle area, and so on. It can be understood that the unselected candidate contents in the N candidate contents are decreasing before each selection.
[0061] In addition, the previously selected candidate content and the page area corresponding to the previously selected candidate content can affect the current selected candidate content and the page area corresponding to the current selected candidate content. For example, the first selected candidate content 3 and the middle area corresponding to the candidate content 3 can affect the second selected candidate content and the page area corresponding to the second selected candidate content. The second selected candidate content 1 and the left area of the middle area corresponding to the candidate content 1 can affect the third selected candidate content and the page area corresponding to the third selected candidate content.
[0062] For example Figure 7 The N candidate contents shown in the figure represent the plurality of target multimedia obtained by the server 42. As shown in the figure Figure 7 As shown in the figure, 51 represents a plurality of page areas in a target page. Assuming that the first selected candidate content of the server 42 from the N candidate contents is the candidate content 3, and the candidate content 3 is placed in the middle area of the target page, the second selected candidate content of the server 42 is selected from the remaining candidate contents except the candidate content 3 in the N candidate contents. The page area corresponding to the second selected candidate content in the target page is other area in the target page except the middle area. That is, the previously selected candidate content and the page area corresponding to the previously selected candidate content can affect the current selected candidate content and the page area corresponding to the current selected candidate content.
[0063] Optionally, the number of the plurality of target multimedia is greater than or equal to the number of the plurality of page areas; the method further comprises: when the number of the plurality of target multimedia is greater than the number of the plurality of page areas, if the number of the selected target multimedia is equal to the number of the plurality of page areas, stopping the selection.
[0064] In the embodiment, the total number N of the candidate contents is greater than or equal to the total number of the page regions, for example, the total number of the page regions is 9, and N is greater than or equal to 9. When N is equal to 9, the server 42 selects 9 times to determine the page region corresponding to each candidate content. When N is greater than 9, before each selection, the server 42 needs to determine whether the number of the candidate contents selected currently is equal to 9. If yes, the selection is stopped. That is, when N is greater than 9, 9 candidate contents selected from the N candidate contents are displayed in the target page, and the remaining candidate contents are not displayed in the target page.
[0065] S603, generating a target page according to each selected target multimedia and the page region corresponding to each selected target multimedia. The selected target multimedia is different each time, and different target multimedia corresponds to different page regions.
[0066] For example, the server 42 selects 9 candidate contents from the N candidate contents, selects one candidate content each time, and determines the page region corresponding to the candidate content each time. For example, the selected candidate content is different each time, and different candidate content corresponds to different page region. Further, the target page is generated according to each selected candidate content and the page region corresponding to each selected candidate content.
[0067] Or in the selection process, the target page is determined according to the selected candidate content and the page region corresponding to the selected candidate content in the target page. For example, the selection process can be recorded as an iteration process. After the first iteration, candidate content 3 is selected, and the page region corresponding to candidate content 3 is determined. At this time, the first layout can be generated according to candidate content 3 and the page region corresponding to candidate content 3. After the second iteration, candidate content 1 is selected, and the page region corresponding to candidate content 1 is determined. At this time, candidate content 1 is added to the first layout according to the page region corresponding to candidate content 1, and the second layout is obtained. That is, in the iteration process, the page layout can be updated continuously. When the 9 selected candidate contents are put into the 9 page regions, the page layout obtained can be used as the target page.
[0068] The embodiments of the present disclosure can obtain multiple target multimedia, select one target multimedia from the multiple target multimedia each time, and determine the page area corresponding to the target multimedia selected each time, so that the target multimedia selected last time and the page area corresponding to the target multimedia selected last time can affect the target multimedia selected this time and the page area corresponding to the target multimedia selected this time. Therefore, the multiple target multimedia displayed in the target page are selected in a continuous iteration process, so that the target page can be closer to real human-computer interaction, for example, a user can pay attention to a single content or a single area in the target page at the same time, and then move to other areas or other contents, and the iteration process is learning this natural process. Therefore, the influence of the previous content on the subsequent content can be effectively modeled, and the layout of the target page is more consistent with the user's browsing mode.
[0069] For example, the first model and the second model can be deployed in the server 42, the first model can be denoted as a machine learning model, and the machine learning model can perform the page layout algorithm as shown in Figure 5 The second model can be an evaluator as shown in Figure 5 The second model can also be a machine learning model. That is, the page layout algorithm can be used to generate the target page as described above, and the process of generating the target page can be the use stage or inference stage of the first model. Before the use stage or inference stage of the first model, the first model needs to be trained, and specifically, the trained second model can participate in the training process of the first model. That is, the second model is mainly used to assist the training of the first model, so that the trained first model is more accurate. The page layout algorithm will be introduced below. Figure 5 The page layout algorithm will be introduced below.
[0070] On the basis of the above embodiments, selecting one target multimedia from the multiple target multimedia each time and determining the page area corresponding to the target multimedia selected each time includes: taking the multiple target multimedia and the multiple page areas as inputs of a machine learning model, and selecting one target multimedia from the multiple target multimedia each time and determining the page area corresponding to the target multimedia selected each time through the machine learning model.
[0071] As shown in Figure 5The N candidate contents shown represent multiple target multimedia, and the page space represents the division information of the page area in the target page. The N candidate contents and the page space are input into a machine learning model, e.g., a first model. Since the first model can perform a page layout algorithm as described above, the page layout algorithm can process the N candidate contents and the page space. For example, the first model can select one candidate content from the N candidate contents at a time, and determine the page area corresponding to the selected candidate content, thereby obtaining two outputs. One output is the page layout as shown in Figure 5 The content order shown, and the other output is the human-computer interaction as shown in Figure 5
[0072] For example, when determining the ranking result of multiple candidate contents, the page layout algorithm can iteratively select candidate contents from the N candidate contents, and determine the page area corresponding to each selected candidate content in the page space. In the selection process, the previously selected candidate content and the page area corresponding to the previously selected candidate content will affect the current selected candidate content and the page area corresponding to the current selected candidate content. For example, as shown in Figure 5 The page layout algorithm selects candidate content 3 in the first iteration, and determines that the page area corresponding to candidate content 3 in the target page is the middle area. In the second iteration, candidate content 1 is selected, and it is determined that the page area corresponding to candidate content 1 in the target page is the left area of the middle area. Similarly, when the candidate content corresponding to each page area is determined, the corresponding candidate content can be placed in each page area, thereby obtaining the page layout as shown in Figure 5
[0073] Optionally, the method further includes updating the network parameters of the first model according to the feedback information of the target page by the user.
[0074] For example, the training phase of the first model can be offline training. The usage phase or inference phase of the first model can be online, for example, deploying the trained first model on an online server. Since the second model is mainly used to assist the training of the first model, the second model can not be needed when the first model is used online. In some embodiments, the first model can also be referred to as a generator network (Tile Networks), a layout generator, or a page layout generator, etc. In addition, the base network of Tile Networks can use other deep networks in addition to directly using self-attention networks to encode candidate content and candidate positions (e.g., page regions), such as forward networks, recurrent networks, etc. When the first model is used online, the network parameters of the finally trained first model can be loaded, and then the set of content candidates and the multiple page regions in the page space can be input into the first network as inputs, where the set of content candidates can be a set of N candidate contents as shown in Figure 5 Figure 5 The first network can include an encoder and a decoder. The encoder can encode each candidate content in the set of content candidates and each candidate position in the candidate positions. The decoder can sequentially decode and output each candidate content and the corresponding placement position of each candidate content, i.e., the corresponding page region in the target page, in combination with an attention mechanism. In order to verify the effectiveness of the first model and iteratively update the first model online, the online server can obtain and record user satisfaction indicators of the target page, such as the number of clicks, the number of purchases after clicking, the browsing time, the browsing depth, etc. Further, the online server can update the network parameters of the first model according to the user satisfaction indicators of the target page, thereby correcting the system bias learned by the first model during the training process.
[0075] On the basis of the above-mentioned embodiments, one target multimedia is selected from the target multimedia that is not selected each time, including the following steps as shown in Figure 8
[0076] S801, updating the previous corresponding hidden vector according to the previous selected target multimedia and the page region corresponding to the previous selected target multimedia, to obtain the current corresponding hidden vector.
[0077] As shown in Figure 10 The internal structure and processing flow of the first model as described above are shown in, for example, the first network can include an encoder and a decoder. The encoder can encode each candidate content in the set of content candidates and each candidate position in the candidate positions.Figure 5 The set of multiple page regions in the page space shown can be as follows: Figure 10 The page shown contains a set of candidate positions, with each page region representing a candidate position. The decoder can progressively select candidate content and its corresponding placement position within the target page. For example, the decoder selects one candidate piece of content and its placement position at a time, and the previous layout influences the current layout.
[0078] like Figure 10 As shown, the encoder can be a self-attention neural network, and the content candidate set can be denoted as... 'n' represents the total number of candidate contents included in the candidate content set. Here, we use n=3 as an example for illustration. For instance, X1, X2, and X3 are three different candidate contents. After X1, X2, and X3 pass through a self-attention network, the self-attention network can output latent vectors corresponding to X1, X2, and X3 respectively. For example, the latent vector of X1 can specifically be its representation vector, feature vector, or expression vector. Further, the latent vector of X1 output by the self-attention network is superimposed with X1, and then the superimposed result is normalized to obtain the normalized latent vector of X1. Alternatively, the latent vector of X1 output by the self-attention network is normalized, and then the normalized result is superimposed with X1 to obtain the normalized latent vector of X1. Similarly, the normalized latent vectors of X2 and X3 can be obtained. The normalized latent vector of X1 is denoted as... The normalized implicit vector of X2 is denoted as The normalized implicit vector of X3 is denoted as
[0079] In addition, such as Figure 10 As shown, the set of candidate locations on the page is denoted as... k represents the total number of candidate positions included in the candidate position set; here, k=3 is used as an example for illustration. For example, Z1, Z2, and Z3 represent three different candidate positions, which can also be denoted as candidate regions or page regions. After passing through a self-attention network and undergoing normalization, Z1, Z2, and Z3 can be processed to obtain their corresponding normalized latent vectors. This process is similar to the calculation of normalized latent vectors described above, and will not be elaborated further. For example, the normalized latent vector corresponding to Z1 is denoted as... The normalized implicit vector corresponding to Z2 is denoted as: The normalized implicit vector corresponding to Z3 is denoted as:
[0080] Figure 10The decoder shown can perform the iterative process described above. For example, this embodiment can have a pre-set learnable initial input vector set. After encoding, the latent vector h can be obtained. 1 latent vector h 1 This can be denoted as the latent vector corresponding to the first iteration, and then the attention mechanism A is used to calculate h. 1 The weight value (attention) between h and each candidate content can be denoted as the first weight value. 1 The weight value between the candidate content X1 and h is based on h. 1 and the normalized latent vector of candidate content X1 Calculated. Similarly, h 1 The weight value between the candidate content X2 and h is based on h 1 Normalized latent vectors of candidate content X2 Calculated. h 1 The weight value between h and candidate content X3 is based on h 1 Normalized latent vectors of candidate content X3 Calculated.
[0081] Furthermore, according to h 1 The weight values between each candidate content are used to select the candidate content with the largest weight value from candidates X1, X2, and X3 as the first selected candidate content. The method for selecting the largest weight value can be a greedy algorithm or beam search. For example, based on h... 1 Normalized latent vectors of candidate content X3 h was calculated 1 If the weight value between candidate X3 and candidate X4 is the largest, then candidate X3 will be selected as the first candidate. Therefore, if... Figure 10 shown It represents X3.
[0082] After determining the first selected candidate content, the placement position of that candidate content can be further determined. For example, attention mechanism B can be used to calculate h. 1 The weight value between each candidate position and the weight value can be denoted as the second weight value. Where h... 1 The weight values between candidate position Z1 and h are based on 1 and the normalized latent vector of candidate position Z1 Calculated. Similarly, h 1 The weight value between candidate position Z2 and h is based on 1 and the normalized latent vector of candidate position Z2 Calculated. h1 The weight value between candidate position Z3 and h is based on 1 and the normalized latent vector of candidate position Z3 Calculated. Further, based on h... 1 Based on the weight values between each candidate position, the candidate position with the largest weight value from candidate positions Z1, Z2, and Z3 is selected as the placement position of the first selected candidate content. For example, according to h 1 and The candidate with the largest calculated weight value is selected as the first candidate to be placed. Therefore, if... Figure 10 Z shown φ(1) Z1 represents the first candidate content selected. The first candidate content selected can be the content that the user is most interested in, and its placement can be the area or location where the user is most likely to focus.
[0083] In this embodiment, the first selected candidate content X3 can be denoted as the first target multimedia selected in historical time, and the candidate position Z1 can be denoted as the page area corresponding to the first target multimedia in the target page. Latent vector h 1 It can also be denoted as the historical latent vector. Furthermore, based on X3 and Z1, h can be... 1 The update is performed to obtain the updated latent vector, which is, for example, like this: Figure 10 h shown 2 .For example Figure 10 As shown, according to h 1 , Z φ(1) h was calculated 2 h 2 This can be denoted as the latent vector corresponding to the second iteration. In other words, h 1 It can be denoted as the implicit vector corresponding to the previous one, h 2 This can be denoted as the latent vector corresponding to this instance.
[0084] S802. Calculate the first weight value between the hidden vector corresponding to this time and each of the multiple target multimedia that was not selected.
[0085] For example, after candidate X3 is selected, the remaining candidate contents are X1 and X2, and h can be further calculated. 2 The first weight values between X1 and X2 respectively.
[0086] S803. Select the target multimedia with the largest first weight value as the target multimedia for this selection.
[0087] For example, the candidate content with the largest first weight value in X1 and X2 is selected as the second selected candidate content. The second selected candidate content can be denoted as a second target multimedia.
[0088] Optionally, the page region corresponding to the target multimedia selected each time is determined, including Figure 9 The steps are shown as follows:
[0089] S901, calculating second weight values between the current corresponding hidden vector and each of the remaining page regions in the page space.
[0090] For example, after the candidate position Z1 is selected, the remaining candidate positions are Z2 and Z3, and further, the second weight values between h 2 and Z2 and Z3 respectively can be calculated.
[0091] S902, taking the page region corresponding to the largest second weight value as the page region corresponding to the target multimedia selected this time.
[0092] For example, the candidate position with the largest second weight value in Z2 and Z3 is selected as the placement position of the second selected candidate content, i.e., the page region corresponding to the second target multimedia in the target page.
[0093] For example Figure 10 The steps are shown as follows: The second selected candidate content is denoted as Z φ(2) The placement position of the second selected candidate content is denoted as Z Z φ(2) The h 2 may be updated to obtain an updated hidden vector h 3 , so that the above process is repeated until all the candidate contents are selected and all the candidate contents correspond to the corresponding placement positions. Further, according to each of the selected candidate contents and the placement position corresponding to each of the candidate contents, the target page is determined. In addition, the target page can be displayed to the user.
[0094] The page layout method provided in the embodiment is different from the traditional list-type page layout in that the page layout method provided in the embodiment can simultaneously select the candidate content and the placement position of the candidate content in the target page, so that the browsing mode of the user, such as focusing on the middle region and jumping browsing, can be adaptively learned. However, the traditional list-type page layout only selects the candidate content and then places it according to a certain preset rule, such as from top to bottom, without considering the complex relationship between the placement positions and the human-computer interaction. In addition, the page layout method described in the embodiment does not need to be arranged according toFigure 1 The prior art shown selects candidate content through the latent vector corresponding to each region, because if the latent vector corresponding to each region is not calculated accurately, the candidate content selected in each region will not meet the user's demand, ultimately resulting in an unreasonable page layout. The embodiment directly selects the candidate content corresponding to the maximum weight value by calculating the weight value between the latent vector and each candidate content through the attention mechanism, thereby reducing the selection error of the candidate content.
[0095] In addition, the page layout method provided by the embodiment has an advantage of breaking through the assumption of user habits, and designing an end-to-end page layout solution for the diversity of content from different sources and page regions. Because the candidate content ranked at the top position is not necessarily closest to the user, and the user's browsing mode is diverse and complex. The embodiment fully considers the possibility of different user habits. By simultaneously selecting the candidate content and the placement position, the page layout is gradually generated to generate a page layout that meets the maximum satisfaction of the user.
[0096] It can be understood that the page layout method described in the embodiment can also be applied to the layout design of chip circuit boards and the three-dimensional space structure design when synthesizing medical molecules after simple changes, that is, the page layout method similar to the embodiment has wide applicability.
[0097] The use stage or inference stage of the first model is introduced above, and the training process of the first model is introduced below. Specifically, the machine learning model is obtained by training through the following steps as shown in the following steps: Figure 11
[0098] S1101, multiple sample multimedia and multiple page regions are taken as inputs of the machine learning model, one sample multimedia is selected from the sample multimedia not selected in the multiple sample multimedia each time through the machine learning model, and the page region corresponding to the selected sample multimedia each time is determined.
[0099] For example, the network parameters of the first model can be initialized in a supervised pre-training manner. The specific process of initialization can be: one or more sample multimedia in the training sample and the division information of the region in the sample page, that is, the multiple page regions in the sample page, are taken as inputs of the first model to be trained, and the page layout output by the first model is required to be consistent with the page layout in the training sample. Using this supervised pre-training manner can accelerate the training process of the first model, while avoiding the first model converging to a local optimal solution.
[0100] After initialization, the first model is formally trained. For example, one or more multimedia samples from the training samples, as well as multiple page regions from the sample pages, are used as inputs to the first model to be trained. This allows the first model to gradually select multimedia samples using the iterative process described above, and determine the corresponding page region, i.e., the placement position, of each selected multimedia sample on the sample page.
[0101] S1102. Generate a sample page based on the selected sample multimedia each time and the page area corresponding to the selected sample multimedia each time.
[0102] In the process of continuously selecting sample multimedia, when multiple page areas in the sample page correspond to sample multimedia, the corresponding sample multimedia is added to each page area to generate a sample page.
[0103] S1103. Train the machine learning model based on the evaluation information of the evaluator for the sample page.
[0104] The sample page is fed into the second model, namely the evaluator described above. This evaluator can be referred to as the layout evaluator or the page evaluator. The second model can evaluate the sample page and obtain the first evaluation information. For example... Figure 5 As shown, assuming Figure 5 The page layout shown is the sample page. When this sample page is input into the evaluator, the evaluator can evaluate the sample page and obtain evaluation information, which can be recorded as the first evaluation information.
[0105] For example Figure 5 As shown, the evaluation information generated by this evaluator can be used to optimize the page layout algorithm, that is, to optimize the network parameters of the first model. The corresponding optimization algorithm can employ proximal-policy-optimization (PPO). Specifically, the first evaluation information can be used as a reward to calculate the optimization direction of the network parameters. This optimization direction can also be constrained; for example, by controlling that the jump between this optimization direction and the original optimizer policy distribution is not too large. In other words, by constraining the optimization direction, the network parameters of the first model can be smoothly transitioned without any abrupt changes.
[0106] Furthermore, in the process of optimizing the network parameters of the first model, in order to ensure that the distribution of the sample pages generated by the first model is as consistent as possible with the distribution of the page layout in the training samples, the evaluator can learn a discriminant function. This discriminant function can determine whether the distribution of the sample pages generated by the first model is consistent with the distribution of the page layout in the training samples. The discriminant result obtained by this discriminant function can be used as a regularization term to constrain the network parameters of the first model.
[0107] The embodiment obtains evaluation information by evaluating the sample page generated by the first model by the evaluator, further optimizes the network parameters of the first model using the evaluation information, and improves the convergence speed of the network parameters of the first model. In addition, the approximate strategy optimization algorithm is used in the optimization process to ensure that the network parameters of the first model remain within a reliable range during each update process. In addition, the network parameters of the first model are initialized in a pre-training manner, which can further improve the convergence speed of the network parameters of the first model. In addition, the embodiment models the influence relationship between global candidate contents, and the sample page is also generated step by step, so that the influence of the content browsed first by the user on the subsequent content can be modeled. Therefore, the target page generated by the first model after training meets the different browsing habits of users.
[0108] It can be understood that, in the process of training the first model, the process of the second model evaluating the sample page generated by the first model can be the use stage or inference stage of the second model. The specific process of the second model evaluating the sample page is introduced as follows. Figure 12 As shown in FIG. 3, the first model outputs a sample page in the training stage, and the sample page includes each sample multimedia selected by the first model and the placement position of each sample multimedia. For example, taking three sample multimedia as an example, M1 represents the result after splicing the features of sample multimedia 1 and its placement position, M2 represents the result after splicing the features of sample multimedia 2 and its placement position, and M3 represents the result after splicing the features of sample multimedia 3 and its placement position. Further, M1, M2 and M3 are input into a self-attention network, the self-attention network can output the representation vectors corresponding to M1, M2 and M3 respectively, and the representation vectors corresponding to M1, M2 and M3 output by the self-attention network are normalized to obtain the normalized representation vectors corresponding to M1, M2 and M3 respectively. Further, the normalized representation vector corresponding to M1 is superimposed with the original feature (for example, M1) after residual connection to obtain the final hidden vector 1. Similarly, the normalized representation vector corresponding to M2 is superimposed with the original feature (for example, M2) after residual connection to obtain the final hidden vector 2. The normalized representation vector corresponding to M3 is superimposed with the original feature (for example, M3) after residual connection to obtain the final hidden vector 3. Further, the final hidden vector 1, the final hidden vector 2 and the final hidden vector 3 are processed by a full connection layer to obtain three numerical values, for example, Figure 12The three values are added to obtain a final output value, which can be a value between 0 and 1. The closer the value is to 1, the better the layout of the sample page, and vice versa. That is, the output value can be used as evaluation information for evaluating the sample page. The goodness of the sample page can be reflected in many aspects, for example, the content of interest of the user is placed in the area where the user is easy to notice, and the content in each area of the sample page shows diversity and certain relevance. In addition, the second model can also evaluate the target page generated by the first model. The specific evaluation process can be similar to the evaluation process of the sample page by the second model.
[0109] It can be understood that in other embodiments, after the self-attention network outputs the representation vectors corresponding to M1, M2 and M3, the representation vector corresponding to M1 can be superimposed with the input (for example, M1) after residual connection to obtain superimposition result 1, the representation vector corresponding to M2 can be superimposed with the input (for example, M2) after residual connection to obtain superimposition result 2, and the representation vector corresponding to M3 can be superimposed with the input (for example, M3) after residual connection to obtain superimposition result 3. Further, the superimposition results 1, 2 and 3 are normalized respectively, and then the normalized results are input into the fully connected layer.
[0110] The second model, i.e., the evaluator, is set in this embodiment, so that the evaluator can evaluate the sample page generated by the first model in the training stage, guide the training of the first model, reduce the variance of the first model, accelerate the convergence of the network parameters of the first model, and improve the robustness of the first model.
[0111] The training process of the second model will be introduced below. Specifically, the evaluator is trained by the following steps as shown in Figure 13
[0112] S1301, input the historical page into the evaluator to obtain evaluation information of the evaluator for the historical page.
[0113] Specifically, the sample data for training the second model can be historical pages and user evaluation information corresponding to the historical pages. The number of historical pages is not limited herein, and for example, can be multiple. Therefore, the multiple historical pages can correspond to user evaluation information respectively, i.e., the user evaluation information is also multiple. Any historical page and the user evaluation information corresponding to the historical page can constitute a group of sample data. Multiple groups of sample data can train a second model with generalization, so that the sample page output by the first model can be evaluated by the second model, and the first model has the characteristics of low variance and high robustness. It can be understood that different sample data can be collected for different application scenarios. For example, taking a search engine as an example, the collected sample data can include a two-dimensional page layout displayed to a user and a user satisfaction index, denoted as historical page and user evaluation information. The user satisfaction index can be the number of times the user clicks the two-dimensional page layout, the number of purchased goods after clicking, the browsing time, the browsing depth, and the like.
[0114] For example, taking a group of sample data as an example, the historical page in the sample data can be input to the second model, and the second model evaluates the historical page to obtain second evaluation information. Specifically, the process of the second model evaluating the historical page can refer to the process of the second model evaluating the sample page, which will not be described herein. In order to distinguish the evaluation results, i.e., evaluation information, the evaluation information obtained after the second model evaluates the sample page can be denoted as first evaluation information, and the evaluation information obtained after the second model evaluates the historical page can be denoted as second evaluation information.
[0115] S1302, training the evaluator according to the user evaluation information corresponding to the historical page and the evaluation information of the evaluator on the historical page.
[0116] For example, according to the user evaluation information corresponding to the historical page and the second evaluation information, a loss function is calculated, and then the network parameters of the second model are optimized according to the loss function, i.e., the second model is trained. In some embodiments, the final second model can be learned through supervised learning and stochastic gradient descent method.
[0117] In some embodiments, in the training process of the second model, the historical page as described above can be a historical page generated by the first model, or can be a historical page collected in advance and not generated by the first model. When the historical page is generated by the first model, the training process of the second model can be as follows: Figure 14The first model can generate a historical page and display the historical page to the user to obtain an overall evaluation of the historical page by the user, i.e., a user evaluation. Further, the historical page and the user evaluation can be used as sample data for training a second model, i.e., an evaluator. The specific training process is as described above, and will not be described here again. When the evaluator is trained, the evaluator can guide the first model to learn or optimize, so that the first model after learning or optimization can output a target page that maximizes the user satisfaction.
[0118] Figure 15 A structural schematic diagram of a page layout apparatus provided by an embodiment of the present disclosure is shown. The page layout apparatus provided by the embodiment of the present disclosure can perform the processing flow provided by the page layout method embodiment, as shown in Figure 15 The page layout apparatus 150 includes the following components, as shown in
[0119] The acquisition module 151 is configured to acquire a plurality of target multimedia.
[0120] The generation module 152 is configured to generate a target page according to the plurality of target multimedia and a plurality of page regions in a page space of a preset size, the target page including the plurality of page regions, and each page region in the target page including one target multimedia.
[0121] Optionally, the page layout apparatus 150 further includes an updating module 153. The updating module 153 is configured to update the target page according to evaluation information of the target page by an evaluator after the generation module 152 generates the target page according to the plurality of target multimedia and the plurality of page regions in the page space of the preset size.
[0122] Optionally, when the generation module 152 generates the target page according to the plurality of target multimedia and the plurality of page regions in the page space of the preset size, the generation module 152 is specifically configured to:
[0123] select one target multimedia from the target multimedia that is not selected each time, and determine a page region corresponding to the target multimedia selected each time, wherein the target multimedia selected last time and the page region corresponding to the target multimedia selected last time affect the target multimedia selected this time and the page region corresponding to the target multimedia selected this time.
[0124] generate the target page according to the target multimedia selected each time and the page region corresponding to the target multimedia selected each time, wherein the target multimedia selected each time is different, and different target multimedia corresponds to different page regions.
[0125] Optionally, the number of the plurality of target multimedia is greater than or equal to the number of the plurality of page regions; the generating module 152 is further configured to: when the number of the plurality of target multimedia is greater than the number of the plurality of page regions, if the number of the selected target multimedia is equal to the number of the plurality of page regions, stop selecting.
[0126] Optionally, the generating module 152 comprises an updating unit 1521, a calculating unit 1522 and a selecting unit 1523, wherein the updating unit 1521 is configured to update the previous corresponding hidden vector according to the previous selected target multimedia and the page region corresponding to the previous selected target multimedia, to obtain a current corresponding hidden vector; the calculating unit 1522 is configured to calculate a first weight value between the current corresponding hidden vector and each target multimedia that has not been selected from the plurality of target multimedia; and the selecting unit 1523 is configured to select the target multimedia corresponding to the maximum first weight value as the current selected target multimedia.
[0127] Optionally, the calculating unit 1522 is further configured to calculate a second weight value between the current corresponding hidden vector and each page region remaining in the page space; and the selecting unit 1523 is configured to select the page region corresponding to the maximum second weight value as the page region corresponding to the current selected target multimedia.
[0128] Optionally, the generating module 152 selects one target multimedia at a time from the target multimedia that has not been selected from the plurality of target multimedia, and determines the page region corresponding to the selected target multimedia, and is specifically configured to:
[0129] The plurality of target multimedia and the plurality of page regions are used as inputs of a machine learning model, and one target multimedia is selected at a time from the target multimedia that has not been selected from the plurality of target multimedia, and the page region corresponding to the selected target multimedia is determined by the machine learning model.
[0130] Optionally, the machine learning model is obtained by the following steps:
[0131] A plurality of sample multimedia and a plurality of page regions are used as inputs of the machine learning model, and one sample multimedia is selected at a time from the sample multimedia that has not been selected from the plurality of sample multimedia, and the page region corresponding to the selected sample multimedia is determined by the machine learning model.
[0132] A sample page is generated according to the selected sample multimedia and the page region corresponding to the selected sample multimedia.
[0133] The machine learning model is trained according to the evaluation information of the sample page by an evaluator.
[0134] Optionally, the evaluator is trained by the following steps:
[0135] inputting the historical page into the evaluator to obtain evaluation information of the historical page by the evaluator;
[0136] training the evaluator according to the user evaluation information corresponding to the historical page and the evaluation information of the historical page by the evaluator.
[0137] Figure 15 The page layout apparatus of the embodiments can be used to implement the technical solutions of the method embodiments, and has similar implementation principles and technical effects, which will not be described here.
[0138] The internal functions and structures of the page layout apparatus are described above, and the apparatus can be implemented as an electronic device. Figure 16 The structural schematic diagram of an electronic device embodiment provided by the embodiments of the present disclosure is shown in FIG. 16. Figure 16 As shown in the figure, the electronic device includes a memory 161 and a processor 162.
[0139] The memory 161 is used to store programs. In addition to the above programs, the memory 161 can also be configured to store various other data to support operations on the electronic device. Examples of these data include instructions for any application or method operating on the electronic device, contact data, phonebook data, messages, pictures, videos, etc.
[0140] The memory 161 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.
[0141] The processor 162 is coupled to the memory 161 and executes the programs stored in the memory 161 to:
[0142] obtain a plurality of target multimedia;
[0143] generate a target page according to the plurality of target multimedia and a plurality of page regions in a page space of a preset size, the target page including the plurality of page regions, and each page region in the target page including one target multimedia.
[0144] Further, as shown in the figure, the electronic device can further include a communication component 163, a power supply component 164, an audio component 165, a display 166, and other components. Figure 16 Further, as shown in the figure, the electronic device can further include a communication component 163, a power supply component 164, an audio component 165, a display 166, and other components.Figure 16 The components are merely illustrative, which does not mean the electronic device only includes the components. Figure 16 The components are merely illustrative, which does not mean the electronic device only includes the components.
[0145] The communication component 163 is configured to facilitate wired or wireless communication between the electronic device and other devices. The electronic device can access a wireless network based on a communication standard, such as WiFi, 2G, or 3G, or a combination thereof. In an exemplary embodiment, the communication component 163 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 163 further includes a Near Field Communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.
[0146] The power component 164 provides power to the various components of the electronic device. The power component 164 can include a power management system, one or more power sources, and other components associated with generating, managing, and distributing power to the electronic device.
[0147] The audio component 165 is configured to output and / or input audio signals. For example, the audio component 165 includes a microphone (MIC) that is configured to receive an external audio signal when the electronic device is in an operation mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signal can be further stored in the memory 161 or transmitted via the communication component 163. In some embodiments, the audio component 165 also includes a speaker for outputting audio signals.
[0148] The display 166 includes a screen, which can include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen can be implemented as a touch screen to receive an input signal from a user. The touch panel includes one or more touch sensors to sense a touch, a slide, and a gesture on the touch panel. The touch sensor can not only sense a boundary of a touching or sliding action, but also detect a duration and a pressure related to the touching or sliding action.
[0149] In addition, the embodiments of the present disclosure further provide a computer-readable storage medium, which stores a computer program executed by a processor to implement the page layout method described in the above embodiments.
[0150] It should be noted that, in this document, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0151] The above description is merely a specific embodiment of this disclosure, enabling those skilled in the art to understand or implement it. 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 this disclosure. Therefore, this disclosure is not to be limited to the embodiments described herein, but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A page layout method, wherein, The method includes: Acquire multiple target multimedia files; A target page is generated based on the plurality of target multimedia and multiple page regions in a preset-size page space. The target page includes the plurality of page regions, and each page region in the target page includes a target multimedia. Based on the multiple target multimedia resources and multiple page regions within a preset-sized page space, a target page is generated, including: Following the order of decreasing interest, one target multimedia is selected from the unselected target multimedia in the plurality of target multimedia at a time, including: updating the latent vector corresponding to the previously selected target multimedia and the page area corresponding to the previously selected target multimedia to obtain the current latent vector; calculating the first weight value between the current latent vector and each unselected target multimedia in the plurality of target multimedia; and selecting the target multimedia with the largest first weight value as the current selected target multimedia. In descending order of interest, a page region corresponding to the target multimedia is determined from the remaining page regions of the plurality of page regions for each selection; The target page is generated based on the selected target multimedia and the corresponding page area for each selected target multimedia.
2. The method according to claim 1, wherein, After generating the target page based on the multiple target multimedia and multiple page regions within a preset-sized page space, the method further includes: The target page is updated based on the evaluator's evaluation information.
3. The method according to claim 1, wherein, The number of the plurality of target multimedia elements is greater than or equal to the number of the plurality of page regions; the method further includes: When the number of target multimedia objects is greater than the number of page regions, if the number of selected target multimedia objects is equal to the number of page regions, then selection stops.
4. The method according to claim 1, wherein, The page areas corresponding to the target multimedia selected each time are determined in descending order of interest, including: Calculate the second weight value between the implicit vector corresponding to this time and each remaining page region in the page space; The page area corresponding to the largest second weight value is taken as the page area corresponding to the target multimedia selected in this instance.
5. The method according to claim 1, wherein, Selecting one target multimedia from the unselected target multimedia from the plurality of target multimedia at a time, and determining the page area corresponding to the selected target multimedia at each time, includes: The multiple target multimedias and the multiple page regions are used as input to a machine learning model. The machine learning model selects one target multimedia from the multiple target multimedias that have not been selected, and determines the page region corresponding to each selected target multimedia.
6. The method according to claim 5, wherein, The machine learning model was trained through the following steps: Multiple sample multimedias and multiple page regions are used as inputs to the machine learning model. The machine learning model selects one sample multimedia from the unselected sample multimedias at a time and determines the page region corresponding to the selected sample multimedia at each time. A sample page is generated based on the selected sample multimedia and the corresponding page area of the selected sample multimedia each time. The machine learning model is trained based on the evaluator's evaluation information of the sample page.
7. The method according to claim 6, wherein, The evaluator is trained through the following steps: Input the historical page into the evaluator to obtain the evaluator's evaluation information for the historical page; The evaluator is trained based on the user review information corresponding to the historical pages and the evaluator's evaluation information of the historical pages.
8. A page layout device, wherein, include: The acquisition module is used to acquire multiple target multimedia files. The generation module is used to generate a target page based on the plurality of target multimedia and a plurality of page regions in a page space of a preset size. The target page includes the plurality of page regions, and each page region in the target page includes a target multimedia. Based on the multiple target multimedia resources and multiple page regions within a preset-sized page space, a target page is generated, including: Following the order of decreasing interest, one target multimedia is selected from the unselected target multimedia in the plurality of target multimedia at a time, including: updating the latent vector corresponding to the previously selected target multimedia and the page area corresponding to the previously selected target multimedia to obtain the current latent vector; calculating the first weight value between the current latent vector and each unselected target multimedia in the plurality of target multimedia; and selecting the target multimedia with the largest first weight value as the current selected target multimedia. In descending order of interest, a page region corresponding to the target multimedia is determined from the remaining page regions of the plurality of page regions for each selection; The target page is generated based on the selected target multimedia and the corresponding page area for each selected target multimedia.
9. An electronic device, wherein, include: Memory; processor; as well as Computer programs; The computer program is stored in the memory and configured to be executed by the processor to implement the method as described in any one of claims 1-7.
10. A computer-readable storage medium having a computer program stored thereon, wherein, When the computer program is executed by a processor, it implements the method as described in any one of claims 1-7.
Citation Information
Patent Citations
Page processing method and mobile terminal
CN109840114A
Page generation method and device
CN110941784A
Page generation method and device, equipment and medium
CN113608737A