Page conversion method and device and storage medium
Through the analysis of the conversion page structure and parallel conversion module methods, the problem of inefficient conversion of PC-side pages to mobile-side pages is solved, and efficient page conversion is achieved.
Patent Information
- Application Number
- CN202310808725.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-07-03
- Publication Date
- 2025-01-03
AI Technical Summary
When converting PC pages to mobile pages, the prior art needs to rely on information such as the layout and area length of the previous module, resulting in low page conversion efficiency.
By analyzing the page to be converted, the target page structure is obtained, and multiple modules to be converted are converted in parallel to build the target page, avoiding dependence on the layout of the previous module.
The efficiency of page conversion is improved, so that multiple modules to be converted can be converted in parallel, and the conversion efficiency of the target page is improved.
Smart Images

Figure CN119248271A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of network technology, and in particular to a page conversion method and device, and a storage medium. Background Art
[0002] In the display of various web pages, when the same page content is displayed on a personal computer (PC), it is necessary to use the PC-side modules and templates to generate the PC-side page, and when it is displayed on a mobile phone, it is necessary to use the mobile-side modules and templates to generate the mobile-side page. In the case of promoting the page content, the PC-side page needs to be directly converted into a mobile phone page.
[0003] In the related art, in the process of converting the current module on the PC side into the module on the mobile side, it is necessary to determine the layout of the previous module of the current module and the area length and other information, and determine the layout of the current module based on the layout and area length and other information of the previous module. In this way, the modules on the PC side are converted one by one, thereby reducing the conversion efficiency of the page. Summary of the invention
[0004] In order to solve the above technical problems, the embodiments of the present application hope to provide a page conversion method and device, and a storage medium, which can improve the efficiency of page conversion.
[0005] The technical solution of this application is implemented as follows:
[0006] The present application provides a page conversion method, which includes:
[0007] Get the page to be converted;
[0008] Performing page structure analysis on the page to be converted to obtain a target page structure;
[0009] Converting multiple modules to be converted in the target page structure in parallel to obtain multiple target modules; the multiple modules to be converted are modules in the page to be converted;
[0010] A target page is constructed according to the multiple target modules.
[0011] The present application provides a page conversion device, the device comprising:
[0012] An acquisition unit, used for acquiring a page to be converted;
[0013] An analysis unit, used for performing page structure analysis on the page to be converted to obtain a target page structure;
[0014] A conversion unit, used for converting a plurality of modules to be converted in the target page structure in parallel to obtain a plurality of target modules; the plurality of modules to be converted are modules in the page to be converted;
[0015] A building unit is used to build a target page according to the multiple target modules.
[0016] The present application provides a page conversion device, the device comprising:
[0017] A memory, a processor and a communication bus, wherein the memory communicates with the processor via the communication bus, and the memory stores a page conversion program executable by the processor. When the page conversion program is executed, the page conversion method described above is executed by the processor.
[0018] An embodiment of the present application provides a storage medium on which a computer program is stored, which is applied to a page conversion device, and is characterized in that when the computer program is executed by a processor, the above-mentioned page conversion method is implemented.
[0019] The embodiment of the present application provides a page conversion method and device, and a storage medium. The page conversion method includes: obtaining a page to be converted; performing a page structure analysis on the page to be converted to obtain a target page structure; performing parallel conversion on multiple modules to be converted in the target page structure to obtain multiple target modules; multiple modules to be converted are modules in the page to be converted; and constructing a target page according to multiple target modules. The above method is adopted to implement the scheme. The page conversion device performs a page structure analysis on the page to be converted to obtain a target page structure. The target page structure is the layout structure of the target module in the target page, that is, the layout structure of the target module in the target page has been determined, so that multiple modules to be converted in the target page structure can be converted in parallel, and there is no need to determine the layout of the current module based on the layout of the previous module and the information such as the length of the area, and multiple modules to be converted are converted at the same time, thereby improving the conversion efficiency of the target page. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] Figure 1 A flow chart of a page conversion method provided in an embodiment of the present application;
[0021] Figure 2 An exemplary page conversion block diagram provided for an embodiment of the present application;
[0022] Figure 3 A schematic diagram of an exemplary web page provided in an embodiment of the present application;
[0023] Figure 4 A schematic diagram of an exemplary module group conversion method provided in an embodiment of the present application;
[0024] Figure 5 A schematic diagram of the structure of a page conversion device provided in an embodiment of the present application Figure 1 ;
[0025] Figure 6 A schematic diagram of the structure of a page conversion device provided in an embodiment of the present application Figure 2 . DETAILED DESCRIPTION
[0026] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. It should be understood that the specific embodiments described here are only used to explain the present application and are not used to limit the present application.
[0027] The present application embodiment provides a page conversion method, which is applied to a page conversion device. Figure 1 A flow chart of a page conversion method provided in an embodiment of the present application is as follows: Figure 1 As shown, the page conversion method may include:
[0028] S101, obtaining a page to be converted.
[0029] A page conversion method provided in an embodiment of the present application is applicable to a scenario in which a page to be converted is converted into a target page.
[0030] In the embodiments of the present application, the page conversion device can be implemented in various forms. For example, the page conversion device described in the present application can include devices such as mobile phones, cameras, tablet computers, laptop computers, PDAs, portable media players (PMPs), navigation devices, wearable devices, smart bracelets, pedometers, and devices such as digital TVs, desktop computers, and servers.
[0031] In an embodiment of the present application, the page to be converted can be a page on the PC, such as a web page on the PC; it can also be a page on a tablet computer, or it can be a page on other devices. The specific page can be determined based on actual conditions, and the embodiment of the present application does not limit this.
[0032] In the embodiment of the present application, the number of pages to be converted can be one or more, and the specific number can be determined according to actual conditions, and the embodiment of the present application does not limit this.
[0033] It should be noted that if there are multiple pages to be converted, the page conversion method in the embodiment of the present application can be executed on the multiple pages to be converted respectively, so as to obtain multiple target pages.
[0034] It should also be noted that the page conversion method in the embodiment of the present application can be executed sequentially on multiple pages to be converted to obtain multiple target pages; the page conversion method in the embodiment of the present application can also be executed in parallel on multiple pages to be converted to obtain multiple target pages; the specific method can be determined based on actual conditions, and the embodiment of the present application is not limited to this.
[0035] In an embodiment of the present application, the page to be converted can be a page transmitted to the page conversion device by other devices, or it can be a page obtained by the page conversion device in other ways; the specific way in which the page conversion device obtains the page to be converted can be determined according to actual conditions, and the embodiment of the present application does not limit this.
[0036] S102: Analyze the page structure of the page to be converted to obtain the target page structure.
[0037] In the embodiment of the present application, after the page conversion device obtains the page to be converted, it can perform page structure analysis on the page to be converted to obtain the target page structure.
[0038] In an embodiment of the present application, a page conversion device performs page structure analysis on a page to be converted to obtain a target page structure, including: searching for a module group in the page to be converted; when a module group exists in the page to be converted, determining a first module other than the module group in the page to be converted, and using the module group as a second module; sorting the first module and the second module by hot spot distribution according to the hot spot distribution in the page to be converted to obtain a module sequence; and performing layout conversion analysis on the modules in the module sequence in turn to obtain a target page structure.
[0039] It should be noted that the number of module groups is at least one, and the specific number of module groups can be determined according to actual conditions, which is not limited in the embodiments of the present application.
[0040] It should be noted that the first module is a module that is not merged with other modules in the page to be converted, that is, the first module is a separate module.
[0041] In the embodiment of the present application, the number of first modules can be zero (ie, there is no first module), one, or multiple. The specific number of first modules can be determined based on actual conditions, and the embodiment of the present application does not limit this.
[0042] In an embodiment of the present application, the first module provides display content through a data source, and different first modules provide different content. For example, the carousel module provides pictures for carousel display, the text module is responsible for providing the text required for display, and the product module provides product information for display.
[0043] In the embodiment of the present application, the hotspot distribution is the distribution of the hotspots that the user is looking at in the page to be converted. Among them, in the web page on the PC side, the hotspots that the user is looking at are distributed in an E-type or F-type, and can also be distributed in other shapes. The specific shape can be determined according to the actual situation, and the embodiment of the present application is not limited by comparison.
[0044] In an embodiment of the present application, a page conversion device sequentially performs layout conversion analysis on modules in a module sequence to obtain a target page structure, including: determining layout parameters of a first module and a second module, a first size parameter of the first module, and a second size parameter of the second module; obtaining a preset module matching relationship, and using the preset module matching relationship and the first size parameter to determine a first target size parameter corresponding to the first target module; determining a second target size parameter corresponding to the second target module according to a module group conversion mode and a second size parameter; obtaining a target page size parameter, and determining a target page structure according to the target page size parameter, the layout parameter, the first target size parameter, and the second target size parameter.
[0045] In the embodiment of the present application, the first target module and the second target module constitute a plurality of target modules.
[0046] In an embodiment of the present application, the parameter layout includes a first parameter layout of the first module and a second parameter layout of the second module.
[0047] It should be noted that the parameter layout of the module includes parameters such as the overall pixel width of the module, the number of columns, and the pixel width of each column. That is, the first parameter layout includes parameters such as the first overall pixel width of the first module, the first number of columns, and the pixel width of each column; the second parameter layout includes parameters such as the second overall pixel width of the second module, the second number of columns, and the pixel width of each column.
[0048] It should be noted that each module consists of Block-level tags mark the parameter layout, that is, each module consists of The block-level tags include the parameter layout of each module.
[0049] In an embodiment of the present application, the preset module matching relationship can be a matching relationship configured in the page conversion device, or a matching relationship transmitted to the page conversion device from other devices, or a matching relationship obtained by the page conversion device in other ways. The specific way in which the page conversion device obtains the preset module matching relationship can be determined based on actual conditions, and the embodiment of the present application does not limit this.
[0050] In the embodiment of the present application, the preset module matching relationship may be a module matching relationship in the prior art, that is, the method of determining the first target size parameter by using the preset module matching relationship and the first size parameter is the prior art, and the specific embodiment of the present application will not be described in detail here.
[0051] In the embodiment of the present application, after the first target size parameter is determined, the first template can be determined according to the first target size parameter, wherein the first template is a filling style (or display style) of the first target module in the page of the target end.
[0052] In the embodiment of the present application, the module group conversion method can be a conversion method configured in the page conversion device, or a conversion method transmitted from other devices to the page conversion device, or a conversion method obtained by the page conversion device in other ways. The specific method can be determined based on actual conditions, and the embodiment of the present application does not limit this.
[0053] In the embodiment of the present application, after the second target size parameter is determined, the second template can be determined according to the second target size parameter, wherein the second template is the filling style (or display style) of the second target module in the page of the target end.
[0054] It should be noted that the first template and the second template constitute multiple templates.
[0055] It should be noted that the target end may be a mobile end, such as a mobile phone, or a display end of other types of electronic devices. The specific one may be determined based on actual conditions, and the embodiments of the present application do not limit this.
[0056] In the embodiment of the present application, the second size parameter corresponds to the number of second modules one by one, that is, one second module corresponds to one second size parameter. The first size parameter corresponds to the number of first modules one by one, that is, one first module corresponds to one first size parameter.
[0057] In an embodiment of the present application, the process of determining the target page structure based on the target page size parameters, layout parameters, first target size parameters, and second target size parameters can be determined based on the target page size parameters, layout parameters, first target size parameters, second target size parameters, a first template, and a second template.
[0058] In the embodiment of the present application, the target page structure may be a document object model (DOM) structure or other structures, which may be determined based on actual conditions and is not limited in the embodiment of the present application.
[0059] In an embodiment of the present application, the page conversion device determines the second target size parameter according to the module group conversion mode and the second size parameter, including: obtaining the width parameter of the second module from the second size parameter; when the parameter value of the width parameter is less than or equal to the preset parameter, scaling the second size parameter using the preset scaling factor to obtain the second target size parameter.
[0060] In the embodiment of the present application, the second module is a module group, and the width parameter of the second module is specifically the overall width of the module group.
[0061] In the embodiment of the present application, the number of second modules is the same as the number of width parameters, that is, one second module (one module group) corresponds to one width parameter. In the case of multiple second modules, the multiple width parameters are compared with the respective preset parameters to determine the second target size parameter.
[0062] In the embodiment of the present application, the preset parameters can be parameters configured by the page conversion device, or parameters transmitted to the page conversion device by other devices, or parameters obtained by the page conversion device in other ways. The specific way in which the page conversion device obtains the preset parameters can be determined based on actual conditions, and the embodiment of the present application does not limit this.
[0063] It should be noted that the preset parameter may be a width parameter of a device display terminal that displays the target page. For example, if the target page is displayed on a mobile phone, the product of the logical resolution of the mobile phone width*the width coefficient is the preset parameter.
[0064] Exemplarily, the width coefficient may be 1.5, or other coefficient values. The specific coefficient value may be determined based on actual conditions, and the embodiments of the present application do not limit this.
[0065] It should be noted that the logical resolution of the mobile phone width can be a value in the range of 325 to 500. The specific value can be determined according to actual conditions, and the embodiment of the present application does not limit this.
[0066] In the embodiment of the present application, the preset zoom factor may be a zoom factor corresponding to the adaptive zoom mode. If the target page is displayed on the mobile phone, the preset zoom factor may be determined according to the displayed page on the mobile phone.
[0067] In the embodiment of the present application, if the second module is a square module, each side of the square is scaled according to the preset scaling factor to obtain the size of the second target module at the target end, that is, to obtain the second target size parameter. If the second module is a rectangular module, each side of the rectangle is scaled according to the preset scaling factor to obtain the size of the second target module at the target end, that is, to obtain the second target size parameter.
[0068] Exemplarily, if the second module is a square module, the side length of the square is 10, and the preset scaling factor is 0.1, then each side of the square is scaled according to the preset scaling factor, and the side length of the second target module at the target end is 1, that is, the second target size is a square with a side length of 1.
[0069] In an embodiment of the present application, the logical resolution of the current mainstream mobile phone width (clientWidth) is generally 325 to 500. When the module group width (width parameter of the second module) is less than or equal to clientWidth*1.5 (scaling factor), the module group is adaptively scaled and displayed as a whole, which can fully and clearly display the entire module group, thereby generating a layout area for the overall display and binding the modules.
[0070] In an embodiment of the present application, after the page conversion device obtains the width parameter of the second module from the second size parameter, when the parameter value is greater than the preset parameter, the number of columns in the second module is determined; when the number value of the number of columns is an odd number less than or equal to the preset number value, the second size parameter is scaled using a preset scaling factor to obtain a second target size parameter; when the number value of the number of columns is an odd number greater than the preset number value, or the number value of the number of columns is an even number, the columns in the second module are grouped according to a preset grouping value to obtain a plurality of groups; a plurality of width values corresponding to the plurality of groups are obtained; and when a plurality of width values are less than or equal to the preset parameter, the plurality of groups are scaled using a preset scaling factor to obtain a second target size parameter; when a plurality of width values are greater than the preset parameter, each column in the second module is scaled using a preset scaling factor to obtain a second target size parameter.
[0071] In the embodiment of the present application, the number of columns is the number of columns occupied by the second module in the page to be converted.
[0072] It should be noted that, when the value of the number of columns is an odd number less than or equal to the preset value, the number of columns occupied by the second module in the page to be converted (i.e., the number of columns) is the same as the number of columns in the display page of the second target module on the target end. When the value of the number of columns is an odd number greater than the preset value or the value of the number of columns is an even number, and the width value corresponding to each group is greater than the preset parameter, the number of columns occupied by the second module in the page to be converted (i.e., the number of columns) is the same as the number of columns in the display page of the second target module on the target end.
[0073] In the embodiment of the present application, the preset quantity value can be 1, the preset quantity value can also be 3, and the preset quantity value can also be other numerical values. The specific preset quantity can be determined according to actual conditions, and the embodiment of the present application does not limit this.
[0074] In the embodiment of the present application, the preset grouping value may be 2 or other values. The specific value of the preset grouping value may be determined according to actual conditions, and the embodiment of the present application does not limit this.
[0075] In the embodiment of the present application, multiple groups correspond to multiple width values one by one, that is, one group corresponds to one width value. For example, if the number of columns is 5, the columns in the second module are grouped in pairs to obtain 3 groups (the first column and the second column are grouped into one group, the third column and the fourth column are grouped into one group, and the fifth column is a group); the 3 width values corresponding to the 3 groups can be determined respectively: the sum of the width of the first column and the width of the second column is determined to obtain the first width value; the sum of the width of the third column and the width of the fourth column is determined to obtain the second width value; the width value of the fifth column is determined to obtain the third width value. Exemplarily, if the number of columns is 5, the columns in the second module are grouped in pairs to obtain 3 groups (the first column and the second column are grouped together, the third column and the fourth column are grouped together, and the fifth column and the sixth column are grouped together); the three width values corresponding to the three groups can be determined respectively: the sum of the width of the first column and the width of the second column is determined to obtain the first width value; the sum of the width of the third column and the width of the fourth column is determined to obtain the second width value; the sum of the width of the fifth column and the width of the sixth column is determined to obtain the third width value.
[0076] In the embodiment of the present application, the multiple width values include a first width value and a second width value, the first width value is a width value less than or equal to a preset parameter, and the second width value is a width value greater than the preset parameter. The first group corresponding to the first width value is scaled using a preset scaling factor, and each column in the second group corresponding to the second width value is scaled using a preset scaling factor to obtain a second target size parameter.
[0077] In the embodiment of the present application, the module is too wide and the matching is dynamically calculated. That is, when the module group is too wide, it is necessary to display it in columns according to the odd and even numbers of the columns and the threshold of the modules.
[0078] When the number of columns is a small odd number: one column or three columns, each column is displayed exclusively on the mobile phone, and is displayed in adaptive scaling;
[0079] The number of columns is greater than or equal to the larger base of five columns: There are many columns, and the width of a single column is narrow. The threshold is the logical resolution of the phone width*1.5. When the width of two columns is less than or equal to the threshold, they are displayed in pairs, and the last column is exclusively adaptively scaled; if the width of two columns is greater than the threshold, a single column is adaptively scaled.
[0080] When the number of columns is even: the threshold is the logical resolution of the phone width*1.5. When the width of the two columns is less than or equal to the threshold, they are displayed in pairs. If the width of the two columns is greater than the threshold, the single column is adaptively scaled.
[0081] Generate a multi-column layout according to the above steps, and bind the corresponding relationship between the module and the layout;
[0082] The page conversion of the module group is carried out through the above two methods. The ordinary modules are matched according to the correspondence between the Web-end modules and the mobile-end modules. The correspondence is maintained in the background. Finally, the generation of the mobile-end page structure is completed through the above method.
[0083] For example, Figure 2 As shown:
[0084] S1. Determine layout parameters of a first module and a second module, a first size parameter of the first module, and a second size parameter of the second module.
[0085] S2. Obtain a preset module matching relationship, and use the preset module matching relationship and the first size parameter to determine a first target size parameter corresponding to the first target module.
[0086] S3. Obtain a width parameter of the second module from the second size parameter.
[0087] S4. When the parameter value of the width parameter is less than or equal to the preset parameter, the second size parameter is scaled using the preset scaling factor to obtain a second target size parameter.
[0088] S5. Obtain target page size parameters, and determine the target page structure according to the target page size parameters, layout parameters, the first target size parameters, and the second target size parameters.
[0089] S6. When the parameter value is greater than the preset parameter, determine the number of columns in the second module.
[0090] S7. When the value of the number of columns is an odd number less than or equal to the preset value, the second size parameter is scaled using a preset scaling factor to obtain a second target size parameter.
[0091] S8. When the number value of the number of columns is an odd number greater than the preset number value, or the number value of the number of columns is an even number, the columns in the second module are grouped according to the preset grouping value to obtain multiple groups.
[0092] S9, obtaining multiple width values corresponding to the multiple groups; and when the multiple width values are less than or equal to the preset parameter, scaling the multiple groups using the preset scaling coefficient to obtain a second target size parameter.
[0093] S10. When multiple width values are greater than preset parameters, each column in the second module is scaled using a preset scaling factor to obtain a second target size parameter.
[0094] In an embodiment of the present application, a page conversion device performs hotspot distribution sorting on the first module and the second module according to the hotspot distribution in the page to be converted to obtain a module sequence, including: determining the normalized probability of each pixel in the first module and the second module according to the hotspot distribution in the page to be converted; determining the first hotspot parameters of the first module and the second module according to the pixel area and position information of the first module and the second module; determining the second hotspot parameters of the first module and the second module according to the content information corresponding to the first module and the second module; determining the target hotspot parameters of the first module and the second module according to the normalized probability, the first hotspot parameter, and the second hotspot parameter; and sorting the first module and the second module according to the target hotspot parameters to obtain a module sequence.
[0095] It should be noted that the first module in the module sequence is the module with the largest corresponding first hotspot parameter value.
[0096] In an embodiment of the present application, by matching the hotspot distribution shape with the page to be converted, the hotspot distribution area in the page to be converted can be determined. The normalized probabilities corresponding to different pixel positions in the hotspot distribution area are different, that is, the normalized probability corresponding to the pixel is determined according to the position of the pixel.
[0097] It should be noted that the normalized probability of each pixel in the first module and the second module can be determined based on the correspondence between the position of the preset pixel point and the preset probability; it can also be determined in other ways according to the distribution of hot spots in the page to be converted; the specific method of determining the normalized probability of each pixel in the first module and the second module can be determined according to actual conditions, and the embodiments of the present application are not limited to this.
[0098] In the embodiment of the present application, the normalized probability includes a first probability corresponding to the first module and a second probability corresponding to the second module.
[0099] In an embodiment of the present application, the first hotspot parameter includes a first hotspot value corresponding to the first module and a second hotspot value corresponding to the second module. The first hotspot value is positively correlated with the sum of the pixel areas of each pixel of the first module and is positively correlated with the position information of the first module. The second hotspot value is positively correlated with the sum of the pixel areas of each pixel of the second module and is positively correlated with the position information of the second module.
[0100] In the embodiment of the present application, according to the pixel area and position information of the first module and the second module, the method of determining the first hotspot parameters of the first module and the second module can be determined according to actual conditions, and the embodiment of the present application is not limited to this.
[0101] In an embodiment of the present application, the second hotspot parameter includes a third hotspot value corresponding to the first module and a fourth hotspot value corresponding to the second module. The third hotspot value is determined according to the content of the first module, and the fourth hotspot value is determined according to the content of the second module. Exemplarily, the third hotspot value is a function of “the number of videos, pictures, the area occupied by the pictures, and the number of words in the first module”; the fourth hotspot value is a function of “the number of videos, pictures, the area occupied by the pictures, and the number of words in the second module”.
[0102] In the embodiment of the present application, according to the content information corresponding to the first module and the second module, the method of determining the second hotspot parameters of the first module and the second module can be determined according to actual conditions, and the embodiment of the present application does not limit this.
[0103] In an embodiment of the present application, a method for determining target hotspot parameters of the first module and the second module based on the normalized probability, the first hotspot parameter, and the second hotspot parameter includes: determining the first target parameter corresponding to the first module based on the first probability, the first hotspot value, and the third hotspot value of each pixel in the first module; determining the second target parameter corresponding to the second module based on the second probability, the second hotspot value, and the fourth hotspot value of each pixel in the second module.
[0104] In an embodiment of the present application, the first target parameter corresponding to the first module is determined based on the first probability, the first hotspot value, and the third hotspot value of each pixel in the first module, including: accumulating the first probability of each pixel in the first module to obtain a first accumulated value, determining the product of the first accumulated value, the first hotspot value, and the third hotspot value to obtain the first target parameter.
[0105] Exemplarily, the process of determining the first target parameter corresponding to the first module according to the first probability (h(x,y)), the first hotspot value (m), and the third hotspot value (t) of each pixel in the first module is as shown in formula (1):
[0106] h=m*t*∑ x,y是属于该模块的像素 h(x,y) (1)
[0107] Among them, ∑ x,y是属于该模块的像素 h(x, y) is the first accumulated value obtained by accumulating the first probability of each pixel in the first module. (x, y) is the horizontal and vertical coordinates of each pixel.
[0108] In an embodiment of the present application, the second target parameter corresponding to the second module is determined based on the second probability, the second hotspot value, and the fourth hotspot value of each pixel in the second module, including: accumulating the second probability of each pixel in the second module to obtain a second accumulated value, determining the product of the second accumulated value, the second hotspot value, and the fourth hotspot value to obtain the second target parameter.
[0109] In an embodiment of the present application, the process of sorting the first module and the second module according to the target hotspot parameter to obtain a module sequence includes: sorting the first module and the second module using the second target parameter and the first target parameter to obtain a module sequence.
[0110] In the embodiment of the present application, the hotspot distribution in the page to be converted can be determined by the hotspots that the user is watching being distributed in an E-type or an F-type. The hotspot distribution in the page to be converted can also be determined in other ways, which can be determined according to actual conditions, and the embodiment of the present application does not limit this.
[0111] In an embodiment of the present application, in the web page on the PC side (page to be converted), the hot spots that the user is looking at are distributed in E or F. In an embodiment of the present application, it is set as the prior of the E distribution, so according to the screen ratio, the statistics of the E distribution are mapped to the ratio of different screens. Then the normalized probability that each pixel can be assigned to this distribution is h(x, y). According to different modules, each module of the page has a normalized importance probability, which can be set manually. The importance of the pixels in this module is m (first hot spot parameter), and m is a function of area and position. According to different modules, each module of the page has a normalized importance probability, which is set manually. The importance of the pixels in this module is t (second hot spot parameter). The module is related to whether there is a video, the number of pictures, the area occupied by the pictures, and the amount of text, and is determined by artificially set rules. Then the importance of a module on the PC side page can be expressed as h=m*t*∑ x,y是属于该模块的像素 h(x,y). According to the importance h (target hotspot parameter), sort each module in reverse order, from high to low importance.
[0112] In the embodiment of the present application, a method for analyzing and converting module priorities based on web page viewpoint hotspots is proposed. First, the module group is determined and merged. In the overall page, the module priority is calculated and sorted according to the user's access habits, and the sorting priority of the page module is generated.
[0113] It can be understood that in the embodiment of the present application, the page module priority analysis and sorting are performed according to the user's visual hot spots to ensure a better user experience of the converted page.
[0114] In an embodiment of the present application, a process in which a page conversion device searches for a module group in a page to be converted includes: when there are at least two initial modules of the same template in the page to be converted, determining whether the at least two initial modules are aligned; when the at least two initial modules are aligned, merging the at least two initial modules to obtain at least one initial module group; when the number of at least one initial module group is multiple, determining whether the multiple initial module groups are aligned; when the multiple initial module groups are aligned, merging the multiple initial module groups to obtain a merged initial module group; when the merged initial module groups are no longer aligned, or the number of the merged initial module groups is one, using the merged initial module group as the module group.
[0115] In the embodiment of the present application, when some of the initial modules in at least two initial modules are aligned, the some initial modules are merged to obtain at least one initial module group.
[0116] In the embodiment of the present application, when some module groups in a plurality of initial module groups are aligned, the some module groups are merged to obtain a merged initial module group.
[0117] It is understandable that the embodiment of the present application analyzes the page structure, determines the module groups in the page, and merges the module groups. The elements in the module group should be presented in the same or continuous layout after being converted to the mobile terminal. The present application proposes a module group judgment, merging, and conversion scheme to better meet the presentation effect of the mobile terminal page.
[0118] In an embodiment of the present application, the process of the page conversion device determining whether at least two initial modules are aligned includes: determining that the upper edges and lower edges of at least two initial modules are aligned; or, determining that the upper edges and right edges of at least two initial modules are aligned.
[0119] In an embodiment of the present application, the process of the page conversion device determining whether multiple initial module groups are aligned includes: determining that the upper edges of multiple initial module groups are aligned, the lower edges of multiple initial module groups are aligned, and the center points of multiple initial module groups are aligned; or, determining that the left edges of multiple initial module groups are aligned, the right edges of multiple initial module groups are aligned, and the center points of multiple initial module groups are aligned.
[0120] In the embodiment of the present application, after the page conversion device merges at least two initial modules to obtain at least one initial module group, if the number of the at least one initial module group is one, the at least one initial module group is used as a module group.
[0121] In the embodiment of the present application, for the modules appearing in the page (the page to be converted), it is determined whether there are modules with the same template. For each module with the same template, it is determined whether there is one of the following situations:
[0122] (1) Horizontally, the upper and lower edges are aligned;
[0123] (2) Vertically, the left and right edges are aligned;
[0124] If the above situation exists, merge them into one template group. Then, for the template groups merged above, determine whether one of the following situations exists between each pair:
[0125] (1) Horizontally, the upper edge, lower edge or middle are aligned;
[0126] (2) Vertically, the left edge, right edge or center are aligned;
[0127] If the above situation exists, the two template groups are merged into a new template group again. After the merger, the above steps need to be repeated until the merger is completed without the above situation.
[0128] In the embodiments of the present application, Figure 3 As shown: Since there are cases where the same modules are arranged continuously, when transferring the web page (page to be converted) to the mobile page (target page), it is usually hoped that the continuously arranged pages will continue to be arranged continuously on the mobile phone, so the page module groups are merged first. In the web page of the PC, modules of the same template may appear multiple times, but the data content filled inside is different. For modules of the same template that appear multiple times, they are considered to belong to the same module group; for different modules that appear alternately in space, they are also considered to belong to the same module group (supplementary schematic diagram, such as horizontal and vertical arrangement of ABAB..., ABCABC...). Therefore, it is necessary to merge the same modules into one module group. That is, when there are at least two initial modules of the same template in the page to be converted, determine whether the at least two initial modules are aligned; when the at least two initial modules are aligned, merge the at least two initial modules to obtain at least one initial module group; when the number of at least one initial module group is multiple, determine whether the multiple initial module groups are aligned; when the multiple initial module groups are aligned, merge the multiple initial module groups to obtain a merged initial module group; when the merged initial module groups are no longer aligned or the number of the merged initial module groups is one, use the merged initial module group as a module group.
[0129] S103, performing parallel conversion on multiple modules to be converted in the target page structure to obtain multiple target modules; the multiple modules to be converted are modules in the page to be converted.
[0130] In the embodiment of the present application, the page conversion device performs page structure analysis on the page to be converted, and after obtaining the target page structure, it can perform parallel conversion on multiple modules to be converted in the target page structure to obtain multiple target modules.
[0131] In an embodiment of the present application, a page conversion device converts multiple modules to be converted in a target page structure in parallel to obtain multiple target modules, including: parsing the target page structure to obtain a tree structure; converting multiple leaf nodes in parallel to obtain multiple target modules.
[0132] It should be noted that the tree structure includes multiple leaf nodes; the multiple leaf nodes are multiple modules to be converted in the page to be converted.
[0133] In the embodiment of the present application, the tree structure is specifically a tree-like hierarchical relationship.
[0134] In the embodiment of the present application, the method of converting the leaf node to obtain the target module is a method in the prior art, and the specific embodiment of the present application is not limited here.
[0135] In the embodiment of the present application, the target page structure is parsed to obtain a tree structure in a manner known in the prior art, and the specific embodiment of the present application is not limited herein.
[0136] In an embodiment of the present application, the page conversion device performs parallel conversion on multiple leaf nodes to obtain multiple target modules, including: using a thread pool to perform parallel conversion on multiple leaf nodes to obtain multiple modules and multiple templates; using multiple modules and multiple templates as multiple target modules.
[0137] It should be noted that, in one page, multiple modules correspond to multiple templates one by one; a specific module corresponds to one template.
[0138] In an embodiment of the present application, the thread pool includes multiple threads, which are used to perform parallel conversion on multiple leaf nodes respectively to obtain multiple target modules.
[0139] It should also be noted that the template controls the display effect of the module content, which is mainly composed of CSS and JS. The content provided by a module can have multiple display effects, so a module will have multiple different templates, and different templates control different display effects.
[0140] In the embodiment of the present application, for the analyzed module priority, the layout selection is performed according to the module resolution during conversion, and the module group is dynamically combined and adaptively matched according to its resolution and size during matching, and finally the layout and module binding relationship of the mobile terminal page are generated (the target page structure includes the binding relationship). In the design process of the entire flow, the layout and module binding relationship of the mobile terminal page can be generated first, ensuring that the modules are calculated in parallel in the background, and the module data and styles are filled in parallel, ensuring the generation efficiency of the mobile terminal page.
[0141] It can be understood that the technical solution in the embodiment of the present application can ensure that after the page layout and binding relationship are generated, each module is calculated in parallel to improve page conversion efficiency.
[0142] S104: construct a target page according to multiple target modules.
[0143] In the embodiment of the present application, the page conversion device converts multiple modules to be converted in the target page structure in parallel. After obtaining multiple target modules, the target page can be constructed according to the multiple target modules.
[0144] In an embodiment of the present application, the process of the page conversion device constructing a target page according to multiple target modules includes: filling multiple modules into the target end page according to multiple filling styles corresponding to multiple templates to obtain the target page.
[0145] In an embodiment of the present application, after parsing the target page structure to obtain a tree structure including multiple leaf nodes, the multiple leaf nodes can be parsed to obtain attribute information corresponding to the multiple leaf nodes (the attribute information includes information such as multiple template numbers and module numbers). In the case where multiple modules to be converted are converted in parallel to obtain multiple target modules, the multiple target modules are stored and the multiple target modules and attribute information are bound. The process of filling multiple modules into the target end page according to the multiple filling styles corresponding to the multiple templates to obtain the target page can be to obtain each module and each corresponding template at the storage location, and fill each module into the target end page according to the filling style corresponding to each template, thereby obtaining the target page.
[0146] It can be understood that the zero-code page generation method described in this application can quickly help various units generate pages, and become an indispensable part of daily office, emergency handling, command and dispatch, strategic decision-making and other scenarios.
[0147] In the embodiment of the present application, a page structure (target page structure) of the mobile terminal is generated according to the page of the Web terminal (page to be converted), and the relationship between the module and the layout is established in the page structure. The attributes of the tag are described, and the data and style of all modules in the layout need to be filled in the background. Specifically, it includes: first parsing the generated page DOM structure (target page structure), generating a tree-like hierarchical relationship (tree structure) corresponding to the page DOM structure, where each leaf node is a module; The node is parsed to obtain its attribute value, including module number, template number and other information; the thread pool is used to convert the data of all leaf nodes in parallel, generate the data and module filling style corresponding to the mobile terminal, and store them in the page file, and bind the storage location with the attributes of the leaf node; after completing the data and style filling according to the above process, a complete mobile terminal page is generated.
[0148] In the embodiment of the present application, the schematic diagram of the page conversion process is as follows: Figure 4 As shown: determine and combine the page module group (search for the module group in the page to be converted; when the module group exists in the page to be converted, determine the first module in the page to be converted except the module group, and use the module group as the second module); analyze the page, calculate the corresponding relationship, layout, occupied area and other factors of the modules in the area where the modules are located, and perform priority sorting analysis on the page modules (according to the hot spot distribution in the page to be converted, perform hot spot distribution sorting on the first module and the second module to obtain a module sequence); according to the calculated priority sorting, match and convert the modules on the PC side to the mobile side; dynamically combine the module group and the layout of each module to generate the page structure of the mobile side page (perform layout conversion analysis on the modules in the module sequence in turn to obtain the target page structure); fill in module data and styles in parallel; generate a mobile side page (build a target page based on multiple target modules).
[0149] It can be understood that the page conversion device obtains the target page structure by performing page structure analysis on the page to be converted. The target page structure is the layout structure of the target module in the target page, that is, the layout structure of the target module in the target page has been determined, so that multiple modules to be converted in the target page structure can be converted in parallel, and there is no need to determine the layout of the current module based on the layout of the previous module and information such as the area length. Multiple modules to be converted can be converted at the same time, thereby improving the conversion efficiency of the target page.
[0150] Based on the same inventive concept as the above-mentioned page conversion method, the embodiment of the present application provides a page conversion device 1, corresponding to a page conversion method; Figure 5 A schematic diagram of the structure of a page conversion device provided in an embodiment of the present application Figure 1 , the page conversion device 1 may include:
[0151] An acquisition unit 11 is used to acquire a page to be converted;
[0152] An analysis unit 12 is used to perform page structure analysis on the page to be converted to obtain a target page structure;
[0153] The conversion unit 13 is used to convert multiple modules to be converted in the target page structure in parallel to obtain multiple target modules; the multiple modules to be converted are modules in the page to be converted;
[0154] The building unit 14 is used to build a target page according to the multiple target modules.
[0155] In some embodiments of the present application, the device further includes a parsing unit,
[0156] The parsing unit is used to parse the target page structure to obtain a tree structure; the tree structure includes a plurality of leaf nodes; the plurality of leaf nodes are a plurality of modules to be converted in the page to be converted;
[0157] The conversion unit 13 is used to perform parallel conversion on the multiple leaf nodes to obtain the multiple target modules.
[0158] In some embodiments of the present application, the conversion unit 13 is used to use a thread pool to perform parallel conversion on the multiple leaf nodes to obtain multiple modules and multiple templates; the multiple modules and the multiple templates correspond one to one; and the multiple modules and the multiple templates are used as the multiple target modules.
[0159] In some embodiments of the present application, the device further comprises a filling unit;
[0160] The filling unit is used to fill multiple modules into the page of the target end according to multiple filling styles corresponding to multiple templates, so as to obtain the target page.
[0161] In some embodiments of the present application, the device further includes a searching unit, a determining unit, and a sorting unit;
[0162] The searching unit is used to search for a module group in the page to be converted; the number of the module group is at least one;
[0163] The determining unit is used to determine, when the module group exists in the page to be converted, a first module other than the module group in the page to be converted, and use the module group as the second module; the first module is a module that is not merged with other modules in the page to be converted;
[0164] The sorting unit is used to sort the first module and the second module by hot spot distribution according to the hot spot distribution in the page to be converted, so as to obtain a module sequence;
[0165] The conversion unit 13 is used to perform layout conversion analysis on the modules in the module sequence in sequence to obtain the target page structure.
[0166] In some embodiments of the present application, the determining unit is used to determine the layout parameters of the first module and the second module, the first size parameter of the first module and the second size parameter of the second module; determine the first target size parameter corresponding to the first target module by using the preset module matching relationship and the first size parameter; determine the second target size parameter corresponding to the second target module according to the module group conversion mode and the second size parameter; the first target module and the second target module constitute the multiple target modules; determine the target page structure according to the target page size parameter, the layout parameter, the first target size parameter and the second target size parameter;
[0167] The acquisition unit 11 is used to acquire the preset module matching relationship; and acquire the target page size parameter.
[0168] In some embodiments of the present application, the apparatus further comprises a scaling unit;
[0169] The acquiring unit 11 is configured to acquire a width parameter of the second module from the second size parameter;
[0170] The scaling unit is used to scale the second size parameter using a preset scaling factor to obtain the second target size parameter when the parameter value of the width parameter is less than or equal to a preset parameter.
[0171] In some embodiments of the present application, the apparatus further comprises a grouping unit;
[0172] The determining unit is used to determine the number of columns in the second module when the parameter value is greater than the preset parameter;
[0173] The scaling unit is configured to scale the second size parameter using a preset scaling factor to obtain the second target size parameter when the number value of the number of columns is an odd number less than or equal to the preset number value; scale the multiple groups using the preset scaling factor to obtain the second target size parameter when the multiple width values are less than or equal to the preset parameter; and scale each column in the second module using the preset scaling factor to obtain the second target size parameter when the multiple width values are greater than the preset parameter;
[0174] The grouping unit is used to group the columns in the second module according to the preset grouping value to obtain a plurality of groups when the number value of the number of columns is an odd number greater than the preset number value or the number value of the number of columns is an even number;
[0175] The obtaining unit 11 is used to obtain a plurality of width values corresponding to the plurality of groups.
[0176] In some embodiments of the present application, the determination unit is used to determine the normalized probability of each pixel in the first module and the second module according to the hotspot distribution in the page to be converted; determine the first hotspot parameters of the first module and the second module according to the pixel area and position information of the first module and the second module; determine the second hotspot parameters of the first module and the second module according to the content information corresponding to the first module and the second module; determine the target hotspot parameters of the first module and the second module according to the normalized probability, the first hotspot parameter, and the second hotspot parameter; sort the first module and the second module according to the target hotspot parameter to obtain the module sequence; the first module in the module sequence is the module with the largest corresponding first hotspot parameter value.
[0177] In some embodiments of the present application, the device further comprises a merging unit;
[0178] The determining unit is used to determine whether the at least two initial modules are aligned when there are at least two initial modules of the same template in the page to be converted; and to determine whether the multiple initial module groups are aligned when there are multiple initial module groups.
[0179] The merging unit is used to merge the at least two initial modules to obtain at least one initial module group when the at least two initial modules are aligned; merge the multiple initial module groups to obtain the merged initial module group when the multiple initial module groups are aligned; and use the merged initial module group as the module group when the merged initial module groups are no longer aligned or the number of the merged initial module groups is one.
[0180] In some embodiments of the present application, the determining unit is used to determine that the upper edges and lower edges of the at least two initial modules are aligned; or, to determine that the lower edges and right edges of the at least two initial modules are aligned.
[0181] In some embodiments of the present application, the determining unit is used to determine that the upper edges of the multiple initial module groups are aligned, the lower edges of the multiple initial module groups are aligned, and the center points of the multiple initial module groups are aligned; or, to determine that the left edges of the multiple initial module groups are aligned, the right edges of the multiple initial module groups are aligned, and the center points of the multiple initial module groups are aligned.
[0182] In some embodiments of the present application, the determining unit is configured to use the at least one initial module group as the module group when the number of the at least one initial module group is one.
[0183] It should be noted that, in actual applications, the above-mentioned acquisition unit 11, analysis unit 12, conversion unit 13 and establishment unit 14 can be implemented by a processor 15 on the page conversion device 1, specifically a CPU (Central Processing Unit), an MPU (Microprocessor Unit), a DSP (Digital Signal Processing) or a Field Programmable Gate Array (FPGA); the above-mentioned data storage can be implemented by a memory 16 on the page conversion device 1.
[0184] The present application also provides a page conversion device 1, such as Figure 6 As shown, the page conversion device 1 includes: a processor 15, a memory 16 and a communication bus 17. The memory 16 communicates with the processor 15 via the communication bus 17. The memory 16 stores a program executable by the processor 15. When the program is executed, the page conversion method described above is executed by the processor 15.
[0185] In practical applications, the memory 16 may be a volatile memory, such as a random access memory (RAM); or a non-volatile memory, such as a read-only memory (ROM), a flash memory, a hard disk (HDD) or a solid-state drive (SSD); or a combination of the above types of memory, and provide instructions and data to the processor 15.
[0186] An embodiment of the present application provides a computer-readable storage medium having a computer program thereon, and when the program is executed by the processor 15, the page conversion method as described above is implemented.
[0187] It can be understood that the page conversion device obtains the target page structure by performing page structure analysis on the page to be converted. The target page structure is the layout structure of the target module in the target page, that is, the layout structure of the target module in the target page has been determined, so that multiple modules to be converted in the target page structure can be converted in parallel, and there is no need to determine the layout of the current module based on the layout of the previous module and information such as the area length. Multiple modules to be converted can be converted at the same time, thereby improving the conversion efficiency of the target page.
[0188] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of hardware embodiments, software embodiments, or embodiments in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage and optical storage, etc.) that contain computer-usable program code.
[0189] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0190] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0191] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0192] The above description is only a preferred embodiment of the present application and is not intended to limit the protection scope of the present application.
Claims
1. A page conversion method, characterized in that: The method comprises: Get the page to be converted; Performing page structure analysis on the page to be converted to obtain a target page structure; Parallel conversion is performed on a plurality of modules to be converted in the target page structure to obtain a plurality of target modules; the plurality of modules to be converted are modules in the page to be converted; A target page is constructed according to the multiple target modules.
2. The method according to claim 1, characterized in that The multiple modules to be converted in the target page structure are converted in parallel to obtain multiple target modules, including: The target page structure is parsed to obtain a tree structure; the tree structure includes a plurality of leaf nodes; the plurality of leaf nodes are a plurality of modules to be converted in the page to be converted; The multiple leaf nodes are converted in parallel to obtain the multiple target modules.
3. The method according to claim 2, characterized in that The step of converting the plurality of leaf nodes in parallel to obtain the plurality of target modules includes: The plurality of leaf nodes are converted in parallel by using a thread pool to obtain a plurality of modules and a plurality of templates; the plurality of modules and the plurality of templates correspond one to one; The plurality of modules and the plurality of templates are used as the plurality of target modules.
4. The method according to claim 1, characterized in that: The step of constructing a target page according to the plurality of target modules comprises: The multiple modules are filled into the target end page according to the multiple filling styles corresponding to the multiple templates to obtain the target page.
5. The method according to claim 1, characterized in that: The performing page structure analysis on the page to be converted to obtain a target page structure includes: Searching for a module group in the page to be converted; the number of the module group is at least one; In the case where the module group exists in the page to be converted, determining a first module in the page to be converted except the module group, and using the module group as a second module; the first module is a module that is not merged with other modules in the page to be converted; According to the hotspot distribution in the to-be-converted page, the first module and the second module are sorted by hotspot distribution to obtain a module sequence; The modules in the module sequence are sequentially subjected to layout conversion analysis to obtain the target page structure.
6. The method according to claim 5, characterized in that The step of sequentially performing layout conversion analysis on the modules in the module sequence to obtain the target page structure includes: Determining layout parameters of the first module and the second module, a first size parameter of the first module, and a second size parameter of the second module; Acquire a preset module matching relationship, and determine a first target size parameter corresponding to a first target module by using the preset module matching relationship and the first size parameter; Determine a second target size parameter corresponding to a second target module according to the module group conversion mode and the second size parameter; the first target module and the second target module constitute the plurality of target modules; A target page size parameter is acquired, and the target page structure is determined according to the target page size parameter, the layout parameter, the first target size parameter, and the second target size parameter.
7. The method according to claim 6, characterized in that The determining, according to the module group conversion mode and the second size parameter, a second target size parameter corresponding to the second target module includes: Obtaining a width parameter of the second module from the second size parameter; When the parameter value of the width parameter is less than or equal to a preset parameter, the second size parameter is scaled using a preset scaling factor to obtain the second target size parameter.
8. The method according to claim 7, characterized in that After acquiring the width parameter of the second module from the second size parameter, the method further includes: In the case where the parameter value is greater than the preset parameter, determining the number of columns in the second module; When the number of columns is an odd number less than or equal to a preset number, scaling the second size parameter using a preset scaling factor to obtain the second target size parameter; When the number value of the number of columns is an odd number greater than the preset number value, or when the number value of the number of columns is an even number, the columns in the second module are grouped according to the preset grouping value to obtain a plurality of groups; Acquire multiple width values corresponding to the multiple groups; and when the multiple width values are less than or equal to the preset parameter, use the preset scaling factor to scale the multiple groups respectively to obtain the second target size parameter; When the multiple width values are greater than the preset parameter, each column in the second module is scaled using a preset scaling factor to obtain the second target size parameter.
9. The method according to claim 5, characterized in that The hotspot distribution sorting of the first module and the second module according to the hotspot distribution in the to-be-converted page to obtain a module sequence includes: Determining the normalized probability of each pixel in the first module and the second module according to the hot spot distribution in the page to be converted; Determining first hotspot parameters of the first module and the second module according to the pixel areas and position information of the first module and the second module; Determining second hotspot parameters of the first module and the second module according to content information corresponding to the first module and the second module; Determining target hotspot parameters of the first module and the second module according to the normalized probability, the first hotspot parameter, and the second hotspot parameter; The first module and the second module are sorted according to the target hotspot parameter to obtain the module sequence; the first module in the module sequence is the module with the largest corresponding first hotspot parameter value.
10. The method according to claim 5, characterized in that The step of searching for a module group in the page to be converted includes: In the case where there are at least two initial modules of the same template in the page to be converted, determining whether the at least two initial modules are aligned; In the case where the at least two initial modules are aligned, merging the at least two initial modules to obtain at least one initial module group; In a case where the number of the at least one initial module group is plural, determining whether the multiple initial module groups are aligned; When the multiple initial module groups are aligned, the multiple initial module groups are merged to obtain the merged initial module group; when the merged initial module groups are no longer aligned, or the number of the merged initial module groups is one, the merged initial module group is used as the module group.
11. The method according to claim 10, characterized in that The determining whether the at least two initial modules are aligned comprises: Determining that the upper edges of the at least two initial modules are aligned and the lower edges are aligned; Alternatively, it is determined that the top edges and right edges of the at least two initial modules are aligned.
12. The method according to claim 10, characterized in that The step of determining whether the plurality of initial module groups are aligned comprises: Determining that upper edges of the plurality of initial module groups are aligned, lower edges of the plurality of initial module groups are aligned, and center points of the plurality of initial module groups are aligned; Alternatively, it is determined that the left edges of the multiple initial module groups are aligned, the right edges of the multiple initial module groups are aligned, and the center points of the multiple initial module groups are aligned.
13. The method according to claim 10, characterized in that After merging the at least two initial modules to obtain at least one initial module group, the method further includes: When the number of the at least one initial module group is one, the at least one initial module group is used as the module group.
14. A page conversion device, characterized in that: The device comprises: An acquisition unit, used for acquiring a page to be converted; An analysis unit, used for performing page structure analysis on the page to be converted to obtain a target page structure; A conversion unit, used for converting a plurality of modules to be converted in the target page structure in parallel to obtain a plurality of target modules; the plurality of modules to be converted are modules in the page to be converted; A building unit is used to build a target page according to the multiple target modules.
15. A page conversion device, characterized in that: The device comprises: A memory, a processor and a communication bus, wherein the memory communicates with the processor via the communication bus, the memory stores a page conversion program executable by the processor, and when the page conversion program is executed, the method according to any one of claims 1 to 13 is executed by the processor.
16. A storage medium having a computer program stored thereon, applied to a page conversion device, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 13 is implemented.
