Exercise word recommendation method, device and apparatus

By evaluating students' handwriting and recommending practice characters based on pre-set calligraphy knowledge maps, the problem of calligraphy teachers' difficulty in conducting targeted assessments is solved, thus improving students' calligraphy learning efficiency.

CN116110060BActive Publication Date: 2026-03-03INST OF AUTOMATION CHINESE ACAD OF SCI
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202310073041.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-01-13
Publication Date
2026-03-03
Estimated Expiration
2043-01-13

AI Technical Summary

Technical Problem

In the current technology, it is difficult for calligraphy teachers to evaluate each calligraphy character written by each student, resulting in poor teaching focus and low learning efficiency for students.

Method used

By acquiring images of students' handwriting, the system evaluates the characters based on template characters, identifies problematic strokes and radicals, and recommends practice characters using a pre-set calligraphy knowledge graph, thereby improving the relevance of the evaluation.

Benefits of technology

It enables precise evaluation of each student's calligraphy character, improving students' calligraphy learning efficiency and allowing for timely correction of writing problems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116110060B_ABST
    Figure CN116110060B_ABST
Patent Text Reader

Abstract

The application provides a writing practice word recommendation method, device and equipment. The method comprises the following steps: obtaining a practice image, wherein the practice image comprises a writing word currently written by a student; performing an evaluation process on the writing word in the practice image based on a template word corresponding to the writing word, to obtain an evaluation result; determining a writing practice word from a plurality of preset words based on the evaluation result, wherein the plurality of preset words comprise the template word; and recommending the writing practice word to the student. The writing practice word recommendation method, device and equipment provided by the application are used to improve the calligraphy learning efficiency of the student.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of calligraphy practice technology, and in particular to a method, apparatus, and device for recommending practice characters. Background Technology

[0002] Calligraphy is the essence of traditional Chinese culture and a unique art form of the Chinese nation. Currently, calligraphy teachers mainly teach multiple students through a teaching model that includes demonstration, copying, and evaluation.

[0003] When calligraphy teachers evaluate the calligraphy works of multiple students, they usually only evaluate common problems that appear in the works of multiple students. It is difficult to evaluate each individual character written by each student, resulting in poor teaching focus and low learning efficiency for students.

[0004] Therefore, how to evaluate the calligraphy written by each student in a targeted manner and recommend relevant characters to students in order to improve their calligraphy learning efficiency has become an urgent technical problem to be solved. Summary of the Invention

[0005] This invention provides a method, apparatus, and device for recommending calligraphy practice characters, which addresses the shortcomings of existing technologies where calligraphy teachers find it difficult to evaluate each calligraphy character written by each student, resulting in poor teaching focus and low calligraphy learning efficiency for students. This invention aims to improve the calligraphy learning efficiency of students.

[0006] In a first aspect, the present invention provides a method for recommending practice characters, comprising:

[0007] Obtain an image of the student's work; the image includes the handwriting currently being written by the student.

[0008] Based on the template characters corresponding to the handwritten characters, the handwritten characters in the student artwork images are evaluated and the evaluation results are obtained.

[0009] Based on the evaluation results, practice characters were selected from a number of preset characters; these preset characters included template characters.

[0010] And recommend practice characters to students.

[0011] According to the present invention, a method for recommending practice characters involves evaluating the handwritten characters in a practice image based on template characters corresponding to the handwritten characters, and obtaining evaluation results, including:

[0012] Based on the student's artwork and the template character, determine the individual strokes of the written character;

[0013] Based on the template characters, each writing stroke, and the mapping relationship between each radical and each stroke of multiple preset characters stored in the character radical information database, the writing radical of the writing character is determined;

[0014] Based on the template character, identify the problematic strokes in each writing stroke and determine the first problem degree value of the problematic strokes;

[0015] Based on each written radical and template character, the problematic radical is identified, and the second problem severity value of the problematic radical is determined.

[0016] The evaluation results include the number of problematic strokes, the severity of the first problem, the problematic radical, and the severity of the second problem.

[0017] According to a method for recommending practice characters provided by the present invention, based on template characters, problem strokes are identified in each writing stroke, and a first problem severity value is determined for each problem stroke, including:

[0018] Perform the following operations for each written stroke:

[0019] Extract the first number of outline points from the outline points of the written strokes, and extract the first number of outline points from the outline points of the template strokes corresponding to the written strokes in the template characters.

[0020] Based on the extracted multiple contour points, the Hausdorff distance corresponding to the writing stroke is determined;

[0021] If the Hausdorff distance is greater than the first preset distance, the written stroke is identified as a problem stroke;

[0022] The first problem severity value is determined based on the Hausdorff distance and error baseline.

[0023] According to the present invention, a method for recommending practice characters is provided, which identifies problematic radicals based on various writing radicals and template characters, including:

[0024] For any two first and second written radicals in each written radical group, perform the following operation:

[0025] Determine the first centroid distance and the first minimum edge distance between the first and second written radicals;

[0026] Determine the second centroid distance and the second minimum edge distance between the first template radical corresponding to the first writing radical in the template character and the second template radical corresponding to the second writing radical in the template character;

[0027] Determine the first absolute value of the difference between the first centroid distance and the second centroid distance;

[0028] If the second absolute value of the difference between the first edge minimum distance and the second edge minimum distance is greater than the first absolute value and / or greater than the preset centroid distance, then the first writing radical and the second writing radical are determined to be problem radicals.

[0029] According to a method for recommending practice characters provided by the present invention, determining the first centroid distance and the first minimum edge distance between a first writing radical and a second writing radical includes:

[0030] The first minimum convex hull surface of the first writing radical and the second minimum convex hull surface of the second writing radical are determined respectively.

[0031] The first centroid distance is determined based on the centroid distance between the first minimum convex hull surface and the second minimum convex hull surface.

[0032] The first minimum edge distance is determined based on the minimum edge distance between the first minimum convex hull surface and the second minimum convex hull surface.

[0033] According to the present invention, a method for recommending practice characters, based on evaluation results, determines practice characters from a plurality of preset characters, including:

[0034] Based on the problematic strokes and radicals in the evaluation results, as well as the template characters and the preset calligraphy knowledge graph, multiple candidate characters are determined from multiple preset characters; among them, the preset calligraphy knowledge graph includes the feature vector of each preset character, the stroke feature vector of each stroke of the preset character, and the radical feature vector of each radical of the preset character.

[0035] Extract the stroke feature vector of the problematic stroke from the preset calligraphy knowledge graph;

[0036] Based on a pre-defined calligraphy knowledge graph, the radical feature vector of the problematic radical is determined;

[0037] Based on stroke feature vectors and radical feature vectors, the fusion feature vector of the written character is determined;

[0038] By using a preset encoder, the fused feature vector and the fused feature vector of multiple historical written characters are processed to obtain the target feature vector;

[0039] Based on the target feature vector and the feature vectors of multiple candidate characters, practice characters are determined from the multiple candidate characters.

[0040] According to a method for recommending practice characters provided by the present invention, based on problematic strokes and radicals in the evaluation results, as well as template characters and preset calligraphy knowledge graphs, multiple candidate characters are determined from multiple preset characters, including:

[0041] Based on the problem strokes, template characters, and preset calligraphy knowledge graphs, the first candidate character is determined from multiple preset characters;

[0042] Based on the problem radical, template characters, and preset calligraphy knowledge graph, the second candidate character is determined from multiple preset characters;

[0043] The first and second candidate characters are determined as multiple candidate characters.

[0044] According to the present invention, a method for recommending practice characters, based on problematic strokes, template characters, and a preset calligraphy knowledge graph, determines a first candidate character from a plurality of preset characters, including:

[0045] From the preset calligraphy knowledge graph, obtain the feature vector of the template stroke corresponding to the problem stroke in the template character, and the feature vector of the target stroke corresponding to the template stroke in each preset character;

[0046] Determine the similarity between the feature vectors of the template strokes and the feature vectors of each target stroke;

[0047] The preset characters to which the N target strokes with the highest similarity belong are determined as the first candidate characters; where N is an integer greater than or equal to 1.

[0048] Secondly, the present invention also provides a practice character recommendation device, comprising:

[0049] The acquisition module is used to acquire images of student work; these images include the handwritten characters currently being written by the student.

[0050] The evaluation module is used to evaluate the handwritten characters in the student artwork image based on the template characters corresponding to the handwritten characters, and obtain the evaluation results.

[0051] The determination module is used to select practice characters from multiple preset characters based on the evaluation results; the multiple preset characters include template characters.

[0052] The recommendation module is used to recommend characters for practice to students.

[0053] According to the present invention, a practice character recommendation device is provided, wherein the evaluation module is specifically used for:

[0054] Based on the student's artwork and the template character, determine the individual strokes of the written character;

[0055] Based on the template characters, each writing stroke, and the mapping relationship between each radical and each stroke of multiple preset characters stored in the character radical information database, the writing radical of the writing character is determined;

[0056] Based on the template character, identify the problematic strokes in each writing stroke and determine the first problem degree value of the problematic strokes;

[0057] Based on each written radical and template character, the problematic radical is identified, and the second problem severity value of the problematic radical is determined.

[0058] The evaluation results include the number of problematic strokes, the severity of the first problem, the problematic radical, and the severity of the second problem.

[0059] According to the present invention, a practice character recommendation device is provided, wherein the evaluation module is specifically used for:

[0060] Perform the following operations for each written stroke:

[0061] Extract the first number of outline points from the outline points of the written strokes, and extract the first number of outline points from the outline points of the template strokes corresponding to the written strokes in the template characters.

[0062] Based on the extracted multiple contour points, the Hausdorff distance corresponding to the writing stroke is determined;

[0063] If the Hausdorff distance is greater than the first preset distance, the written stroke is identified as a problem stroke;

[0064] The first problem severity value is determined based on the Hausdorff distance and error baseline.

[0065] According to the present invention, a practice character recommendation device is provided, wherein the evaluation module is specifically used for:

[0066] For any two first and second written radicals in each written radical group, perform the following operation:

[0067] Determine the first centroid distance and the first minimum edge distance between the first and second written radicals;

[0068] Determine the second centroid distance and the second minimum edge distance between the first template radical corresponding to the first writing radical in the template character and the second template radical corresponding to the second writing radical in the template character;

[0069] Determine the first absolute value of the difference between the first centroid distance and the second centroid distance;

[0070] Determine the second absolute value of the difference between the minimum distance of the first edge and the minimum distance of the second edge.

[0071] If the first absolute value is greater than the preset centroid distance and / or the second absolute value is greater than the preset minimum edge distance, the first and second writing radicals are determined to be problematic radicals.

[0072] According to the present invention, a practice character recommendation device is provided, wherein the evaluation module is specifically used for:

[0073] The first minimum convex hull surface of the first writing radical and the second minimum convex hull surface of the second writing radical are determined respectively.

[0074] The first centroid distance is determined based on the centroid distance between the first minimum convex hull surface and the second minimum convex hull surface.

[0075] The first minimum edge distance is determined based on the minimum edge distance between the first minimum convex hull surface and the second minimum convex hull surface.

[0076] According to the present invention, a practice character recommendation device is provided, wherein the determining module is specifically used for:

[0077] Based on the problematic strokes and radicals in the evaluation results, as well as the template characters and the preset calligraphy knowledge graph, multiple candidate characters are determined from multiple preset characters; among them, the preset calligraphy knowledge graph includes the feature vector of each preset character, the stroke feature vector of each stroke of the preset character, and the radical feature vector of each radical of the preset character.

[0078] Extract the stroke feature vector of the problematic stroke from the preset calligraphy knowledge graph;

[0079] Based on a pre-defined calligraphy knowledge graph, the radical feature vector of the problematic radical is determined;

[0080] Based on stroke feature vectors and radical feature vectors, the fusion feature vector of the written character is determined;

[0081] By using a preset encoder, the fused feature vector and the fused feature vector of multiple historical written characters are processed to obtain the target feature vector;

[0082] Based on the target feature vector and the feature vectors of multiple candidate characters, practice characters are determined from the multiple candidate characters.

[0083] According to the present invention, a practice character recommendation device is provided, wherein the determining module is specifically used for:

[0084] Based on the problem strokes, template characters, and preset calligraphy knowledge graphs, the first candidate character is determined from multiple preset characters;

[0085] Based on the problem radical, template characters, and preset calligraphy knowledge graph, the second candidate character is determined from multiple preset characters;

[0086] The first and second candidate characters are determined as multiple candidate characters.

[0087] According to the present invention, a practice character recommendation device is provided, wherein the determining module is specifically used for:

[0088] From the preset calligraphy knowledge graph, obtain the feature vector of the template stroke corresponding to the problem stroke in the template character, and the feature vector of the target stroke corresponding to the template stroke in each preset character;

[0089] Determine the similarity between the feature vectors of the template strokes and the feature vectors of each target stroke;

[0090] The preset characters to which the N target strokes with the highest similarity belong are determined as the first candidate characters; where N is an integer greater than or equal to 1.

[0091] Thirdly, the present invention also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement any of the above-described methods for recommending practice characters.

[0092] Fourthly, the present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements any of the above-described methods for recommending practice characters.

[0093] Fifthly, the present invention also provides a computer program product, including a computer program that, when executed by a processor, implements any of the above-described methods for recommending practice characters.

[0094] This invention provides a method, apparatus, and device for recommending practice characters. By acquiring images of student-written characters, and evaluating the characters based on corresponding template characters, the invention avoids the difficulty for calligraphy teachers to evaluate each character written by each student. It enables evaluation of each character, thereby improving the efficiency of students' calligraphy learning. Attached Figure Description

[0095] To more clearly illustrate the technical solutions in this invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0096] Figure 1 This is a flowchart illustrating the method for recommending practice characters provided by this invention;

[0097] Figure 2 This is a schematic diagram of the written characters and template characters provided by the present invention;

[0098] Figure 3 This is a schematic diagram of the method for obtaining evaluation results provided by the present invention;

[0099] Figure 4 This is a flowchart of the method for obtaining practice characters provided by the present invention;

[0100] Figure 5 This is a schematic diagram of the structure of the preset calligraphy knowledge graph provided by the present invention;

[0101] Figure 6 This is a schematic diagram of the network structure of the Transformer encoder provided by the present invention;

[0102] Figure 7 This is one of the structural schematic diagrams of the intelligent calligraphy learning system provided by the present invention;

[0103] Figure 8 This is the second structural schematic diagram of the intelligent calligraphy learning system provided by the present invention;

[0104] Figure 9 This is a schematic diagram of the structure of the calligraphy practice recommendation device provided by the present invention;

[0105] Figure 10 This is a schematic diagram of the physical structure of the electronic device provided by the present invention. Detailed Implementation

[0106] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.

[0107] In this invention, the term "comprising" and its variations can refer to a non-limiting inclusion; the term "or" and its variations can refer to "and / or". The terms "first", "second", etc., in this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. In this invention, "at least one" refers to two or more. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, and B existing alone. The character " / " generally indicates that the preceding and following related objects have an "or" relationship.

[0108] In existing technologies, when calligraphy teachers evaluate the calligraphy works written by multiple students, they usually only evaluate common problems that appear in the calligraphy works written by multiple students. It is difficult to evaluate each calligraphy work written by each student individually, resulting in poor teaching focus and low learning efficiency for students.

[0109] In this invention, in order to improve the efficiency of students' calligraphy learning, the inventors designed a method for recommending practice characters. In this method, for each student, the inventors evaluate the student's work image to obtain the evaluation result, and then recommend practice characters to the student based on the evaluation result. This makes the teaching more targeted and can improve the efficiency of students' calligraphy learning.

[0110] The following is a description of the practice character recommendation method provided by the present invention in combination with Figure 1 specific embodiments.

[0111] Figure 1 is a schematic flowchart of the practice character recommendation method provided by the present invention. As Figure 1 shown, the practice character recommendation method provided in this embodiment includes:

[0112] Step 101, obtain a practice image; wherein, the practice image includes the writing characters currently written by the student.

[0113] Optionally, for the practice character recommendation method provided by the present invention, the execution subject can be an electronic device or a practice character recommendation device provided in the electronic device.

[0114] The electronic device can be, for example, a mobile phone, a computer, an all-in-one machine with scanning and printing functions, etc.

[0115] The practice character recommendation device can be implemented by the combination of software and / or hardware. For example, when the practice character recommendation device is implemented by software, it can be Figure 7 or Figure 8 the intelligent calligraphy learning system shown.

[0116] Optionally, the practice image is any one of the following:

[0117] The original image obtained by taking a photo of the writing characters currently written by the student;

[0118] The image after correcting the shooting angle of the original image;

[0119] The black-and-white image obtained by binarizing the original image.

[0120] For example, when the electronic device is a mobile phone, the original image can be a calligraphy image obtained by taking a photo of the writing characters through the camera of the mobile phone.

[0121] For example, when the electronic device is a computer, the original image can be a calligraphy image sent by a scanning device (such as a scanner, the above-mentioned all-in-one machine, etc.) to the computer, where the calligraphy image is an image obtained by the scanning device scanning the writing characters.

[0122] Step 102, based on the template characters corresponding to the writing characters, perform evaluation processing on the writing characters in the practice image to obtain an evaluation result.

[0123] For example, when the writing character is "国", the template character is "国". Figure 2 is a schematic diagram of a template character and a writing character in a black-and-white image provided by the present invention. As Figure 2 shown, it includes: the template character and the writing character in the black-and-white image.

[0124] Optionally, based on the template character, evaluation processing can be performed on each writing brushstroke and / or each writing radical of the written character. Correspondingly, the evaluation result may include: the problematic stroke and the first problem degree value of the problematic stroke, and / or, the problematic radical and the second problem degree value of the problematic radical.

[0125] The problematic stroke is a writing stroke with relatively poor writing quality among all writing strokes.

[0126] The first problem degree value indicates the severity of relatively poor quality. The larger the first problem degree value, the greater the severity; conversely, the smaller the severity.

[0127] The problematic radical is a radical with centroid problems and / or edge problems, and the centroid problems and / or edge problems indicate relatively poor structural quality between two writing radicals.

[0128] The second problem degree value indicates the severity of the centroid problems and / or edge problems existing in the problematic radical. The larger the second problem degree value, the greater the severity; conversely, the smaller the severity.

[0129] Optionally, the evaluation result may further include the above-mentioned radical problems.

[0130] Step 103: Based on the evaluation result, determine practice characters from multiple preset characters; among them, the multiple preset characters include the template character.

[0131] Optionally, the number of practice characters can be one or more. The practice characters can be one or more preset characters with the greatest similarity to the template character among the multiple preset characters.

[0132] Optionally, the practice characters can also be any of the following:

[0133] The template character;

[0134] The preset character with the same structure as the written character;

[0135] The preset character with the same radical as the written character;

[0136] The preset character with the same strokes as the written character.

[0137] Optionally, the structure can be left-right structure, up-down structure, left-middle-right structure, or up-middle-down structure, etc.

[0138] For example, in the case where the evaluation result includes a problematic stroke, if the problematic stroke is "one", and the written character is "forest", the practice characters can be the template character "forest", the template character "sample", etc.

[0139] For example, when the problem radical is included in the evaluation result, if the problem radical is "亻", and the written character is "优" with a left-right structure, the practice character can be "伏" with a left-right structure.

[0140] Step 104: Recommend practice characters to the trainee.

[0141] For example, when the electronic device is a mobile phone (or a computer), practice characters can be displayed on the screen of the mobile phone (or the computer) to recommend practice characters to the trainee. Further, the mobile phone (or the computer) can be communicatively connected to a printing device (such as a printer, the above-mentioned all-in-one machine). When the mobile phone (or the computer) sends the practice characters to the printing device, the printing device can directly print the practice characters so that the trainee can promptly practice calligraphy based on the printed practice characters.

[0142] In the present invention, a习作 image is obtained, and the习作 image includes the written characters written by the trainee. Based on the template characters corresponding to the written characters, the written characters are evaluated to obtain an evaluation result, which avoids the defect that it is difficult for calligraphy teachers to evaluate each calligraphy character written by each trainee and can evaluate each calligraphy character specifically. Further, since the practice characters are preset characters obtained based on the evaluation result, during the process of the trainee practicing calligraphy based on the practice characters, the writing problems of the trainee can be corrected promptly, thereby improving the efficiency of the trainee's calligraphy learning.

[0143] On the basis of the above embodiments, the following further Figure 3 makes a further detailed explanation of step 102.

[0144] Figure 3 is a schematic flowchart of the method for obtaining the evaluation result provided by the present invention. As Figure 3 shown, the method includes:

[0145] Step 301: Determine each writing stroke of the written character based on the习作 image and the template character.

[0146] Optionally, step 301 may include the following steps 3011 to step 3022.

[0147] Step 3011: When the习作 image is the original image, correct the shooting angle of the习作 image.

[0148] Step 3012: Based on the Hough line detection algorithm, perform detection processing on the corrected image to obtain a detection result.

[0149] Step 3013: Perform projective transformation on the detection result to obtain a corrected image.

[0150] Step 3014: Based on the histogram Figure 2The binarization algorithm performs binarization processing on the corrected image to obtain a black and white image.

[0151] Step 3015: Based on the Sobel edge detection operator, process the black and white image to obtain the outline points of the written characters.

[0152] Step 3016: Based on the skeleton thinning algorithm, process the black and white image to obtain the skeleton of the written character.

[0153] Step 3017: Detect the intersection points of the skeleton; based on the intersection points, split the skeleton to obtain at least one preliminary skeleton segmentation.

[0154] Step 3018: For each preliminary segmentation skeleton, determine the arrangement direction features and length features of the preliminary segmentation skeleton; using the A* registration search algorithm, based on the arrangement direction features and length features of the preliminary segmentation skeleton, as well as the arrangement direction features and length features of the template stroke skeleton in the template character corresponding to the preliminary segmentation skeleton, establish the skeleton mapping relationship between the preliminary segmentation skeleton and the template stroke skeleton.

[0155] Step 3019: Based on the skeleton mapping relationship, reorganize at least one preliminary skeleton division to obtain the skeleton of each stroke of the written character.

[0156] Step 3020: Based on the watershed algorithm, obtain the stroke regions corresponding to each stroke skeleton from the practice image.

[0157] Step 3021: For each stroke skeleton, determine the outline points within the stroke area and the outline points on the boundary of the stroke area as the outline points of the written stroke (with stroke skeleton).

[0158] Step 3022: For each writing stroke, the writing stroke can be presented in the form of the outline points of the writing stroke.

[0159] Step 302: Based on the template character, each writing stroke, and the mapping relationship between each radical and each stroke of multiple preset characters stored in the character radical information database, determine each writing radical of the writing character.

[0160] The character radical information database was created in advance.

[0161] The character radical information database stores the mapping relationship between the radicals and strokes of multiple preset characters in the character radical information database.

[0162] Optionally, step 302 may include:

[0163] For each template stroke in the template character, establish the correspondence between the template stroke and the corresponding written stroke in each written stroke;

[0164] For each template radical of the template character, based on the template strokes and their correspondence, target writing strokes are determined in each writing stroke. The target writing strokes are the writing strokes included in the writing radicals of the writing character that correspond to the template radicals. The target writing strokes are combined to obtain the writing radicals of the writing character that correspond to the template radicals.

[0165] Step 303: Based on the template character, identify the problematic strokes in each writing stroke and determine the first problem degree value of the problematic strokes.

[0166] Optionally, step 303 may include:

[0167] Perform the following operations for each written stroke:

[0168] Extract the first number of outline points from the outline points of the written strokes;

[0169] Extract the first number of outline points from the outline points of the template strokes that correspond to the written strokes in the template character;

[0170] Based on the extracted multiple contour points, the Hausdorff distance corresponding to the writing stroke is determined;

[0171] If the Hausdorff distance is greater than the first preset distance, the written stroke is identified as a problem stroke;

[0172] The first problem severity value is determined based on the Hausdorff distance and error baseline.

[0173] Optionally, based on the extracted contour points, the Hausdorff distance corresponding to the written stroke is determined, including:

[0174] Alternatively, the Hausdorff distance corresponding to a writing stroke can be determined using the following formula 1:

[0175] H(A,B)=max a∈A {min b∈B Formula 1; d(a,b)}

[0176] Where A represents the first number of contour points extracted from the contour points of the written stroke, a represents the contour points in A, B represents the first number of contour points extracted from the contour points of the template stroke corresponding to the written stroke in the template character, b represents the contour points in B, d represents the distance between a and b, and H represents the Hausdorff distance corresponding to the written stroke.

[0177] Alternatively, the first problem level value of the written stroke can be determined based on the following formula 2:

[0178]

[0179] Where α represents the first problem level of the written stroke, and L0 represents the error baseline value.

[0180] Step 304: Based on each written radical and template character, determine the problematic radical and the second problem severity value of the problematic radical; the evaluation results include the problematic strokes, the first problem severity value, the problematic radical, and the second problem severity value.

[0181] Optionally, step 304 includes:

[0182] For any two first and second written radicals in each written radical group, perform the following operation:

[0183] Determine the first centroid distance and the first minimum edge distance between the first and second written radicals;

[0184] Determine the second centroid distance and the second minimum edge distance between the first template radical corresponding to the first writing radical in the template character and the second template radical corresponding to the second writing radical in the template character;

[0185] If the first absolute value of the difference between the first centroid distance and the second centroid distance is greater than the preset centroid distance and / or the second absolute value of the difference between the first minimum edge distance and the second minimum edge distance is greater than the preset minimum edge distance, it is determined that a radical problem exists, and the first written radical and the second written radical are determined to be problematic radicals in the radical problem.

[0186] Optionally, determining the first centroid distance and the first minimum edge distance between the first and second written radicals includes:

[0187] The first minimum convex hull surface of the first writing radical and the second minimum convex hull surface of the second writing radical are determined respectively.

[0188] The first centroid distance is determined based on the centroid distance between the first minimum convex hull surface and the second minimum convex hull surface.

[0189] The first minimum edge distance is determined based on the minimum edge distance between the first minimum convex hull surface and the second minimum convex hull surface.

[0190] Alternatively, the minimum convex hull surface can be obtained through a preset algorithm (such as Sklansky's algorithm).

[0191] Optionally, the centroid distance can be determined as the first centroid distance; or the centroid distance can be normalized based on the size of the written character to obtain the first centroid distance.

[0192] Optionally, the methods for obtaining the second centroid distance and the first centroid distance are the same and will not be repeated here.

[0193] Optionally, the minimum edge distance can be determined as the first minimum edge distance; or the minimum edge distance can be normalized based on the size of the written character to obtain the first minimum edge distance.

[0194] Optionally, the method for obtaining the minimum distance of the second edge is the same as that for the minimum distance of the first edge, and will not be repeated here.

[0195] Optionally, when the written character includes a first writing radical and a second writing radical, if the first writing radical and the second writing radical are problematic radicals, the second problem degree value of the first writing radical and the second problem degree value of the second writing radical can be obtained using the following method:

[0196] Replace H(A,B) in Formula 2 with the first absolute value of the difference between the first centroid distance and the second centroid distance to obtain the first centroid problem value;

[0197] Replace H(A,B) in Formula 2 with the second absolute value of the difference between the first edge distance and the second edge distance to obtain the second edge problem value;

[0198] The sum, average, or weighted sum of the first centroid problem value and the second edge problem value is determined as the second problem degree value of the first writing radical and the second problem degree value of the second writing radical.

[0199] Optionally, when the written character includes a first writing radical, a second writing radical, and a third writing radical, if the first writing radical, the second writing radical, and the third writing radical are problematic radicals, the following method can be used to obtain the second problem degree value of the first writing radical, the second problem degree value of the second writing radical, and the second problem degree value of the third writing radical:

[0200] The second problem level values ​​of the first writing radical, the second writing radical, and the third writing radical are initialized to 0 respectively;

[0201] Determine the centroid distance between the first and second written radicals, as well as the edge problem degree value;

[0202] The centroid distance values ​​of the first and second written radicals are respectively added to the second problem degree value of the first written radical and the second problem degree value of the second written radical;

[0203] The edge problem severity values ​​of the first and second writing radicals are respectively added to the second problem severity value of the first writing radical and the second problem severity value of the second writing radical.

[0204] Determine the centroid distance between the first and third written radicals, as well as the edge problem degree value;

[0205] The centroid distance values ​​of the first and third written radicals are respectively added to the second problem degree value of the first written radical and the second problem degree value of the third written radical;

[0206] The edge problem severity values ​​of the first and third writing radicals are respectively added to the second problem severity value of the first writing radical and the second problem severity value of the third writing radical;

[0207] Determine the centroid distance between the third and second writing radicals, as well as the edge problem degree value;

[0208] The centroid distance values ​​of the third and second written radicals are respectively added to the second problem degree value of the third written radical and the second problem degree value of the second written radical;

[0209] The edge problem severity values ​​of the third and second writing radicals are respectively added to the second problem severity value of the third writing radical and the second problem severity value of the second writing radical.

[0210] Finally, we obtain the second problem degree values ​​for the first writing radical, the second problem degree values ​​for the second writing radical, and the second problem degree values ​​for the third writing radical.

[0211] Optionally, determining the centroid distance between the first and second written radicals includes:

[0212] Determine the first centroid distance between the first and second written radicals, corresponding to the second centroid distance between the first and second template radicals in the template character;

[0213] If the first absolute value of the difference between the first centroid distance and the second centroid distance is greater than the preset centroid distance, replace H(A,B) in Formula 2 with the first absolute value to obtain the centroid distance degree value between the first and second writing radicals.

[0214] Optionally, the edge problem severity values ​​of the first and second writing radicals are determined, including:

[0215] Determine the minimum distance between the first and second edges of the first and second written radicals, corresponding to the minimum distance between the second edges of the first and second template radicals in the template character;

[0216] If the second absolute value of the difference between the first minimum edge distance and the second minimum edge distance is greater than the preset minimum edge distance, replace H(A,B) in Formula 2 with the second absolute value to obtain the edge problem degree value of the first and second writing radicals.

[0217] Optionally, the methods for determining the centroid distance and edge problem degree values ​​of the second and third writing radicals, as well as the methods for determining the centroid distance and edge problem degree values ​​of the first and third writing radicals, are the same as those for determining the centroid distance and edge problem degree values ​​of the first and second writing radicals, and will not be repeated here.

[0218] Optionally, the evaluation results can be packaged into a conventional format such as XML / JSON.

[0219] Based on the above embodiments, the following is combined with Figure 4 Step 103 will be explained in detail.

[0220] Figure 4 This is a flowchart of the method for obtaining practice characters provided by the present invention. For example... Figure 4 As shown, the method includes:

[0221] Step 401: Based on the problematic strokes and radicals in the evaluation results, as well as the template characters and preset calligraphy knowledge graphs, determine multiple candidate characters from multiple preset characters.

[0222] The preset calligraphy knowledge graph includes feature vectors for each preset character, stroke feature vectors for each stroke of the preset character, and radical feature vectors for each radical of the preset character. Figure 5 This is a schematic diagram of the structure of the preset calligraphy knowledge graph provided by the present invention. For example... Figure 5 As shown, it includes: knowledge graph structures corresponding to multiple preset characters.

[0223] Each character corresponds to a knowledge graph structure that includes one or more knowledge graph entities. Preset characters have attributes such as the work they belong to, the author, and the calligraphic style.

[0224] One or more knowledge graph entities include preset characters, radicals, and strokes. Figure 5 This explanation uses three preset characters as an example. These three preset characters are Preset Character 1, Preset Character 2, and Preset Character 3. For example, Preset Character 1 and Preset Character 3 are the same. Preset Character 1 includes radicals 11 and 12. Radical 11 includes strokes 111 and 112, and radical 12 includes strokes 121, 122, and 123. Preset Character 2 includes radicals 21 and 22. Radical 21 includes strokes 211 and 212, and radical 22 includes strokes 221, 222, and 223.

[0225] Entities can be composed of images.

[0226] The entity of the preset character includes an image containing the preset character, and the image matches and conforms to the attributes of the calligraphy character.

[0227] The entity of the radical includes the radical image extracted from the image of the preset character to which it belongs.

[0228] The entity of a stroke includes the stroke image extracted from the image of its corresponding radical.

[0229] The entity construction, link construction, and image extraction in the pre-defined calligraphy knowledge graph are mainly carried out manually. The pre-defined calligraphy knowledge graph can be stored using Neo4j. For example, by constructing a calligraphy ontology model using the OntologyWed Language (OWL), the relationships between the aforementioned pre-defined characters and radicals, radicals and strokes, and pre-defined characters, as well as the attributes of pre-defined characters, radicals, and strokes, can be modeled to obtain the pre-defined calligraphy knowledge graph.

[0230] Optionally, step 401 may include steps 4011 to 4013.

[0231] Step 4011: Based on the problem strokes, template characters, and preset calligraphy knowledge graph, determine the first candidate character from multiple preset characters.

[0232] Step 4012: Based on the problem radical, template character, and preset calligraphy knowledge graph, determine the second candidate character from multiple preset characters.

[0233] Step 4013: Determine the first candidate character and the second candidate character as multiple candidate characters.

[0234] Optionally, based on the problem stroke, template characters, and a preset calligraphy knowledge graph, the first candidate character is determined from multiple preset characters, including: obtaining the feature vectors of the template strokes corresponding to the problem strokes in the template characters and the feature vectors of the target strokes corresponding to the template strokes in each preset character from the preset calligraphy knowledge graph; determining the similarity between the feature vectors of the template strokes and the feature vectors of each target stroke; and determining the preset characters to which the N target strokes with the highest similarity belong as the first candidate character; where N is an integer greater than or equal to 1.

[0235] The problematic stroke and the template stroke corresponding to the problematic stroke are the same stroke. For example, the problematic stroke is "丨" and the template stroke is "丨". Optionally, a character may have multiple "丨", but the problematic stroke may only be one of them. Therefore, the problematic stroke needs to be precise to which "丨", and the strokes between the written character and the template character can be registered. Based on this registration relationship, it can be determined which stroke of the written character is problematic, and it can also be known which stroke of the template character this stroke corresponds to, that is, that problematic stroke.

[0236] The template stroke and the target stroke corresponding to the template stroke are the same stroke. For example, the template stroke is "丿" and the target stroke is "丿".

[0237] Optionally, for each target stroke, the cosine similarity calculation method (and it can be other methods) can be used to process the feature vectors of the template stroke and the target stroke to obtain the similarity between the feature vectors of the template stroke and the target stroke.

[0238] For example, when the written character is "大" and the problematic stroke is "一", the first candidate characters can be "大", "天", "太", "十", etc.

[0239] Optionally, the method for determining the second candidate characters is similar to the method for determining the first candidate characters, and will not be elaborated here.

[0240] Step 402: Obtain the stroke feature vector of the problematic stroke from the preset calligraphy knowledge graph.

[0241] Optionally, obtain the feature vector of the template stroke corresponding to the problematic stroke in the template character from the preset calligraphy knowledge graph, and determine the feature vector of the template stroke as the stroke feature vector of the problematic stroke.

[0242] Step 403: Determine the radical feature vector of the problematic radical based on the preset calligraphy knowledge graph.

[0243] Optionally, obtain the feature vector of the template radical corresponding to the problematic radical in the template character from the preset calligraphy knowledge graph; determine the feature vector of the template radical as the radical feature vector of the problematic radical.

[0244] Step 404: Determine the fusion feature vector of the written character based on the stroke feature vector and the radical feature vector.

[0245] Optionally, the fusion feature vector of the written character can be determined by the following formula 3:

[0246]

[0247] where F tLet represent the fusion feature vector of the written character, t represent the current writing round (representing the t-th round of practice), X represent the total number of problematic strokes in the evaluation results, and w i s represents the first problem severity value of the i-th problem stroke. i Y is the stroke feature vector of the i-th problematic stroke in this round, and Y represents the total number of problematic radicals in the evaluation results. j c represents the degree value of the second problem for the j-th problem radical. j This represents the radical feature vector of the j-th problem radical. Indicates a connection, for example, Where l and h represent the dimensions of the vector.

[0248] Step 405: Process the fused feature vector of the written character and the fused feature vector of multiple historical written characters using a preset encoder to obtain the target feature vector.

[0249] Optionally, the preset encoder can be a Transformer encoder. Figure 6 This is a schematic diagram of the network structure of the Transformer encoder provided by this invention. Figure 6 As shown, the Transformer encoder includes: a multi-head attention mechanism layer, two summation and normalization layers, and a feedforward network layer. The connection relationships between the multi-head attention mechanism layer, the two summation and normalization layers, and the feedforward network layer are as follows: Figure 6 As shown, it will not be elaborated further here.

[0250] Optionally, the initial Transformer encoder can be trained using the following method to obtain the preset encoder: acquire multiple sets of sample data, each set of sample data including W fused feature vectors and label feature vectors of a sample written character; based on the multiple sets of sample data, update the model parameters of the initial Transformer encoder to obtain the preset encoder.

[0251] For example, W can be 5 or 6.

[0252] The W fused feature vectors of a sample written character can include preset vectors (e.g., the zero vector).

[0253] For example, if a sample character has undergone two rounds of writing practice, only two fusion feature vectors of the sample character can be obtained (the method for obtaining the fusion feature vector of the sample character is the same as the method for obtaining the fusion feature vector of the written character, and will not be repeated here). If W=5, then the three preset vectors and the two obtained fusion feature vectors are determined as the W fusion feature vectors of a sample character.

[0254] Optionally, the label feature vector is the feature vector of the preferred characters recommended by the calligraphy teacher based on the sample written characters.

[0255] Optionally, when there are multiple preferred characters, the label feature vector is the average of the sum of the feature vectors of the multiple preferred characters.

[0256] During each update of model parameters, multiple fused feature vectors from a set of sample data are input into the initial Transformer encoder after the previous model parameter update to obtain the predicted feature vectors.

[0257] Calculate the loss value (e.g., cosine distance) between the predicted feature vector and the label feature vector;

[0258] If the loss value is less than or equal to a preset threshold, the initial Transformer encoder after the previous model parameter update is determined as the preset encoder.

[0259] If the loss value is greater than the preset threshold, the next set of sample data will be used to update the model parameters of the initial Transformer encoder after the previous model parameter update, until the preset encoder is obtained when the loss value is less than or equal to the preset threshold.

[0260] The multiple historical characters are written by the student and are located before and adjacent to the written characters.

[0261] The number of historical characters can be 5, 6, etc.

[0262] The method for obtaining the fusion feature vector of historical written characters is the same as that for obtaining the fusion feature vector of written characters, and will not be repeated here.

[0263] Step 406: Based on the target feature vector and the feature vectors of multiple candidate characters, determine the practice characters from among the multiple candidate characters.

[0264] Optionally, perform the following operation for each candidate character:

[0265] Step 4061: Determine the cosine similarity between the target feature vector and the feature vector of the candidate character, and normalize the cosine similarity to obtain the normalized similarity of the candidate character.

[0266] Step 4062: Sort the multiple candidate characters in descending order of normalized similarity to obtain a candidate character sequence; select the first M candidate characters from the candidate character sequence as practice characters. Where M is an integer greater than or equal to 1.

[0267] Alternatively, the cosine similarity between the target feature vector and the feature vectors of the candidate characters can be obtained using the following formula 4:

[0268]

[0269] Wherein, cosθ i A represents the cosine similarity between the feature vector of the target character and the feature vector of the candidate character. i B represents the i-th element in the target feature vector. i This represents the i-th element of the feature vector of the candidate character, where n represents the dimension of the feature vector.

[0270] Alternatively, the normalized similarity can be obtained using the following formula 5:

[0271]

[0272] Wherein, Softmax(cosθ) i ) represents the normalized similarity of the i-th candidate character, cosθ i Let ∑ represent the cosine similarity of the i-th candidate character. j exp(cosθ j ) represents the sum of the cosine similarities of all candidate characters, cosθ j This represents the cosine similarity of any one of the candidate characters.

[0273] Figure 7 This is one of the structural schematic diagrams of the intelligent calligraphy learning system provided by this invention. For example... Figure 7 As shown, it includes: a calligraphy copying evaluation subsystem and a calligraphy practice resource recommendation subsystem.

[0274] The calligraphy copying evaluation subsystem is used to obtain evaluation results based on the images of the practice works.

[0275] The calligraphy practice resource recommendation subsystem is used to obtain and recommend practice characters based on the evaluation results.

[0276] exist Figure 7 Based on this, the following will combine Figure 8 A detailed description of the intelligent calligraphy learning system is provided.

[0277] Figure 8 This is the second structural schematic diagram of the intelligent calligraphy learning system provided by this invention. (See diagram below.) Figure 8 As shown, the calligraphy copying evaluation subsystem includes: a preprocessing module, a content extraction module, an evaluation module, and a writing problem output module.

[0278] The preprocessing module includes a binarization unit and an image correction unit. The image correction unit is used to implement steps 3011 to 3013. The binarization unit is used to implement step 3014.

[0279] The content extraction module includes: a text extraction unit, a stroke extraction unit, and a radical extraction unit. The text extraction unit is used to implement step 3015. The stroke extraction unit is used to implement steps 3016 to 3022. The radical extraction unit is used in step 302.

[0280] The evaluation module includes a stroke evaluation unit and a radical evaluation unit. The stroke evaluation unit is used to implement step 303. The radical evaluation unit is used to implement step 304.

[0281] The writing problem output module is used to encapsulate the evaluation results into conventional formats such as XML / JSON and input them into the calligraphy practice resource recommendation subsystem.

[0282] The calligraphy practice resource recommendation subsystem includes: an evaluation history database module, a preset calligraphy knowledge graph module, a demand feature calculation module, and a resource recommendation module.

[0283] The evaluation history database module is used to store evaluation results from multiple evaluations.

[0284] The preset calligraphy knowledge graph module includes: preset calligraphy knowledge graph units and knowledge feature calculation units.

[0285] The preset calligraphy knowledge graph unit stores the preset calligraphy knowledge graph.

[0286] The knowledge feature computation unit is used to compute the feature vector of each knowledge graph entity in the preset calligraphy knowledge graph using graph neural network techniques (such as GCN (Graph Convolutional Network), GAT (Graph Attention Networks), and GraphSage).

[0287] The requirement feature calculation module includes: a problem mapping unit, a feature aggregation unit, and a feature encoding unit.

[0288] The problem mapping unit includes a problem radical mapping subunit and a problem stroke mapping subunit. The problem mapping unit is used to implement steps 4011 to 4013. The problem radical mapping subunit is used to implement step 4011. The problem stroke mapping subunit is used to implement step 4012.

[0289] The feature aggregation unit is used to obtain the fused feature vector of the written character in steps 402 to 404.

[0290] The feature encoding unit is used to implement step 405.

[0291] The resource recommendation module includes a similarity calculation unit and a ranking unit. The similarity calculation unit is used to implement step 4061. The ranking unit is used to implement step 4062.

[0292] In this invention, based on the template characters corresponding to the written characters, the written characters in the practice image are evaluated to obtain evaluation results. Based on the evaluation results, practice characters are determined from multiple preset characters, and then practice characters are recommended to students. This avoids the shortcomings of students' poor systematic learning of calligraphy due to the lack of professionalism of calligraphy teachers and the lack of standardized teaching, and improves the systematic nature of students' calligraphy learning.

[0293] The following describes the practice character recommendation device provided by the present invention. The practice character recommendation device described below can be referred to in correspondence with the practice character recommendation method described above.

[0294] Figure 9 This is a schematic diagram of the structure of the calligraphy practice recommendation device provided by the present invention. Figure 9 As shown, the handwriting practice recommendation device includes:

[0295] The acquisition module 910 is used to acquire the artwork image; the artwork image includes the handwriting currently being written by the student.

[0296] Evaluation module 920 is used to evaluate the handwritten characters in the exercise image based on the template characters corresponding to the handwritten characters, and obtain the evaluation results;

[0297] The determination module 930 is used to determine the practice characters from a plurality of preset characters based on the evaluation results; wherein the plurality of preset characters includes template characters;

[0298] The recommended module 940 is used to recommend characters for practice to students.

[0299] According to the present invention, a practice character recommendation device is provided, wherein the evaluation module 920 is specifically used for:

[0300] Based on the student's artwork and the template character, determine the individual strokes of the written character;

[0301] Based on the template characters, each writing stroke, and the mapping relationship between each radical and each stroke of multiple preset characters stored in the character radical information database, the writing radical of the writing character is determined;

[0302] Based on the template character, identify the problematic strokes in each writing stroke and determine the first problem degree value of the problematic strokes;

[0303] Based on each written radical and template character, the problematic radical is identified, and the second problem severity value of the problematic radical is determined.

[0304] The evaluation results include the number of problematic strokes, the severity of the first problem, the problematic radical, and the severity of the second problem.

[0305] According to the present invention, a practice character recommendation device is provided, wherein the evaluation module 920 is specifically used for:

[0306] Perform the following operations for each written stroke:

[0307] Extract the first number of outline points from the outline points of the written strokes, and extract the first number of outline points from the outline points of the template strokes corresponding to the written strokes in the template characters.

[0308] Based on the extracted multiple contour points, the Hausdorff distance corresponding to the writing stroke is determined;

[0309] If the Hausdorff distance is greater than the first preset distance, the written stroke is identified as a problem stroke;

[0310] The first problem severity value is determined based on the Hausdorff distance and error baseline.

[0311] According to the present invention, a practice character recommendation device is provided, wherein the evaluation module 920 is specifically used for:

[0312] For any two first and second written radicals in each written radical group, perform the following operation:

[0313] Determine the first centroid distance and the first minimum edge distance between the first and second written radicals;

[0314] Determine the second centroid distance and the second minimum edge distance between the first template radical corresponding to the first writing radical in the template character and the second template radical corresponding to the second writing radical in the template character;

[0315] Determine the first absolute value of the difference between the first centroid distance and the second centroid distance;

[0316] Determine the second absolute value of the difference between the minimum distance of the first edge and the minimum distance of the second edge.

[0317] If the first absolute value is greater than the preset centroid distance and / or the second absolute value is greater than the preset minimum edge distance, the first and second writing radicals are determined to be problematic radicals.

[0318] According to the present invention, a practice character recommendation device is provided, wherein the evaluation module 920 is specifically used for:

[0319] The first minimum convex hull surface of the first writing radical and the second minimum convex hull surface of the second writing radical are determined respectively.

[0320] The first centroid distance is determined based on the centroid distance between the first minimum convex hull surface and the second minimum convex hull surface.

[0321] The first minimum edge distance is determined based on the minimum edge distance between the first minimum convex hull surface and the second minimum convex hull surface.

[0322] According to the present invention, a practice character recommendation device is provided, wherein the determining module 930 is specifically used for:

[0323] Based on the problematic strokes and radicals in the evaluation results, as well as the template characters and the preset calligraphy knowledge graph, multiple candidate characters are determined from multiple preset characters; among them, the preset calligraphy knowledge graph includes the feature vector of each preset character, the stroke feature vector of each stroke of the preset character, and the radical feature vector of each radical of the preset character.

[0324] Extract the stroke feature vector of the problematic stroke from the preset calligraphy knowledge graph;

[0325] Based on a pre-defined calligraphy knowledge graph, the radical feature vector of the problematic radical is determined;

[0326] Based on stroke feature vectors and radical feature vectors, the fusion feature vector of the written character is determined;

[0327] By using a preset encoder, the fused feature vector and the fused feature vector of multiple historical written characters are processed to obtain the target feature vector;

[0328] Based on the target feature vector and the feature vectors of multiple candidate characters, practice characters are determined from the multiple candidate characters.

[0329] According to the present invention, a practice character recommendation device is provided, wherein the determining module 930 is specifically used for:

[0330] Based on the problem strokes, template characters, and preset calligraphy knowledge graphs, the first candidate character is determined from multiple preset characters;

[0331] Based on the problem radical, template characters, and preset calligraphy knowledge graph, the second candidate character is determined from multiple preset characters;

[0332] The first and second candidate characters are determined as multiple candidate characters.

[0333] According to the present invention, a practice character recommendation device is provided, wherein the determining module 930 is specifically used for:

[0334] From the preset calligraphy knowledge graph, obtain the feature vector of the template stroke corresponding to the problem stroke in the template character, and the feature vector of the target stroke corresponding to the template stroke in each preset character;

[0335] Determine the similarity between the feature vectors of the template strokes and the feature vectors of each target stroke;

[0336] The preset characters to which the N target strokes with the highest similarity belong are determined as the first candidate characters; where N is an integer greater than or equal to 1.

[0337] Figure 10 This is a schematic diagram of the physical structure of the electronic device provided by the present invention. For example... Figure 10 As shown, the electronic device may include a processor 110, a communications interface 120, a memory 130, and a communication bus 140, wherein the processor 110, communications interface 120, and memory 130 communicate with each other via the communication bus 140. The processor 110 can call logical instructions in the memory 130 to execute a method for recommending practice characters. This method includes: acquiring a practice image, wherein the practice image includes the characters currently being written by the student; evaluating the characters in the practice image based on template characters corresponding to the characters being written, obtaining evaluation results; determining practice characters from a plurality of preset characters based on the evaluation results, wherein the plurality of preset characters includes template characters; and recommending practice characters to the student.

[0338] Furthermore, the logical instructions in the aforementioned memory 130 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, essentially, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0339] On the other hand, the present invention also provides a computer program product, which includes a computer program that can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer can execute the practice character recommendation method provided by the above methods. The method includes: acquiring a practice character image, wherein the practice character image includes the handwriting currently being written by the student; evaluating the handwriting in the practice character image based on the template character corresponding to the handwriting, and obtaining an evaluation result; determining practice characters from a plurality of preset characters based on the evaluation result, wherein the plurality of preset characters includes the template character; and recommending practice characters to the student.

[0340] In another aspect, the present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon. When executed by a processor, the computer program implements a method for recommending practice characters provided by the methods described above. The method includes: acquiring a practice image, wherein the practice image includes the handwritten characters currently being written by the student; evaluating the handwritten characters in the practice image based on template characters corresponding to the handwritten characters, and obtaining an evaluation result; determining practice characters from a plurality of preset characters based on the evaluation result, wherein the plurality of preset characters includes template characters; and recommending practice characters to the student.

[0341] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.

[0342] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., including several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods of various embodiments or some parts of embodiments.

[0343] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for recommending practice characters, characterized in that, include: Obtain an image of the student's work; wherein, the image of the student's work includes the handwriting currently being written by the student; Based on the template character corresponding to the written character, the written character in the exercise image is evaluated to obtain the evaluation result; Based on the problematic strokes and radicals in the evaluation results, as well as the template characters and preset calligraphy knowledge graphs among the multiple preset characters, multiple candidate characters are determined from the multiple preset characters; wherein, the preset calligraphy knowledge graph includes the feature vectors of each preset character, the stroke feature vectors of each stroke of the preset character, and the radical feature vectors of each radical of the preset character; Obtain the stroke feature vector of the problematic stroke from the preset calligraphy knowledge graph; Based on the preset calligraphy knowledge graph, the radical feature vector of the problematic radical is determined; Based on the stroke feature vector and the radical feature vector, the fusion feature vector of the written character is determined; The target feature vector is obtained by processing the fused feature vector and the fused feature vector of multiple historical written characters through a preset encoder. Based on the target feature vector and the feature vectors of the plurality of candidate characters, the practice character is determined from the plurality of candidate characters; The practice characters were then recommended to the students.

2. The method for recommending practice characters according to claim 1, characterized in that, The evaluation process, based on the template character corresponding to the written character, evaluates the written character in the exercise image to obtain the evaluation result, including: Based on the practice image and template character, determine each stroke of the written character; Based on the template character, the writing strokes, and the mapping relationship between the radicals and strokes of the multiple preset characters stored in the character radical information database, the writing radical of the writing character is determined; Based on the template character, problem strokes are identified among the various writing strokes, and a first problem severity value for the problem strokes is determined. Based on the written radicals and the template characters, the problematic radicals are determined, and a second problem severity value for the problematic radicals is determined. The evaluation results include the number of problematic strokes, the first problem severity value, the problematic radical, and the second problem severity value.

3. The method for recommending practice characters according to claim 2, characterized in that, The step of identifying problematic strokes among the various written strokes based on the template character, and determining a first problem severity value for the problematic strokes, includes: Perform the following operations for each written stroke: Extract a first number of contour points from the contour points of the written strokes, and extract the first number of contour points from the contour points of the template strokes corresponding to the written strokes in the template characters. Based on the extracted multiple contour points, the Hausdorff distance corresponding to the writing stroke is determined; If the Hausdorff distance is greater than a first preset distance, the written stroke is identified as a problem stroke; The first problem severity value is determined based on the Hausdorff distance and error baseline value.

4. The method for recommending practice characters according to claim 2, characterized in that, The determination of the problematic radical based on the written radicals and the template characters includes: For any two first and second written radicals in each written radical group, perform the following operation: Determine the first centroid distance and the first minimum edge distance between the first written radical and the second written radical; Determine the second centroid distance and the second minimum edge distance between the first template radical corresponding to the first writing radical in the template character and the second template radical corresponding to the second writing radical in the template character; Determine the first absolute value of the difference between the first centroid distance and the second centroid distance; Determine the second absolute value of the difference between the first edge minimum distance and the second edge minimum distance. If the first absolute value is greater than the preset centroid distance and / or the second absolute value is greater than the preset minimum edge distance, the first written radical and the second written radical are determined to be problematic radicals.

5. The method for recommending practice characters according to claim 4, characterized in that, Determining the first centroid distance and the first minimum edge distance between the first written radical and the second written radical includes: The first minimum convex envelope surface of the first writing radical and the second minimum convex envelope surface of the second writing radical are determined respectively. The first centroid distance is determined based on the centroid distance between the first minimum convex hull surface and the second minimum convex hull surface; The first minimum edge distance is determined based on the minimum edge distance between the first minimum convex envoy surface and the second minimum convex envoy surface.

6. The method for recommending practice characters according to claim 5, characterized in that, Based on the problematic strokes and radicals in the evaluation results, as well as the template characters and preset calligraphy knowledge graphs, multiple candidate characters are determined from the multiple preset characters, including: Based on the problematic strokes, the template characters, and the preset calligraphy knowledge graph, a first candidate character is determined from the plurality of preset characters; Based on the problem radical, the template character, and the preset calligraphy knowledge graph, a second candidate character is determined from the plurality of preset characters; The first candidate character and the second candidate character are determined as the plurality of candidate characters.

7. The method for recommending practice characters according to claim 6, characterized in that, Based on the problematic strokes, the template characters, and the preset calligraphy knowledge graph, a first candidate character is determined from the plurality of preset characters, including: From the preset calligraphy knowledge graph, obtain the feature vector of the template stroke corresponding to the problem stroke in the template character, and the feature vector of the target stroke corresponding to the template stroke in each preset character; Determine the similarity between the feature vectors of the template strokes and the feature vectors of each target stroke; The preset characters to which the top N target strokes with the highest similarity belong are determined as the first candidate characters; where N is an integer greater than or equal to 1.

8. A device for recommending practice characters, characterized in that, include: The acquisition module is used to acquire images of student work; wherein, the images of student work include the handwritten characters currently being written by the student. The evaluation module is used to evaluate the handwritten characters in the exercise image based on the template characters corresponding to the handwritten characters, and obtain the evaluation results. A determination module is used to determine multiple candidate characters from the multiple preset characters based on the problematic strokes and radicals in the evaluation results, as well as template characters and preset calligraphy knowledge graphs from multiple preset characters. The preset calligraphy knowledge graph includes feature vectors for each preset character, stroke feature vectors for each stroke of the preset character, and radical feature vectors for each radical of the preset character. The module obtains the stroke feature vectors of the problematic strokes from the preset calligraphy knowledge graph; determines the radical feature vectors of the problematic radicals based on the preset calligraphy knowledge graph; determines the fusion feature vector of the written character based on the stroke feature vectors and the radical feature vectors; processes the fusion feature vectors and the fusion feature vectors of multiple historical written characters using a preset encoder to obtain a target feature vector; and determines the practice character from the multiple candidate characters based on the target feature vector and the feature vectors of the multiple candidate characters. The recommendation module is used to recommend the practice characters to the students.

9. An electronic 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, it implements the practice character recommendation method as described in any one of claims 1 to 7.

10. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the practice character recommendation method as described in any one of claims 1 to 7.

11. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the practice character recommendation method as described in any one of claims 1 to 7.

Citation Information

Patent Citations

  • Chinese-character learning method and electronic equipment

    CN107862024A