Address identification detection method and device, and storage medium

By using the trained BERT neural network model to calculate the feature similarity of address text, the problem of cumbersome and inaccurate address information processing in the prior art is solved, and automated address matching recognition is realized, which improves accuracy and reduces costs.

CN119886104APending Publication Date: 2025-04-25E SURFING IOT CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411972035.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-30
Publication Date
2025-04-25

AI Technical Summary

Technical Problem

The existing technology has problems such as cumbersome interaction processes, inconsistent formats, and deviations from map software positioning when collecting and processing address information. Especially when large-scale IoT devices are installed, the cost of manually entering addresses is high.

Method used

The trained BERT neural network model is used to calculate the characteristic similarity of N address texts, and the two most similar address texts are identified through comparison, so that address matching recognition is automatically performed.

Benefits of technology

It realizes automatic address text similarity recognition, reduces user operation steps, reduces user usage costs, improves the accuracy of address matching recognition, and reduces application maintenance costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119886104A_ABST
    Figure CN119886104A_ABST
Patent Text Reader

Abstract

The invention discloses an address identification detection method, which comprises the following steps of: S1, acquiring address data expressed by different texts as a data set, and dividing the data set into training data, inspection data and test data; s2, establishing a BERT neural network model based on pre-training, inputting training data into a neural network for training in the BERT neural network model, adjusting confusion matrix values according to expression differences of address texts in the training process, and substituting the confusion matrix values into the training process of the neural network model in combination with a preset model evaluation rule to obtain a final neural network model; s3, calculating a performance index, evaluating the availability of the model, and if the requirement is met, storing the model; and S4, using the model to calculate feature similarity of a plurality of address texts, comparing the feature similarity, and identifying and obtaining the address text most similar to the specified address text. According to the method, the similarity identification of the address text can be automatically carried out, the matching accuracy is improved, and the use cost of a user is also reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of information processing technology, and in particular to an address recognition detection method, device and storage medium. Background Art

[0002] Address information plays a vital role in many industries and applications including e-commerce, Internet of Things, smart cities, etc. Its application is not limited to positioning and service provision, but also involves optimizing operations, improving efficiency, enhancing user experience, and supporting decision-making. However, when most applications actually collect and process address information, there are problems such as cumbersome interaction processes, inconsistent formats, and deviations from map software positioning.

[0003] For example, when the existing Internet of Things platform is actually applied, with the introduction of application policies including green energy conservation, carbon metering, and smart fire protection, the number of users and the number of device installations of the existing Internet of Things platform have increased sharply. At this time, the traditional overall method of manually inputting and confirming the equipment installation address has the problems of cumbersome process and high cost. For example, in the application of green dual-carbon fire guards, large-scale Internet of Things device installation operations are often involved. During large-scale installation, users are required to enter the detailed address of each device in the fire guard application, and then select the correct address from the multiple standard addresses that pop up, which is costly for users.

[0004] To this end, the present application proposes an address recognition detection method to solve the above technical problems. Summary of the invention

[0005] The main purpose of the present invention is to provide an address recognition detection method, which uses a trained artificial neural network model to calculate the feature similarity of N address texts, and then compares them to identify the two most similar address texts to solve the technical problems raised in the background technology.

[0006] The present invention adopts the following technical solutions to solve the above technical problems:

[0007] An address recognition detection method comprises the following steps:

[0008] S1. Collect N address data expressed in different texts as a data set, and divide the data set into training data, verification data and test data, wherein the data set contains different texts expressing different addresses;

[0009] S2. Establish a BERT neural network model based on pre-training, input the training data into the neural network for training in the BERT neural network model, adjust the confusion matrix value according to the difference in the expression of the address text during the training process, set the model evaluation rules, and combine the training process of the neural network model to obtain the final neural network model;

[0010] S3. Specify accuracy, precision, recall and F1 score as performance indicators, evaluate the availability of the final neural network model by calculating the performance indicators, and if the availability meets the specified requirements, save the final neural network model and use the model in the specified application;

[0011] S4. Use the model to calculate the feature similarity of the specified address text and other multiple address texts and compare them to identify and obtain the address text that is most similar to the specified address text.

[0012] Preferably, the BERT neural network model in step S2 is sequentially provided with a fully connected layer one, a RELU layer, a fully connected layer two with an output length of 4096, and a fully connected layer three with an output length of N and a sparse softmax cross entropy loss function after the pooled output layer, which is used for gradient descent during model training.

[0013] Preferably, the training process of step S2 further comprises selecting multiple groups of address texts to input into the BERT neural network model and calculating the cosine similarity after normalizing the output of the fully connected layer 2, specifically comprising:

[0014] A threshold value S is preset, and the cosine similarity of any two different text outputs of the same address is calculated after normalization and recorded as d1, and the cosine similarity of any two text outputs of different addresses is calculated after normalization and recorded as d2;

[0015] If d1 ≥ the specified threshold S, TP increases by one, otherwise FN increases by one;

[0016] If d2 ≥ the specified threshold S, FP increases by one, otherwise TN increases by one;

[0017] TP means that the actual example is positive and the prediction is also positive; FP means that the actual example is negative and the prediction is positive; TN means that the actual example is negative and the prediction is also negative; FN means that the actual example is positive and the prediction is negative.

[0018] Performance indicators including accuracy, precision, recall and F1 score are calculated through TP, FP, TN and FN.

[0019] Preferably, during the model training process in step S2, a threshold k and a threshold T are preset, and the training stops when the output average of the loss function is less than the specified threshold k or the number of training times reaches the specified threshold T.

[0020] Preferably, after the training in step S2 is completed, a model evaluation rule is preset according to the F1 score recorded during the process, and a version model whose F1 score meets the requirements of the model evaluation rule is selected as the final model.

[0021] Preferably, in the training process of step S2, typos, address connection symbols, dashes, underscores, and brackets are randomly added to the address text.

[0022] On the other hand, the present invention further discloses a computer-readable storage medium storing a computer program, wherein when the computer program is executed by a processor, the processor executes the steps of the above method.

[0023] On the other hand, the present invention further discloses a computer device, including a memory and a processor, wherein the memory stores a computer program, and when the computer program is executed by the processor, the processor executes the steps of the above method.

[0024] It can be seen from the above technical solution that the present invention provides an address recognition detection method. Compared with the prior art, the present invention has the following advantages:

[0025] 1. The present invention can automatically identify the similarity of address texts, so that after the user enters the address, there is no need to reconfirm the matching result, which reduces the user's operation steps, improves the user experience, and can significantly reduce the user's usage cost.

[0026] 2. The present invention adopts a BERT-based classification neural network to train the recognition ability of address text, and performs matching and recognition through the cosine similarity of feature vectors, which can improve the accuracy of address text matching and recognition, thereby reducing the need for manual intervention due to misjudgment and reducing the maintenance cost of the application.

[0027] 3. The present invention can take into account each word in the address text and its context information, which facilitates a better understanding of the overall meaning of the text. Therefore, for complex address texts, it can match more accurately and avoid the misjudgment problem that is easy to occur based on string matching methods.

[0028] 4. The present invention uses the confusion matrix to calculate the performance index and adjusts it in conjunction with the cosine similarity threshold, which not only improves the accuracy of address matching, but also optimizes the performance evaluation of the model and reduces the misjudgment rate.

[0029] 5. By adding noise data during the training process, the present invention enables the model to maintain a high recognition accuracy when facing various variations and noises in actual application scenarios, thereby enhancing the generalization ability of the model in the data processing process.

[0030] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present invention, nor is it intended to limit the scope of the present invention. Other features of the present invention will become easy to understand through the following description. Of course, it is not necessary to achieve all of the advantages described above simultaneously for any product implementing the present invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0031] The drawings constituting a part of the present application are used to provide a further understanding of the present invention. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:

[0032] Figure 1 Schematic diagram of the BERT neural network structure of the present invention;

[0033] Figure 2 It is a schematic diagram of the overall method flow of the present invention;

[0034] Figure 3 A schematic diagram of the model evaluation process in the neural network model training process of the present invention;

[0035] Figure 4 The figure is a schematic diagram of address text input in an embodiment of the present invention. DETAILED DESCRIPTION

[0036] The technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all of the embodiments. In the absence of conflict, the embodiments in this application and the features in the embodiments can be combined with each other. Based on the embodiments in the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.

[0037] In the embodiment, see Figures 1 to 4 .

[0038] In the mainstream applications of the prior art, in order to achieve address text matching, common solutions include: (1) address standardization; (2) word segmentation and then rule-based similarity calculation; (3) reliance on address segmentation and common substring matching; (4) string matching algorithm; However, the above common solutions have the problem of low accuracy in actual use, and are also difficult to process complex address texts.

[0039] Therefore, an embodiment of the present invention proposes an address recognition and detection method based on text vector similarity, which can be used in green dual carbon, smart fire protection, logistics, e-commerce and other fields. The method uses a trained artificial neural network model to calculate the feature similarity of N address texts, and then compares them to identify the two most similar address texts.

[0040] Specific as Figure 2 As shown, the implementation scheme of the method is as follows:

[0041] L1. Prepare N address data, N is not less than 50,000, covering multiple regions, and each address has multiple text expressions, such as "A City Daily Center", "A City B District Daily Center", "C Province A City Daily Center", "B District Daily Center" and other different expressions.

[0042] L2. For the above address data, take 70% of the addresses as training data, another 15% of the addresses as verification data, and the last 15% of the addresses as test data.

[0043] L3. Use the pre-trained BERT neural network, where Figure 1 As shown in the figure, a fully connected layer 1, a RELU layer, a fully connected layer 2 with an output length of 4096, a fully connected layer 3 with an output length of N, and a sparse softmax cross entropy loss function are added after the pooling output layer for gradient descent during training.

[0044] At this time, by setting the fully connected layer, RELU layer and sparse softmax cross entropy loss function, the ability of the neural network to extract the address text feature vector can be effectively trained, so that the model can extract richer feature information from the address text and improve the matching accuracy.

[0045] At the same time, by using the sparse softmax cross entropy loss function for training, the parameters of the neural network can be optimized to reach the optimal state, which not only improves the training efficiency of the model, but also enhances the prediction ability of the model.

[0046] L4. Use training data for training, and the input of the neural network is the address text.

[0047] It can be supplemented that, in order to achieve better generalization effect during the training process, typos, address connection symbols, hyphens, underscores, brackets, etc. can be randomly added to the above address text.

[0048] At this time, by adding noise data during the training process, such as randomly adding typos, address connection symbols, etc., the address text data can be enhanced, thereby enhancing the generalization ability of the model in the data processing process, so that the model can still maintain a high recognition accuracy when facing various variations and noises in actual application scenarios.

[0049] L5. During training, verification and testing, Figure 3As shown, multiple groups of texts (a1, a2, b1, c1) are selected to input into the neural network model, where a1 and a2 are two different description texts of the same address, and b1 and c1 are description texts of different addresses. At this time, a threshold S is preset (usually 0.5), and the cosine similarity is calculated after the output of the fully connected layer 2 is normalized. The cosine similarity calculated after the normalization of the output of a1 and a2 is recorded as d1, and the cosine similarity calculated after the normalization of the output of b1 and c1 is recorded as d2.

[0050] If d1 ≥ the specified threshold S, TP increases by one, otherwise FN increases by one;

[0051] If d2 ≥ the specified threshold S, FP increases by one, otherwise TN increases by one;

[0052] Among them, TP indicates the case where the actual example is a positive example and the prediction is also a positive example; FP indicates the case where the actual example is a negative example and the prediction is a positive example; TN indicates the case where the actual example is a negative example and the prediction is also a negative example; FN indicates the case where the actual example is a positive example and the prediction is a negative example, and TP, FP, TN, and FN constitute the confusion matrix.

[0053] At this time, by introducing a large amount of address data expressed in different forms during the neural network training process and conducting classification training, the model can understand the meaning of complex address text, thereby improving the adaptability and accuracy of text recognition.

[0054] In addition, the feature vector of the address text is extracted through a neural network, and the address matching is performed by calculating the cosine similarity between the feature vectors. Not only the local features of the address text but also the global features are considered, so that it can more accurately identify whether two texts represent the same address.

[0055] L6. Calculate the following performance indicators through TP, FP, TN, FN (confusion matrix):

[0056] (1) Accuracy, which refers to the ratio of all correctly predicted samples to the total number of samples: Accuracy = (TP + TN) / (TP + TN + FP + FN)

[0057] (2) Precision, which indicates the proportion of samples that are actually positive among all samples predicted by the model to be positive: Precision = TP / (TP+FP)

[0058] (3) Recall, which indicates the proportion of samples that are actually positive and are correctly identified: Recall = TP / (TP+FN)

[0059] (4) F1 score, used for comprehensive evaluation of the model: F1 = 2*Precision*Recall / (Precision+Recall)

[0060] L7. During the training process, stop when the output average of the loss function is less than the preset threshold k or the number of training times reaches the preset threshold T.

[0061] L8. After training is completed, preset model evaluation rules based on the F1 value recorded during the process. Here, the model evaluation rule is: select the version with the highest F1 as the final model.

[0062] L9. Use the final model for inspection and testing, and use accuracy, precision, recall, and F1 score as indicators to evaluate the usability of the model. If applicable, save the model to the application.

[0063] The above steps use a BERT-based classification neural network to train the recognition ability of address text, and match and identify through the cosine similarity of feature vectors, which can improve the accuracy of address text matching and identification, thereby reducing the need for manual intervention due to misjudgment and reducing the maintenance cost of the application. At the same time, compared with existing string matching methods, this method uses a pre-trained BERT model to consider not only the word itself but also the surrounding words, so that each word in the address text and its contextual information can be taken into account, which facilitates a better understanding of the overall meaning of the text. Therefore, for complex address texts, more accurate matching can be performed, avoiding the misjudgment problem that is easy to occur based on string matching methods.

[0064] At this point, it is necessary to add that in the model building and training steps, this method uses a preset threshold S to evaluate the similarity of the address text during the model training process, and updates the confusion matrix (TP, FP, TN, FN) based on the calculation results, thereby calculating performance indicators including accuracy, precision, recall, and F1 score. Specifically:

[0065] (1) The present invention can effectively distinguish different description texts of the same address and description texts of different addresses by setting a preset threshold S during the training process;

[0066] For different expressions of the same address, if the normalized cosine similarity d1 is greater than or equal to the threshold S, it is considered a correct match (TP plus one), otherwise it is considered a wrong mismatch (FN plus one);

[0067] For the description texts of different addresses, if their normalized cosine similarity d2 is greater than or equal to the threshold S, it is considered a false match (FP plus one), otherwise it is considered a correct mismatch (TN plus one);

[0068] In this way, the model can more accurately identify which addresses are the same and which are different, thereby improving the accuracy of address matching;

[0069] (2) By calculating the values ​​of TP, FP, TN and FN, the present invention can further calculate performance indicators such as accuracy, precision, recall and F1 score. These indicators provide a comprehensive model performance evaluation and help better understand the performance of the model;

[0070] Specifically, accuracy reflects the proportion of correct predictions by the model; precision reflects the proportion of samples predicted by the model as positive examples that are actually positive examples; recall reflects the proportion of samples that are actually positive examples that are correctly predicted by the model as positive examples; F1 score is the harmonic mean of precision and recall, which combines the performance of both.

[0071] Through these performance indicators, the model can be fine-tuned to ensure its optimal performance in practical applications;

[0072] (3) By setting an appropriate threshold S, the occurrence of misjudgment can be effectively reduced;

[0073] For example, when d1 is less than the threshold S, the model will recognize different expressions of the same address as different addresses (FN increases), which can be optimized by adjusting the threshold S; similarly, when d2 is greater than the threshold S, the model will recognize different expressions of different addresses as the same address (FP increases), which also needs to be optimized by adjusting the threshold S;

[0074] By continuously adjusting and optimizing the threshold S, the misjudgment rate can be significantly reduced and the reliability and stability of the model can be improved;

[0075] (4) By calculating TP, FP, TN, and FN and optimizing performance indicators, the generalization ability of the model can be further verified and improved to ensure that it can operate stably in complex and changing actual environments.

[0076] In summary, this method evaluates the similarity of address texts by using a preset threshold S during the model training process, and uses TP, FP, TN and FN to calculate performance indicators. This not only improves the accuracy of address matching, but also optimizes the performance evaluation of the model, reduces the misjudgment rate, and enhances the generalization ability of the model. These improvements ultimately make the overall model more efficient and reliable in practical applications, improve user experience and reduce maintenance costs.

[0077] L10. Specific application methods:

[0078] By deploying a pre-trained model on the application server, the similarity of the address text can be automatically identified. Therefore, after the user enters the address, there is no need to reconfirm the matching result, which reduces the user operation steps, improves the user experience, and can significantly reduce the user's usage costs.

[0079] Moreover, the neural network model used here has been trained and has strong generalization ability and robustness, and can maintain high performance in different scenarios.

[0080] Taking a green dual-carbon firefighting application as an example, the trained neural network model is deployed in the firefighting application;

[0081] When similarity recognition of address text is required, the fire protection application inputs the address text a0 input by the user and several address texts a1, a2, ... to be matched from the standard address library into the model;

[0082] Normalize the output of the fully connected layer 2 to obtain the feature vectors v0, v1, v2, etc. of the address text;

[0083] Calculate the cosine similarity of v1, v2, ... and v0, and select the address text with the largest cosine similarity as the matching result. If its similarity is less than the threshold S (0.5 in this case), output that no matching address is found.

[0084] What can be explained at this point is that in the specific implementation process, taking a certain city's connection to the fire protection application platform as an example, it is necessary to install 3,000 intelligent smoke detection devices and input approximately 2,000 device installation addresses. These detailed addresses are imported into the fire protection application platform at one time through spreadsheet software.

[0085] In addition, it can be added that, in the specific implementation process, the fire protection application platform needs to query and return multiple formatted addresses and their longitudes and latitudes for each device installation address through the map software API, and find the one that best matches the address entered by the user and store it in the fire protection application platform system, where the longitude and latitude information is used to display the location of the device on the large screen.

[0086] According to the previous solution, the user input address obtained by the fire application platform is "A City B District C Area E Road", and the address text is used to query the map software API to obtain three formatted addresses and latitude and longitude (such as Figure 4 As shown), the fire application selects the first one as the matching result by default and stores it in the system of the fire application platform. In fact, the first address is a bus stop, not the user's expected address.

[0087] After using the application method, the trained neural network model is deployed on the server side of the fire protection application platform. The fire protection application platform inputs each input address and the address to be matched into the model. According to the application method, the most matching address is obtained and stored in the system of the fire protection application platform, that is, the fire protection application platform will input "A City B District C Area E Road" and its three addresses to be matched into the trained model.

[0088] The four address texts entered in the above steps are processed by the model:

[0089] 1) Normalize the output of the fully connected layer 2 (normalization means changing the Euclidean length of the vector to 1 while keeping the proportion of each component unchanged) to obtain the feature vectors v0, v1, v2, and v3 of the address text;

[0090] 2) Calculate the cosine similarity of v1, v2, v3 and v0 respectively (for example, the cosine similarity of v0 and v1 vectors is calculated by multiplying each component and summing them up;

[0091] If the components of v0 are d00, d01, ... d09, and the components of v1 are d10, d11, ... d19, then the cosine similarity is d00*d10+d01*d11+...+d09*d19);

[0092] 3) Find the text with the largest cosine similarity to v0 from v1, v2, and v3;

[0093] The calculated cosine similarity of v1 and v0 is 0.71;

[0094] The calculated cosine similarity between v2 and v0 is 0.84;

[0095] The cosine similarity between v3 and v0 is calculated to be 0.434;

[0096] 4) It is found that v2 has the largest cosine similarity with v0, that is, "117.293095, 40.187235, E Road, District B, City A", and the cosine similarity is greater than a certain threshold S (0.5 this time), which means that "117.293095, 40.187235, E Road, District B, City A" is considered to be the best match for the address entered by the user.

[0097] Finally, the fire protection application platform uses the matching result "117.293095,40.187235, Road E, District B, City A" as the actual address entered by the user for subsequent business processing.

[0098] The above method of the present application can reduce the interaction links between users and applications, reduce user usage costs, application development and maintenance costs, while ensuring the accuracy of address matching and identification. At the same time, when the equipment alarms, accurate address information can help users quickly locate hidden dangers and ensure personal and property safety.

[0099] In summary, compared with the prior art, the present invention has significant advantages in address text matching, which not only improves the matching accuracy, but also reduces the user's usage cost and application maintenance cost, and finally realizes efficient address text recognition and matching.

[0100] On the other hand, the present invention further discloses a computer-readable storage medium storing a computer program, wherein when the computer program is executed by a processor, the processor executes the steps of the above method.

[0101] On the other hand, the present invention further discloses a computer device, including a memory and a processor, wherein the memory stores a computer program, and when the computer program is executed by the processor, the processor executes the steps of the above method.

[0102] In another embodiment provided in the present application, a computer program product including instructions is also provided, which, when executed on a computer, enables the computer to execute any of the address identification and detection methods in the above embodiments.

[0103] In addition, an embodiment of the present application further provides an electronic device, including a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other via the communication bus.

[0104] Memory, used to store computer programs;

[0105] The processor is used to implement the above-mentioned address recognition and detection method when executing the program stored in the memory.

[0106] The communication bus mentioned in the above electronic device may be a Peripheral Component Interconnect (PCI) bus or an Extended Industrial Standard Architecture (EISA) bus, etc. The communication bus may be divided into an address bus, a data bus, a control bus, etc.

[0107] The communication interface is used for communication between the above electronic device and other devices.

[0108] The memory may include a random access memory (RAM) or a non-volatile memory (NVM), such as at least one disk memory. Optionally, the memory may also be at least one storage device located away from the aforementioned processor.

[0109] The above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), 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.

[0110] It should also be noted that electronic devices also include terminal devices, which can also be called terminals, user equipment, mobile stations, mobile terminals, etc. Terminal devices can be mobile phones, smart TVs, wearable devices, tablet computers, computers with wireless transceiver functions, virtual reality terminal devices, augmented reality terminal devices, wireless terminals in industrial control, wireless terminals in unmanned driving, wireless terminals in remote surgery, wireless terminals in smart grids, wireless terminals in transportation safety, wireless terminals in smart cities, wireless terminals in smart homes, etc. The embodiments of this application do not limit the specific technology and specific device form used by the terminal devices.

[0111] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from a website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line) or wireless (e.g., infrared, wireless, microwave) mode to another website site, computer, server or data center. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integration. The available medium can be a magnetic medium, (e.g., a floppy disk, a hard disk, a tape), an optical medium, or a semiconductor medium (e.g., a solid-state hard disk), etc.

[0112] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

[0113] In addition, it should be noted that if the embodiments of the present invention involve directional indications (such as up, down, left, right, front, back, etc.), the directional indications are only used to explain the relative position relationship, movement status, etc. between the components in a certain specific posture. If the specific posture changes, the directional indication will also change accordingly.

[0114] In addition, if there are descriptions involving "first", "second", etc. in the embodiments of the present invention, the descriptions of "first", "second", etc. are only used for descriptive purposes and cannot be understood as indicating or implying their relative importance or implicitly indicating the number of technical features indicated. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In addition, the meaning of "and / or" appearing in the full text includes three parallel schemes. Taking "A and / or B" as an example, it includes scheme A, or scheme B, or schemes that A and B meet at the same time. In addition, in the embodiments of the present invention, "multiple" refers to more than two. In addition, the technical solutions between the various embodiments can be combined with each other, but it must be based on the ability of ordinary technicians in the field to implement. When the combination of technical solutions is contradictory or cannot be implemented, it should be considered that such a combination of technical solutions does not exist and is not within the scope of protection required by the present invention.

Claims

1. An address recognition detection method, characterized in that: The following steps are involved: S1. Collect address data expressed in different texts as a data set, and divide the data set into training data, verification data and test data; S2. Establish a BERT neural network model based on pre-training, input the training data into the BERT neural network model for training, set the model evaluation rules according to the expression differences of the address text in the training process and bring them into the training process of the neural network model to obtain the final neural network model; S3. Specify accuracy, precision, recall and F1 score as performance indicators, evaluate the availability of the final neural network model by calculating the performance indicators, and if the availability meets the specified requirements, save the final neural network model and use the model in the specified application; S4. Use the model to calculate the feature similarity of the specified address text and other multiple address texts and compare them to identify and obtain the address text that is most similar to the specified address text.

2. The address recognition detection method according to claim 1, characterized in that: In the S2 step, the BERT neural network model is sequentially provided with a fully connected layer 1, a RELU layer, a fully connected layer 2 with an output length of 4096, and a fully connected layer 3 with an output length of N and a sparse softmax cross entropy loss function after the pooled output layer, which is used for gradient descent during model training.

3. The address recognition detection method according to claim 2, characterized in that: In the training process of step S2, multiple groups of address texts are selected to be input into the BERT neural network model and the cosine similarity is calculated after the output of the fully connected layer 2 is normalized, specifically including: A threshold value S is preset, and the cosine similarity of any two different text outputs of the same address is calculated after normalization and recorded as d1, and the cosine similarity of any two text outputs of different addresses is calculated after normalization and recorded as d2; If d1 ≥ the specified threshold S, TP increases by one, otherwise FN increases by one; If d2 ≥ the specified threshold S, FP increases by one, otherwise TN increases by one; TP means that the actual example is positive and the prediction is also positive; FP means that the actual example is negative and the prediction is positive; TN means that the actual example is negative and the prediction is also negative; FN means that the actual example is positive and the prediction is negative. Performance indicators including accuracy, precision, recall and F1 score are calculated through TP, FP, TN and FN.

4. The address recognition detection method according to claim 3, characterized in that: During the model training process in step S2, a threshold k and a threshold T are preset, and the training stops when the output average of the loss function is less than the specified threshold k or the number of training times reaches the specified threshold T.

5. The address recognition detection method according to claim 3, characterized in that: After the training in step S2 is completed, the model evaluation rules are preset according to the F1 scores recorded in the process, and the version model whose F1 score meets the requirements of the model evaluation rules is selected as the final model.

6. The address recognition detection method according to claim 1, characterized in that: During the training process of step S2, typos, address connection symbols, dashes, underscores, and brackets are randomly added to the address text.

7. A computer-readable storage medium, characterized in that: A computer program is stored, and when the computer program is executed by a processor, the processor is caused to execute the steps of the method according to any one of claims 1 to 6.

8. A computer device, characterized in that: The method comprises a memory and a processor, wherein the memory stores a computer program, and when the computer program is executed by the processor, the processor executes the steps of the method according to any one of claims 1 to 6.

Citation Information

Cited By

  • Address data processing method and device, storage medium and program product

    CN121327048A