Courseware format analysis method and device, equipment and storage medium

Through the detection and analysis of teaching courseware pictures, statistics and calculation of the number of courseware contents and spatial utilization rates, the subjective and unscientific problems of courseware evaluation in the existing technologies have been solved, and the scientific and objective of the courseware format is realized Analysis and evaluation.

CN119380358APending Publication Date: 2025-01-28GUANGZHOU AVA ELECTRONICS TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411508268.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-28
Publication Date
2025-01-28

AI Technical Summary

Technical Problem

The existing technology has problems that are subjective, scientific and objective when diagnosing and evaluating teaching courseware, and the analysis and evaluation are mainly aimed at the courseware outline, rather than the actual presentation of the courseware.

Method used

By obtaining courseware pictures, detecting and counting the number and proportion of the title, text, tables and pictures, calculate the spatial utilization rate, and according to the differences between the actual value and the ideal value, the analysis of the category equilibrium and spatial utilization rate is obtained. In the end Receive the results of the text space characteristics and format analysis results of the courseware content.

Benefits of technology

A scientific and objective analysis of the teaching courseware format can be implemented, and the evaluation of the screen can be evaluated according to the actual presentation of the courseware, which improves the accuracy and consistency of diagnosis.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 00000000_0000_ABST
    Figure 00000000_0000_ABST
Patent Text Reader

Abstract

The invention discloses a courseware format analysis method and device, equipment and a storage medium. The method comprises the following steps: detecting a title, a text, a table and a picture in each frame of courseware picture; counting the actual values of the percentages of the title, the text, the table and the picture in the total quantity and the space size proportion RF of the sum of the areas of three content boxes of the text, the table and the picture in the whole picture for the single-frame courseware picture; obtaining an ideal value of the percentage and an ideal space utilization rate range; obtaining a single-frame category balance degree analysis result according to the difference between the actual value and the ideal value of the percentage accounting for the total number; obtaining a single-frame space utilization rate analysis result according to the RF and an ideal space utilization rate range; and obtaining a single frame result according to a category balance degree analysis result and a space utilization rate analysis result of the single frame, obtaining a courseware overall result according to each single frame result, and then obtaining a courseware format analysis result. The teaching courseware format is objectively analyzed and evaluated, and a scientific evaluation conclusion is obtained.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of artificial intelligence technology, and more specifically, to a courseware format analysis method, device, equipment and storage medium. Background Art

[0002] In the educational scenario, teaching courseware is a teaching aid that can assist teachers in teaching and explaining in class. Teaching courseware is designed to make teachers' teaching more vivid and intuitive, and help students better understand and master knowledge. At the same time, it can also be used as materials for students to review and self-study.

[0003] The analysis and evaluation of teaching courseware is also one of the most basic and core contents of education and teaching quality assurance, and is also an important part of education evaluation. At present, the current diagnosis of the teacher's courseware level depends only on people, which is highly subjective. The evaluation standards of each diagnostician are different, and it is difficult to ensure the scientificity and objectivity of the diagnosis. In addition, the current analysis and evaluation methods are aimed at the courseware outline itself, not the pictures presented by the courseware, and the evaluation results are also somewhat different from the actual feelings. Summary of the invention

[0004] In order to overcome at least one of the above-mentioned defects of the prior art, the present invention provides a courseware format analysis method, device, equipment and storage medium. The technical solution adopted by the present invention is as follows.

[0005] In a first aspect, the present invention provides a courseware format analysis method, comprising:

[0006] Obtaining a courseware picture, wherein the courseware picture is obtained by converting courseware data into image type data;

[0007] Detect each frame of the courseware image to detect the title, text, table and image;

[0008] For a single-frame courseware image, count the total number of titles, texts, tables, and images combined, as well as the actual values ​​of the percentages of titles, texts, tables, and images in the total number;

[0009] Count the proportion of the sum of the areas of the text, table, and picture content boxes in the entire picture space to get the actual space utilization rate;

[0010] Get the preset ideal values ​​of the percentages of the title, text, table and picture in the total quantity respectively, and get the preset ideal range of space utilization;

[0011] The results of the single-frame category balance analysis are obtained based on the difference between the actual and ideal percentages of the total number of titles, texts, tables, and pictures;

[0012] According to the relationship between the actual space utilization and the ideal space utilization range, the single-frame space utilization analysis result is obtained;

[0013] According to the category balance analysis result and the space utilization analysis result of the single frame, a single frame courseware content space feature analysis result is obtained, and according to the spatial feature analysis results of each single frame courseware content, a courseware content space feature analysis result is obtained;

[0014] Based on the results of the courseware content space feature analysis, the courseware format analysis results are obtained.

[0015] In one embodiment, the process of obtaining the single-frame category balance analysis result based on the difference between the actual value and the ideal value of the percentage of the total number of titles, texts, tables, and pictures, respectively, includes:

[0016] Let the category balance analysis result S_balance = 1-|N_title-P_title|-|N_text-P_text|-|N_table-P_table|-|N_img-P_img|;

[0017] Among them, N_title is the ideal value of the percentage of the title in the total number, P_title is the actual value of the percentage of the title in the total number, N_text is the ideal value of the percentage of the text in the total number, P_text is the actual value of the percentage of the text in the total number, N_table is the ideal value of the percentage of the table in the total number, P_table is the actual value of the percentage of the table in the total number, N_img is the ideal value of the percentage of the image in the total number, P_img is the actual value of the percentage of the image in the total number.

[0018] In one embodiment, the process of obtaining a single-frame space utilization analysis result based on the relationship between the actual space utilization and the ideal space utilization range includes:

[0019] The ideal space utilization range is [a,b];

[0020] If the actual space utilization is within the ideal space utilization range, the space utilization analysis result S_space=1;

[0021] Otherwise, the space utilization analysis result S_space=1-|R_F-(a+b) / 2|, where R_F is the actual space utilization.

[0022] In one embodiment, the process of obtaining the single-frame courseware content spatial feature analysis result based on the category balance analysis result and the space utilization analysis result of the single frame includes:

[0023] The result of the spatial feature analysis of the content of a single-frame courseware is S_sstotal=alpha*S_balance+beta*S_space, where S_balance is the result of the category balance analysis, S_space is the result of the space utilization analysis, and alpha and beta are preset weight coefficients.

[0024] In one embodiment, the process of obtaining the courseware content spatial feature analysis results based on the spatial feature analysis results of each single-frame courseware content includes:

[0025] Obtaining a preset spatial feature threshold range;

[0026] Counting the first number of the spatial feature analysis results of the single-frame courseware content within the preset spatial feature threshold range;

[0027] According to the first number and the total number of courseware pictures, the proportion of frames that meet the requirements is obtained R_34;

[0028] Based on the R_34, the results of the courseware content space feature analysis are obtained.

[0029] In one embodiment, it further includes:

[0030] For a single-frame courseware image, the text is taken as the target area, and the RGB representation color of the text is extracted; the background is taken as the target area, and the RGB representation color of the background is extracted. The background is the image obtained by covering all the contents of the four categories of title, text, table, and picture.

[0031] Count the colors with the largest proportion of text and background RGB representation colors in all frames of the entire courseware, and record them as courseware text representation color RGB_tfg and courseware background representation color RGB_tbg respectively;

[0032] Based on hue, brightness and / or coldness and warmth, calculate the color contrast between the text representation color RGB_tfg and the courseware background representation color RGB_tbg, wherein the color contrast is calculated according to the ratio of the larger value to the smaller value between RGB_tfg and RGB_tbg;

[0033] Based on the preset contrast mapping model, the main color contrast analysis result R_33 is obtained according to the color contrast;

[0034] Based on the R_33, the results of the courseware visual design analysis are obtained;

[0035] The process of extracting the RGB color representation of the target area includes:

[0036] Get the hue of each pixel in the target area;

[0037] Determine the hue interval into which each pixel hue falls according to a preset color mapping method, wherein in the preset color mapping method, each fixed RGB representation color has a corresponding hue interval;

[0038] Each target area uses the hue interval with the most pixel hues as its own RGB representation color;

[0039] The process of obtaining the courseware format analysis result is also based on the courseware visual design analysis result.

[0040] In one implementation, the process of determining the hue interval into which each pixel hue falls according to a preset color mapping method includes:

[0041] Convert pixel hue from RGB space to HSV space;

[0042] Determine whether the V value of the pixel hue is less than 46. If it is less than 46, it is determined to be black;

[0043] When the pixel hue is not black, determine whether the S value of the pixel hue is greater than 43. If it is greater than 43, determine it as color;

[0044] When the pixel hue is not a color, determine whether the V value of the pixel hue is greater than 221. If it is greater than 221, it is determined to be white, otherwise it is determined to be gray;

[0045] When the pixel hue is a color, the hue interval into which the pixel hue falls is determined according to the range intervals of various colors preset on the hue circle according to the H value of the pixel hue.

[0046] In one implementation, the preset contrast mapping model is:

[0047]

[0048] Among them, y is the color contrast.

[0049] In one embodiment, it is characterized in that

[0050] Count the number of background RGB representation colors in all frames of the entire courseware that are different from the representation color RGB_tbg of the courseware background, recorded as N_dgb;

[0051] Get the ideal color category number range [n_min,n_max];

[0052] If N_dgb is within the ideal color category number range, the color diversity analysis result S_32=1; otherwise, the color diversity analysis result S_32=1-(|N_dfg-(n_min+n_max) / 2| / max(n_min,N_dfg-n_min));

[0053] The process of obtaining the courseware visual design analysis result is also based on the color diversity analysis result.

[0054] In one embodiment, it is characterized in that

[0055] Count the number of text and background RGB representation colors in all frames of the entire courseware that are different from the courseware text representation color RGB_tfg and the courseware background representation color RGB_tbg, which are recorded as N_dfg and N_dgb respectively;

[0056] Color consistency analysis result S_31 = 1-(w_fg*N_dfg+w_fg*N_dgb) / 2*N, where N is the total number of frames of the courseware, and w_fg and w_bg are both preset weights;

[0057] The process of obtaining the courseware visual design analysis result is also based on the color consistency analysis result.

[0058] In a second aspect, the present invention provides a courseware format analysis device, characterized in that it comprises:

[0059] The acquisition module is used to acquire courseware images, wherein the courseware images are obtained by converting courseware data into image type data; acquire the preset ideal values ​​of the percentages of the title, text, table and image in the total number respectively, and acquire the preset ideal space utilization range;

[0060] The detection module is used to detect each frame of the courseware image and detect the title, text, table and image;

[0061] The first statistical module is used to count the total number of titles, texts, tables and pictures in a single-frame courseware picture, as well as the actual value of the percentage of the total number of titles, texts, tables and pictures respectively; and to count the proportion of the sum of the areas of the three content frames of the text, table and picture in the entire picture space to obtain the actual space utilization rate;

[0062] The first analysis module is used to obtain a single-frame category balance analysis result based on the difference between the actual value and the ideal value of the percentage of the title, text, table and picture in the total number respectively; obtain a single-frame space utilization analysis result based on the relationship between the actual space utilization and the ideal space utilization range; obtain a single-frame courseware content space feature analysis result based on the category balance analysis result and the space utilization analysis result of the single frame, and obtain a courseware content space feature analysis result based on the space feature analysis results of each single-frame courseware content;

[0063] The overall analysis module is used to obtain the courseware format analysis results based on the courseware content space feature analysis results.

[0064] In a third aspect, the present invention provides a computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements any of the above-mentioned methods when executing the program.

[0065] In a fourth aspect, the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein the program, when executed by a processor, implements the method of any of the above-mentioned embodiments.

[0066] In the present invention, by analyzing the screen presented by the courseware, the positions of the title, text, table and picture are detected, and by comparing the actual value of the quantity proportion of the title, text, table and picture with the ideal value, and by comparing the actual value of the area proportion of the title, text, table and picture in the entire PPT with the ideal value, the teaching courseware format is analyzed and evaluated with objective normative standards, so as to obtain a scientific and objective evaluation conclusion. BRIEF DESCRIPTION OF THE DRAWINGS

[0067] Figure 1 It is a schematic diagram of the overall process of an implementation method of Example 1 of the present invention.

[0068] Figure 2 It is a schematic diagram of the overall process of another implementation method of the first embodiment of the present invention.

[0069] Figure 3 This is a diagram that divides the hue range into 12 equal parts.

[0070] Figure 4 It is a schematic diagram of the overall structure of the second embodiment of the present invention. DETAILED DESCRIPTION

[0071] The exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although the exemplary embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be limited by the embodiments set forth herein. On the contrary, these embodiments are provided to enable a more thorough understanding of the present disclosure and to fully convey the scope of the present disclosure to those skilled in the art.

[0072] It should be noted that the terms "first\second\..." involved in the embodiments of the present invention are only used to distinguish similar objects, and do not represent a specific order for the objects. It is understandable that the specific order or sequence of "first\second\..." can be interchanged where permitted. It should be understood that the objects distinguished by "first\second\..." can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein.

[0073] Embodiment 1

[0074] See also Figure 1 , Figure 1 The flowchart of a courseware format analysis method provided in the first embodiment of the present invention includes step S110, step S120, step S130, step S140, step S150, step S160, step S170, step S180 and step S190. It should be noted that step S110, step S120, step S130, step S140, step S150, step S160, step S170, step S180 and step S190 are only reference numerals for clear explanation of the embodiment and the appendix. Figure 1 The corresponding relationship does not limit the order of the steps in this embodiment.

[0075] Step S110, obtaining a courseware picture, wherein the courseware picture is obtained by converting the courseware data into image type data;

[0076] Step S120, detecting each frame of the courseware image to detect the title, text, table and image;

[0077] Step S130, for a single-frame courseware picture, count the total number of titles, texts, tables and pictures combined, as well as the actual values ​​of the percentages of the titles, texts, tables and pictures in the total number respectively;

[0078] Step S140, calculating the proportion of the sum of the areas of the three content boxes of the text, the table, and the picture in the entire picture space to obtain the actual space utilization rate R_F;

[0079] Step S150, obtaining preset ideal values ​​of the percentages of the title, text, table and picture in the total quantity, and obtaining a preset ideal range of space utilization;

[0080] Step S160, obtaining a single-frame category balance analysis result based on the difference between the actual value and the ideal value of the percentage of the title, text, table and picture in the total number respectively;

[0081] Step S170, obtaining a single-frame space utilization analysis result according to the relationship between the actual space utilization R_F and the ideal space utilization range;

[0082] Step S180, obtaining a single-frame courseware content space feature analysis result based on the category balance analysis result and the space utilization analysis result of the single frame, and obtaining a courseware content space feature analysis result based on the courseware content space feature analysis results of each single-frame courseware content;

[0083] Step S190, obtaining the courseware format analysis result based on the courseware content space feature analysis result.

[0084] First, a courseware page data stream is input, which can be a PPT or PDF file, or a video about the courseware, and the courseware page data stream is processed to convert the courseware data into image type data to obtain courseware pictures frame by frame. In step S110, these courseware pictures frame by frame are obtained.

[0085] The input processed in this method is of image type, so it can support the analysis of courseware files of different formats. Although the PPT format files commonly used in courseware can obtain PPT content by using a specific PPT reading tool, it cannot process courseware files in PDF format or image format, is not generalizable, and has limitations on usage scenarios. In addition, during the teaching process, the courseware that students see is presented in the form of slides, and each slide can show a frame of picture. The analysis and evaluation of pictures in this method is more in line with students' actual feelings.

[0086] After obtaining the courseware picture, step S120 detects each frame of the courseware picture to detect the title, text, table and picture. For the specific method of detecting the title, text, table and picture in the courseware picture, the courseware picture can be passed into the courseware content structure detection module. The courseware content structure detection module is a module that uses image features to output the preset category and target frame position in the picture. The courseware content structure detection module detects whether there is a preset category target in the input image. If the picture has a target category, it outputs its position in the picture and the target category. In this method, the preset content category targets include: title, text, table and picture.

[0087] The specific implementation methods of the courseware content structure detection module may include the following two:

[0088] Implementation method 1: The four preset target detection tasks of title, text, table and picture are taken as a unified target detection task. A network model trained by supervised learning method based on neural network is used. The network training data is training pictures with manual annotations. The network parameter adjustment is guided by two tasks, one is the classification task of target category and the other is the regression task of target position coordinates.

[0089] Implementation method 2: Detect the four types of targets separately according to their image features. Titles and texts are classified as text detection, and OCR detection methods can be used. Then, empirical classification is performed based on the size and spatial position of the text box. Table detection can be performed using the significant line features of the table. Images can be detected using the complex pixel detail features that distinguish the image from the background and the inverted pyramid spatial sliding window positioning.

[0090] After detecting the title, text, table and picture, the required information can be extracted according to the title, text, table and picture, and then evaluated. Among them, step S130, step S150 and step S160 are for analyzing the category balance, and step S140, step S150 and step S170 are for analyzing the space utilization.

[0091] In the process of analyzing the category balance, the number of titles, texts, tables and pictures is counted in step S130. For example, if there is 1 title, the number of titles is counted as 1; if there are 2 paragraphs of text, the number of texts is counted as 2; if there are 3 tables, the number of tables is counted as 3; if there are 4 pictures, the number of pictures is counted as 4, and the total number of them is 10. Then, the actual value of the percentage of the title in the total number is N_title=10%, the actual value of the percentage of the text in the total number is N_text=20%, the actual value of the percentage of the table in the total number is N_table=30%, and the actual value of the percentage of the picture in the total number is N_img=40%.

[0092] In step S150, the ideal value P_title of the preset percentage of the total number of titles, the ideal value P_text of the preset percentage of the total number of texts, the ideal value P_table of the preset percentage of the total number of tables, and the ideal value P_img of the preset percentage of the total number of images are obtained. These ideal values ​​can be obtained based on experience.

[0093] The ideal value is obtained based on experience. By comparing the actual value with the ideal value and looking at the difference between the two values, the gap from the ideal value can be seen. Therefore, in step S160, the category balance analysis result is obtained based on the difference between the actual value and the ideal value of the percentage of the total number of titles, texts, tables and pictures respectively.

[0094] In one implementation, the process of step S160 includes:

[0095] Let the category balance analysis result S_balance = 1-|N_title-P_title|-|N_text-P_text|-|N_table-P_table|-|N_img-P_img|;

[0096] Among them, N_title is the ideal value of the percentage of the title in the total number, P_title is the actual value of the percentage of the title in the total number, N_text is the ideal value of the percentage of the text in the total number, P_text is the actual value of the percentage of the text in the total number, N_table is the ideal value of the percentage of the table in the total number, P_table is the actual value of the percentage of the table in the total number, N_img is the ideal value of the percentage of the image in the total number, P_img is the actual value of the percentage of the image in the total number.

[0097] In the process of analyzing the space utilization, in step S140, the proportion of the sum of the areas of the three content boxes of the text, table, and picture in the entire picture space size is first counted to obtain the actual space utilization R_F. In step S150, the preset ideal space utilization range is obtained. In this method, the ideal space utilization is a range, and as long as it is within the range, it is considered to be relatively good, so in step S170, it is only necessary to compare the relationship between the actual space utilization R_F and the ideal space utilization range to obtain the single frame category balance analysis result.

[0098] In one implementation, the process of step S170 includes:

[0099] The ideal space utilization range is [a,b];

[0100] If the actual space utilization R_F is within the ideal space utilization range, the space utilization analysis result S_space=1;

[0101] Otherwise, the space utilization analysis result S_space=1-|R_F-(a+b) / 2|.

[0102] In this embodiment, for example, the ideal space utilization rate range is set to [0.7, 0.9].

[0103] If the space utilization R_F is within the ideal space utilization range, S_space = 1; otherwise, S_space = 1-|R_F-0.8|. In this embodiment, the score is 1, which is the best score.

[0104] After step S160 and step S170, after obtaining the category balance analysis result and space utilization analysis result of a frame, step S180 further analyzes the frame according to these two results, so as to obtain the spatial feature analysis result of the single-frame courseware content.

[0105] In one embodiment, the process of obtaining the single-frame courseware content spatial feature analysis result according to the category balance analysis result and the space utilization analysis result of the single frame in step S180 includes:

[0106] The result of the spatial feature analysis of the content of a single-frame courseware is S_sstotal=alpha*S_balance+beta*S_space, where S_balance is the result of the category balance analysis, S_space is the result of the space utilization analysis, and alpha and beta are preset weight coefficients.

[0107] In one embodiment, the process of obtaining the courseware content spatial feature analysis results according to the spatial feature analysis results of each single-frame courseware content in step S180 includes: step S181, step S182, step S183 and step S184.

[0108] Step S181, obtaining a preset spatial feature threshold range;

[0109] Step S182, counting the first number of single-frame courseware content spatial feature analysis results within the preset spatial feature threshold range;

[0110] Step S183, according to the first number and the total number of courseware pictures, the proportion R_34 of frames that meet the requirements is obtained;

[0111] Step S184, obtaining the results of the courseware content space feature analysis based on R_34.

[0112] In this implementation, the courseware picture frames within the preset spatial feature threshold range are frames that meet the requirements, and the proportion of these frames in all frames is counted to obtain the proportion of frames that meet the requirements R_34. Based on this proportion, no correction is required, or a slight correction can be made to obtain the spatial feature analysis result of the entire courseware content.

[0113] Finally, in step S190, the courseware format analysis result is obtained using the courseware content space feature analysis result as one of the factors.

[0114] In this method, the positions of the title, text, table and picture are detected by analyzing the pictures presented in the courseware, and the actual value of the proportion of the number of titles, texts, tables and pictures is compared with the ideal value, and the actual value of the proportion of the area of ​​titles, texts, tables and pictures in the entire PPT is compared with the ideal value. With objective normative standards, the format of the teaching courseware is analyzed and evaluated, so as to obtain scientific and objective evaluation conclusions.

[0115] In one embodiment, the courseware format analysis result is also obtained based on the courseware visual design analysis result. Figure 2 As shown, the courseware visual design analysis includes: step S210, step S220, step S230, step S240 and step S250.

[0116] Step S210, for a single-frame courseware image, take the text as the target area, extract the RGB representation color of the text, take the background as the target area, extract the RGB representation color of the background, wherein the background is an image obtained by covering all the contents of the four categories of title, text, table, and picture;

[0117] Step S220, counting the colors with the largest proportion of text and background RGB representation colors in all frames of the entire courseware, and recording them as courseware text representation color RGB_tfg and courseware background representation color RGB_tbg respectively;

[0118] Step S230, based on hue, brightness and / or coldness and warmth, calculate the color contrast between the text representation color RGB_tfg and the courseware background representation color RGB_tbg, wherein the color contrast is calculated according to the ratio of the larger value to the smaller value between RGB_tfg and RGB_tbg;

[0119] Step S240, based on a preset contrast mapping model, obtaining a main color contrast analysis result R_33 according to the color contrast;

[0120] Step S250, obtaining the courseware visual design analysis result based on R_33;

[0121] The process of extracting the RGB color representation of the target area includes: step S211, step S212 and step S213;

[0122] Step S211, obtaining the hue of each pixel in the target area;

[0123] Step S212, determining the hue interval into which each pixel hue falls according to a preset color mapping method, wherein in the preset color mapping method, each fixed RGB representation color has a corresponding hue interval;

[0124] Step S213 : each target area uses the hue interval with the most pixel hues as its own RGB representation color.

[0125] For each frame of the courseware image, there is a background and a text. In this embodiment, the color usage of the background and the text is used to obtain the courseware visual design analysis result. In step S210, the main colors of the text and the background are found, that is, the characterizing colors. In this embodiment, the background is the part after all the four categories of content, namely, the title, the text, the table, and the picture, are covered.

[0126] Step S210 extracts the most commonly used color types for the background and text, and steps S211, S212, and S213 count the color of each pixel, using the most commonly used color for the pixel as the representative color of the target area. In actual operation, taking green as an example, there are many subdivided greens such as emerald green and dark green, so these subdivided categories are first classified into several categories in advance. In step S212, the color of each pixel is first classified into the corresponding category, that is, the hue interval, through a preset color mapping method. Step S213 counts these classified data, using the hue interval with the most pixel hues as its own RGB representative color.

[0127] In one implementation, the process of step S212 includes:

[0128] Convert pixel hue from RGB space to HSV space;

[0129] Determine whether the V value of the pixel hue is less than 46. If it is less than 46, it is determined to be black;

[0130] When the pixel hue is not black, determine whether the S value of the pixel hue is greater than 43. If it is greater than 43, determine it as color;

[0131] When the pixel hue is not a color, determine whether the V value of the pixel hue is greater than 221. If it is greater than 221, it is determined to be white, otherwise it is determined to be gray;

[0132] When the pixel hue is a color, the hue interval into which the pixel hue falls is determined according to the range intervals of various colors preset on the hue circle according to the H value of the pixel hue.

[0133] In this embodiment, the first step is to determine the three colors of black, white and gray. First, the pixel hue is converted from the RGB space to the HSV space; then, it is determined whether the pixels in the target area in the HSV format are colored or black, white and gray.

[0134] 1. Determine whether the V value of the pixel is less than 46. If it is less than 46, it is determined to be black;

[0135] 2. If the pixel is not black in the previous step, determine whether the S value of the pixel is greater than 43. If it is greater than 43, it is determined to be color;

[0136] 3. If the previous step is not color, determine whether the V value of the pixel is greater than 221. If it is greater than 221, it is determined to be white, otherwise it is determined to be gray.

[0137] like Figure 3 As shown, Figure 3A schematic diagram of dividing the hue range into 12 equal parts. After determining that the pixel hue is a color, the hue interval that the pixel hue falls into can be determined by looking at which color interval the pixel hue falls into.

[0138] After step S210, the RGB representation colors of the text and background in each frame are determined, and step S220 counts the entire courseware and counts the colors with the largest proportion of the text and background RGB representation colors, which are recorded as the courseware text representation color RGB_tfg and the courseware background representation color RGB_tbg respectively.

[0139] Step S230 calculates the color contrast between the courseware text representation color RGB_tfg and the courseware background representation color RGB_tbg. There are many contrast methods for obtaining the color contrast Cont_ratio, such as based on hue, brightness, pure color, cold and warm factors, etc. We take relative brightness as an example to calculate the color contrast.

[0140] Calculate the brightness value of the color to be compared:

[0141] L=0.2126×R+0.7152×G+0.0722×B;

[0142] Then calculate the contrast ratio of the two colors:

[0143] Cont_ratio=(L1+0.05) / (L2+0.05);

[0144] Among them, L1 is the value with larger brightness among the two colors, and L2 is the value with smaller brightness among the two colors.

[0145] After the color contrast is obtained in step S230, it can be used as a factor and put into a preset contrast mapping model to obtain the main color contrast analysis result R_33. The model can be a preset function mapping.

[0146] In one implementation, the preset contrast mapping model is:

[0147]

[0148] Among them, y is the color contrast.

[0149] Finally, step S250 obtains the courseware visual design analysis result based on the main color contrast analysis result R_33.

[0150] Corresponding weights can be preset between the courseware visual design analysis results and the courseware content space feature analysis results to obtain the courseware format analysis results.

[0151] In one embodiment, the courseware visual design analysis result is also obtained based on the color diversity analysis result. The process of obtaining the color diversity analysis result includes: step S310, step S320 and step S330.

[0152] Step S310, counting the number of background RGB representation colors in all frames of the entire courseware that are different from the representation color RGB_tbg of the courseware background, recorded as N_dgb;

[0153] Step S320, obtaining an ideal color category number range [n_min, n_max];

[0154] Step S330, if N_dgb is within the ideal color category number range, the color diversity analysis result S_32=1; otherwise, the color diversity analysis result S_32=1-(|N_dfg-(n_min+n_max) / 2| / max(n_min,N_dfg-n_min)).

[0155] The color diversity analysis of this embodiment is to encourage moderate color changes. Assuming that the ideal color category number range is [3,5], if the number N_dfg of the characterizing colors RGB_tbg used by the courseware that are different from the courseware background is within this range, then S_32 = 1, otherwise S_32 = 1-(|N_dfg-(3+5) / 2| / max(3,N_dfg-3)).

[0156] In one embodiment, the courseware visual design analysis result is also obtained based on the color consistency analysis result. The process of obtaining the color consistency analysis result includes: step S410 and step S420.

[0157] Step S410, counting the number of text and background RGB representation colors in all frames of the entire courseware that are different from the courseware text representation color RGB_tfg and the courseware background representation color RGB_tbg, which are recorded as N_dfg and N_dgb respectively;

[0158] Step S420, color consistency analysis result S_31 = 1-(w_fg*N_dfg+w_fg*N_dgb) / 2*N, where N is the total number of frames of the courseware, and w_fg and w_bg are both preset weights.

[0159] For the main color contrast analysis result R_33, the color diversity analysis result S_32 and the color consistency analysis result S_31, the corresponding weights can be preset respectively to obtain the courseware visual design analysis results.

[0160] Embodiment 2

[0161] Corresponding to the method of embodiment 1, as Figure 4 As shown, the present invention also provides a courseware format analysis device, including: an acquisition module 410, a detection module 420, a first statistics module 430, a first analysis module 440 and a total analysis module 450;

[0162] The acquisition module 410 is used to acquire courseware images, wherein the courseware images are obtained by converting courseware data into image type data; acquire preset ideal values ​​of the percentages of the title, text, table and image in the total number respectively, and acquire a preset ideal range of space utilization;

[0163] The detection module 420 is used to detect each frame of the courseware image and detect the title, text, table and image;

[0164] The first statistical module 430 is used to count the total number of titles, texts, tables and pictures in a single-frame courseware picture, as well as the actual value of the percentage of the total number of titles, texts, tables and pictures respectively; and to count the proportion of the sum of the areas of the three content frames of the text, table and picture in the total picture space to obtain the actual space utilization rate R_F;

[0165] The first analysis module 440 is used to obtain a single-frame category balance analysis result based on the difference between the actual value and the ideal value of the percentage of the title, text, table and picture in the total number respectively; obtain a single-frame space utilization analysis result based on the relationship between the actual space utilization rate R_F and the ideal space utilization rate range; obtain a single-frame courseware content space feature analysis result based on the category balance analysis result and the space utilization analysis result of the single frame, and obtain a courseware content space feature analysis result based on the space feature analysis results of each single-frame courseware content;

[0166] The overall analysis module 450 is used to obtain the courseware format analysis result based on the courseware content space feature analysis result.

[0167] In one embodiment, the first analysis module executes the process of obtaining the single-frame category balance analysis result based on the difference between the actual value and the ideal value of the percentage of the total number of titles, texts, tables and pictures, respectively, including:

[0168] Let the category balance analysis result S_balance = 1-|N_title-P_title|-|N_text-P_text|-|N_table-P_table|-|N_img-P_img|;

[0169] Among them, N_title is the ideal value of the percentage of the title in the total number, P_title is the actual value of the percentage of the title in the total number, N_text is the ideal value of the percentage of the text in the total number, P_text is the actual value of the percentage of the text in the total number, N_table is the ideal value of the percentage of the table in the total number, P_table is the actual value of the percentage of the table in the total number, N_img is the ideal value of the percentage of the image in the total number, P_img is the actual value of the percentage of the image in the total number.

[0170] In one embodiment, the first analysis module executes the process of obtaining a single-frame space utilization analysis result based on the relationship between the actual space utilization R_F and the ideal space utilization range, including:

[0171] The ideal space utilization range is [a,b];

[0172] If the actual space utilization R_F is within the ideal space utilization range, the space utilization analysis result S_space=1;

[0173] Otherwise, the space utilization analysis result S_space=1-|R_F-(a+b) / 2|.

[0174] In one embodiment, the first analysis module performs the process of obtaining the single-frame courseware content spatial feature analysis result based on the category balance analysis result and the space utilization analysis result of the single frame, including:

[0175] The result of the spatial feature analysis of the content of a single-frame courseware is S_sstotal=alpha*S_balance+beta*S_space, where S_balance is the result of the category balance analysis, S_space is the result of the space utilization analysis, and alpha and beta are preset weight coefficients.

[0176] In one embodiment, the first analysis module executes the process of obtaining the courseware content space feature analysis result based on the single-frame courseware content space feature analysis result, including:

[0177] Obtaining a preset spatial feature threshold range;

[0178] Counting the first number of the spatial feature analysis results of the single-frame courseware content within the preset spatial feature threshold range;

[0179] According to the first number and the total number of courseware pictures, the proportion of frames that meet the requirements is obtained R_34;

[0180] Based on the R_34, the results of the courseware content space feature analysis are obtained.

[0181] In one embodiment, it further includes:

[0182] The extraction module is used to extract the RGB color representation of the text and the background from a single-frame courseware image, with the text as the target area, and the RGB color representation of the background as the target area. The background is an image obtained by covering all the contents of the four categories of title, text, table, and picture.

[0183] The second statistical module is used to count the colors with the largest proportion of text and background RGB representation colors in all frames of the entire courseware, which are recorded as courseware text representation color RGB_tfg and courseware background representation color RGB_tbg respectively;

[0184] The second analysis module is used to calculate the color contrast between the text representation color RGB_tfg and the courseware background representation color RGB_tbg based on hue, brightness and / or coldness and warmth, wherein the color contrast is obtained according to the ratio of the larger value to the smaller value between RGB_tfg and RGB_tbg; based on a preset contrast mapping model, obtain the main color contrast analysis result R_33 according to the color contrast; and obtain the courseware visual design analysis result based on R_33;

[0185] The overall analysis module is also used to obtain a courseware format analysis result based on the courseware visual design analysis result.

[0186] The extraction module performs the process of extracting the RGB color representation of the target area, including:

[0187] Get the hue of each pixel in the target area;

[0188] Determine the hue interval into which each pixel hue falls according to a preset color mapping method, wherein in the preset color mapping method, each fixed RGB representation color has a corresponding hue interval;

[0189] Each target area uses the hue interval with the most pixel hues as its own RGB representation color;

[0190] The process of obtaining the courseware format analysis result is also based on the courseware visual design analysis result.

[0191] In this device, the positions of titles, texts, tables and pictures are detected by analyzing the pictures presented in the courseware. By comparing the actual values ​​of the proportion of the number of titles, texts, tables and pictures with the ideal values, and by comparing the actual values ​​of the proportion of the area of ​​titles, texts, tables and pictures in the entire PPT with the ideal values, the format of the teaching courseware is analyzed and evaluated with objective normative standards, thereby obtaining scientific and objective evaluation conclusions.

[0192] Embodiment 3

[0193] An embodiment of the present invention further provides a storage medium on which computer instructions are stored. When the instructions are executed by a processor, the courseware format analysis method of any of the above embodiments is implemented.

[0194] Those skilled in the art can understand that: all or part of the steps of implementing the above method embodiments can be completed by hardware related to program instructions, and the aforementioned program can be stored in a computer-readable storage medium. When the program is executed, it executes the steps of the above method embodiments; and the aforementioned storage medium includes: mobile storage devices, random access memories (RAM), read-only memories (ROM), magnetic disks or optical disks, etc., various media that can store program codes.

[0195] Alternatively, if the above-mentioned integrated unit of the present invention is implemented in the form of a software function module and sold or used as an independent product, it can also be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the embodiment of the present invention can be essentially or partly reflected in the form of a software product that contributes to the relevant technology. The computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, terminal, or network device, etc.) to execute all or part of the methods of each embodiment of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as mobile storage devices, RAM, ROM, magnetic disks or optical disks.

[0196] Corresponding to the above-mentioned computer storage medium, in one embodiment, a computer device is also provided, which includes a memory, an encoder, and a computer program stored in the memory and executable on the encoder, wherein when the encoder executes the program, it implements any one of the courseware format analysis methods in the above-mentioned embodiments.

[0197] The above-mentioned computer equipment analyzes the images presented in the courseware to detect the positions of the title, text, table and picture, compares the actual value of the proportion of the number of the title, text, table and picture with the ideal value, and compares the actual value of the proportion of the area of ​​the title, text, table and picture in the entire PPT with the ideal value, and analyzes and evaluates the format of the teaching courseware with objective and standardized standards, thereby obtaining scientific and objective evaluation conclusions.

[0198] The technical features of the above-described embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above-described embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0199] Obviously, the above embodiments of the present invention are merely examples for clearly illustrating the present invention, and are not intended to limit the embodiments of the present invention. For those skilled in the art, other different forms of changes or modifications can be made based on the above description. It is not necessary and impossible to list all the embodiments here. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the claims of the present invention.

Claims

1. A courseware format analysis method, characterized in that: include: Obtaining a courseware picture, wherein the courseware picture is obtained by converting courseware data into image type data; Detect each frame of the courseware image to detect the title, text, table and image; For a single-frame courseware image, count the total number of titles, texts, tables, and images combined, as well as the actual values ​​of the percentages of titles, texts, tables, and images in the total number; Count the proportion of the sum of the areas of the text, table, and picture content boxes in the entire picture space to get the actual space utilization rate; Get the preset ideal values ​​of the percentages of the title, text, table and picture in the total quantity respectively, and get the preset ideal range of space utilization; The results of the single-frame category balance analysis are obtained based on the difference between the actual and ideal percentages of the total number of titles, texts, tables, and pictures; According to the relationship between the actual space utilization and the ideal space utilization range, the single-frame space utilization analysis result is obtained; According to the category balance analysis result and the space utilization analysis result of the single frame, a single frame courseware content space feature analysis result is obtained, and according to the spatial feature analysis results of each single frame courseware content, a courseware content space feature analysis result is obtained; Based on the results of the courseware content space feature analysis, the courseware format analysis results are obtained.

2. The courseware format analysis method according to claim 1, characterized in that: The process of obtaining the single-frame category balance analysis result according to the difference between the actual value and the ideal value of the percentage of the title, text, table and picture in the total number, includes: Let the category balance analysis result S_balance = 1-|N_title-P_title|-|N_text-P_text|-|N_table-P_table|-|N_img-P_img|; Among them, N_title is the ideal value of the percentage of the title in the total number, P_title is the actual value of the percentage of the title in the total number, N_text is the ideal value of the percentage of the text in the total number, P_text is the actual value of the percentage of the text in the total number, N_table is the ideal value of the percentage of the table in the total number, P_table is the actual value of the percentage of the table in the total number, N_img is the ideal value of the percentage of the image in the total number, P_img is the actual value of the percentage of the image in the total number.

3. The courseware format analysis method according to claim 1, characterized in that: The process of obtaining the single-frame space utilization analysis result according to the relationship between the actual space utilization and the ideal space utilization range includes: The ideal space utilization range is [a,b]; If the actual space utilization is within the ideal space utilization range, the space utilization analysis result S_space=1; Otherwise, the space utilization analysis result S_space=1-|R_F-(a+b) / 2|, where R_F is the actual space utilization.

4. The courseware format analysis method according to claim 1, 2 or 3, characterized in that: The process of obtaining the spatial feature analysis result of the single-frame courseware content according to the category balance analysis result and the space utilization analysis result of the single-frame includes: The result of the spatial feature analysis of the content of a single-frame courseware is S_sstotal=alpha*S_balance+beta*S_space, where S_balance is the result of the category balance analysis, S_space is the result of the space utilization analysis, and alpha and beta are preset weight coefficients.

5. The courseware format analysis method according to claim 4, characterized in that: The process of obtaining the courseware content space feature analysis result according to the single-frame courseware content space feature analysis result includes: Obtaining a preset spatial feature threshold range; Counting the first number of the spatial feature analysis results of the single-frame courseware content within the preset spatial feature threshold range; According to the first number and the total number of courseware pictures, the proportion of frames that meet the requirements is obtained R_34; Based on the R_34, the results of the courseware content space feature analysis are obtained.

6. The courseware format analysis method according to claim 1, characterized in that: Also includes: For a single-frame courseware image, the text is taken as the target area, and the RGB representation color of the text is extracted; the background is taken as the target area, and the RGB representation color of the background is extracted. The background is the image obtained by covering all the contents of the four categories of title, text, table, and picture. Count the colors with the largest proportion of text and background RGB representation colors in all frames of the entire courseware, and record them as courseware text representation color RGB_tfg and courseware background representation color RGB_tbg respectively; Based on hue, brightness and / or coldness and warmth, calculate the color contrast between the text representation color RGB_tfg and the courseware background representation color RGB_tbg, wherein the color contrast is calculated according to the ratio of the larger value to the smaller value between RGB_tfg and RGB_tbg; Based on the preset contrast mapping model, the main color contrast analysis result R_33 is obtained according to the color contrast; Based on the R_33, the results of the courseware visual design analysis are obtained; The process of extracting the RGB color representation of the target area includes: Get the hue of each pixel in the target area; Determine the hue interval into which each pixel hue falls according to a preset color mapping method, wherein in the preset color mapping method, each fixed RGB representation color has a corresponding hue interval; Each target area uses the hue interval with the most pixel hues as its own RGB representation color; The process of obtaining the courseware format analysis result is also based on the courseware visual design analysis result.

7. The courseware format analysis method according to claim 6, characterized in that: The process of determining the hue interval into which each pixel hue falls according to a preset color mapping method includes: Convert pixel hue from RGB space to HSV space; Determine whether the V value of the pixel hue is less than 46. If it is less than 46, it is determined to be black; When the pixel hue is not black, determine whether the S value of the pixel hue is greater than 43. If it is greater than 43, determine it as color; When the pixel hue is not a color, determine whether the V value of the pixel hue is greater than 221. If it is greater than 221, it is determined to be white, otherwise it is determined to be gray; When the pixel hue is a color, the hue interval into which the pixel hue falls is determined according to the range intervals of various colors preset on the hue circle according to the H value of the pixel hue.

8. The courseware format analysis method according to claim 6, characterized in that: The preset contrast mapping model is: Among them, y is the color contrast.

9. The courseware format analysis method according to claim 6, characterized in that: Count the number of background RGB representation colors in all frames of the entire courseware that are different from the representation color RGB_tbg of the courseware background, recorded as N_dgb; Get the ideal color category number range [n_min,n_max]; If N_dgb is within the ideal color category number range, the color diversity analysis result S_32=1; otherwise, the color diversity analysis result S_32=1-(|N_dfg-(n_min+n_max) / 2| / max(n_min,N_dfg-n_min)); The process of obtaining the courseware visual design analysis result is also based on the color diversity analysis result.

10. The courseware format analysis method according to claim 6, characterized in that: Count the number of text and background RGB representation colors in all frames of the entire courseware that are different from the courseware text representation color RGB_tfg and the courseware background representation color RGB_tbg, which are recorded as N_dfg and N_dgb respectively; Color consistency analysis result S_31 = 1-(w_fg*N_dfg+w_fg*N_dgb) / 2*N, where N is the total number of frames of the courseware, and w_fg and w_bg are both preset weights; The process of obtaining the courseware visual design analysis result is also based on the color consistency analysis result.

11. A courseware format analysis device, characterized in that: include: The acquisition module is used to acquire courseware images, wherein the courseware images are obtained by converting courseware data into image type data; acquire the preset ideal values ​​of the percentages of the title, text, table and image in the total number respectively, and acquire the preset ideal space utilization range; The detection module is used to detect each frame of the courseware image and detect the title, text, table and image; The first statistical module is used to count the total number of titles, texts, tables and pictures in a single-frame courseware picture, as well as the actual value of the percentage of the total number of titles, texts, tables and pictures respectively; and to count the proportion of the sum of the areas of the three content frames of the text, table and picture in the entire picture space to obtain the actual space utilization rate; The first analysis module is used to obtain a single-frame category balance analysis result based on the difference between the actual value and the ideal value of the percentage of the title, text, table and picture in the total number respectively; obtain a single-frame space utilization analysis result based on the relationship between the actual space utilization and the ideal space utilization range; obtain a single-frame courseware content space feature analysis result based on the category balance analysis result and the space utilization analysis result of the single frame, and obtain a courseware content space feature analysis result based on the space feature analysis results of each single-frame courseware content; The overall analysis module is used to obtain the courseware format analysis results based on the courseware content space feature analysis results.

12. A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the method according to any one of claims 1 to 10 is implemented.

13. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 10 is implemented.