332 views|8 replies

1452

Posts

1

Resources
The OP
 

[K230 Embedded AI Development Board Review] + Character Recognition and Book Entry Processing [Copy link]

 

The "character recognition" mentioned here refers to optical character recognition, namely OCR (Optical Character Recognition).

The process of using electronic equipment (such as a scanner or digital camera) to check the characters printed on paper, determine their shape by detecting the degree of lightness and darkness, and then translate the shape into computer text using character recognition methods.

The character recognition process of the K230 development board is:

CanMV K230 supports the recognition of Chinese and English characters in images, and the models used are stored in the CanMV K230 file system, so there is no need to provide them separately.

The scene of identifying the display screen content is shown in Figure 1, and it can be seen that the recognition efficiency is very high.

Figure 1 Recognizing Chinese characters in an image

The scene of identifying the content of printed materials or books is shown in Figure 2. Due to the influence of the camera shooting quality, the recognition efficiency will be slightly reduced.

Figure 2 Recognizing text on a book

How to get the recognition results?

This can be found from the output recognition results. The output results of Figure 2 are:

[array([275.0662, 278.0513, 440.2838, 282.0602, 438.9337, 350.9487, 273.7161, 346.9398], dtype=float32), array([134.241, 180.2511, 586.11 93, 189.2587, 584.759, 273.7489, 132.8807, 264.7413],

dtype=float32), array([108.8152, 23.9488, 620.5769, 13.94075, 623.1848, 179.0512, 111.4231, 189.0593], dtype=float32)] ['\u7b2c2\u7248', '\u5 feb\u901f\u7f16\u7a0b\u5165\ u95e8', 'Python']

1.399683

Therefore, we can know that: The recognition result we need is:

['\u7b2c2\u7248', '\u5feb\u901f\u7f16\u7a0b\u5165\u95e8', 'Python']

in:

'Python'---The first line of recognition results

'\u5feb\u901f\u7f16\u7a0b\u5165\u95e8'--The second line of recognition results

'\u7b2c2\u7248'---The third line of recognition results

The specific content is shown in Figure 3. Which encoding method is used for the Chinese characters?

Figure 3 Recognition results

After testing, it was found that the encoding method is not the area code method, as shown in Figure 4.

Figure 4: Area code conversion

After repeated testing, the encoding method is Unicode code, as shown in Figure 5.

Figure 5 Unicode code conversion

So how do we extract the recognition results?

Taking the obtained book title as an example, its content can be obtained through the procedure shown in FIG6 .

Figure 6 Unicode code conversion

In this way, when managing book entry, you can first obtain the book name through recognition and limit the repeated appearance of the recognition result. Then, combine the "RTC timing and file reading and writing application" introduced earlier to provide the corresponding time value and store the information in the file.

If you are managing the borrowing of books, after identifying the book name, you need to check whether the book exists in the management file. If it does not exist, add a borrowing information; otherwise, just modify the storage status of the book. Of course, this is just a simple management idea. In actual management, you also need to add borrower information and solve the problem of multiple copies of books.

This post is from Domestic Chip Exchange

Latest reply

Not necessarily. Pre-processing the image should increase the recognition rate (such as highlighting certain features), but it will greatly reduce the amount of computing caused by the size.   Details Published on 2024-10-29 14:08
 
 

6555

Posts

0

Resources
2
 

It is also related to the resolution of the camera.

This post is from Domestic Chip Exchange

Comments

Yes, higher resolution cameras will improve recognition efficiency.  Details Published on 2024-10-28 13:12
 
 
 

1452

Posts

1

Resources
3
 
Jacktang posted on 2024-10-28 07:45 It is also related to the resolution of the camera

Yes, higher resolution cameras will improve recognition efficiency.

This post is from Domestic Chip Exchange

Comments

The higher the resolution, the longer the computation time will be.  Details Published on 2024-10-28 14:58
 
 
 

7422

Posts

2

Resources
4
 
jinglixixi posted on 2024-10-28 13:12 Yes, high-resolution cameras will improve the efficiency of recognition.

The higher the resolution, the longer the computation time will be.

This post is from Domestic Chip Exchange

Comments

The time will increase, but it will directly improve the recognition accuracy.  Details Published on 2024-10-28 17:27
Personal signature

默认摸鱼,再摸鱼。2022、9、28

 
 
 

7422

Posts

2

Resources
5
 

“Affected by the quality of camera shooting”

Is there any qualitative test for this?

This post is from Domestic Chip Exchange

Comments

Of course, some images will be invalid if they are photographed directly, but taking pictures with a mobile phone and browsing them on a computer, and then providing them to the camera for recognition, will increase the recognition rate, which indirectly illustrates the impact of camera shooting quality on recognition effect.  Details Published on 2024-10-28 17:32
Personal signature

默认摸鱼,再摸鱼。2022、9、28

 
 
 

1452

Posts

1

Resources
6
 
freebsder posted on 2024-10-28 14:58 The higher the resolution, the longer the calculation time will be.

The time will increase, but it will directly improve the recognition accuracy.

This post is from Domestic Chip Exchange

Comments

Not necessarily. Pre-processing the image should increase the recognition rate (such as highlighting certain features), but it will greatly reduce the amount of computing caused by the size.  Details Published on 2024-10-29 14:08
 
 
 

1452

Posts

1

Resources
7
 
freebsder posted on 2024-10-28 15:23 “Affected by the quality of camera shooting” Is there any more qualitative test for this?

Of course, some images will be invalid if they are photographed directly, but taking pictures with a mobile phone and browsing them on a computer, and then providing them to the camera for recognition, will increase the recognition rate, which indirectly illustrates the impact of camera shooting quality on recognition effect.

This post is from Domestic Chip Exchange
 
 
 

7422

Posts

2

Resources
8
 
jinglixixi posted on 2024-10-28 17:27 The time will increase, but it will directly improve the accuracy of recognition.

Not necessarily. Pre-processing the image should increase the recognition rate (such as highlighting certain features), but it will greatly reduce the amount of computing caused by the size.

This post is from Domestic Chip Exchange

Comments

That's another question.  Details Published on 2024-10-29 17:03
Personal signature

默认摸鱼,再摸鱼。2022、9、28

 
 
 

1452

Posts

1

Resources
9
 
freebsder posted on 2024-10-29 14:08 Not necessarily. Pre-processing the image should increase the recognition rate (such as highlighting certain features), but it will greatly reduce the size of the operation...

That's another question.

This post is from Domestic Chip Exchange
 
 
 

Just looking around
Find a datasheet?

EEWorld Datasheet Technical Support

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京B2-20211791 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号
快速回复 返回顶部 Return list