WO2021056621A1 - 文本序列的识别方法及装置、电子设备和存储介质 - Google Patents

文本序列的识别方法及装置、电子设备和存储介质 Download PDF

Info

Publication number
WO2021056621A1
WO2021056621A1 PCT/CN2019/111170 CN2019111170W WO2021056621A1 WO 2021056621 A1 WO2021056621 A1 WO 2021056621A1 CN 2019111170 W CN2019111170 W CN 2019111170W WO 2021056621 A1 WO2021056621 A1 WO 2021056621A1
Authority
WO
WIPO (PCT)
Prior art keywords
text
binary tree
sequence
feature
text sequence
Prior art date
Application number
PCT/CN2019/111170
Other languages
English (en)
French (fr)
Inventor
岳晓宇
旷章辉
孙红斌
宋小萌
张伟
Original Assignee
深圳市商汤科技有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 深圳市商汤科技有限公司 filed Critical 深圳市商汤科技有限公司
Priority to JP2021518910A priority Critical patent/JP7123255B2/ja
Priority to SG11202105174XA priority patent/SG11202105174XA/en
Priority to KR1020217010064A priority patent/KR20210054563A/ko
Publication of WO2021056621A1 publication Critical patent/WO2021056621A1/zh
Priority to US17/232,278 priority patent/US20210232847A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V20/00Scenes; Scene-specific elements
    • G06V20/60Type of objects
    • G06V20/62Text, e.g. of license plates, overlay texts or captions on TV images
    • G06V20/63Scene text, e.g. street names
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/30Semantic analysis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/211Selection of the most significant subset of features
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • G06F18/2148Generating training patterns; Bootstrap methods, e.g. bagging or boosting characterised by the process organisation or structure, e.g. boosting cascade
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/2163Partitioning the feature space
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • G06F18/241Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • G06F18/243Classification techniques relating to the number of classes
    • G06F18/24323Tree-organised classifiers
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/40Extraction of image or video features
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V20/00Scenes; Scene-specific elements
    • G06V20/50Context or environment of the image
    • G06V20/56Context or environment of the image exterior to a vehicle by using sensors mounted on the vehicle
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V30/00Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
    • G06V30/10Character recognition
    • G06V30/14Image acquisition
    • G06V30/148Segmentation of character regions
    • G06V30/153Segmentation of character regions using recognition of characters or words
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V30/00Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
    • G06V30/10Character recognition
    • G06V30/19Recognition using electronic means
    • G06V30/191Design or setup of recognition systems or techniques; Extraction of features in feature space; Clustering techniques; Blind source separation
    • G06V30/19173Classification techniques
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/279Recognition of textual entities
    • G06F40/284Lexical analysis, e.g. tokenisation or collocates
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V30/00Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
    • G06V30/10Character recognition

Definitions

  • the present disclosure relates to the field of data processing technology, and in particular to a method and device for recognizing text sequences, electronic equipment and storage media.
  • the recognition of irregular text plays an important role in fields such as visual understanding and autonomous driving.
  • a large number of irregular texts exist in natural scenes such as traffic signs and storefront signs. Due to factors such as viewing angle changes and lighting changes, the recognition difficulty is higher than that of regular texts, and its recognition performance needs to be improved.
  • the present disclosure proposes a technical solution for text sequence recognition.
  • a method for recognizing a text sequence including:
  • a to-be-processed image containing a text sequence is obtained. Since the text sequence is recognized according to the recognition network, multiple single characters that constitute the text sequence can be obtained. The semantic relationship between the characters is not dependent on the multiple single characters. Characters are processed in parallel to obtain recognition results, which can improve recognition accuracy, and parallel processing can improve processing efficiency.
  • the recognition of the text sequence in the image to be processed according to the recognition network to obtain a plurality of single characters constituting the text sequence includes:
  • the multiple single characters constituting the text sequence in the image to be processed are recognized.
  • the binary tree-based processing can achieve the effect of parallel encoding and decoding of multiple single characters, which greatly improves the recognition accuracy of single characters.
  • the recognizing the plurality of single characters constituting the text sequence in the image to be processed according to the binary tree set in the recognition network includes:
  • the text sequence in the image to be processed can be coded to obtain the binary tree node characteristics of the corresponding text segment in the text sequence, that is, a text sequence is converted into a node of the binary tree through coding Feature to facilitate subsequent decoding processing based on the binary tree.
  • the method further includes:
  • the image features of the text sequence in the image to be processed are extracted to obtain a feature map, so as to recognize the text sequence according to the feature map to obtain a plurality of single characters constituting the text sequence.
  • the image features of the text sequence in the image to be processed can be extracted through the recognition network to obtain a feature map. Since the image features are processed according to the image features, subsequent semantic analysis can be performed instead of directly extracting semantics. In other words, the result of semantic analysis is more accurate, which improves the recognition accuracy.
  • the extracting image features of the text sequence in the image to be processed through the recognition network to obtain a feature map includes:
  • the feature map is obtained.
  • feature extraction can be performed by the feature extraction module in the recognition network. Since the network is self-adapting parameter adjustment, the feature map obtained by the feature extraction is more accurate, thereby improving the recognition accuracy.
  • the encoding process of the text sequence in the image to be processed according to the binary tree to obtain the binary tree node feature of the corresponding text segment in the text sequence includes:
  • the attention module in the process of binary tree coding, can be encoded by segmenting the attention module in the recognition network to obtain the binary tree node characteristics of the corresponding text segment in the text sequence, that is, a text sequence is divided by the sequence of the binary tree in the attention module.
  • the encoding is converted into the node characteristics of the binary tree to facilitate subsequent decoding processing based on the binary tree. Since the network is self-adapting, the coding result obtained by the sequence segmentation attention module is more accurate, thereby improving the recognition accuracy.
  • the multi-channel selection of the feature map based on the binary tree included in the sequence segmentation attention module includes:
  • the feature map is processed based on the sequence segmentation attention rule, and after the attention feature matrix is obtained, multi-channel selection is performed on the attention feature matrix according to the binary tree.
  • the attention feature matrix in the process of segmenting the binary tree encoding in the attention module by sequence, after the attention feature matrix can be obtained, the attention feature matrix can be multi-channel selected according to the binary tree, so as to obtain multiple text segmentation. Target channel group.
  • the performing text segmentation according to the multiple target channel groups to obtain the binary tree node feature of the corresponding text segment in the text sequence includes:
  • the multiple attention feature maps and the convolution processing result are weighted, and the binary tree node feature of the corresponding text segment in the text sequence is obtained according to the weighting result.
  • text segmentation is performed according to the multiple target channel groups to obtain multiple attention feature maps, and the multiple attention feature maps are combined with the feature maps.
  • the convolution processing result obtained by the product processing is weighted, and then the binary tree node characteristics of the corresponding text segment in the text sequence can be obtained according to the weighting result, so as to facilitate subsequent decoding processing based on the binary tree.
  • the decoding processing on the node characteristics of the binary tree according to the binary tree to recognize the plurality of single characters constituting the text segment includes:
  • the plurality of single characters constituting the text segment are recognized.
  • the binary tree-based decoding process can use a classification module for classification processing.
  • the classification process may input the binary tree and the previously encoded binary tree node characteristics into the classification module in the recognition network to perform node classification, and obtain the classification result, and according to the classification result, recognize the plurality of single characters constituting the text segment.
  • the decoding process based on the binary tree is also parallel, and the network is adaptively adjusted. Therefore, the decoding result obtained by the classification module is more accurate, thereby improving the recognition accuracy.
  • the recognizing the multiple single characters constituting the text segment according to the classification result includes:
  • the text semantics of the feature corresponding to the single character is determined to identify the semantic classification corresponding to the single character feature.
  • the binary tree-based decoding process can use a classification module for classification processing.
  • the classification result obtained by the classification process is a single character corresponding feature
  • the semantic classification corresponding to the single character feature can be identified, because the semantic classification is not directly extracted, but the semantic classification is obtained through analysis , Thereby improving the recognition accuracy.
  • a text sequence recognition device comprising:
  • the acquiring unit is used to acquire a to-be-processed image containing a text sequence
  • the recognition unit is configured to recognize the text sequence in the image to be processed according to the recognition network to obtain multiple single characters constituting the text sequence, and perform character parallel processing on the multiple single characters to obtain a recognition result.
  • the identification unit is configured to:
  • the multiple single characters constituting the text sequence in the image to be processed are recognized.
  • the identification unit is configured to:
  • the identification unit is configured to:
  • the image features of the text sequence in the image to be processed are extracted to obtain a feature map, so as to recognize the text sequence according to the feature map to obtain a plurality of single characters constituting the text sequence.
  • the identification unit is configured to:
  • the feature map is obtained.
  • the identification unit is configured to:
  • the identification unit is configured to:
  • the feature map is processed based on the sequence segmentation attention rule, and after the attention feature matrix is obtained, multi-channel selection is performed on the attention feature matrix according to the binary tree.
  • the identification unit is configured to:
  • the multiple attention feature maps and the convolution processing result are weighted, and the binary tree node feature of the corresponding text segment in the text sequence is obtained according to the weighting result.
  • the identification unit is configured to:
  • the plurality of single characters constituting the text segment are recognized.
  • the identification unit is configured to:
  • the text semantics of the feature corresponding to the single character is determined to identify the semantic classification corresponding to the single character feature.
  • an electronic device including:
  • a memory for storing processor executable instructions
  • the processor is configured to execute the above-mentioned text sequence recognition method.
  • a computer-readable storage medium having computer program instructions stored thereon, and when the computer program instructions are executed by a processor, the above-mentioned text sequence recognition method is realized.
  • a computer program wherein the computer program includes computer-readable code, and when the computer-readable code runs in an electronic device, a processor in the electronic device executes To realize the above-mentioned text sequence recognition method.
  • the text sequence in the to-be-processed image is recognized according to a recognition network to obtain a plurality of single characters constituting the text sequence, and the plurality of single characters are obtained.
  • Parallel processing of a single character is performed to obtain the recognition result.
  • a to-be-processed image containing a text sequence is obtained. Since the text sequence is recognized according to the recognition network, multiple single characters that constitute the text sequence can be obtained. The semantic relationship between the characters is not dependent on the multiple single characters. Characters are processed in parallel to obtain recognition results, which can improve recognition accuracy, and parallel processing can improve processing efficiency.
  • Fig. 1 shows a flowchart of a method for recognizing a text sequence according to an embodiment of the present disclosure.
  • Fig. 2 shows a flowchart of a method for recognizing a text sequence according to an embodiment of the present disclosure.
  • Fig. 3 shows a schematic diagram of a convolutional neural network based on an attention mechanism according to an embodiment of the present disclosure.
  • FIGS. 4a-4d show schematic diagrams of binary trees included in a convolutional neural network based on an attention mechanism according to an embodiment of the present disclosure.
  • Fig. 5 shows a schematic diagram of a sequence segmentation attention module in a convolutional neural network based on an attention mechanism according to an embodiment of the present disclosure.
  • Fig. 6 shows a block diagram of a processing device according to an embodiment of the present disclosure.
  • FIG. 7 shows a block diagram of an electronic device according to an embodiment of the present disclosure.
  • FIG. 8 shows a block diagram of an electronic device according to an embodiment of the present disclosure.
  • regular text can be recognized, and irregular text can also be recognized.
  • irregular text Take the recognition of irregular characters as an example.
  • the store name or logo on the store is irregular characters
  • the traffic signs are irregular characters.
  • the recognition of irregular characters plays an important role in fields such as visual understanding and autonomous driving.
  • Irregular text recognition technology can use an encoding-decoding framework, where the encoder and decoder parts can use recurrent neural networks.
  • Recursive neural network is a serial processing network, its essence is to input once at each step, and get an output result accordingly. Regardless of whether it is for regular or irregular text, encoding and decoding using recurrent neural networks must encode and decode output character by character.
  • a convolutional neural network can be used to downsample the input image, and finally a feature map with a height of 1 pixel and a width of w pixels is obtained, and then long and short-term memory (LSTM Recursive neural networks such as long term memory) encode the characters in the text sequence from left to right to obtain a feature vector, and then use the connectionist temporal classification (CTC, connectionist temporal classification) algorithm to perform the decoding operation to obtain the final Character output.
  • CTC connectionist temporal classification
  • the characters in the text sequence can be encoded from left to right.
  • the attention module can be combined with the recurrent neural network to analyze the image features.
  • the network can be a convolutional neural network structure.
  • the convolutional neural network structure is basically the same as the above-mentioned method for regular text recognition, but the downsampling magnification is controlled so that the height of the final feature map is not 1. h. After that, a maximum pooling layer is used to make the height of the feature map to 1, and then the recurrent neural network is still used for encoding, and the last output of the recurrent neural network is taken as the encoding result.
  • the decoder is replaced with another recursive neural network, the first recursive input is the output of the encoder, and then each recursive output will be input to the attention module to weight the feature map, thereby obtaining the text output of each step .
  • the text output of each step corresponds to a character, and the last output is the end character.
  • recurrent neural networks are used as encoders or decoders, and text recognition is essentially a serialized task. If recursive neural networks are used to encode or decode Because the recursive neural network can only be processed in series, the output of each recursion is often dependent on the previous output, which is easy to cause cumulative errors, resulting in low accuracy of text recognition, and serial processing is also limited to a large extent Improve the processing efficiency of text recognition. It can be seen that the serial processing characteristics of the recurrent neural network are applied to serialized text recognition tasks, but are not applicable. Especially for the recognition of irregular text, it largely depends on the decoder's encoding of contextual semantics, rather than image feature encoding. This can lead to scenes with repeated characters or text without semantics, such as license plate number recognition. The recognition accuracy is lower.
  • the recognition network of the present disclosure (which may be a convolutional neural network based on the attention mechanism) is used to recognize the text sequence in the image to be processed to obtain multiple single characters that constitute the text sequence.
  • the multiple single characters are processed in parallel to obtain a recognition result (for example, the above-mentioned text sequence composed of multiple single characters is included). Therefore, through the recognition network and parallel processing, the recognition accuracy and the recognition efficiency of the text sequence recognition task are improved.
  • the process of recognition through the recognition network may include: encoding based on a binary tree to obtain binary tree node characteristics of text segments in the text sequence; and, in the case of decoding based on the binary tree, performing single character recognition based on the binary tree node characteristics. Encoding and decoding based on a binary tree is also a parallel processing mechanism, so that the recognition accuracy and efficiency of text sequence recognition tasks can be further improved.
  • the present disclosure is based on the parallel processing of binary trees, which can decompose a serial processing task and assign it to one or more binary trees for simultaneous processing.
  • the binary tree is a data structure in a tree connection mode.
  • the present disclosure is not limited to encoding and decoding based on binary trees, but can also be tree-shaped network structures such as tri-trees, and other non-tree-shaped network structures, as long as the network structures that can implement parallel encoding and decoding are within the protection scope of the present disclosure.
  • FIG. 1 shows a flowchart of a text sequence recognition method according to an embodiment of the present disclosure.
  • the method is applied to a text sequence recognition device.
  • the terminal equipment can be user equipment (UE, User Equipment), mobile equipment, cellular phones, cordless phones, personal digital assistants (PDAs, Personal Digital Assistant), handheld devices, computing devices, vehicle-mounted devices, wearable devices, and so on.
  • the processing method may be implemented by a processor invoking a computer-readable instruction stored in the memory. As shown in Figure 1, the process includes:
  • Step S101 Obtain a to-be-processed image containing a text sequence.
  • the image to be processed containing a text sequence can be obtained by image collection of a target object (such as a store name).
  • a target object such as a store name
  • Irregular text sequences can be store names or logos on stores, and can also be various traffic signs and so on. Whether the text sequence is regular can be judged by the shape of the text line, for example, the single line level is regular.
  • the curved lines, such as the Starbucks logo, are irregular.
  • Step S102 Recognizing the text sequence in the image to be processed according to the recognition network to obtain multiple single characters constituting the text sequence, and performing character parallel processing on the multiple single characters to obtain a recognition result.
  • the multiple single characters in the text sequence in the image to be processed may be recognized according to a binary tree set in the recognition network.
  • the recognition network may be: a convolutional neural network based on the attention mechanism.
  • the present disclosure is not limited to the specific network structure.
  • a binary tree may be provided and a neural network that recognizes multiple single characters based on the binary tree is within the protection scope of the present disclosure. .
  • the parallel processing of the multiple single characters is performed according to the recognition network to obtain a text sequence composed of multiple single characters.
  • the text sequence is the recognition result.
  • the text sequence can be cut into text fragments to recognize multiple single characters in the text fragment.
  • After recognizing multiple single characters continue to apply the recognition network for character parallel processing. Because the essence of the recognition network is a neural network model based on artificial neural networks, and one of the characteristics of the neural network model is that it can realize parallel distributed processing. Therefore, Multiple single characters can be processed separately in parallel based on the neural network model to obtain a text sequence composed of multiple single characters.
  • the recognition process may include: 1) encoding based on a binary tree to obtain binary tree node characteristics of text segments in a text sequence; and 2) in the case of decoding based on a binary tree, performing single character recognition based on the binary tree node characteristics.
  • the feature map can be obtained through the feature extraction module, and then the feature map is input into the attention mechanism-based sequence segmentation attention module for encoding to generate the features of the corresponding node of the binary segmentation tree, that is, the feature of the binary tree node of the above text fragment , And then output the binary tree node characteristics of the text segment to the classification module for decoding.
  • the classification can be performed twice in the decoding process to recognize the meaning of a single character in the text segment.
  • a recursive neural network is used for serial processing.
  • characters are encoded from left to right, and the encoding depends on the semantic relationship between the characters.
  • the text sequence is obtained.
  • a recognition network such as a convolutional neural network based on the attention mechanism
  • the semantic relationship between characters can be processed in parallel after multiple single characters are obtained, thereby improving the recognition accuracy and processing efficiency of the character recognition task.
  • Fig. 2 shows a flowchart of a text sequence recognition method according to an embodiment of the present disclosure. As shown in Fig. 2, the process includes:
  • Step S201 Perform image acquisition on the target object to obtain a to-be-processed image containing a text sequence.
  • the target image can be collected by a collection device including a collection processor (such as a camera) to obtain a to-be-processed image containing a text sequence, such as an irregular text sequence.
  • a collection processor such as a camera
  • Step S202 Extract the image features of the text sequence in the image to be processed through the recognition network to obtain a feature map.
  • the image feature of the text sequence in the image to be processed is extracted through the recognition network (such as a convolutional neural network based on the attention mechanism) to obtain an image convolution feature map.
  • the recognition network such as a convolutional neural network based on the attention mechanism
  • recursive neural networks can only be used for serial processing. For example, for irregular text, characters are encoded from left to right. In this way, image features cannot be extracted well, and the extraction is usually Context semantics, while the image convolution feature map is extracted by the recognition network of the present disclosure. Compared with the context semantics, it contains more feature information, which is helpful for subsequent recognition processing.
  • the attention mechanism of the convolutional neural network based on the attention mechanism may be a sequence segmentation attention rule.
  • the attention mechanism is widely used in at least one of different types of deep learning tasks such as natural language processing, image recognition, and speech recognition. Its purpose is to select information that is more critical to the current task goal from a large number of information. Improve the accuracy and processing efficiency of screening high-value information from a large amount of information.
  • it is similar to the human attention mechanism. For example, humans obtain the area that needs to be focused on by quickly scanning the text, that is, the focus of attention, and then invest more attention resources in this area to obtain more attention. Need to pay attention to the detailed information of the target, so as to suppress other useless information, and achieve the purpose of filtering out high-value information.
  • the sequence segmentation attention rule is used to characterize the position of a single character in the text sequence. Since this rule can characterize the position of a single character in the text sequence, and the purpose of binary tree encoding is to not rely on the semantics between characters, it is to split the text sequence into text fragments, and then identify multiple single characters in the text fragment. Characters, and in order to correspond to the binary tree encoding and subsequent decoding, the text segment is described by the binary tree node characteristics of the text segment in the text sequence through this encoding. Therefore, the rule is followed and the width of the binary tree is traversed first according to the rule, thus , Parallel coding is realized under the condition that the coding does not depend on the semantics between characters, which improves the recognition accuracy and processing efficiency.
  • the attention rule and the binary tree can be segmented by the sequence, and these sequences can be converted into an intermediate description (for example, the description of the node characteristics of the binary tree of the text fragment ), and then get the final recognition result based on the information provided by the description of the middle layer.
  • searching and traversing along the width of the binary tree from the root node traversing at least one node of the tree in depth, so as to search for at least one branch of the binary tree. For example, starting from a node of the binary tree (which may be a root node or a leaf node), check other nodes connected to this node to obtain the at least one visit branch.
  • a node of the binary tree which may be a root node or a leaf node
  • the attention mechanism-based convolutional neural network includes at least: a feature extraction module for extracting feature maps (which can be implemented by a graph convolutional neural network), and a sequence segmentation attention rule implemented in combination with a binary tree The sequence segmentation attention module.
  • the text sequence in the image to be processed may be input into a feature extraction module for feature extraction to obtain a feature map, and the feature extraction module is a backbone module of the front end of the recognition network.
  • the feature map can be input to the sequence segmentation attention module containing the binary tree, and the sequence segmentation attention module is used to encode the input feature map to generate the feature corresponding to each node of the binary segmentation tree, that is, the text sequence
  • the binary tree node feature of the Chinese text segment is the character position discrimination module of the convolutional neural network based on the sequence segmentation attention rule.
  • the sequence segmentation attention module can also be connected to the classification module, so that the binary tree node characteristics of the text fragments in the text sequence are input into the classification module for decoding processing.
  • FIG. 3 shows a schematic diagram of a convolutional neural network based on an attention mechanism according to an embodiment of the present disclosure, including: a feature extraction module 11, a sequence segmentation attention module 12, and a classification module 13.
  • the sequence segmentation attention module 12 contains a preset binary tree (also called a binary segmentation tree or a binary selection tree).
  • the feature extraction module 11 can generate corresponding feature maps (such as image convolution feature maps) according to the input image. ).
  • the feature map output by the feature extraction module can be used as input, and the binary tree contained in the sequence segmentation attention module can be coded, and feature extraction is performed on text fragments at different positions of the text sequence to generate each binary tree node Corresponding features, such as the feature of the binary tree node of the corresponding text segment in the text sequence.
  • the output result 121 of the sequence segmentation attention module can be classified by the classification module 13 to obtain the final recognition result, that is, after the classification processing, the text sequence composed of text fragments is recognized and used as the recognition result.
  • the feature extraction module may be a convolutional neural network (CNN, convolutional neural network) or a graph convolutional network (GCN, graph convolutional network).
  • the sequence segmentation attention module can be a sequence segmentation attention network (SPA2Net, sequence partition-aware attention network)
  • each node of the binary tree is a vector with the same dimension as the number of channels of the image convolution feature map
  • each node of the image convolution feature map is processed through the binary tree.
  • the attention position of the currently focused character sequence part can be obtained from the selected channel group.
  • the node channel value of the binary tree corresponding to the selected channel is 1, and the others are 0.
  • you can change "Continuous segment 1" means a group of channels.
  • Each node of the binary tree is a vector, and 1 and 0 can represent the node characteristics of the binary tree.
  • the attention position of the character sequence part of the current attention is described by encoding based on the node characteristics. It is also possible to perform the process of selecting each channel after obtaining the attention matrix according to the image convolution feature map. After performing the process of selecting each channel, the different attention feature maps thus obtained and the image convolution feature maps are weighted, and the weighted sum can be based on a neural network fully connected layer (Full Connected layer, FC layer) (FC layer in Figure 3) twice classification. Among them, according to the first classification, it can be judged whether the character sequence position contains only one text. If not, perform the next text segmentation encoding process based on binary trees. If yes, perform the second classification, and perform the second classification according to the second classification. Single-character categories are classified to learn their semantic characteristics, so that the meaning of a single character can be identified based on the semantic characteristics.
  • FC layer Fully connected layer
  • each node of the binary tree set in the sequence segmentation attention module can be calculated in parallel, and the prediction of each character does not depend on the prediction of the characters before and after it, the leaf nodes of the binary tree are encoded to obtain multiple single After the characters, follow the above sequence segmentation attention rules based on the sequence segmentation attention module to carry out the width-first traversal of the binary tree, and then you can get at least one character output, so that parallel coding can be realized without the semantics of the characters. , Improve the recognition accuracy and processing efficiency.
  • 4a-4d show schematic diagrams of binary trees included in a convolutional neural network based on an attention mechanism according to an embodiment of the present disclosure.
  • the encoding formats used in Figures 4a to 4d respectively encode character strings of different lengths according to different binary trees, and the text segment can be encoded via the binary tree shown in Figure 4a, and the text segment contains a single character "a”; and
  • the text segment is encoded via the binary tree shown in Figure 4b, the text segment is “ab” and contains multiple single characters “a” and “b”; and the text segment is encoded via the binary tree shown in Figure 4c, the text segment Is “abc”, which contains multiple single characters "a", "b”, and “c”; and the text segment is encoded via the binary tree shown in Figure 4d.
  • the text segment is “abcd” and contains multiple single characters " a", "b", "c” and "d”.
  • At least one binary tree is calculated in parallel for each node. In a specific application, a width-first traversal can be added as above to obtain at least one access branch.
  • Step S203 Perform encoding processing on the text sequence in the image to be processed according to the binary tree set in the recognition network to obtain the binary tree node feature of the corresponding text segment in the text sequence.
  • the text sequence in the image to be processed may be subjected to encoding processing for text segmentation of the text sequence according to the binary tree set in the recognition network, which may be referred to as the encoding processing of text segmentation.
  • Step S204 decode the node characteristics of the binary tree corresponding to the text segment in the text sequence, and recognize multiple single characters in the text segment.
  • the process of decoding the node features of the binary tree according to the binary tree can be realized by a classification module.
  • the present disclosure is not limited to the realization of decoding processing and a specific module structure through classification processing, and a processing module that can realize decoding based on the binary tree All are within the protection scope of the present disclosure.
  • the first classification of the classification module is used to determine whether the corresponding text segment in the text sequence contains only a single character. If it only contains a single character, the second classification is performed; if it does not contain only a single character, the next text segmentation is performed Encoding processing. For the second classification, the semantic feature of a single character is recognized. Finally, the multiple single characters in the text segment are all recognized.
  • the text sequence in the image to be processed can be recognized according to the recognition network to obtain multiple single characters that constitute the text sequence.
  • Step S205 Perform character parallel processing on the multiple single characters according to the recognition network to obtain a recognition result.
  • the multiple single characters are processed in parallel according to the recognition network (such as a convolutional neural network based on the attention mechanism) to obtain a text sequence composed of multiple single characters.
  • the text sequence is the recognition result.
  • the text sequence in the image to be processed can be encoded and correspondingly decoded according to the binary tree set in the recognition network.
  • the recognition network can perform parallel processing based on the sequence segmentation attention rule, that is, the present disclosure is based on
  • the encoding and decoding processes performed by the recognition network including the binary tree are also parallel, and through the binary tree in the recognition network, a fixed proportion of channels can be used to encode text line positions of the same proportion of length.
  • the dichotomy is to compare a text sequence with a number in the middle of the text sequence at a "fixed ratio of 1/2" each time to determine how the text sequence is Divide into two text fragments, and continue to compare the divided text fragments at a "fixed ratio of 1/2" to obtain the comparison result until there is only one single character left, and the segmentation process ends.
  • the structure of the binary tree includes: the root node, the leaf nodes under the root node, and the child nodes of the leaf node under the leaf node, and the channel connecting at least one node is called the node channel Therefore, from the perspective of binary tree coding, it can be understood as: divide the text sequence with "1/2 fixed-proportion channel” each time and determine how to remove half of the text fragment each time as the node feature of the next node corresponding to the text fragment. And continue to compare the text fragments obtained by the "1/2 fixed ratio channel” to obtain the comparison result until there is only one single character left, and the segmentation process ends.
  • the root node of a binary tree is used to represent the entire text sequence "abcdf", and the root node encodes 5 characters.
  • the left and right children after the root node correspond to the first half of the text fragment "abc" of the text sequence "abcdf" represented by the root node. "And the latter half of the text fragment "df”.
  • the encoding process of the segmentation is based on the "1/2 fixed-proportion channel" for segmentation, but for the characters in which specific text line position in the text sequence, the same ratio length is used for encoding
  • Fig. 5 shows a schematic diagram of a sequence segmentation attention module in a convolutional neural network based on an attention mechanism according to an embodiment of the present disclosure.
  • a feature extraction module such as CNN or GCN
  • a corresponding feature map such as an image convolution feature map
  • X in Figure 5 is the feature map.
  • the sequence segmentation attention module (such as SPA2Net) takes the feature map output by the feature extraction module as input, encodes the binary tree contained in the sequence segmentation attention module, and performs feature extraction on text fragments at different positions in the text sequence to generate each binary tree
  • the feature corresponding to the node such as the binary tree node feature of the corresponding text fragment in the text sequence, can be specifically obtained from a text fragment to obtain a binary tree, or from a text sequence to obtain a binary tree, and then a binary tree node is a text fragment.
  • the a module and the b module in the sequence segmentation attention module can be a convolutional neural network, for example, a CNN containing two convolutional layers, which can be used to predict attention and change the feature map respectively.
  • the a module is used to obtain the output of the attention after obtaining the feature map X.
  • Activation function such as Sigmoid's nonlinear operation to obtain the attention matrix x a
  • the b module is used to continue to extract features to update the feature map
  • x a is the attention matrix output by the a module
  • x a will be used by the c module ( For example, a module containing a binary tree) is used for multi-channel selection.
  • the c module is used to multiply x a channel by channel to obtain the attention feature map d of each channel.
  • the selected different attention feature maps d will be It is used to weight and sum the output of the b module to extract the feature e of each part, and use the feature e as the output result 121 obtained by the sequence segmentation attention module and provide it to the classification module for classification processing.
  • the feature e is used to characterize the feature of a certain text segment in the entire sequence of text, which can be called the feature corresponding to each binary tree node, such as the feature of the binary tree node of the corresponding text segment in the text sequence.
  • the feature In the process of classification processing through the classification module, the feature will first be classified whether it is a feature for single character recognition, if it is, it will be directly classified into the category of the word to know its semantic feature, and then recognize it based on the semantic feature The meaning of a single character.
  • the processing of the above sequence segmentation attention module is mainly realized by the following formula (1)-formula (3), where formula (1) is used to calculate the attention matrix x a output by module a; formula (2) is used to calculate the attention
  • the matrix x a is the different attention feature maps d selected after multi-channel selection by the c module (such as the module containing the binary tree); the formula (3) is used to calculate the different attention feature maps d to perform the output of the b module
  • the weighted sum is used to extract the feature e of each part, and use the feature e as the output result 121 obtained by the sequence segmentation attention module.
  • X is the convolution feature map of the input image obtained by the feature extraction module
  • w a1 and w a2 are the convolution kernels of the convolution operation
  • * is the convolution operator
  • T(X) In order to calculate the output feature of the feature map X through the relative position self-attention module, ⁇ is the operation using an activation function such as the Sigmoid function, and finally the attention matrix x a output by the a module is obtained.
  • x a is the attention matrix output by module a;
  • is the channel-by-channel multiplication operator, and
  • X is the feature map obtained by the feature extraction module of the input image
  • W f1 and W f2 are the convolution kernels of the convolution operation respectively
  • H and W are the height information and width of the attention feature map d, respectively Information
  • d is the different attention feature maps selected after multi-channel selection
  • e is the feature vector obtained by weighting the different attention maps d and the convolution feature map (the output of module b);
  • the i in (3) is the traversal parameter used for breadth-first traversal based on the binary tree.
  • d i D may be, d i to a feature specific to traverse the binary tree of FIG positions corresponding to node i
  • e i e may be, especially i e i obtained according to D Feature vector.
  • the encoding process of performing text segmentation on the text sequence in the image to be processed according to the binary tree to obtain the binary tree node feature of the corresponding text segment in the text sequence includes: inputting the feature map to include all The sequence segmentation attention module of the binary tree, the sequence segmentation attention module is the character position discrimination module of the recognition network; multi-channel (such as each channel) selection is performed on the feature map according to the binary tree to obtain multiple Target channel group; encoding of text segmentation according to the multiple target channel groups to obtain the binary tree node feature of the corresponding text segment in the text sequence.
  • the multi-channel selection of the feature map according to the binary tree includes: processing the feature map based on the sequence segmentation attention rule to obtain an attention feature matrix (as shown in Figure 5). After x a ), multi-channel selection is performed on the attention feature matrix according to the binary tree. For example, the attention matrix is obtained after prediction by the sequence segmentation attention rule, and then the attention matrix is provided to the binary tree for multi-channel selection, and finally multiple different attention feature maps are output (d in Figure 5).
  • performing text segmentation according to the multiple target channel groups to obtain binary tree node features of corresponding text fragments in the text sequence includes: performing multi-channel selection on the feature map according to the binary tree.
  • the target channel group is encoded for text segmentation to obtain multiple attention feature maps (as shown in d in Figure 5); convolution processing is performed on the feature maps that are initially input to the recognition network, and the convolution processing result is obtained (as shown in Figure 5).
  • the decoding part of the present disclosure is relatively simple in terms of encoding.
  • Two classifiers (such as a node classifier and a character classifier) can be included in the classification module to perform two classifications, and the node classifier is used to perform the first classification.
  • the binary tree node features are classified, and the output of the node classifier is obtained, and the output result (single character) is input into the character classifier for the second classification, which is to classify the text semantics corresponding to the single character.
  • performing decoding processing on the feature of the binary tree node according to the binary tree to recognize the plurality of single characters in the text segment includes: inputting the feature of the binary tree and the node of the binary tree The classification module classifies nodes to obtain a classification result; according to the classification result, recognizes the multiple single characters in the text segment.
  • recognizing the plurality of single characters in the text segment includes: in the case that the classification result is a feature corresponding to a single character, explaining the text segment corresponding to the feature of the binary tree node If a single character is contained in the single character, the text semantics corresponding to the single character is determined (to know the meaning corresponding to the single character), so as to identify the semantic classification corresponding to the single character.
  • the writing order of the steps does not mean a strict execution order but constitutes any limitation on the implementation process.
  • the specific execution order of each step should be based on its function and possibility.
  • the inner logic is determined.
  • the present disclosure also provides text sequence recognition devices, electronic equipment, computer-readable storage media, and programs, all of which can be used to implement any text sequence recognition method provided in the present disclosure.
  • text sequence recognition devices electronic equipment, computer-readable storage media, and programs, all of which can be used to implement any text sequence recognition method provided in the present disclosure.
  • the corresponding technical solutions and descriptions and refer to methods Part of the corresponding records will not be repeated here.
  • Fig. 6 shows a block diagram of a text sequence recognition device according to an embodiment of the present disclosure.
  • the device includes: an acquisition unit 31 for acquiring a to-be-processed image containing a text sequence; and a recognition unit 32 for Recognizing the text sequence in the image to be processed according to the recognition network to obtain a plurality of single characters constituting the text sequence, and performing character parallel processing on the multiple single characters to obtain a recognition result.
  • the recognition unit is configured to: according to a binary tree set in the recognition network, recognize the multiple single characters that constitute the text sequence in the image to be processed.
  • the recognition unit is configured to: encode the text sequence in the image to be processed according to the binary tree to obtain the binary tree node characteristics of the corresponding text segment in the text sequence; The binary tree node features are decoded, and the multiple single characters constituting the text segment are recognized.
  • the recognition unit is configured to: extract image features of the text sequence in the image to be processed through the recognition network to obtain a feature map, so as to recognize the text sequence according to the feature map, Obtain a plurality of single characters constituting the text sequence.
  • the recognition unit is configured to: input the text sequence in the image to be processed into a feature extraction module; obtain the feature map after feature extraction by the feature extraction module.
  • the recognition unit is configured to: input the feature map into a sequence segmentation attention module based on sequence segmentation attention rules; segment the attention module according to the sequence of the binary tree included in the feature
  • the graph performs multi-channel selection to obtain multiple target channel groups; performs text segmentation according to the multiple target channel groups to obtain the binary tree node characteristics of the corresponding text fragments in the text sequence.
  • the recognition unit is configured to: process the feature map based on the sequence segmentation attention rule, and after obtaining the attention feature matrix, multiply the attention feature matrix according to the binary tree. Channel selection.
  • the recognition unit is configured to: perform text segmentation according to the multiple target channel groups to obtain multiple attention feature maps; perform convolution processing on the feature maps to obtain a convolution processing result;
  • the multiple attention feature maps and the convolution processing result are weighted, and the binary tree node feature of the corresponding text segment in the text sequence is obtained according to the weighting result.
  • the recognition unit is configured to: input the binary tree and the node characteristics of the binary tree into a classification module to perform node classification, and obtain a classification result; according to the classification result, identify all components that constitute the text segment Describe multiple single characters.
  • the recognition unit is configured to: when the classification result is a feature corresponding to a single character, determine the text semantics of the feature corresponding to the single character to identify the semantic classification corresponding to the feature of the single character .
  • the functions or modules contained in the device provided in the embodiments of the present disclosure can be used to execute the methods described in the above method embodiments.
  • the functions or modules contained in the device provided in the embodiments of the present disclosure can be used to execute the methods described in the above method embodiments.
  • the embodiments of the present disclosure also provide a computer-readable storage medium on which computer program instructions are stored, and the computer program instructions implement the above-mentioned method when executed by a processor.
  • the computer-readable storage medium may be a volatile computer-readable storage medium or a non-volatile computer-readable storage medium.
  • the embodiments of the present disclosure also provide a computer program product, which includes computer-readable code.
  • the processor in the device executes the recognition of the text sequence provided by any of the above embodiments. instruction.
  • the embodiments of the present disclosure also provide another computer program product for storing computer-readable instructions, which when executed, cause the computer to perform the operations of the text sequence recognition method provided by any of the foregoing embodiments.
  • the computer program product can be specifically implemented by hardware, software, or a combination thereof.
  • the computer program product is specifically embodied as a computer storage medium.
  • the computer program product is specifically embodied as a software product, such as a software development kit (SDK, Software Development Kit), etc. Wait.
  • SDK software development kit
  • Software Development Kit Software Development Kit
  • An embodiment of the present disclosure also provides an electronic device, including: a processor; a memory for storing executable instructions of the processor; wherein the processor is configured as the above method.
  • the electronic device can be provided as a terminal, server or other form of device.
  • Fig. 7 is a block diagram showing an electronic device 800 according to an exemplary embodiment.
  • the electronic device 800 may be a mobile phone, a computer, a digital broadcasting terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, and other terminals.
  • the electronic device 800 may include one or more of the following components: a processing component 802, a memory 804, a power supply component 806, a multimedia component 808, an audio component 810, an input/output (I/O) interface 812, and a sensor component 814 , And communication component 816.
  • the processing component 802 generally controls the overall operations of the electronic device 800, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations.
  • the processing component 802 may include one or more processors 820 to execute instructions to complete all or part of the steps of the foregoing method.
  • the processing component 802 may include one or more modules to facilitate the interaction between the processing component 802 and other components.
  • the processing component 802 may include a multimedia module to facilitate the interaction between the multimedia component 808 and the processing component 802.
  • the memory 804 is configured to store various types of data to support operations in the electronic device 800. Examples of these data include instructions for any application or method operating on the electronic device 800, contact data, phone book data, messages, pictures, videos, etc.
  • the memory 804 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable and Programmable read only memory (EPROM), programmable read only memory (PROM), read only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.
  • SRAM static random access memory
  • EEPROM electrically erasable programmable read-only memory
  • EPROM erasable and Programmable read only memory
  • PROM programmable read only memory
  • ROM read only memory
  • magnetic memory flash memory
  • flash memory magnetic disk or optical disk.
  • the power supply component 806 provides power for various components of the electronic device 800.
  • the power supply component 806 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the electronic device 800.
  • the multimedia component 808 includes a screen that provides an output interface between the electronic device 800 and the user.
  • the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from the user.
  • the touch panel includes one or more touch sensors to sense touch, sliding, and gestures on the touch panel. The touch sensor may not only sense the boundary of a touch or slide action, but also detect the duration and pressure related to the touch or slide operation.
  • the multimedia component 808 includes a front camera and/or a rear camera. When the electronic device 800 is in an operation mode, such as a shooting mode or a video mode, the front camera and/or the rear camera can receive external multimedia data. Each front camera and rear camera can be a fixed optical lens system or have focal length and optical zoom capabilities.
  • the audio component 810 is configured to output and/or input audio signals.
  • the audio component 810 includes a microphone (MIC), and when the electronic device 800 is in an operation mode, such as a call mode, a recording mode, and a voice recognition mode, the microphone is configured to receive an external audio signal.
  • the received audio signal may be further stored in the memory 804 or transmitted via the communication component 816.
  • the audio component 810 further includes a speaker for outputting audio signals.
  • the I/O interface 812 provides an interface between the processing component 802 and a peripheral interface module.
  • the peripheral interface module may be a keyboard, a click wheel, a button, and the like. These buttons may include, but are not limited to: home button, volume button, start button, and lock button.
  • the sensor component 814 includes one or more sensors for providing the electronic device 800 with various aspects of state evaluation.
  • the sensor component 814 can detect the on/off status of the electronic device 800 and the relative positioning of the components.
  • the component is the display and the keypad of the electronic device 800.
  • the sensor component 814 can also detect the electronic device 800 or the electronic device 800.
  • the position of the component changes, the presence or absence of contact between the user and the electronic device 800, the orientation or acceleration/deceleration of the electronic device 800, and the temperature change of the electronic device 800.
  • the sensor component 814 may include a proximity sensor configured to detect the presence of nearby objects when there is no physical contact.
  • the sensor component 814 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications.
  • the sensor component 814 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
  • the communication component 816 is configured to facilitate wired or wireless communication between the electronic device 800 and other devices.
  • the electronic device 800 can access a wireless network based on a communication standard, such as WiFi, 2G, or 3G, or a combination thereof.
  • the communication component 816 receives a broadcast signal or broadcast related information from an external broadcast management system via a broadcast channel.
  • the communication component 816 further includes a near field communication (NFC) module to facilitate short-range communication.
  • the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.
  • RFID radio frequency identification
  • IrDA infrared data association
  • UWB ultra-wideband
  • Bluetooth Bluetooth
  • the electronic device 800 may be implemented by one or more application-specific integrated circuits (ASIC), digital signal processors (DSP), digital signal processing devices (DSPD), programmable logic devices (PLD), field-available A programmable gate array (FPGA), controller, microcontroller, microprocessor, or other electronic components are implemented to implement the above methods.
  • ASIC application-specific integrated circuits
  • DSP digital signal processors
  • DSPD digital signal processing devices
  • PLD programmable logic devices
  • FPGA field-available A programmable gate array
  • controller microcontroller, microprocessor, or other electronic components are implemented to implement the above methods.
  • a computer-readable storage medium is also provided, such as the memory 804 including computer program instructions, which can be executed by the processor 820 of the electronic device 800 to complete the foregoing method.
  • Fig. 8 is a block diagram showing an electronic device 900 according to an exemplary embodiment.
  • the electronic device 900 may be provided as a server.
  • the electronic device 900 includes a processing component 922, which further includes one or more processors, and a memory resource represented by a memory 932, for storing instructions that can be executed by the processing component 922, such as an application program.
  • the application program stored in the memory 932 may include one or more modules each corresponding to a set of instructions.
  • the processing component 922 is configured to execute instructions to perform the above-mentioned methods.
  • the electronic device 900 may also include a power supply component 926 configured to perform power management of the electronic device 900, a wired or wireless network interface 950 configured to connect the electronic device 900 to a network, and an input output (I/O) interface 958 .
  • the electronic device 900 can operate based on an operating system stored in the memory 932, such as Windows ServerTM, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM or the like.
  • a computer-readable storage medium such as a memory 932 including computer program instructions, which can be executed by the processing component 922 of the electronic device 900 to complete the foregoing method.
  • the present disclosure may be a system, method and/or computer program product.
  • the computer program product may include a computer-readable storage medium loaded with computer-readable program instructions for enabling a processor to implement various aspects of the present disclosure.
  • the computer-readable storage medium may be a tangible device that can hold and store instructions used by the instruction execution device.
  • the computer-readable storage medium may be, for example, but not limited to, an electrical storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination of the foregoing.
  • Non-exhaustive list of computer-readable storage media include: portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM) Or flash memory), static random access memory (SRAM), portable compact disk read-only memory (CD-ROM), digital versatile disk (DVD), memory stick, floppy disk, mechanical encoding device, such as a printer with instructions stored thereon
  • RAM random access memory
  • ROM read-only memory
  • EPROM erasable programmable read-only memory
  • flash memory flash memory
  • SRAM static random access memory
  • CD-ROM compact disk read-only memory
  • DVD digital versatile disk
  • memory stick floppy disk
  • mechanical encoding device such as a printer with instructions stored thereon
  • the computer-readable storage medium used here is not interpreted as the instantaneous signal itself, such as radio waves or other freely propagating electromagnetic waves, electromagnetic waves propagating through waveguides or other transmission media (for example, light pulses through fiber optic cables), or through wires Transmission of electrical signals.
  • the computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to various computing/processing devices, or downloaded to an external computer or external storage device via a network, such as the Internet, a local area network, a wide area network, and/or a wireless network.
  • the network may include copper transmission cables, optical fiber transmission, wireless transmission, routers, firewalls, switches, gateway computers, and/or edge servers.
  • the network adapter card or network interface in each computing/processing device receives computer-readable program instructions from the network, and forwards the computer-readable program instructions for storage in the computer-readable storage medium in each computing/processing device .
  • the computer program instructions used to perform the operations of the present disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-related instructions, microcode, firmware instructions, state setting data, or in one or more programming languages.
  • Source code or object code written in any combination, the programming language includes object-oriented programming languages such as Smalltalk, C++, etc., and conventional procedural programming languages such as "C" language or similar programming languages.
  • Computer-readable program instructions can be executed entirely on the user's computer, partly on the user's computer, executed as a stand-alone software package, partly on the user's computer and partly executed on a remote computer, or entirely on the remote computer or server carried out.
  • the remote computer can be connected to the user's computer through any kind of network-including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computer (for example, using an Internet service provider to connect to the user's computer) connection).
  • LAN local area network
  • WAN wide area network
  • an electronic circuit such as a programmable logic circuit, a field programmable gate array (FPGA), or a programmable logic array (PLA), can be customized by using the status information of the computer-readable program instructions.
  • FPGA field programmable gate array
  • PDA programmable logic array
  • the computer-readable program instructions are executed to realize various aspects of the present disclosure.
  • These computer-readable program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, thereby producing a machine that makes these instructions when executed by the processor of the computer or other programmable data processing device , A device that implements the functions/actions specified in one or more blocks in the flowcharts and/or block diagrams is produced. It is also possible to store these computer-readable program instructions in a computer-readable storage medium. These instructions make computers, programmable data processing apparatuses, and/or other devices work in a specific manner. Thus, the computer-readable medium storing the instructions includes An article of manufacture, which includes instructions for implementing various aspects of the functions/actions specified in one or more blocks in the flowcharts and/or block diagrams.
  • each block in the flowchart or block diagram may represent a module, program segment, or part of an instruction, and the module, program segment, or part of an instruction contains one or more components for realizing the specified logical function.
  • Executable instructions may also occur in a different order than the order marked in the drawings. For example, two consecutive blocks can actually be executed substantially in parallel, or they can sometimes be executed in the reverse order, depending on the functions involved.
  • each block in the block diagram and/or flowchart, and the combination of the blocks in the block diagram and/or flowchart can be implemented by a dedicated hardware-based system that performs the specified functions or actions Or it can be realized by a combination of dedicated hardware and computer instructions.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Artificial Intelligence (AREA)
  • General Engineering & Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Multimedia (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Health & Medical Sciences (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Evolutionary Computation (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Evolutionary Biology (AREA)
  • Biophysics (AREA)
  • Biomedical Technology (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Character Discrimination (AREA)
  • Image Analysis (AREA)
  • Character Input (AREA)

Abstract

一种文本序列的识别方法及装置、电子设备和存储介质,其中,该方法包括:获取包含文本序列的待处理图像(S101);根据识别网络对所述待处理图像中的文本序列进行识别,得到构成所述文本序列的多个单字符,对所述多个单字符进行字符并行处理,得到识别结果(S102)。

Description

文本序列的识别方法及装置、电子设备和存储介质
本公开要求在2019年09月27日提交中国专利局、申请号为201910927338.4、申请名称为“文本序列的识别方法及装置、电子设备和存储介质”的中国专利申请的优先权,其全部内容通过引用结合在本公开中。
技术领域
本公开涉及数据处理技术领域,尤其涉及一种文本序列的识别方法及装置、电子设备和存储介质。
背景技术
在文本序列的识别场景中,识别不规则文字在诸如视觉理解、自动驾驶等领域有着重要的作用。不规则文字大量存在于交通标志、店面招牌等自然场景中,由于视角变化、光照变化等因素,导致识别难度相较于对规则文字的识别更高,需要对其识别性能进行完善。
发明内容
本公开提出了一种文本序列识别的技术方案。
根据本公开的一方面,提供了一种文本序列的识别方法,所述方法包括:
获取包含文本序列的待处理图像;
根据识别网络对所述待处理图像中的文本序列进行识别,得到构成所述文本序列的多个单字符,对所述多个单字符进行字符并行处理,得到识别结果。
采用本公开,获取包含文本序列的待处理图像,由于根据识别网络对文本序列进行识别,可以得到构成该文本序列的多个单字符,不依赖于字符之间的语义关系,则对多个单字符进行字符并行处理,得到识别结果,可以提高识别精度,且并行处理可以提高处理效率。
可能的实现方式中,所述根据识别网络对所述待处理图像中的文本序列进行识别,得到构成所述文本序列的多个单字符,包括:
根据所述识别网络中设置的二叉树,识别出所述待处理图像中构成所述文本序列的所述多个单字符。
采用本公开,基于二叉树的处理可以达到对多个单字符并行编码和解码的作用,使单字符的识别精度大大提高。
可能的实现方式中,所述根据所述识别网络中设置的二叉树,识别出所述待处理图像中构成所述文本序列的所述多个单字符,包括:
根据所述二叉树对所述待处理图像中的文本序列进行编码处理,得到文本序列中对应文本片段的二叉树节点特征;
根据所述二叉树对所述二叉树节点特征进行解码处理,识别出构成所述文本片段的所述多个单字符。
采用本公开,基于二叉树编码的过程中,可以对所述待处理图像中的文本序列进行编码处理,以得到文本序列中对应文本片段的二叉树节点特征,即将一段文本序列通过编码转换为二叉树的节点特征,以便于后续基于该二叉树进行解码处理。
可能的实现方式中,所述获取包含文本序列的待处理图像之后,所述方法还包括:
通过所述识别网络,提取所述待处理图像中的文本序列的图像特征,得到特征图,以根据所述特征图识别所述文本序列,得到构成所述文本序列的多个单字符。
采用本公开,可以通过所述识别网络,提取所述待处理图像中的文本序列的图像特征,得到特征图,由于根据图像特征去处理,以便后续进行语义分析,而不是直接提取语义,相比较而言,语义分析的结果更为准确,从而提高了识别精度。
可能的实现方式中,所述通过所述识别网络,提取所述待处理图像中的文本序列的图像特征,得到特征图,包括:
将所述待处理图像中的文本序列输入特征提取模块;
经所述特征提取模块的特征提取,得到所述特征图。
采用本公开,可以通过识别网络中的特征提取模块进行特征提取,由于网络是自适应调参的,因此,特征提取所得到的特征图更为精确,从而提高了识别精度。
可能的实现方式中,所述根据所述二叉树对所述待处理图像中的文本序列进行编码处理,得到文本序列中对应文本片段的二叉树节点特征,包括:
将所述特征图输入基于序列分割注意力规则的序列分割注意力模块;
根据所述序列分割注意力模块包含的所述二叉树对所述特征图进行多通道选择,得到多个目标通道组;
根据所述多个目标通道组进行文本分割,得到文本序列中对应文本片段的二叉树节点特征。
采用本公开,基于二叉树编码的过程中,可以通过识别网络中的序列分割注意力模块进行编码,以得到文本序列中对应文本片段的二叉树节点特征,即将一段文本序列通过序列分割注意力模块中二叉树的编码转换为二叉树的节点特征,以便于后续基于该二叉树进行解码处理。由于网络是自适应调参的,因此,通过序列分割注意力模块所得到的编码结果更为精确,从而提高了识别精度。
可能的实现方式中,所述根据所述序列分割注意力模块包含的所述二叉树对所述特征图进行多通道选择,包括:
对所述特征图基于所述序列分割注意力规则进行处理,得到注意力特征矩阵后,根据所述二叉树对所述注意力特征矩阵进行多通道选择。
采用本公开,通过序列分割注意力模块中二叉树编码的过程中,可以得到注意力特征矩阵后,根据所述二叉树对所述注意力特征矩阵进行多通道选择,以便得到用于文本分割的多个目标通道组。
可能的实现方式中,所述根据所述多个目标通道组进行文本分割,得到文本序列中对应文本片段的二叉树节点特征,包括:
根据所述多个目标通道组进行文本分割,得到多个注意力特征图;
对所述特征图进行卷积处理,得到卷积处理结果;
将所述多个注意力特征图与所述卷积处理结果进行加权,根据加权结果得到文本序列中对应文本片段的二叉树节点特征。
采用本公开,通过序列分割注意力模块中二叉树编码的过程中,根据所述多个目标通道组进行文本分割,得到多个注意力特征图,将多个注意力特征图与对特征图进行卷积处理得到的卷积处理结果进行加权,则可以根据加权结果得到文本序列中对应文本片段的二叉树节点特征,以便于后续基于该二叉树进行解码处理。
可能的实现方式中,所述根据所述二叉树对所述二叉树节点特征进行解码处理,识别出构成所述文本片段的所述多个单字符,包括:
将所述二叉树和所述二叉树节点特征输入分类模块进行节点分类,得到分类结果;
根据所述分类结果,识别出构成所述文本片段的所述多个单字符。
采用本公开,基于二叉树的解码过程可以采用分类模块进行分类处理。分类处理可以将二叉树和之前编码得到的二叉树节点特征输入识别网络中的分类模块进行节点分类,得到分类结果,根据所述分类结果,识别出构成所述文本片段的所述多个单字符。基于二叉树的解码处理也是并行的,且网络是自适应调参的,因此,通过分类模块所得到的解码结果更为精确,从而提高了识别精度。
可能的实现方式中,所述根据所述分类结果,识别出构成所述文本片段的所述多个单字符,包括:
所述分类结果为单字符对应特征的情况下,判断所述单字符对应特征的文本语义,以识别出所述单字符特征对应的语义分类。
采用本公开,基于二叉树的解码过程可以采用分类模块进行分类处理。分类处理得到的分类结果 为单字符对应特征的情况下,通过判断出单字符对应特征的文本语义,可以识别出单字符特征对应的语义分类,由于不是直接提取语义,而是通过分析得到语义分类,从而提高了识别精度。
根据本公开的一方面,提供了一种文本序列的识别装置,所述装置包括:
获取单元,用于获取包含文本序列的待处理图像;
识别单元,用于根据识别网络对所述待处理图像中的文本序列进行识别,得到构成所述文本序列的多个单字符,对所述多个单字符进行字符并行处理,得到识别结果。
可能的实现方式中,所述识别单元,用于:
根据所述识别网络中设置的二叉树,识别出所述待处理图像中构成所述文本序列的所述多个单字符。
可能的实现方式中,所述识别单元,用于:
根据所述二叉树对所述待处理图像中的文本序列进行编码处理,得到文本序列中对应文本片段的二叉树节点特征;
根据所述二叉树对所述二叉树节点特征进行解码处理,识别出构成所述文本片段的所述多个单字符。
可能的实现方式中,所述识别单元,用于:
通过所述识别网络,提取所述待处理图像中的文本序列的图像特征,得到特征图,以根据所述特征图识别所述文本序列,得到构成所述文本序列的多个单字符。
可能的实现方式中,所述识别单元,用于:
将所述待处理图像中的文本序列输入特征提取模块;
经所述特征提取模块的特征提取,得到所述特征图。
可能的实现方式中,所述识别单元,用于:
将所述特征图输入基于序列分割注意力规则的序列分割注意力模块;
根据所述序列分割注意力模块包含的所述二叉树对所述特征图进行多通道选择,得到多个目标通道组;
根据所述多个目标通道组进行文本分割,得到文本序列中对应文本片段的二叉树节点特征。
可能的实现方式中,所述识别单元,用于:
对所述特征图基于所述序列分割注意力规则进行处理,得到注意力特征矩阵后,根据所述二叉树对所述注意力特征矩阵进行多通道选择。
可能的实现方式中,所述识别单元,用于:
根据所述多个目标通道组进行文本分割,得到多个注意力特征图;
对所述特征图进行卷积处理,得到卷积处理结果;
将所述多个注意力特征图与所述卷积处理结果进行加权,根据加权结果得到文本序列中对应文本片段的二叉树节点特征。
可能的实现方式中,所述识别单元,用于:
将所述二叉树和所述二叉树节点特征输入分类模块进行节点分类,得到分类结果;
根据所述分类结果,识别出构成所述文本片段的所述多个单字符。
可能的实现方式中,所述识别单元,用于:
所述分类结果为单字符对应特征的情况下,判断所述单字符对应特征的文本语义,以识别出所述单字符特征对应的语义分类。
根据本公开的一方面,提供了一种电子设备,包括:
处理器;
用于存储处理器可执行指令的存储器;
其中,所述处理器被配置为:执行上述文本序列的识别方法。
根据本公开的一方面,提供了一种计算机可读存储介质,其上存储有计算机程序指令,所述计算 机程序指令被处理器执行时实现上述文本序列的识别方法。
根据本公开的一方面,提供了一种计算机程序,其中,所述计算机程序包括计算机可读代码,当所述计算机可读代码在电子设备中运行时,所述电子设备中的处理器执行用于实现上述文本序列的识别方法。
在本公开实施例中,通过获取包含文本序列的待处理图像,根据识别网络对所述待处理图像中的文本序列进行识别,得到构成所述文本序列的多个单字符,对所述多个单字符进行字符并行处理,得到识别结果。采用本公开,获取包含文本序列的待处理图像,由于根据识别网络对文本序列进行识别,可以得到构成该文本序列的多个单字符,不依赖于字符之间的语义关系,则对多个单字符进行字符并行处理,得到识别结果,可以提高识别精度,且并行处理可以提高处理效率。
应当理解的是,以上的一般描述和后文的细节描述仅是示例性和解释性的,而非限制本公开。
根据下面参考附图对示例性实施例的详细说明,本公开的其它特征及方面将变得清楚。
附图说明
此处的附图被并入说明书中并构成本说明书的一部分,这些附图示出了符合本公开的实施例,并与说明书一起用于说明本公开的技术方案。
图1示出根据本公开实施例的文本序列的识别方法的流程图。
图2示出根据本公开实施例的文本序列的识别方法的流程图。
图3示出根据本公开实施例的基于注意力机制的卷积神经网络的示意图。
图4a-图4d示出根据本公开实施例的基于注意力机制的卷积神经网络中所包含二叉树的示意图。
图5示出根据本公开实施例的基于注意力机制的卷积神经网络中序列分割注意力模块的示意图。
图6示出根据本公开实施例的处理装置的框图。
图7示出根据本公开实施例的电子设备的框图。
图8示出根据本公开实施例的电子设备的框图。
具体实施方式
以下将参考附图详细说明本公开的各种示例性实施例、特征和方面。附图中相同的附图标记表示功能相同或相似的元件。尽管在附图中示出了实施例的各种方面,但是除非特别指出,不必按比例绘制附图。
在这里专用的词“示例性”意为“用作例子、实施例或说明性”。这里作为“示例性”所说明的任何实施例不必解释为优于或好于其它实施例。
本文中术语“和/或”,仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。另外,本文中术语“至少一种”表示多种中的任意一种或多种中的至少两种的任意组合,例如,包括A、B、C中的至少一种,可以表示包括从A、B和C构成的集合中选择的任意一个或多个元素。
另外,为了更好的说明本公开,在下文的具体实施方式中给出了众多的具体细节。本领域技术人员应当理解,没有某些具体细节,本公开同样可以实施。在一些实例中,对于本领域技术人员熟知的方法、手段、元件和电路未作详细描述,以便于凸显本公开的主旨。
文本序列的识别场景中,可以对规则文字进行识别,也可以对不规则文字进行识别。以识别不规则文字为例,如店铺上的店名或标识是不规则文字,交通标识是不规则文字,对不规则文字的识别在诸如视觉理解、自动驾驶等领域有着重要的作用。
虽然对于规则文字的识别,例如文档解析等任务已经在相关技术中得到较好的解决。然而,不同于对规则文字的识别,对于不规则文字的识别来说,由于不规则文字大量存在于交通标志、店面招牌等自然场景中,由于视角变化、光照变化等因素,其识别难度远远大于规则文字,因而,规则文字的识别技术并不能满足不规则文字识别的应用需求。
不规则文字识别技术可以使用编码-解码框架,其中,编码器和解码器部分可以使用递归神经网络。递归神经网络是一个串行处理的网络,其本质是每一步进行一次输入,相应的得到一个输出结果。不管是针对规则文字还是不规则文字,使用递归神经网络的编码和解码都必须一个字符一个字符的编码及解码输出。
将递归神经网络应用于规则文字识别中,可以采用一个卷积神经网络,对输入图像进行降采样,最终得到一个高度为1像素,宽度为w像素的一个特征图,然后采用长短期记忆(LSTM,long short term memory)等递归神经网络,从左到右对文本序列中的字符进行编码,得到一个特征向量,随后使用连接时序分类器(CTC,connectionist temporal classification)算法进行解码操作,从而得到最终的字符输出。
将递归神经网络应用于不规则文字识别中,可以从左到右对文本序列中的字符进行编码,为了更好的提取图像特征,可以采用注意力模块与递归神经网络结合的方式来对图像特征进行提取,该网络可以为卷积神经网络结构,采用卷积神经网络结构与上述对规则文字识别的做法基本相同,但是控制了降采样的倍率,使得最后的特征图的高度不为1而为h。之后,采用一个最大池化层来让特征图的高度变为1,然后依然采用递归神经网络进行编码,取递归神经网络的最后一个输出作为编码结果。解码器被替换成另外一个递归神经网络,第一次的递归输入为编码器的输出,之后每次递归的输出会被输入到注意力模块对该特征图进行加权,从而得到每一步的文字输出。每一步的文字输出对应一个字符,并且最后一次的输出为结束字符。
综上所述,不论是规则文字识别,还是不规则文字识别,都采用了递归神经网络作为编码器或解码器,而文字识别本质上是一个序列化的任务,如果采用递归神经网络编码或解码,由于该递归神经网络只能串行处理的特性,其每一次递归的输出往往依赖之前的输出,容易造成累计误差,导致对文字识别的精度低,且串行处理在很大程度上也限制了文字识别的处理效率。可见,递归神经网络的串行处理特性应用于序列化的文字识别任务,并不适用。尤其对于不规则文字的识别,很大程度上依赖于解码器对上下文语义的编码,而非图像特征编码,这对于一些有重复字符或文字无语义的场景例如车牌号识别等来说,会导致识别精度更低。
采用本公开的识别网络(可以是基于注意力机制的卷积神经网络)对所述待处理图像中的文本序列进行识别,得到构成所述文本序列的多个单字符,可以根据识别网络对所述多个单字符进行字符并行处理,得到识别结果(如包含由多个单字符构成的上述文本序列)。从而,通过该识别网络和并行处理的方式,提高了对文本序列识别任务的识别精度和识别效率。其中,通过识别网络进行识别的过程中,可以包括:基于二叉树进行编码,以得到文本序列中文本片段的二叉树节点特征;以及,基于二叉树进行解码情况下,根据二叉树节点特征进行单字符识别。基于二叉树进行编码和解码也是并行处理的机制,从而,可以进一步提高了对文本序列识别任务的识别精度和识别效率。
需要指出的是:本公开基于二叉树的并行处理,可以把一个串行处理的任务分解开来,并将其分配给一个或多个二叉树同时处理,二叉树是树形连接方式的数据结构。本公开不限于基于二叉树的编码和解码,还可以是三叉树等树形的网络结构,及其他非树形的网络结构,只要可以实现并行编码和解码的网络结构都在本公开的保护范围之内。
图1示出根据本公开实施例的文本序列识别方法的流程图,该方法应用于文本序列识别装置,例如,该装置部署于终端设备或服务器或其它处理设备执行的情况下,可以执行图像分类、图像检测和视频处理等等。其中,终端设备可以为用户设备(UE,User Equipment)、移动设备、蜂窝电话、无绳电话、个人数字处理(PDA,Personal Digital Assistant)、手持设备、计算设备、车载设备、可穿戴设备等。在一些可能的实现方式中,该处理方法可以通过处理器调用存储器中存储的计算机可读指令的方式来实现。如图1所示,该流程包括:
步骤S101、获取包含文本序列的待处理图像。
一示例中,可以通过对目标对象(如某家店铺店名)进行图像采集,得到包含文本序列(如不规则文本序列)的待处理图像,当然,也可以接收外部设备传输的待处理图像。不规则文本序列可以是 店铺上的店名或标识,还可以是各类交通标识等等。文字序列是否规则,可以通过文字行的形状来判断,比如,单行水平是规则的。而弯曲文字行,比如星巴克的标识是不规则的。
步骤S102、根据识别网络对所述待处理图像中的文本序列进行识别,得到构成所述文本序列的多个单字符,对所述多个单字符进行字符并行处理,得到识别结果。
一示例中,可以根据所述识别网络中设置的二叉树,对所述待处理图像中的文本序列中的所述多个单字符进行识别。识别网络可以是:基于注意力机制的卷积神经网络,本公开不局限该具体的网络结构,可以设置有二叉树并基于该二叉树识别多个单字符的神经网络都在本公开的保护范围之内。
一示例中,根据所述识别网络对所述多个单字符进行字符并行处理,得到包含由多个单字符构成的文本序列。该文本序列即为该识别结果。应用本公开识别网络中设置的二叉树进行如下的编码及解码,可以将文本序列切割为文本片段,以识别出该文本片段中的多个单字符。识别出多个单字符后,继续应用该识别网络进行字符并行处理,由于识别网络的本质是基于人工神经网络的神经网络模型,而神经网络模型的特性之一是可以实现并行分布处理,因此,可以将多个单字符基于神经网络模型进行并行分别处理,从而得到由多个单字符构成的文本序列。
该识别过程可以包括:1)基于二叉树进行编码,以得到文本序列中文本片段的二叉树节点特征;以及,2)基于二叉树进行解码情况下,根据二叉树节点特征进行单字符识别。比如,可以通过特征提取模块得到特征图,之后,将该特征图输入基于注意力机制的序列分割注意力模块进行编码,以产生二叉分割树对应节点的特征,即上述文本片段的二叉树节点特征,然后,将文本片段的二叉树节点特征输出给分类模块进行解码,可以在解码过程中执行两次分类,以识别得到文本片段中单字符的含义。
相关技术中,采用递归神经网络进行串行处理,比如,对于不规则文字,是从左到右对字符进行编码,编码依赖字符之间的语义关系,而采用本公开,获取包含文本序列的待处理图像后,可以通过识别网络(如基于注意力机制的卷积神经网络)得到构成该文本序列的多个单字符,对多个单字符进行字符并行处理,得到识别结果,由于不需要依赖于字符之间的语义关系,得到多个单字符后并行处理即可,从而提高了文字识别任务的识别精度和处理效率。
图2示出根据本公开实施例的文本序列识别方法的流程图,如图2所示,该流程包括:
步骤S201、对目标对象进行图像采集,得到包含文本序列的待处理图像。
可以通过包含采集处理器(如摄像头)的采集装置对目标图象进行图像采集,以得到包含文本序列,如不规则文本序列的待处理图像。
步骤S202、通过所述识别网络,提取所述待处理图像中的文本序列的图像特征,得到特征图。
一示例中,通过所述识别网络(如基于注意力机制的卷积神经网络),提取所述待处理图像中的文本序列的图像特征,可以得到图像卷积特征图。相关技术中,通过递归神经网络由于只能进行串行处理,比如,对于不规则文字,是从左到右对字符进行编码,采用这种方式不能很好的提取图像特征,且提取的通常是上下文语义,而采用本公开的识别网络提取的是图像卷积特征图,相比之上下文语义包含了更多特征信息,有助于后续的识别处理。
一示例中,该基于注意力机制的卷积神经网络,其注意力机制可以为序列分割注意力规则。
其中,注意力机制,被广泛使用在自然语言处理、图像识别及语音识别等至少一种不同类型的深度学习任务中,其目的是为了从众多信息中选择出对当前任务目标更关键的信息,提高了从大量信息中筛选出高价值信息的准确度和处理效率。通俗来说,与人类的注意力机制类似,比如,人类是通过快速扫描文本来获得需要重点关注的区域,即注意力焦点,之后对这一区域投入更多注意力资源,以获取更多所需要关注目标的细节信息,从而抑制其他无用信息,达到筛选出高价值信息的目的。
其中,所述序列分割注意力规则,用于表征单字符在所述文本序列中的位置。由于该规则可以表征单字符在所述文本序列中的位置,且通过二叉树编码的目的是不依赖字符间的语义,是将文本序列拆分成文本片段,进而识别出文本片段中的多个单字符,并且为了对应二叉树的编码和后续的解码,是通过该编码将文本片段以文本序列中文本片段的二叉树节点特征进行描述,因此,遵循该规则并根 据该规则进行二叉树的宽度优先遍历,从而,在编码不依赖字符间语义的情况下实现了并行编码,提高了识别精度和处理效率。也就是说,输入文本序列或语音信号序列等到本公开的识别网络中,可以通过序列分割注意力规则和二叉树,将这些序列转换成一个中间层的描述(比如,文本片段的二叉树节点特征进行描述),然后基于该中间层的描述所提供的信息得到最终的识别结果。
就宽度优先遍历而言,从根结点开始沿着二叉树的宽度进行搜索遍历,深度遍历树的至少一个节点,以便搜索到该二叉树的至少一个分支。比如,从二叉树的一个节点(可以是根节点,也可以是叶子节点)开始,检查与这个节点相连的其他节点,以得到该至少一个访问分支。
从网络结构来说,该基于注意力机制的卷积神经网络至少包括:用于提取特征图的特征提取模块(可以由图卷积神经网络来实现),以及结合二叉树实现的序列分割注意力规则的序列分割注意力模块。可以将所述待处理图像中的文本序列输入特征提取模块进行特征提取以得到特征图,所述特征提取模块为所述识别网络前端的主干(Backbone)模块。可以将所述特征图输入包含所述二叉树的序列分割注意力模块,通过该序列分割注意力模块对输入的特征图进行编码处理,以产生二叉分割树每个节点对应的特征,即文本序列中文本片段的二叉树节点特征,所述序列分割注意力模块为该基于序列分割注意力规则的卷积神经网络的字符位置判别模块。所述序列分割注意力模块还可以与分类模块连接,以便将文本序列中文本片段的二叉树节点特征输入该分类模块进行解码处理。
图3示出根据本公开实施例的基于注意力机制的卷积神经网络的示意图,包括:特征提取模块11、序列分割注意力模块12和分类模块13。序列分割注意力模块12中包含预设的二叉树(也可以称为二叉分割树或二叉选择树),通过特征提取模块11可以根据输入的图像产生对应的特征图(如图像卷积特征图)。通过序列分割注意力模块12可以将特征提取模块输出的特征图作为输入,根据序列分割注意力模块中包含的二叉树进行编码,对文本序列不同位置的文字片段进行特征提取,以产生每个二叉树节点对应的特征,如文本序列中对应文本片段的二叉树节点特征。通过分类模块13可以对序列分割注意力模块的输出结果121进行分类,以得到最终的识别结果,即分类处理后识别得到由文本片段构成的该文本序列并将其作为识别结果。其中,特征提取模块可以是卷积神经网络(CNN,convolutional neural network)或图卷积网络(GCN,graph convolutional network)。序列分割注意力模块可以是序列分割注意力网络(SPA2Net,sequence partition-aware attention network)
其中,通过序列分割注意力模块中设置的二叉树进行编码的过程中,由于二叉树每个节点都是与图像卷积特征图通道数量相同维度的一个向量,则通过二叉树对图像卷积特征图的每个通道进行选择时,可以由选择出的通道组得到目前关注的字符序列部分的注意力位置,其中,选择出的通道所对应在二叉树的节点通道值为1,其他为0,比如,可以将“连续的一段1”来表示一组通道。而二叉树每个节点都是一个向量,通过1和0可以表示二叉树节点特征,如图4a-图4d所示,通过基于节点特征的编码来描述目前关注的字符序列部分的注意力位置。还可以根据图像卷积特征图得到注意力矩阵后进行所述每个通道进行选择的处理。执行所述每个通道进行选择的处理之后,将由此得到的不同注意力特征图与所述图像卷积特征图进行加权,根据得到的加权和可以进行基于神经网络全连接层(Full Connected layer,FC层)(如图3中的FC层)的两次分类。其中,根据第一次分类可以判断该字符序列位置是否只包含一个文字,否的话,进行下一次文本片段基于二叉树的文本分割编码处理,是的话,进行第二次分类,根据第二次分类对单字符类别进行分类,以获知其语义特征,从而根据语义特征识别出单字符所代表的含义。
由于序列分割注意力模块中设置的二叉树的每个节点都可以并行的进行计算,且每个字符的预测并不依赖于其前后字符的预测,因此,通过二叉树的叶子节点来编码得到多个单字符后,遵循序列分割注意力模块所基于的上述序列分割注意力规则进行二叉树的宽度优先遍历,即可拿到至少一个的字符输出,从而,在编码不依赖字符间语义的情况下实现并行编码,提高了识别精度和处理效率。图4a-图4d示出根据本公开实施例的基于注意力机制的卷积神经网络中所包含二叉树的示意图。图4a-图4d所采用的编码格式,分别根据不同二叉树对于不同长度的字符串进行编码,可以得到经图4a所示二叉树对文本片段进行编码,该文本片段中包含单字符“a”;以及经图4b所示二叉树对文本片段进行编码, 该文本片段为“ab”,包含多个单字符“a”和“b”;以及,经图4c所示二叉树对文本片段进行编码,该文本片段为“abc”,包含多个单字符“a”、“b”和“c”;以及,经图4d所示二叉树对文本片段进行编码,该文本片段为“abcd”,包含多个单字符“a”、“b”、“c”和“d”。至少一个二叉树中针对每个节点都是并行计算的,在具体应用时可以如上添加一个宽度优先遍历,以得到至少一个访问分支。
步骤S203、根据识别网络中设置的二叉树,对待处理图像中的文本序列进行编码处理,得到文本序列中对应文本片段的二叉树节点特征。
一示例中,可以根据识别网络中设置的二叉树,对待处理图像中的文本序列进行用于对文本序列文本分割的编码处理,可以简称文本分割的编码处理。
步骤S204、根据识别网络中设置的二叉树,对文本序列中对应文本片段的二叉树节点特征进行解码处理,识别出该文本片段中的多个单字符。
一示例中,根据该二叉树对该二叉树节点特征进行解码处理的过程,可以通过分类模块来实现,本公开不局限通过分类处理来实现解码处理和具体的模块结构,可以基于二叉树实现解码的处理模块都在本公开的保护范围之内。
比如,通过分类模块的第一次分类来判断文本序列中对应文本片段是否只包含单字符,如只包含单字符,则进行第二次分类;如果不只包含单字符,则进行下一次文本分割的编码处理。对于第二次分类,是对单个字符的语义特征进行识别。最终,对文本片段中的该多个单字符都进行了识别。
通过上述步骤S203-步骤S204,可以实现根据识别网络对待处理图像中的文本序列进行识别,以得到构成文本序列的多个单字符。
步骤S205、根据所述识别网络对所述多个单字符进行字符并行处理,得到识别结果。
一示例中,根据所述识别网络(如基于注意力机制的卷积神经网络)对所述多个单字符进行字符并行处理,得到包含由多个单字符构成的文本序列。该文本序列即为该识别结果。
采用本公开,可以根据识别网络中设置的二叉树,对待处理图像中的文本序列进行编码处理及对应的解码处理,该识别网络可以基于序列分割注意力规则进行并行处理,也就是说,本公开基于包含二叉树的该识别网络进行的编码和解码处理也是并行的,且通过该识别网络中的二叉树可以使用固定比例的通道来编码相同比例长度的文字行位置。
其中,二叉树所基于的二分法的实现原理如下:二分法是对一文本序列,每次以“1/2的固定比例”取文本序列中间的一个数进行比较,以确定出将该文本序列如何分割成两个文本片段,及对分割得到的文本片段继续以“1/2的固定比例”比较,以得到比较结果,直到只剩一个单字符,结束分割处理。将二分法应用于二叉树情况下,由于二叉树的结构包括:根节点、根节点下面的叶子节点、叶子节点下面还可以有叶子节点的子节点等,且连接至少一个节点的通道称之为节点通道,因此,从二叉树的编码角度可以理解为:将文本序列每次以“1/2的固定比例通道”分割并确定每次如何去掉一半的文本片段作为下一节点对应该文本片段的节点特征,及对分割得到的文本片段继续以“1/2的固定比例通道”比较,以得到比较结果,直到只剩一个单字符,结束分割处理。比如,采用二叉树的根节点表示整个文本序列“abcdf”,该根节点编码了5个字符。该根节点之后的左右孩子(左右孩子指根节点的叶子节点,叶子节点下面还可以有叶子节点的子节点等)分别对应该根节点所表示的文本序列“abcdf”的前一半文本片段“abc”与后一半文本片段“df”。然后,继续对前一半文本片段“abc”继续以“1/2的固定比例通道”分割,得到前一半文本片段“ab”与后一半文本片段“c”,对于包含后一半文本片段“c”的节点通道,由于只剩单字符,因此,对该节点通道分割结束;继续对前一半文本片段“ab”以“1/2的固定比例通道”分割,得到前一半文本片段“a”与后一半文本片段“b”由于只剩单字符,因此,对该节点通道分割结束。同理,对文本片段“df”以“1/2的固定比例通道”分割,得到前一半文本片段“d”与后一半文本片段“f”,由于只剩单字符,因此,对该节点通道分割结束。虽然二叉树基于二分法,在分割的编码处理时都是基于“1/2的固定比例通道”予以分割,但是,对于字符处于无论文字序列中哪个具体文字行位置,都是采用相同比例长度来编码,比如,可以采用4bit长度的编码“1000”表示“a”,采用4bit长度的编码“0011”表示“c”,采用4bit长度的编码 “1100”表示“ab”,采用4bit长度的编码“1111”表示“abc”等等。也就是说,编码的长度是相同比例长度,但是通过不同“1”和“0”的编码组合可以描述文本序列中位于不同文字行位置的字符。
图5示出根据本公开实施例的基于注意力机制的卷积神经网络中序列分割注意力模块的示意图。通过特征提取模块(如CNN或GCN),可以根据输入的图像产生对应的特征图(如图像卷积特征图),如图5中的X为该特征图。序列分割注意力模块(如SPA2Net)将特征提取模块输出的特征图作为输入,根据序列分割注意力模块中包含的二叉树进行编码,对文本序列不同位置的文字片段进行特征提取,以产生每个二叉树节点对应的特征,如文本序列中对应文本片段的二叉树节点特征,具体的,可以是根据一个文本片段得到一个二叉树,也可以是根据一个文本序列得到一个二叉树,然后一个二叉树节点是一个文本片段。
其中,序列分割注意力模块中的a模块和b模块可以分别为卷积神经网络,比如可以为分别包含两个卷积层的CNN,可以分别用来预测注意力和对特征图进行变化。比如,a模块用于获得特征图X后获取注意力的输出,例如可以根据图5中相对位置自注意模块采用如Transformer算法运算得到输出特征,将该输出特征通过至少一个卷积模块的运算及激活函数如Sigmoid的非线性运算,以得到注意力矩阵x a,而b模块用于继续提取特征,来更新该特征图;x a为a模块输出的注意力矩阵,x a会被c模块(如包含二叉树的模块)来进行多通道选择,例如图5中使用c模块对x a逐通道进行乘法运算,得到每个通道的注意力特征图d,所选择出的不同注意力特征图d会用来对b模块的输出进行加权和,从而提取每一部分的特征e,将该特征e作为通过序列分割注意力模块得到的输出结果121并提供给分类模块进行分类处理。其中,该特征e用于表征整个序列文本中某文本片段的特征,可以称之为每个二叉树节点对应的特征,如文本序列中对应文本片段的二叉树节点特征。通过分类模块进行分类处理的过程中,该特征首先会被分类出是否为单个字符识别的特征,如果是的话,会直接被分类出字的类别,以获知其语义特征,从而根据语义特征识别出单字符所代表的含义。
上述序列分割注意力模块的处理主要通过如下公式(1)-公式(3)实现,其中,公式(1)用于计算a模块输出的注意力矩阵x a;公式(2)用于计算注意力矩阵x a被c模块(如包含二叉树的模块)进行多通道选择后所选择出的不同注意力特征图d;公式(3)用于计算不同注意力特征图d用来对b模块的输出进行加权和,以提取每一部分的特征e,并将该特征e作为通过序列分割注意力模块得到的输出结果121。
X a=δ(T(X)*w a1*w a2)   (1)
Figure PCTCN2019111170-appb-000001
Figure PCTCN2019111170-appb-000002
其中,公式(1)中,X为输入的图像通过特征提取模块得到的卷积特征图;w a1及w a2分别为卷积运算的卷积核,*为卷积运算符;T(X)为对特征图X通过相对位置自注意力模块进行运算得到的输出特征,δ为采用激活函数如Sigmoid函数运算,最终得到a模块输出的注意力矩阵x a。公式(2)中,x a为a模块输出的注意力矩阵;⊙为逐通道乘法运算符,p t为基于二叉树将文本序列分割为对应文本片段的编码过程中第t个二叉树节点特征,即对应文本片段的字符位置编码,其中,t为二叉树的节点序号,如图4a-图4d所示的节点序号0-节点序号6;maxpool为沿通道方向的最大池化运算符;d为多通道选择后所选择出的不同注意力特征图。公式(3)中,X为输入的图像通过特征提取模块得到的特征图;W f1及W f2分别为卷积运算的卷积核;H及W分别为注意力特征图d的高度信息和宽度信息;d为进行多通道选择后所选择出的不同注意力特征图;e为由不同注意力图d与卷积特征图(b模块的输出)进行加权得到的特征向量;公式(2)-公式(3)中的i皆为基于二叉树进行宽度优先遍历所采用的遍历参数。需要指出的是,d和e都是通用表达,d可以为d i,d i特指遍历到二叉树节点i位置对应的某特征图,e可以为e i,e i特指根据d i得到的特征向量。
对本公开的编码部分描述如下:
可能的实现方式中,对于根据所述二叉树对所述待处理图像中的文本序列进行文本分割的编码处理,得到文本序列中对应文本片段的二叉树节点特征,包括:将所述特征图输入包含所述二叉树的序列分割注意力模块,所述序列分割注意力模块为所述识别网络的字符位置判别模块;根据所述二叉树对所述特征图进行多通道(如每个通道)选择,得到多个目标通道组;根据所述多个目标通道组进行文本分割的编码,得到文本序列中对应文本片段的二叉树节点特征。
可能的实现方式中,对于根据所述二叉树对所述特征图进行多通道选择,包括:对所述特征图基于所述序列分割注意力规则进行处理,得到注意力特征矩阵(如图5中的x a)后,根据所述二叉树对所述注意力特征矩阵进行多通道选择。比如,通过序列分割注意力规则进行预测后得到了注意力矩阵,然后,将该注意力矩阵提供给二叉树做多通道选择,最终输出多个不同注意力特征图(如图5中的d)。
可能的实现方式中,根据所述多个目标通道组进行文本分割,得到文本序列中对应文本片段的二叉树节点特征,包括:根据所述二叉树对所述特征图进行多通道选择得到的该多个目标通道组进行文本分割的编码,得到多个注意力特征图(如图5中的d);对初始输入该识别网络的所述特征图进行卷积处理,得到卷积处理结果(如图5中b模块的输出);将所述多个注意力特征图与所述卷积处理结果进行加权,根据加权结果得到文本序列中对应文本片段的二叉树节点特征(如图5中的e)。
本公开的解码部分相对编码来说,相对简单,在分类模块中可以包括两个分类器(如节点分类器和字符分类器)以进行两次分类,通过节点分类器进行第一次分类,是对二叉树节点特征进行分类,得到根据节点分类器的输出,将输出结果(单字符)输入字符分类器进行第二次分类,是对单字符对应的文本语义进行分类。
对本公开的解码部分描述如下:
可能的实现方式中,根据所述二叉树对所述二叉树节点特征进行解码处理,以对所述文本片段中的所述多个单字符进行识别,包括:将所述二叉树和所述二叉树节点特征输入分类模块进行节点分类,得到分类结果;根据所述分类结果,对所述文本片段中的所述多个单字符进行识别。其中,根据所述分类结果,对所述文本片段中的所述多个单字符进行识别,包括:所述分类结果为单字符对应特征的情况下,说明该二叉树节点特征对应的所述文本片段中包含单字符,则判断所述单字符对应的文本语义(以获知单个字符对应的含义),以识别出所述单字符对应的语义分类。
本领域技术人员可以理解,在具体实施方式的上述方法中,各步骤的撰写顺序并不意味着严格的执行顺序而对实施过程构成任何限定,各步骤的具体执行顺序应当以其功能和可能的内在逻辑确定。
本公开提及的上述各个方法实施例,在不违背原理逻辑的情况下,均可以彼此相互结合形成结合后的实施例,限于篇幅,本公开不再赘述。
此外,本公开还提供了文本序列的识别装置、电子设备、计算机可读存储介质、程序,上述均可用来实现本公开提供的任一种文本序列的识别方法,相应技术方案和描述和参见方法部分的相应记载,不再赘述。
图6示出根据本公开实施例的文本序列的识别装置的框图,如图6所示,该装置,包括:获取单元31,用于获取包含文本序列的待处理图像;识别单元32,用于根据识别网络对所述待处理图像中的文本序列进行识别,得到构成所述文本序列的多个单字符,对所述多个单字符进行字符并行处理,得到识别结果。
可能的实现方式中,所述识别单元,用于:根据所述识别网络中设置的二叉树,识别出所述待处理图像中构成所述文本序列的所述多个单字符。
可能的实现方式中,所述识别单元,用于:根据所述二叉树对所述待处理图像中的文本序列进行编码处理,得到文本序列中对应文本片段的二叉树节点特征;根据所述二叉树对所述二叉树节点特征进行解码处理,识别出构成所述文本片段的所述多个单字符。
可能的实现方式中,所述识别单元,用于:通过所述识别网络,提取所述待处理图像中的文本序列的图像特征,得到特征图,以根据所述特征图识别所述文本序列,得到构成所述文本序列的多个单字符。
可能的实现方式中,所述识别单元,用于:将所述待处理图像中的文本序列输入特征提取模块;经所述特征提取模块的特征提取,得到所述特征图。
可能的实现方式中,所述识别单元,用于:将所述特征图输入基于序列分割注意力规则的序列分割注意力模块;根据所述序列分割注意力模块包含的所述二叉树对所述特征图进行多通道选择,得到多个目标通道组;根据所述多个目标通道组进行文本分割,得到文本序列中对应文本片段的二叉树节点特征。
可能的实现方式中,所述识别单元,用于:对所述特征图基于所述序列分割注意力规则进行处理,得到注意力特征矩阵后,根据所述二叉树对所述注意力特征矩阵进行多通道选择。
可能的实现方式中,所述识别单元,用于:根据所述多个目标通道组进行文本分割,得到多个注意力特征图;对所述特征图进行卷积处理,得到卷积处理结果;将所述多个注意力特征图与所述卷积处理结果进行加权,根据加权结果得到文本序列中对应文本片段的二叉树节点特征。
可能的实现方式中,所述识别单元,用于:将所述二叉树和所述二叉树节点特征输入分类模块进行节点分类,得到分类结果;根据所述分类结果,识别出构成所述文本片段的所述多个单字符。
可能的实现方式中,所述识别单元,用于:所述分类结果为单字符对应特征的情况下,判断所述单字符对应特征的文本语义,以识别出所述单字符特征对应的语义分类。
在一些实施例中,本公开实施例提供的装置具有的功能或包含的模块可以用于执行上文方法实施例描述的方法,其具体实现可以参照上文方法实施例的描述,为了简洁,这里不再赘述。
本公开实施例还提出一种计算机可读存储介质,其上存储有计算机程序指令,所述计算机程序指令被处理器执行时实现上述方法。计算机可读存储介质可以是易失性计算机可读存储介质或非易失性计算机可读存储介质。
本公开实施例还提供了一种计算机程序产品,包括计算机可读代码,当计算机可读代码在设备上运行时,设备中的处理器执行用于实现如上任一实施例提供的文本序列的识别指令。
本公开实施例还提供了另一种计算机程序产品,用于存储计算机可读指令,指令被执行时使得计算机执行上述任一实施例提供的文本序列的识别方法的操作。
该计算机程序产品可以具体通过硬件、软件或其结合的方式实现。在一个可选实施例中,所述计算机程序产品具体体现为计算机存储介质,在另一个可选实施例中,计算机程序产品具体体现为软件产品,例如软件开发包(SDK,Software Development Kit)等等。
本公开实施例还提出一种电子设备,包括:处理器;用于存储处理器可执行指令的存储器;其中,所述处理器被配置为上述方法。
电子设备可以被提供为终端、服务器或其它形态的设备。
图7是根据一示例性实施例示出的一种电子设备800的框图。例如,电子设备800可以是移动电话,计算机,数字广播终端,消息收发设备,游戏控制台,平板设备,医疗设备,健身设备,个人数字助理等终端。
参照图7,电子设备800可以包括以下一个或多个组件:处理组件802,存储器804,电源组件806,多媒体组件808,音频组件810,输入/输出(I/O)的接口812,传感器组件814,以及通信组件816。
处理组件802通常控制电子设备800的整体操作,诸如与显示,电话呼叫,数据通信,相机操作和记录操作相关联的操作。处理组件802可以包括一个或多个处理器820来执行指令,以完成上述的方法的全部或部分步骤。此外,处理组件802可以包括一个或多个模块,便于处理组件802和其他组件之间的交互。例如,处理组件802可以包括多媒体模块,以方便多媒体组件808和处理组件802之间的交互。
存储器804被配置为存储各种类型的数据以支持在电子设备800的操作。这些数据的示例包括用于在电子设备800上操作的任何应用程序或方法的指令,联系人数据,电话簿数据,消息,图片,视频等。存储器804可以由任何类型的易失性或非易失性存储设备或者它们的组合实现,如静态随机存取存储器(SRAM),电可擦除可编程只读存储器(EEPROM),可擦除可编程只读存储器(EPROM),可编程只读存储器(PROM),只读存储器(ROM),磁存储器,快闪存储器,磁盘或光盘。
电源组件806为电子设备800的各种组件提供电力。电源组件806可以包括电源管理系统,一个或多个电源,及其他与为电子设备800生成、管理和分配电力相关联的组件。
多媒体组件808包括在所述电子设备800和用户之间的提供一个输出接口的屏幕。在一些实施例中,屏幕可以包括液晶显示器(LCD)和触摸面板(TP)。如果屏幕包括触摸面板,屏幕可以被实现为触摸屏,以接收来自用户的输入信号。触摸面板包括一个或多个触摸传感器以感测触摸、滑动和触摸面板上的手势。所述触摸传感器可以不仅感测触摸或滑动动作的边界,而且还检测与所述触摸或滑动操作相关的持续时间和压力。在一些实施例中,多媒体组件808包括一个前置摄像头和/或后置摄像头。当电子设备800处于操作模式,如拍摄模式或视频模式时,前置摄像头和/或后置摄像头可以接收外部的多媒体数据。每个前置摄像头和后置摄像头可以是一个固定的光学透镜系统或具有焦距和光学变焦能力。
音频组件810被配置为输出和/或输入音频信号。例如,音频组件810包括一个麦克风(MIC),当电子设备800处于操作模式,如呼叫模式、记录模式和语音识别模式时,麦克风被配置为接收外部音频信号。所接收的音频信号可以被进一步存储在存储器804或经由通信组件816发送。在一些实施例中,音频组件810还包括一个扬声器,用于输出音频信号。
I/O接口812为处理组件802和外围接口模块之间提供接口,上述外围接口模块可以是键盘,点击轮,按钮等。这些按钮可包括但不限于:主页按钮、音量按钮、启动按钮和锁定按钮。
传感器组件814包括一个或多个传感器,用于为电子设备800提供各个方面的状态评估。例如,传感器组件814可以检测到电子设备800的打开/关闭状态,组件的相对定位,例如所述组件为电子设备800的显示器和小键盘,传感器组件814还可以检测电子设备800或电子设备800一个组件的位置改变,用户与电子设备800接触的存在或不存在,电子设备800方位或加速/减速和电子设备800的温度变化。传感器组件814可以包括接近传感器,被配置用来在没有任何的物理接触时检测附近物体的存在。传感器组件814还可以包括光传感器,如CMOS或CCD图像传感器,用于在成像应用中使用。在一些实施例中,该传感器组件814还可以包括加速度传感器,陀螺仪传感器,磁传感器,压力传感器或温度传感器。
通信组件816被配置为便于电子设备800和其他设备之间有线或无线方式的通信。电子设备800可以接入基于通信标准的无线网络,如WiFi,2G或3G,或它们的组合。在一个示例性实施例中,通信组件816经由广播信道接收来自外部广播管理系统的广播信号或广播相关信息。在一个示例性实施例中,所述通信组件816还包括近场通信(NFC)模块,以促进短程通信。例如,在NFC模块可基于射频识别(RFID)技术,红外数据协会(IrDA)技术,超宽带(UWB)技术,蓝牙(BT)技术和其他技术来实现。
在示例性实施例中,电子设备800可以被一个或多个应用专用集成电路(ASIC)、数字信号处理器(DSP)、数字信号处理设备(DSPD)、可编程逻辑器件(PLD)、现场可编程门阵列(FPGA)、控制器、微控制器、微处理器或其他电子元件实现,用于执行上述方法。
在示例性实施例中,还提供了一种计算机可读存储介质,例如包括计算机程序指令的存储器804,上述计算机程序指令可由电子设备800的处理器820执行以完成上述方法。
图8是根据一示例性实施例示出的一种电子设备900的框图。例如,电子设备900可以被提供为一服务器。参照图8,电子设备900包括处理组件922,其进一步包括一个或多个处理器,以及由存储器932所代表的存储器资源,用于存储可由处理组件922的执行的指令,例如应用程序。存储器932中存储的应用程序可以包括一个或一个以上的每一个对应于一组指令的模块。此外,处理组件922被配置为执行指令,以执行上述方法。
电子设备900还可以包括一个电源组件926被配置为执行电子设备900的电源管理,一个有线或无线网络接口950被配置为将电子设备900连接到网络,和一个输入输出(I/O)接口958。电子设备900可以操作基于存储在存储器932的操作系统,例如Windows ServerTM,Mac OS XTM,UnixTM,LinuxTM,FreeBSDTM或类似。
在示例性实施例中,还提供了一种计算机可读存储介质,例如包括计算机程序指令的存储器932,上述计算机程序指令可由电子设备900的处理组件922执行以完成上述方法。
本公开可以是系统、方法和/或计算机程序产品。计算机程序产品可以包括计算机可读存储介质,其上载有用于使处理器实现本公开的各个方面的计算机可读程序指令。
计算机可读存储介质可以是可以保持和存储由指令执行设备使用的指令的有形设备。计算机可读存储介质例如可以是――但不限于――电存储设备、磁存储设备、光存储设备、电磁存储设备、半导体存储设备或者上述的任意合适的组合。计算机可读存储介质的更具体的例子(非穷举的列表)包括:便携式计算机盘、硬盘、随机存取存储器(RAM)、只读存储器(ROM)、可擦式可编程只读存储器(EPROM或闪存)、静态随机存取存储器(SRAM)、便携式压缩盘只读存储器(CD-ROM)、数字多功能盘(DVD)、记忆棒、软盘、机械编码设备、例如其上存储有指令的打孔卡或凹槽内凸起结构、以及上述的任意合适的组合。这里所使用的计算机可读存储介质不被解释为瞬时信号本身,诸如无线电波或者其他自由传播的电磁波、通过波导或其他传输媒介传播的电磁波(例如,通过光纤电缆的光脉冲)、或者通过电线传输的电信号。
这里所描述的计算机可读程序指令可以从计算机可读存储介质下载到各个计算/处理设备,或者通过网络、例如因特网、局域网、广域网和/或无线网下载到外部计算机或外部存储设备。网络可以包括铜传输电缆、光纤传输、无线传输、路由器、防火墙、交换机、网关计算机和/或边缘服务器。每个计算/处理设备中的网络适配卡或者网络接口从网络接收计算机可读程序指令,并转发该计算机可读程序指令,以供存储在各个计算/处理设备中的计算机可读存储介质中。
用于执行本公开操作的计算机程序指令可以是汇编指令、指令集架构(ISA)指令、机器指令、机器相关指令、微代码、固件指令、状态设置数据、或者以一种或多种编程语言的任意组合编写的源代码或目标代码,所述编程语言包括面向对象的编程语言—诸如Smalltalk、C++等,以及常规的过程式编程语言—诸如“C”语言或类似的编程语言。计算机可读程序指令可以完全地在用户计算机上执行、部分地在用户计算机上执行、作为一个独立的软件包执行、部分在用户计算机上部分在远程计算机上执行、或者完全在远程计算机或服务器上执行。在涉及远程计算机的情形中,远程计算机可以通过任意种类的网络—包括局域网(LAN)或广域网(WAN)—连接到用户计算机,或者,可以连接到外部计算机(例如利用因特网服务提供商来通过因特网连接)。在一些实施例中,通过利用计算机可读程序指令的状态信息来个性化定制电子电路,例如可编程逻辑电路、现场可编程门阵列(FPGA)或可编程逻辑阵列(PLA),该电子电路可以执行计算机可读程序指令,从而实现本公开的各个方面。
这里参照根据本公开实施例的方法、装置(系统)和计算机程序产品的流程图和/或框图描述了本公开的各个方面。应当理解,流程图和/或框图的每个方框以及流程图和/或框图中各方框的组合,都可以由计算机可读程序指令实现。
这些计算机可读程序指令可以提供给通用计算机、专用计算机或其它可编程数据处理装置的处理器,从而生产出一种机器,使得这些指令在通过计算机或其它可编程数据处理装置的处理器执行时,产生了实现流程图和/或框图中的一个或多个方框中规定的功能/动作的装置。也可以把这些计算机可读程序指令存储在计算机可读存储介质中,这些指令使得计算机、可编程数据处理装置和/或其他设备以特定方式工作,从而,存储有指令的计算机可读介质则包括一个制造品,其包括实现流程图和/或框图中的一个或多个方框中规定的功能/动作的各个方面的指令。
也可以把计算机可读程序指令加载到计算机、其它可编程数据处理装置、或其它设备上,使得在计算机、其它可编程数据处理装置或其它设备上执行一系列操作步骤,以产生计算机实现的过程,从而使得在计算机、其它可编程数据处理装置、或其它设备上执行的指令实现流程图和/或框图中的一个或多个方框中规定的功能/动作。
附图中的流程图和框图显示了根据本公开的多个实施例的系统、方法和计算机程序产品的可能实现的体系架构、功能和操作。在这点上,流程图或框图中的每个方框可以代表一个模块、程序段或指令的一部分,所述模块、程序段或指令的一部分包含一个或多个用于实现规定的逻辑功能的可执行指 令。在有些作为替换的实现中,方框中所标注的功能也可以以不同于附图中所标注的顺序发生。例如,两个连续的方框实际上可以基本并行地执行,它们有时也可以按相反的顺序执行,这依所涉及的功能而定。也要注意的是,框图和/或流程图中的每个方框、以及框图和/或流程图中的方框的组合,可以用执行规定的功能或动作的专用的基于硬件的系统来实现,或者可以用专用硬件与计算机指令的组合来实现。
在不违背逻辑的情况下,本申请不同实施例之间可以相互结合,不同实施例描述有所侧重,为侧重描述的部分可以参见其他实施例的记载。
以上已经描述了本公开的各实施例,上述说明是示例性的,并非穷尽性的,并且也不限于所披露的各实施例。在不偏离所说明的各实施例的范围和精神的情况下,对于本技术领域的普通技术人员来说许多修改和变更都是显而易见的。本文中所用术语的选择,旨在最好地解释各实施例的原理、实际应用或对市场中技术的技术改进,或者使本技术领域的其它普通技术人员能理解本文披露的各实施例。

Claims (23)

  1. 一种文本序列的识别方法,其中,所述方法包括:
    获取包含文本序列的待处理图像;
    根据识别网络对所述待处理图像中的文本序列进行识别,得到构成所述文本序列的多个单字符,对所述多个单字符进行字符并行处理,得到识别结果。
  2. 根据权利要求1所述的方法,其中,所述根据识别网络对所述待处理图像中的文本序列进行识别,得到构成所述文本序列的多个单字符,包括:
    根据所述识别网络中设置的二叉树,识别出所述待处理图像中构成所述文本序列的所述多个单字符。
  3. 根据权利要求2所述的方法,其中,所述根据所述识别网络中设置的二叉树,识别出所述待处理图像中构成所述文本序列的所述多个单字符,包括:
    根据所述二叉树对所述待处理图像中的文本序列进行编码处理,得到文本序列中对应文本片段的二叉树节点特征;
    根据所述二叉树对所述二叉树节点特征进行解码处理,识别出构成所述文本片段的所述多个单字符。
  4. 根据权利要求1-3任一项所述的方法,其中,所述获取包含文本序列的待处理图像之后,所述方法还包括:
    通过所述识别网络,提取所述待处理图像中的文本序列的图像特征,得到特征图,以根据所述特征图识别所述文本序列,得到构成所述文本序列的多个单字符。
  5. 根据权利要求4所述的方法,其中,所述通过所述识别网络,提取所述待处理图像中的文本序列的图像特征,得到特征图,包括:
    将所述待处理图像中的文本序列输入特征提取模块;
    经所述特征提取模块的特征提取,得到所述特征图。
  6. 根据权利要求4或5所述的方法,其中,所述根据所述二叉树对所述待处理图像中的文本序列进行编码处理,得到文本序列中对应文本片段的二叉树节点特征,包括:
    将所述特征图输入基于序列分割注意力规则的序列分割注意力模块;
    根据所述序列分割注意力模块包含的所述二叉树对所述特征图进行多通道选择,得到多个目标通道组;
    根据所述多个目标通道组进行文本分割,得到文本序列中对应文本片段的二叉树节点特征。
  7. 根据权利要求6所述的方法,其中,所述根据所述序列分割注意力模块包含的所述二叉树对所述特征图进行多通道选择,包括:
    对所述特征图基于所述序列分割注意力规则进行处理,得到注意力特征矩阵后,根据所述二叉树对所述注意力特征矩阵进行多通道选择。
  8. 根据权利要求6或7所述的方法,其中,所述根据所述多个目标通道组进行文本分割,得到文本序列中对应文本片段的二叉树节点特征,包括:
    根据所述多个目标通道组进行文本分割,得到多个注意力特征图;
    对所述特征图进行卷积处理,得到卷积处理结果;
    将所述多个注意力特征图与所述卷积处理结果进行加权,根据加权结果得到文本序列中对应文本片段的二叉树节点特征。
  9. 根据权利要求4-8任一项所述的方法,其中,所述根据所述二叉树对所述二叉树节点特征进行解码处理,识别出构成所述文本片段的所述多个单字符,包括:
    将所述二叉树和所述二叉树节点特征输入分类模块进行节点分类,得到分类结果;
    根据所述分类结果,识别出构成所述文本片段的所述多个单字符。
  10. 根据权利要求9所述的方法,其中,所述根据所述分类结果,识别出构成所述文本片段的所述多个单字符,包括:
    所述分类结果为单字符对应特征的情况下,判断所述单字符对应特征的文本语义,以识别出所述单字符特征对应的语义分类。
  11. 一种文本序列的识别装置,其中,所述装置包括:
    获取单元,用于获取包含文本序列的待处理图像;
    识别单元,用于根据识别网络对所述待处理图像中的文本序列进行识别,得到构成所述文本序列的多个单字符,对所述多个单字符进行字符并行处理,得到识别结果。
  12. 根据权利要求11所述的装置,其中,所述识别单元,用于:
    根据所述识别网络中设置的二叉树,识别出所述待处理图像中构成所述文本序列的所述多个单字符。
  13. 根据权利要求12所述的装置,其中,所述识别单元,用于:
    根据所述二叉树对所述待处理图像中的文本序列进行编码处理,得到文本序列中对应文本片段的二叉树节点特征;
    根据所述二叉树对所述二叉树节点特征进行解码处理,识别出构成所述文本片段的所述多个单字符。
  14. 根据权利要求11-13任一项所述的装置,其中,所述识别单元,用于:
    通过所述识别网络,提取所述待处理图像中的文本序列的图像特征,得到特征图,以根据所述特征图识别所述文本序列,得到构成所述文本序列的多个单字符。
  15. 根据权利要求14所述的装置,其中,所述识别单元,用于:
    将所述待处理图像中的文本序列输入特征提取模块;
    经所述特征提取模块的特征提取,得到所述特征图。
  16. 根据权利要求14或15所述的装置,其中,所述识别单元,用于:
    将所述特征图输入基于序列分割注意力规则的序列分割注意力模块;
    根据所述序列分割注意力模块包含的所述二叉树对所述特征图进行多通道选择,得到多个目标通道组;
    根据所述多个目标通道组进行文本分割,得到文本序列中对应文本片段的二叉树节点特征。
  17. 根据权利要求16所述的装置,其中,所述识别单元,用于:
    对所述特征图基于所述序列分割注意力规则进行处理,得到注意力特征矩阵后,根据所述二叉树对所述注意力特征矩阵进行多通道选择。
  18. 根据权利要求16或17所述的装置,其中,所述识别单元,用于:
    根据所述多个目标通道组进行文本分割,得到多个注意力特征图;
    对所述特征图进行卷积处理,得到卷积处理结果;
    将所述多个注意力特征图与所述卷积处理结果进行加权,根据加权结果得到文本序列中对应文本片段的二叉树节点特征。
  19. 根据权利要求14-18任一项所述的装置,其中,所述识别单元,用于:
    将所述二叉树和所述二叉树节点特征输入分类模块进行节点分类,得到分类结果;
    根据所述分类结果,识别出构成所述文本片段的所述多个单字符。
  20. 根据权利要求19所述的装置,其中,所述识别单元,用于:
    所述分类结果为单字符对应特征的情况下,判断所述单字符对应特征的文本语义,以识别出所述单字符特征对应的语义分类。
  21. 一种电子设备,其中,包括:
    处理器;
    用于存储处理器可执行指令的存储器;
    其中,所述处理器被配置为:执行权利要求1至权利要求10中任意一项所述的方法。
  22. 一种计算机可读存储介质,其上存储有计算机程序指令,其中,所述计算机程序指令被处理 器执行时实现权利要求1至权利要求10中任意一项所述的方法。
  23. [根据细则26改正05.11.2019] 
    一种计算机程序,其中,所述计算机程序包括计算机可读代码,当所述计算机可读代码在电子设备中运行时,所述电子设备中的处理器执行用于实现权利要求1至权利要求10中任意一项所述的方法。
PCT/CN2019/111170 2019-09-27 2019-10-15 文本序列的识别方法及装置、电子设备和存储介质 WO2021056621A1 (zh)

Priority Applications (4)

Application Number Priority Date Filing Date Title
JP2021518910A JP7123255B2 (ja) 2019-09-27 2019-10-15 テキストシーケンス認識方法及びその装置、電子機器並びに記憶媒体
SG11202105174XA SG11202105174XA (en) 2019-09-27 2019-10-15 Text sequence recognition method and apparatus, electronic device, and storage medium
KR1020217010064A KR20210054563A (ko) 2019-09-27 2019-10-15 텍스트 시퀀스 인식 방법 및 장치, 전자 기기 및 저장 매체
US17/232,278 US20210232847A1 (en) 2019-09-27 2021-04-16 Method and apparatus for recognizing text sequence, and storage medium

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910927338.4 2019-09-27
CN201910927338.4A CN110659640B (zh) 2019-09-27 2019-09-27 文本序列的识别方法及装置、电子设备和存储介质

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US17/232,278 Continuation US20210232847A1 (en) 2019-09-27 2021-04-16 Method and apparatus for recognizing text sequence, and storage medium

Publications (1)

Publication Number Publication Date
WO2021056621A1 true WO2021056621A1 (zh) 2021-04-01

Family

ID=69039586

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/111170 WO2021056621A1 (zh) 2019-09-27 2019-10-15 文本序列的识别方法及装置、电子设备和存储介质

Country Status (7)

Country Link
US (1) US20210232847A1 (zh)
JP (1) JP7123255B2 (zh)
KR (1) KR20210054563A (zh)
CN (1) CN110659640B (zh)
SG (1) SG11202105174XA (zh)
TW (1) TWI732338B (zh)
WO (1) WO2021056621A1 (zh)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113569839A (zh) * 2021-08-31 2021-10-29 重庆紫光华山智安科技有限公司 证件识别方法、系统、设备及介质
CN115497106A (zh) * 2022-11-14 2022-12-20 合肥中科类脑智能技术有限公司 基于数据增强和多任务模型的电池激光喷码识别方法

Families Citing this family (16)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11494616B2 (en) * 2019-05-09 2022-11-08 Shenzhen Malong Technologies Co., Ltd. Decoupling category-wise independence and relevance with self-attention for multi-label image classification
US11763433B2 (en) * 2019-11-14 2023-09-19 Samsung Electronics Co., Ltd. Depth image generation method and device
CN111539410B (zh) * 2020-04-16 2022-09-06 深圳市商汤科技有限公司 字符识别方法及装置、电子设备和存储介质
CN111626293A (zh) * 2020-05-21 2020-09-04 咪咕文化科技有限公司 图像文本识别方法、装置、电子设备及存储介质
CN111814796A (zh) * 2020-06-29 2020-10-23 北京市商汤科技开发有限公司 字符序列识别方法及装置、电子设备和存储介质
CN111860506B (zh) * 2020-07-24 2024-03-29 北京百度网讯科技有限公司 识别文字的方法和装置
CN112132150B (zh) * 2020-09-15 2024-05-28 上海高德威智能交通系统有限公司 文本串识别方法、装置及电子设备
CN112560862B (zh) 2020-12-17 2024-02-13 北京百度网讯科技有限公司 文本识别方法、装置及电子设备
CN112837204A (zh) * 2021-02-26 2021-05-25 北京小米移动软件有限公司 序列处理方法、序列处理装置及存储介质
CN113313127B (zh) * 2021-05-18 2023-02-14 华南理工大学 文本图像识别方法、装置、计算机设备和存储介质
CN113343981A (zh) * 2021-06-16 2021-09-03 北京百度网讯科技有限公司 一种视觉特征增强的字符识别方法、装置和设备
CN113504891B (zh) * 2021-07-16 2022-09-02 爱驰汽车有限公司 一种音量调节方法、装置、设备以及存储介质
CN113723094B (zh) * 2021-09-03 2022-12-27 北京有竹居网络技术有限公司 文本处理方法、模型训练方法、设备及存储介质
AU2021290429A1 (en) * 2021-12-20 2022-02-10 Sensetime International Pte. Ltd. Sequence recognition method and apparatus, electronic device, and storage medium
CN114207673A (zh) * 2021-12-20 2022-03-18 商汤国际私人有限公司 序列识别方法及装置、电子设备和存储介质
CN115546810B (zh) * 2022-11-29 2023-04-11 支付宝(杭州)信息技术有限公司 图像元素类别的识别方法及装置

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10032072B1 (en) * 2016-06-21 2018-07-24 A9.Com, Inc. Text recognition and localization with deep learning
CN109615006A (zh) * 2018-12-10 2019-04-12 北京市商汤科技开发有限公司 文字识别方法及装置、电子设备和存储介质
US10262235B1 (en) * 2018-02-26 2019-04-16 Capital One Services, Llc Dual stage neural network pipeline systems and methods
CN109871843A (zh) * 2017-12-01 2019-06-11 北京搜狗科技发展有限公司 字符识别方法和装置、用于字符识别的装置
CN110135427A (zh) * 2019-04-11 2019-08-16 北京百度网讯科技有限公司 用于识别图像中的字符的方法、装置、设备和介质

Family Cites Families (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5748807A (en) * 1992-10-09 1998-05-05 Panasonic Technologies, Inc. Method and means for enhancing optical character recognition of printed documents
JPH08147417A (ja) * 1994-11-22 1996-06-07 Oki Electric Ind Co Ltd 単語照合装置
US6741749B2 (en) * 2001-01-24 2004-05-25 Advanced Digital Systems, Inc. System, device, computer program product, and method for representing a plurality of electronic ink data points
US8549399B2 (en) * 2011-01-18 2013-10-01 Apple Inc. Identifying a selection of content in a structured document
CN102509112A (zh) * 2011-11-02 2012-06-20 珠海逸迩科技有限公司 车牌识别方法及其识别系统
AU2014230809B2 (en) * 2013-03-14 2019-05-02 Ventana Medical Systems, Inc. Whole slide image registration and cross-image annotation devices, systems and methods
US10354168B2 (en) * 2016-04-11 2019-07-16 A2Ia S.A.S. Systems and methods for recognizing characters in digitized documents
CN107527059B (zh) * 2017-08-07 2021-12-21 北京小米移动软件有限公司 文字识别方法、装置及终端
CN108108746B (zh) * 2017-09-13 2021-04-09 湖南理工学院 基于Caffe深度学习框架的车牌字符识别方法
CN110276342B (zh) * 2018-03-14 2023-04-18 台达电子工业股份有限公司 车牌辨识方法以及其系统
JP7181761B2 (ja) * 2018-10-30 2022-12-01 株式会社三井E&Sマシナリー 読取システム及び読取方法
TWM583989U (zh) * 2019-04-17 2019-09-21 洽吧智能股份有限公司 序號檢測系統
CN110163206B (zh) * 2019-05-04 2023-03-24 苏州科技大学 车牌识别方法、系统、存储介质和装置
CN110245557B (zh) * 2019-05-07 2023-12-22 平安科技(深圳)有限公司 图片处理方法、装置、计算机设备及存储介质
CN110097019B (zh) * 2019-05-10 2023-01-10 腾讯科技(深圳)有限公司 字符识别方法、装置、计算机设备以及存储介质

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10032072B1 (en) * 2016-06-21 2018-07-24 A9.Com, Inc. Text recognition and localization with deep learning
CN109871843A (zh) * 2017-12-01 2019-06-11 北京搜狗科技发展有限公司 字符识别方法和装置、用于字符识别的装置
US10262235B1 (en) * 2018-02-26 2019-04-16 Capital One Services, Llc Dual stage neural network pipeline systems and methods
CN109615006A (zh) * 2018-12-10 2019-04-12 北京市商汤科技开发有限公司 文字识别方法及装置、电子设备和存储介质
CN110135427A (zh) * 2019-04-11 2019-08-16 北京百度网讯科技有限公司 用于识别图像中的字符的方法、装置、设备和介质

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113569839A (zh) * 2021-08-31 2021-10-29 重庆紫光华山智安科技有限公司 证件识别方法、系统、设备及介质
CN113569839B (zh) * 2021-08-31 2024-02-09 重庆紫光华山智安科技有限公司 证件识别方法、系统、设备及介质
CN115497106A (zh) * 2022-11-14 2022-12-20 合肥中科类脑智能技术有限公司 基于数据增强和多任务模型的电池激光喷码识别方法
CN115497106B (zh) * 2022-11-14 2023-01-24 合肥中科类脑智能技术有限公司 基于数据增强和多任务模型的电池激光喷码识别方法

Also Published As

Publication number Publication date
KR20210054563A (ko) 2021-05-13
JP2022504404A (ja) 2022-01-13
TWI732338B (zh) 2021-07-01
JP7123255B2 (ja) 2022-08-22
CN110659640B (zh) 2021-11-30
US20210232847A1 (en) 2021-07-29
TW202113660A (zh) 2021-04-01
CN110659640A (zh) 2020-01-07
SG11202105174XA (en) 2021-06-29

Similar Documents

Publication Publication Date Title
WO2021056621A1 (zh) 文本序列的识别方法及装置、电子设备和存储介质
JP6926339B2 (ja) 画像のクラスタリング方法及び装置、電子機器並びに記憶媒体
TWI740309B (zh) 圖像處理方法及裝置、電子設備和電腦可讀儲存介質
JP7097513B2 (ja) 画像処理方法及び装置、電子機器並びに記憶媒体
WO2021008023A1 (zh) 图像处理方法及装置、电子设备和存储介质
WO2020029966A1 (zh) 视频处理方法及装置、电子设备和存储介质
CN111612070B (zh) 基于场景图的图像描述生成方法及装置
WO2021208666A1 (zh) 字符识别方法及装置、电子设备和存储介质
WO2021012564A1 (zh) 视频处理方法及装置、电子设备和存储介质
CN109615006B (zh) 文字识别方法及装置、电子设备和存储介质
KR20210114511A (ko) 얼굴 이미지 인식 방법 및 장치, 전자 기기 및 저장 매체
CN110659690B (zh) 神经网络的构建方法及装置、电子设备和存储介质
WO2020220807A1 (zh) 图像生成方法及装置、电子设备及存储介质
WO2020173115A1 (zh) 网络模块和分配方法及装置、电子设备和存储介质
CN111242303B (zh) 网络训练方法及装置、图像处理方法及装置
CN111259967B (zh) 图像分类及神经网络训练方法、装置、设备及存储介质
CN110232181B (zh) 评论分析方法及装置
WO2023092975A1 (zh) 图像处理方法及装置、电子设备、存储介质及计算机程序产品
CN114842404A (zh) 时序动作提名的生成方法及装置、电子设备和存储介质
CN117150066B (zh) 汽车传媒领域的智能绘图方法和装置
CN113822020B (zh) 文本处理方法、设备、存储介质
CN114168807A (zh) 字符串匹配方法及装置
CN111382810A (zh) 字符串的识别方法、装置及存储介质

Legal Events

Date Code Title Description
ENP Entry into the national phase

Ref document number: 20217010064

Country of ref document: KR

Kind code of ref document: A

ENP Entry into the national phase

Ref document number: 2021518910

Country of ref document: JP

Kind code of ref document: A

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19946414

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 30.08.2022)

122 Ep: pct application non-entry in european phase

Ref document number: 19946414

Country of ref document: EP

Kind code of ref document: A1