Two-dimensional code image recognition method and device based on artificial intelligence, equipment and medium

Through the artificial intelligence-based QR code image recognition method, the correction and training model are used to optimize the recognition process, which solves the problem of low QR code image recognition rate and achieves fast and reliable recognition results.

CN120688525APending Publication Date: 2025-09-23CHINA PING AN PROPERTY INSURANCE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510672741.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-05-22
Publication Date
2025-09-23

AI Technical Summary

Technical Problem

The current QR code image recognition process is cumbersome and has a low recognition rate, especially when the positioning marks are deformed or offset due to the tilted shooting angle, which increases the recognition time.

Method used

An artificial intelligence-based method is used to obtain preset QR code images, perform corrections and train artificial intelligence models, use image enhancement networks and loss functions to optimize the recognition process, obtain predicted session identifiers, reduce recognition time and improve recognition rates.

Benefits of technology

The QR code image is recognized by the corrected and trained artificial intelligence model to avoid deformation or offset of positioning marks, reduce recognition time, improve recognition rate and enhance reliability, and reduce subjective interference.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120688525A_ABST
    Figure CN120688525A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of artificial intelligence, can be applied to the field of financial science and technology, and discloses a two-dimensional code image recognition method and device based on artificial intelligence, equipment and a medium, and the method comprises the steps: obtaining an actual session identifier corresponding to a preset two-dimensional code image; correcting the preset two-dimensional code image to obtain a corrected preset two-dimensional code image; determining a predicted session identifier based on a preset artificial intelligence model and the corrected preset two-dimensional code image; obtaining a loss value between the predicted session identifier and the actual session identifier, and training an artificial intelligence model through the loss value; and obtaining a current two-dimensional code image, correcting the current two-dimensional code image to obtain a corrected current two-dimensional code image, and identifying the corrected current two-dimensional code image through the trained artificial intelligence model to obtain a current session identifier. According to the invention, the recognition rate of the current two-dimensional code image can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of artificial intelligence technology and can be applied to the field of financial technology. In particular, the present invention relates to a two-dimensional code image recognition method, device, equipment and medium based on artificial intelligence. Background Art

[0002] With the popularization of digital technology, the application scope of QR code images is becoming more and more extensive, from online real-name authentication to cross-border travel, from financial services to government services, covering almost every aspect of life.

[0003] However, the current QR code image recognition process is cumbersome and not conducive to improving the recognition rate of the current QR code image. This is because the current QR code image may be tilted due to the user's shooting angle. Without correction, the tilt will cause the positioning mark of the current QR code image to deform or shift, requiring the current QR code image to be rescanned, increasing the recognition time of the current QR code image, which is not conducive to improving the recognition rate of the current QR code image. Summary of the Invention

[0004] The present invention provides a two-dimensional code image recognition method, device, computer equipment and storage medium based on artificial intelligence to solve the technical problem that the current two-dimensional code image recognition process is cumbersome and is not conducive to improving the recognition rate of the current two-dimensional code image.

[0005] In a first aspect, a method for QR code image recognition based on artificial intelligence is provided, comprising:

[0006] Obtain a preset QR code image, and obtain an actual session identifier corresponding to the preset QR code image;

[0007] Correcting the preset two-dimensional code image to obtain a corrected preset two-dimensional code image;

[0008] Determining a predicted session identifier based on a preset artificial intelligence model and the corrected preset QR code image;

[0009] Obtaining a loss value between the predicted session identifier and the actual session identifier, and training the artificial intelligence model using the loss value;

[0010] When the loss value meets a preset condition, stop training the artificial intelligence model and obtain the trained artificial intelligence model;

[0011] Acquire a current QR code image, correct the current QR code image to obtain the corrected current QR code image, and recognize the corrected current QR code image through the trained artificial intelligence model to obtain a current session identifier.

[0012] Furthermore, the correcting the preset two-dimensional code image to obtain the corrected preset two-dimensional code image includes:

[0013] Get the configuration file and obtain the specified correction algorithm from the configuration file;

[0014] The preset two-dimensional code image is corrected by using a specified correction algorithm to obtain the corrected preset two-dimensional code image.

[0015] Furthermore, the determining of the predicted session identifier based on the preset artificial intelligence model and the corrected preset QR code image includes:

[0016] Inputting the corrected preset QR code image into a preset image enhancement network, and processing the corrected preset QR code image through the image enhancement network to obtain an enhanced preset QR code image;

[0017] The enhanced preset QR code image is input into the artificial intelligence model, and the enhanced preset QR code image is recognized by the artificial intelligence model to obtain a predicted session identifier.

[0018] Furthermore, obtaining a loss value between the predicted session identifier and the actual session identifier, and training the artificial intelligence model using the loss value, includes:

[0019] Obtaining a loss value between the predicted session identifier and the actual session identifier through a preset loss function, wherein the loss function includes one of a cross entropy loss function and an absolute loss function, or a combination thereof;

[0020] The artificial intelligence model is trained using the loss value.

[0021] Furthermore, when the loss value satisfies a preset condition, stopping training the artificial intelligence model and obtaining the trained artificial intelligence model includes:

[0022] When the loss value is less than a preset value, obtaining a stop instruction;

[0023] Execute the stop instruction to stop training the artificial intelligence model and save the trained artificial intelligence model.

[0024] Furthermore, the acquiring of the current QR code image, correcting the current QR code image to obtain the corrected current QR code image, and recognizing the corrected current QR code image by the trained artificial intelligence model to obtain the current session identifier includes:

[0025] Acquire a current QR code image, correct the current QR code image to obtain a corrected current QR code image, input the corrected current QR code image into a preset image enhancement network, and process the corrected current QR code image through the image enhancement network to obtain an enhanced current QR code image;

[0026] The enhanced current two-dimensional code image is input into the trained artificial intelligence model, and the enhanced current two-dimensional code image is recognized by the trained artificial intelligence model to obtain a current session identifier.

[0027] Furthermore, after acquiring the current QR code image, correcting the current QR code image to obtain the corrected current QR code image, and recognizing the corrected current QR code image using the trained artificial intelligence model to obtain the current session identifier, the artificial intelligence-based QR code image recognition method includes:

[0028] Obtain the consultation content and sensitive information corresponding to the current session identifier, and display the consultation content and sensitive information on the session interface.

[0029] In a second aspect, a two-dimensional code image recognition device based on artificial intelligence is provided, comprising:

[0030] A first acquisition module is configured to acquire a preset QR code image and an actual session identifier corresponding to the preset QR code image;

[0031] A processing module, configured to correct the preset two-dimensional code image to obtain a corrected preset two-dimensional code image;

[0032] a determination module, configured to determine a predicted session identifier based on a preset artificial intelligence model and the corrected preset QR code image;

[0033] A second acquisition module is configured to acquire a loss value between the predicted session identifier and the actual session identifier, and train the artificial intelligence model using the loss value;

[0034] A third acquisition module is configured to stop training the artificial intelligence model and acquire the trained artificial intelligence model when the loss value meets a preset condition;

[0035] The recognition module is used to obtain the current QR code image, correct the current QR code image to obtain the corrected current QR code image, and recognize the corrected current QR code image through the trained artificial intelligence model to obtain the current session identifier.

[0036] In a third aspect, a computer device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the above-mentioned artificial intelligence-based QR code image recognition method are implemented.

[0037] In a fourth aspect, a computer-readable storage medium is provided, which stores a computer program. When the computer program is executed by a processor, the steps of the above-mentioned artificial intelligence-based two-dimensional code image recognition method are implemented.

[0038] The present application provides a two-dimensional code image recognition method, apparatus, computer equipment and storage medium based on artificial intelligence, which obtains a preset two-dimensional code image and obtains an actual session identifier corresponding to the preset two-dimensional code image; corrects the preset two-dimensional code image to obtain the corrected preset two-dimensional code image; determines a predicted session identifier based on a preset artificial intelligence model and the corrected preset two-dimensional code image; obtains a loss value between the predicted session identifier and the actual session identifier, and trains the artificial intelligence model with the loss value; stops training the artificial intelligence model when the loss value meets a preset condition, and obtains the trained artificial intelligence model; obtains a current two-dimensional code image, corrects the current two-dimensional code image to obtain the corrected current two-dimensional code image, and uses the trained artificial intelligence model to identify the session identifier. The artificial intelligence model recognizes the corrected current QR code image to obtain the current session identifier. The beneficial effects are in two aspects. On the one hand, the current QR code image is obtained, and the current QR code image is corrected to obtain the corrected current QR code image. The trained artificial intelligence model recognizes the corrected current QR code image to obtain the current session identifier. Since the correction of the current QR code image will not cause the positioning mark of the current QR code image to be deformed or offset, there is no need to rescan the current QR code image, which reduces the recognition time of the current QR code image and is beneficial to improving the recognition rate of the current QR code image. On the other hand, the trained artificial intelligence model will not be interfered by subjective factors, and is beneficial to improving the reliability of the current QR code image recognition. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments of the present invention. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0040] Figure 1 1 is a schematic diagram of an application environment of a two-dimensional code image recognition method based on artificial intelligence in one embodiment of the present invention;

[0041] Figure 2 A schematic flow chart of a two-dimensional code image recognition method based on artificial intelligence provided by one embodiment of the present invention;

[0042] Figure 3 yes Figure 2 A schematic flow chart of a specific implementation of step S23;

[0043] Figure 4 yes Figure 2 A schematic flow chart of a specific implementation of step S25;

[0044] Figure 5 yes Figure 2 A schematic flow chart of a specific implementation of step S26;

[0045] Figure 6 1 is a schematic structural diagram of a two-dimensional code image recognition device based on artificial intelligence in one embodiment of the present invention;

[0046] Figure 7 is a structural diagram of a computer device in one embodiment of the present invention;

[0047] Figure 8 FIG. 2 is another structural diagram of a computer device according to an embodiment of the present invention. DETAILED DESCRIPTION

[0048] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of them. All other embodiments obtained by ordinary technicians in this field based on the embodiments of the present invention without making any creative efforts shall fall within the scope of protection of the present invention.

[0049] See also Figure 1 , Figure 1 Schematic diagram of an application environment of a two-dimensional code image recognition method based on artificial intelligence in an embodiment of the present invention. The two-dimensional code image recognition method based on artificial intelligence provided by the embodiment of the present invention can be applied in the following situations: Figure 1 In an application environment, a client communicates with a server through a network.

[0050] The server obtains a preset QR code image through the client, and obtains an actual session identifier corresponding to the preset QR code image;

[0051] Correcting the preset two-dimensional code image to obtain a corrected preset two-dimensional code image;

[0052] Determining a predicted session identifier based on a preset artificial intelligence model and the corrected preset QR code image;

[0053] Obtaining a loss value between the predicted session identifier and the actual session identifier, and training the artificial intelligence model using the loss value;

[0054] When the loss value meets a preset condition, stop training the artificial intelligence model and obtain the trained artificial intelligence model;

[0055] Acquire a current QR code image, correct the current QR code image to obtain the corrected current QR code image, and recognize the corrected current QR code image through the trained artificial intelligence model to obtain a current session identifier.

[0056] In the solution implemented by the above-mentioned artificial intelligence-based two-dimensional code image recognition method, device, equipment and medium, the beneficial effects are in two aspects. On the one hand, the current two-dimensional code image is obtained, the current two-dimensional code image is corrected to obtain the corrected current two-dimensional code image, and the corrected current two-dimensional code image is recognized by the trained artificial intelligence model to obtain the current session identifier. Since the correction of the current two-dimensional code image will not cause the positioning mark of the current two-dimensional code image to be deformed or offset, there is no need to rescan the current two-dimensional code image, which reduces the recognition time of the current two-dimensional code image and is therefore conducive to improving the recognition rate of the current two-dimensional code image. On the other hand, the trained artificial intelligence model will not be interfered with by subjective factors, and is therefore conducive to improving the reliability of the current two-dimensional code image recognition.

[0057] The device running the client is referred to as a client device.

[0058] The device running the server is referred to as the server device.

[0059] The client devices may include but are not limited to various personal computers, laptops, smartphones, tablet computers, and portable wearable devices.

[0060] The server device can be implemented as an independent server or a server cluster composed of multiple servers. The present invention will be described in detail below through specific embodiments.

[0061] See also Figure 2 , Figure 2 A flowchart of a two-dimensional code image recognition method based on artificial intelligence provided by one embodiment of the present invention includes the following steps:

[0062] S21, obtaining a preset QR code image, and obtaining an actual session identifier corresponding to the preset QR code image;

[0063] The preset QR code image is a preset QR code image. The QR code image is a two-dimensional matrix graphic composed of black and white modules, which stores information according to specific coding rules.

[0064] The actual session identifier is the actual session identifier.

[0065] S22, correcting the preset two-dimensional code image to obtain a corrected preset two-dimensional code image;

[0066] The correcting the preset two-dimensional code image to obtain the corrected preset two-dimensional code image includes:

[0067] Get the configuration file and obtain the specified correction algorithm from the configuration file;

[0068] The preset two-dimensional code image is corrected by using a specified correction algorithm to obtain the corrected preset two-dimensional code image.

[0069] Exemplarily, obtaining a configuration file and obtaining a specified correction algorithm from the configuration file includes:

[0070] Get the configuration file, obtain the score of each correction algorithm from the configuration file, and use the correction algorithm with the highest score as the designated correction algorithm.

[0071] Among them, the correction algorithm is a computational method used to correct data deviation or geometric deformation. Its core goal is to restore the original state or ideal structure of the data through mathematical modeling and optimization technology.

[0072] S23, determining a predicted session identifier based on a preset artificial intelligence model and the corrected preset QR code image;

[0073] The predicted session identifier is a predicted session identifier.

[0074] S24, obtaining a loss value between the predicted session identifier and the actual session identifier, and training the artificial intelligence model using the loss value;

[0075] The obtaining of the loss value between the predicted session identifier and the actual session identifier, and training the artificial intelligence model using the loss value, includes:

[0076] Obtaining a loss value between the predicted session identifier and the actual session identifier through a preset loss function, wherein the loss function includes one of a cross entropy loss function and an absolute loss function, or a combination thereof;

[0077] Among them, the larger the loss value between the predicted session identifier and the actual session identifier, the greater the difference between the predicted session identifier and the actual session identifier, and the smaller the loss value between the predicted session identifier and the actual session identifier, the smaller the difference between the predicted session identifier and the actual session identifier. The loss value makes the performance of the artificial intelligence model comparable, which is convenient for monitoring the training status of the artificial intelligence model.

[0078] S25, when the loss value meets a preset condition, stop training the artificial intelligence model and obtain the trained artificial intelligence model;

[0079] Among them, when the loss value meets the preset conditions, the training of the artificial intelligence model is stopped, which can save the training time of the artificial intelligence model.

[0080] S26, obtain the current QR code image, correct the current QR code image to obtain the corrected current QR code image, identify the corrected current QR code image through the trained artificial intelligence model, and obtain the current session identifier.

[0081] Among them, the current two-dimensional code image is the current two-dimensional code image.

[0082] The actual session identifier is the actual session identifier.

[0083] Wherein, after acquiring the current QR code image, correcting the current QR code image to obtain the corrected current QR code image, recognizing the corrected current QR code image by the trained artificial intelligence model to obtain the current session identifier, the artificial intelligence-based QR code image recognition method includes:

[0084] Obtain the consultation content and sensitive information corresponding to the current session identifier, and display the consultation content and sensitive information on the session interface.

[0085] For ease of explanation, let's take the consulting content in the financial industry as an example.

[0086] Customer: I travel frequently on business. Which credit card is more suitable for me?

[0087] The salesperson responded: Airline co-branded cards allow you to earn miles through spending, which can be redeemed for free tickets and upgrades, making them suitable for frequent flyers. Hotel co-branded cards allow you to earn hotel points through spending, which can be redeemed for free accommodations and room upgrades, making them suitable for business travelers.

[0088] For ease of explanation, let’s take consulting content in the technology industry as an example.

[0089] Customer: I want to upgrade my company computer. Should I choose a desktop or a laptop?

[0090] Desktop computer: suitable for fixed office use, cost-effective and highly scalable.

[0091] Notebook: Suitable for mobile office, lightweight.

[0092] For ease of explanation, let’s take the insurance industry as an example:

[0093] Customer: What are mild and moderate illnesses in critical illness insurance? What is the compensation amount?

[0094] Salesperson responded:

[0095] Mild illness: Early-stage illness, 20%-30% of the insured amount will be paid;

[0096] Moderate illness: between mild and severe illness, with compensation of 50%-60% of the insured amount.

[0097] Among them, the customer triggers the system to generate the current session identifier by scanning the current QR code image and binds it with the salesperson. The trained artificial intelligence model ensures that the customer can accurately view the current QR code image in various environments, and quickly establish a session interface to display consultation content and sensitive information on the session interface.

[0098] Exemplarily, obtaining the consultation content and sensitive information corresponding to the current session identifier and displaying the consultation content and sensitive information on the session interface includes:

[0099] Obtain the consultation content and sensitive information corresponding to the current session identifier, process the sensitive information using the Laplace mechanism to obtain the processed sensitive information, and display the consultation content and the processed sensitive information on the session interface.

[0100] Exemplarily, after obtaining the consultation content and sensitive information corresponding to the current session identifier and displaying the consultation content and sensitive information on the session interface, the QR code image recognition method includes:

[0101] The consultation content is encrypted using an encryption algorithm to obtain the encrypted consultation content, and the encrypted consultation content is saved.

[0102] In an embodiment of the present invention, the beneficial effects are in two aspects. On the one hand, the current QR code image is acquired, the current QR code image is corrected to obtain the corrected current QR code image, and the corrected current QR code image is recognized by the trained artificial intelligence model to obtain the current session identifier. Since the correction of the current QR code image will not cause the positioning mark of the current QR code image to be deformed or offset, there is no need to rescan the current QR code image, which reduces the recognition time of the current QR code image and is conducive to improving the recognition rate of the current QR code image. On the other hand, the trained artificial intelligence model will not be interfered with by subjective factors and is conducive to improving the reliability of the current QR code image recognition.

[0103] See also Figure 3 , Figure 3 yes Figure 2 A specific implementation flow diagram of step S23 is described in detail as follows:

[0104] S31, inputting the corrected preset QR code image into a preset image enhancement network, and processing the corrected preset QR code image through the image enhancement network to obtain an enhanced preset QR code image;

[0105] S32: Input the enhanced preset QR code image into the artificial intelligence model, and use the artificial intelligence model to identify the enhanced preset QR code image to obtain a predicted session identifier.

[0106] In an embodiment of the present invention, the enhanced preset QR code image is input into the artificial intelligence model, and the artificial intelligence model can more efficiently learn effective features during the training stage and reduce attention to irrelevant or interfering features, thereby shortening the training time and reducing computing resource consumption.

[0107] See also Figure 4 , Figure 4 yes Figure 2 A specific implementation flow diagram of step S25 is described in detail as follows:

[0108] S41, when the loss value is less than a preset value, obtaining a stop instruction;

[0109] S42, execute the stop instruction, stop training the artificial intelligence model, and save the trained artificial intelligence model.

[0110] In an embodiment of the present invention, the trained artificial intelligence model is saved to avoid retraining each time it is used, thereby saving computing resources.

[0111] See also Figure 5 , Figure 5 yes Figure 2 A specific implementation flow diagram of step S26 is described in detail as follows:

[0112] S51, obtaining a current QR code image, correcting the current QR code image to obtain a corrected current QR code image, inputting the corrected current QR code image into a preset image enhancement network, and processing the corrected current QR code image through the image enhancement network to obtain an enhanced current QR code image;

[0113] Among them, the enhanced current two-dimensional code image will have improved contrast and brightness. Improving the contrast will enhance the distinction between the target and the background in the corrected current two-dimensional code image, and improving the brightness can avoid the loss of details in the corrected current two-dimensional code image due to insufficient exposure.

[0114] S52: Input the enhanced current two-dimensional code image into the trained artificial intelligence model, and use the trained artificial intelligence model to recognize the enhanced current two-dimensional code image to obtain a current session identifier.

[0115] In an embodiment of the present invention, the enhanced current QR code image is recognized by the trained artificial intelligence model to obtain the current session identifier. Since the correction of the current QR code image will not cause the positioning mark of the current QR code image to be deformed or offset, there is no need to rescan the current QR code image, which reduces the recognition time of the current QR code image and is therefore conducive to improving the recognition rate of the current QR code image.

[0116] See also Figure 6 , Figure 6 FIG. 1 is a schematic diagram of a structure of a two-dimensional code image recognition device based on artificial intelligence in one embodiment of the present invention. Figure 6 As shown, the artificial intelligence-based two-dimensional code image recognition device includes a first acquisition module 101, a processing module 102, a determination module 103, a second acquisition module 104, a third acquisition module 105, and a recognition module 106. The functional modules are described in detail as follows:

[0117] The first acquisition module 101 is used to acquire a preset QR code image and obtain an actual session identifier corresponding to the preset QR code image;

[0118] The processing module 102 is configured to correct the preset two-dimensional code image to obtain the corrected preset two-dimensional code image;

[0119] A determination module 103 is configured to determine a predicted session identifier based on a preset artificial intelligence model and the corrected preset QR code image;

[0120] A second acquisition module 104 is configured to acquire a loss value between the predicted session identifier and the actual session identifier, and train the artificial intelligence model using the loss value;

[0121] A third acquisition module 105 is configured to stop training the artificial intelligence model and acquire the trained artificial intelligence model when the loss value meets a preset condition;

[0122] The recognition module 106 is used to obtain the current QR code image, correct the current QR code image to obtain the corrected current QR code image, and recognize the corrected current QR code image through the trained artificial intelligence model to obtain the current session identifier.

[0123] In one embodiment, the processing module 102 includes:

[0124] The first acquisition subunit is used to acquire a configuration file and obtain a specified correction algorithm from the configuration file;

[0125] The adopting subunit is used to adopt a specified correction algorithm to correct the preset two-dimensional code image to obtain the corrected preset two-dimensional code image.

[0126] In one embodiment, the determining module 103 includes:

[0127] A first input subunit is configured to input the corrected preset QR code image into a preset image enhancement network, and process the corrected preset QR code image through the image enhancement network to obtain an enhanced preset QR code image;

[0128] The second input subunit is used to input the enhanced preset QR code image into the artificial intelligence model, and recognize the enhanced preset QR code image through the artificial intelligence model to obtain a predicted session identifier.

[0129] In one embodiment, the second acquisition module 104 includes:

[0130] a second acquiring subunit, configured to acquire a loss value between the predicted session identifier and the actual session identifier by using a preset loss function, wherein the loss function includes a cross entropy loss function, an absolute loss function, or a combination thereof;

[0131] A training subunit is used to train the artificial intelligence model through the loss value.

[0132] In one embodiment, the third acquisition module 105 includes:

[0133] a third acquiring unit, configured to acquire a stop instruction when the loss value is less than a preset value;

[0134] The saving subunit is used to execute the stop instruction, stop training the artificial intelligence model, and save the trained artificial intelligence model.

[0135] In one embodiment, the identification module 106 includes:

[0136] a processing subunit, configured to obtain a current QR code image, correct the current QR code image to obtain a corrected current QR code image, input the corrected current QR code image into a preset image enhancement network, and process the corrected current QR code image through the image enhancement network to obtain an enhanced current QR code image;

[0137] The recognition subunit is used to input the enhanced current two-dimensional code image into the trained artificial intelligence model, and recognize the enhanced current two-dimensional code image through the trained artificial intelligence model to obtain the current session identifier.

[0138] In one embodiment, the artificial intelligence-based QR code image recognition device further includes:

[0139] The display module is used to obtain the consultation content and sensitive information corresponding to the current session identifier and display the consultation content and sensitive information on the session interface.

[0140] In an embodiment of the present invention, the beneficial effects are in two aspects. On the one hand, the current QR code image is acquired, the current QR code image is corrected to obtain the corrected current QR code image, and the corrected current QR code image is recognized by the trained artificial intelligence model to obtain the current session identifier. Since the correction of the current QR code image will not cause the positioning mark of the current QR code image to be deformed or offset, there is no need to rescan the current QR code image, which reduces the recognition time of the current QR code image and is conducive to improving the recognition rate of the current QR code image. On the other hand, the trained artificial intelligence model will not be interfered with by subjective factors and is conducive to improving the reliability of the current QR code image recognition.

[0141] For the specific limitations of the artificial intelligence-based two-dimensional code image recognition device, please refer to the limitations of the artificial intelligence-based two-dimensional code image recognition method above, which will not be repeated here.

[0142] Each module in the aforementioned AI-based QR code image recognition device can be implemented in whole or in part through software, hardware, or a combination thereof. Each module can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in the computer device in the form of software, so that the processor can call and execute the corresponding operations of each module.

[0143] See also Figure 7 , Figure 7 This is a schematic diagram of a computer device in one embodiment of the present invention. In one embodiment, a computer device is provided. The computer device may be a server device, and its internal structure diagram may be as shown in FIG. Figure 7 The computer device includes a processor, a memory, a network interface and a database connected via a system bus.

[0144] The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes non-volatile and / or volatile storage media and internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of the operating system and computer program in the non-volatile storage medium. When executed by the processor, the computer program can implement the functions or steps of an artificial intelligence-based QR code image recognition method on the server device.

[0145] See also Figure 8 , Figure 8 This is another structural diagram of a computer device in one embodiment of the present invention. In one embodiment, a computer device is provided. The computer device may be a client device, and its internal structure diagram may be as shown in FIG. Figure 8 As shown. The computer device includes a processor, memory, network interface, display screen, and input device connected via a system bus. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and computer program in the non-volatile storage medium. When the computer program is executed by the processor, the functions or steps of a QR code image recognition method based on artificial intelligence can be implemented on the client device.

[0146] In one embodiment, a computer device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor.

[0147] It should be noted that the above functions or steps that can be implemented by the computer-readable storage medium or computer device can refer to the relevant description in the aforementioned method embodiment. To avoid repetition, they will not be described one by one here.

[0148] The above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a graphics processing unit (GPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.

[0149] The above description and accompanying drawings sufficiently illustrate the embodiments of the present disclosure to enable those skilled in the art to practice them. Other embodiments may include structural, logical, electrical, process and other changes. The embodiments represent only possible variations. Unless explicitly required, individual components and functions are optional, and the order of operations may vary. Portions and subsamples of some embodiments may be included in or replaced with portions and subsamples of other embodiments. Moreover, the terms used in this application are only used to describe the embodiments and are not used to limit the claims.

[0150] In this document, each embodiment may focus on the differences from other embodiments, and similar parts between the embodiments can be referenced. For methods, products, etc. disclosed in the embodiments, if they correspond to the method section disclosed in the embodiments, then the relevant parts can be referenced to the description of the method section.

[0151] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software may depend on the specific application and design constraints of the technical solution. Technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the embodiments of the present disclosure. Technicians can clearly understand that for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0152] In the embodiments disclosed herein, the disclosed methods and products (including but not limited to devices, equipment, etc.) can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of units can be merely a logical functional division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some sub-samples can be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms. The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the units can be selected according to actual needs to implement this embodiment. In addition, the functional units in the embodiments of the present disclosure can be integrated into a processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.

[0153] The flowcharts and block diagrams in the accompanying drawings show the possible implementation architectures, functions and operations of the systems, methods and computer program products according to the embodiments of the present disclosure. In this regard, each box in the flowchart or block diagram can represent a module, program segment or part of the code, and the module, program segment or part of the code contains one or more executable instructions for implementing the specified logical functions. In some alternative implementations, the functions marked in the box can also occur in an order different from that marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, or they can sometimes be executed in the opposite order, which can depend on the functions involved. In the descriptions corresponding to the flowcharts and block diagrams in the accompanying drawings, the operations or steps corresponding to different boxes can also occur in an order different from that disclosed in the description, and sometimes there is no specific order between different operations or steps. For example, two consecutive operations or steps can actually be executed substantially in parallel, or they can sometimes be executed in the opposite order, which can depend on the functions involved. Each block in the block diagrams and / or flow charts, and combinations of blocks in the block diagrams and / or flow charts, may be implemented using a dedicated hardware-based system that performs the specified functions or actions, or may be implemented using a combination of dedicated hardware and computer instructions. In addition, any software tools or components not developed by our company that appear in the embodiments of this application are for illustrative purposes only and do not represent actual use.

Claims

1. A two-dimensional code image recognition method based on artificial intelligence, characterized in that: include: Obtain a preset QR code image, and obtain an actual session identifier corresponding to the preset QR code image; Correcting the preset two-dimensional code image to obtain a corrected preset two-dimensional code image; Determining a predicted session identifier based on a preset artificial intelligence model and the corrected preset QR code image; Obtaining a loss value between the predicted session identifier and the actual session identifier, and training the artificial intelligence model using the loss value; When the loss value meets a preset condition, stop training the artificial intelligence model and obtain the trained artificial intelligence model; Acquire a current QR code image, correct the current QR code image to obtain the corrected current QR code image, and recognize the corrected current QR code image through the trained artificial intelligence model to obtain a current session identifier.

2. The method for two-dimensional code image recognition based on artificial intelligence according to claim 1, characterized in that: Correcting the preset two-dimensional code image to obtain the corrected preset two-dimensional code image includes: Get the configuration file and obtain the specified correction algorithm from the configuration file; The preset two-dimensional code image is corrected by using a specified correction algorithm to obtain the corrected preset two-dimensional code image.

3. The method for two-dimensional code image recognition based on artificial intelligence according to claim 1, characterized in that: The step of determining a predicted session identifier based on a preset artificial intelligence model and the corrected preset QR code image includes: Inputting the corrected preset QR code image into a preset image enhancement network, and processing the corrected preset QR code image through the image enhancement network to obtain an enhanced preset QR code image; The enhanced preset QR code image is input into the artificial intelligence model, and the enhanced preset QR code image is recognized by the artificial intelligence model to obtain a predicted session identifier.

4. The method for two-dimensional code image recognition based on artificial intelligence according to claim 1, characterized in that: The obtaining of a loss value between the predicted session identifier and the actual session identifier, and training the artificial intelligence model using the loss value, includes: Obtaining a loss value between the predicted session identifier and the actual session identifier through a preset loss function, wherein the loss function includes one of a cross entropy loss function and an absolute loss function, or a combination thereof; The artificial intelligence model is trained using the loss value.

5. The method for two-dimensional code image recognition based on artificial intelligence according to claim 1, characterized in that: When the loss value satisfies a preset condition, stopping training the artificial intelligence model and obtaining the trained artificial intelligence model comprises: When the loss value is less than a preset value, obtaining a stop instruction; Execute the stop instruction to stop training the artificial intelligence model and save the trained artificial intelligence model.

6. The method for two-dimensional code image recognition based on artificial intelligence according to claim 1, characterized in that: The acquiring of the current QR code image, correcting the current QR code image to obtain the corrected current QR code image, and recognizing the corrected current QR code image by the trained artificial intelligence model to obtain the current session identifier includes: Acquire a current QR code image, correct the current QR code image to obtain a corrected current QR code image, input the corrected current QR code image into a preset image enhancement network, and process the corrected current QR code image through the image enhancement network to obtain an enhanced current QR code image; The enhanced current two-dimensional code image is input into the trained artificial intelligence model, and the enhanced current two-dimensional code image is recognized by the trained artificial intelligence model to obtain a current session identifier.

7. The method for two-dimensional code image recognition based on artificial intelligence according to any one of claims 1 to 6, characterized in that: After acquiring the current QR code image, correcting the current QR code image to obtain the corrected current QR code image, and recognizing the corrected current QR code image using the trained artificial intelligence model to obtain the current session identifier, the artificial intelligence-based QR code image recognition method includes: Obtain the consultation content and sensitive information corresponding to the current session identifier, and display the consultation content and sensitive information on the session interface.

8. A two-dimensional code image recognition device based on artificial intelligence, characterized in that: include: A first acquisition module is configured to acquire a preset QR code image and an actual session identifier corresponding to the preset QR code image; A processing module, configured to correct the preset two-dimensional code image to obtain a corrected preset two-dimensional code image; a determination module, configured to determine a predicted session identifier based on a preset artificial intelligence model and the corrected preset QR code image; A second acquisition module is configured to acquire a loss value between the predicted session identifier and the actual session identifier, and train the artificial intelligence model using the loss value; A third acquisition module is configured to stop training the artificial intelligence model and acquire the trained artificial intelligence model when the loss value meets a preset condition; The recognition module is used to obtain the current QR code image, correct the current QR code image to obtain the corrected current QR code image, and recognize the corrected current QR code image through the trained artificial intelligence model to obtain the current session identifier.

9. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the computer program, the steps of the artificial intelligence-based two-dimensional code image recognition method as described in any one of claims 1 to 7 are implemented.

10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the steps of the artificial intelligence-based two-dimensional code image recognition method as claimed in any one of claims 1 to 7 are implemented.