Latex normalization method based on katex

A normalized and recursive technology, applied in instruments, character and pattern recognition, computer parts, etc., can solve the problems of poor model recognition rate and high latex analysis complexity, and achieve the effect of improving the recognition rate and reducing the analysis complexity.

Inactive Publication Date: 2022-03-25
中教云智数字科技有限公司
View PDF0 Cites 1 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0005] The main purpose of this application is to provide a katex-based latex normalization method to improve t...

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Latex normalization method based on katex
  • Latex normalization method based on katex
  • Latex normalization method based on katex

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0050] A recursive algorithm in computer science refers to a method of solving a problem by repeatedly decomposing it into subproblems of the same kind. Recursive methods can be used to solve many computer science problems, so it is a very important concept in computer science. Most programming languages ​​support self-invocation of functions. In these languages, functions can perform recursion by calling themselves. Therefore, in many functional programming languages ​​(such as Scheme), it is customary to use recursion to implement loops.

[0051] LaTeX is a typesetting system based on TeX, developed by American computer scientist Leslie Lambert (Leslie Lamport) in the early 1980s, using this format, even if the user has no knowledge of typesetting and programming Taking full advantage of the powerful features provided by TeX, it is possible to generate many book-quality prints in a few days, or even a few hours. The general nature of Latex allows it to be used as the output...

Embodiment 2

[0060] see figure 1 , figure 2 , image 3 and Figure 4 , a latex normalization method based on katex, which specifically includes the following steps:

[0061] S1: input latex expression;

[0062] S2: katex rendering, python calls katex through multiple threads, renders the input latex expression, obtains the intermediate result of katex rendering, and uses the intermediate result as a parse tree;

[0063] In this embodiment, the parsing tree itself contains parsing groups, and the parsing groups are specifically defined as: sqrt group: root group; ord group: common group; genfrac group: fractional group; textword group: text group; The levels of the elements in the common group are the same; the text group is composed of Chinese characters and / or numbers and / or English letters, and the text group cannot be further divided.

[0064] S3: Recursive parsing, parsing and reprocessing the parsing tree in a recursive manner, transforming the parsing results obtained by katex ...

Embodiment 3

[0090] see figure 1 , figure 2 , image 3 and Figure 4 , a latex normalization method based on katex, which specifically includes the following steps:

[0091] S1: input latex expression;

[0092] S2: katex rendering, python calls katex through multiple threads, renders the input latex expression, obtains the intermediate result of katex rendering, and uses the intermediate result as a parse tree;

[0093] In this embodiment, the parsing tree itself contains parsing groups, and the parsing groups are specifically defined as: sqrt group: root group; ord group: common group; genfrac group: fractional group; textword group: text group; The levels of the elements in the common group are the same; the text group is composed of Chinese characters and / or numbers and / or English letters, and the text group cannot be further divided.

[0094]S3: Recursive parsing, parsing and reprocessing the parsing tree in a recursive manner, transforming the parsing results obtained by katex p...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention discloses a latex normalization method based on katex. The method comprises the steps that a latex expression is input, katex rendering, recursive analysis and recoding are conducted, a new latex expression is output, python calls katex through multiple threads, rendering is conducted on the input latex expression, an intermediate result of katex rendering is obtained, and the intermediate result serves as an analytic tree; performing analysis and secondary processing on the analysis tree in a recursion mode; and when the output of the analysis group is {} including the left bracket and the right bracket, judging whether the analysis object is an operator, and if the analysis object is the operator, specifying the name of the operator in front of the left bracket or the right bracket. According to the scheme, latex expressions irrelevant to semantics are removed, some redundant expressions in latex training labels are removed, and the recognition rate of the model is greatly improved; the characters required for representing the score by the latex are simplified, and the analysis complexity of latex evaluation during automatic correction is reduced.

Description

technical field [0001] This application relates to the technical field of automatic correction, in particular, to a katex-based latex normalization method. Background technique [0002] OCR (Optical Character Recognition, Optical Character Recognition) means that an electronic device (such as a scanner or a digital camera) checks characters printed on paper, determines its shape by detecting dark and bright patterns, and then uses character recognition to translate the shape into a computer The process of text; that is, for printed characters, the text in the paper document is converted into a black and white dot matrix image file by optical means, and the text in the image is converted into a text format by recognition software for further processing by word processing software Editing technology. [0003] In the OCR system of handwritten mathematical formulas, generally by using What You Get Is What You See (Yuntian Deng, Anssi Kanervisto, and Alexander M.Rush.2016.What Y...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
IPC IPC(8): G06V30/40G06V10/96G06V30/19G06V30/196G06K9/62
CPCG06F18/214
Inventor 徐飞钱锟王钰王宇阳
Owner 中教云智数字科技有限公司
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products