Road data format detection method and device, equipment, storage medium and product

Through field information analysis and format detection of road data, and the use of logistic regression models to achieve automatic detection, the problem of low manual detection efficiency in the existing technology is solved, and the accuracy and stability of data management of the intelligent driving system are improved.

CN118760672APending Publication Date: 2024-10-11SINO TRUK JINAN POWER CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410688513.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-30
Publication Date
2024-10-11

AI Technical Summary

Technical Problem

The existing technology requires manual detection of road data formats, resulting in low management efficiency and accuracy, and making it impossible to achieve the reliability and stability of the intelligent driving system.

Method used

By parsing the collected road data into field information, and performing format detection on each field information, the correctness of the field name and field value is judged. If correct, it is stored in the standard cache, otherwise it is stored in the non-standard cache, and a logistic regression model is used. The constructed format detection model is automatically detected.

Benefits of technology

It realizes the automatic detection of road data format, improves the accuracy and efficiency of management, reduces manual operations, and ensures the reliability and stability of the intelligent driving system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118760672A_ABST
    Figure CN118760672A_ABST
Patent Text Reader

Abstract

The invention provides a road data format detection method and device, equipment, a storage medium and a product, and the method comprises the steps: carrying out the analysis of collected to-be-detected road data, and obtaining a plurality of pieces of field information; wherein each piece of field information comprises a field name and a field value; performing format detection processing on each piece of field information, and judging whether the format of each piece of field information is correct or not; if the format of the field information is correct, storing the field information into a standard cache; otherwise, storing the field information into the non-standard cache. According to the scheme of the invention, automatic detection of the road data format can be realized, and the efficiency and accuracy of road data management are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of intelligent driving technology, and in particular to a road data format detection method, device, equipment, storage medium and product. Background Art

[0002] With the rapid development of sensor technology, computer vision technology and machine learning technology, intelligent driving technology has made great progress. Intelligent driving systems require a large amount of road data as input to achieve functions such as perception, decision-making and control.

[0003] In actual applications, the quality of road data collected by vehicles under different road environments and weather conditions may vary greatly. Vehicles of different manufacturers and models may use different data formats and communication protocols, resulting in inconsistent road data formats, which is not conducive to the integration and sharing of road data. In order to ensure the reliability and stability of the intelligent driving system, it is necessary to perform format detection on the collected road data and process the road data with incorrect formats in a timely manner.

[0004] In the related art, it is necessary to manually perform format detection on the collected road data, and the efficiency and accuracy of road data management are low. Summary of the invention

[0005] The present invention provides a road data format detection method, device, equipment, storage medium and product, which are used to solve the defect of the prior art that manual format detection of collected road data is required, realize automatic detection of road data format, and improve the efficiency and accuracy of road data management.

[0006] The present invention provides a road data format detection method, comprising: parsing collected road data to be detected to obtain multiple field information; wherein each field information comprises a field name and a field value; performing format detection processing on each field information to determine whether the format of each field information is correct; wherein the format detection processing comprises: detecting whether the field name is correct; detecting whether the format of the field value is correct; if the formats of the field name and the field value are both correct, determining that the format of the field information is correct; otherwise, determining that the format of the field information is incorrect; if the format of the field information is correct, storing the field information in a standard cache; otherwise, storing the field information in a non-standard cache.

[0007] According to a road data format detection method provided by the present invention, the detection of whether the field name is correct includes: comparing the field name with each reference field name in a standard list, and determining whether the standard list includes a reference field name consistent with the field name; wherein the standard list includes reference field names corresponding to all field names that may exist in the road data; if the standard list includes a reference field name consistent with the field name, then the field name is determined to be correct; otherwise, then the field name is determined to be incorrect.

[0008] According to a road data format detection method provided by the present invention, the specification list also includes a field value specification corresponding to each reference field name; the detection of whether the format of the field value is correct includes: if it is determined that the field name is correct, querying the specification list according to the field name to obtain the field value specification corresponding to the field value; judging whether the field value complies with the field value specification; if so, determining that the format of the field value is correct, otherwise, determining that the format of the field value is incorrect.

[0009] According to a road data format detection method provided by the present invention, the field value specification includes at least one of the following: a reference data type, a field value range, an abnormal value determination standard, and an associated field value determination standard.

[0010] According to a road data format detection method provided by the present invention, before parsing the collected road data to be detected to obtain multiple field information, the method also includes: initializing the standard cache and the non-standard cache; if the format of the field information is correct, storing the field information in the standard cache; otherwise, after storing the field information in the non-standard cache, the method includes: sending all the field information stored in the non-standard cache and the standard cache to a road data management system.

[0011] According to a road data format detection method provided by the present invention, before performing format detection processing on each field information to determine whether the format of each field information is correct, the method also includes: generating a feature vector corresponding to the road data to be detected based on the multiple field information; inputting the feature vector into a format detection model to obtain a format detection result corresponding to the road data to be detected output by the format detection model; wherein the format detection model is constructed based on a logistic regression model and trained based on a training set; the training set includes a feature matrix and a target variable vector corresponding to historical road data; performing format detection processing on each field information to determine whether the format of each field information is correct includes: if the format detection result corresponding to the road data to be detected is a format error, performing format detection processing on each field information to determine whether the format of each field information is correct.

[0012] The present invention also provides a road data format detection device, comprising: a parsing module, used to parse the collected road data to be detected to obtain multiple field information; wherein each field information includes a field name and a field value; a detection module, used to perform format detection processing on each field information to determine whether the format of each field information is correct; wherein the format detection processing includes: detecting whether the field name is correct; detecting whether the format of the field value is correct; if the formats of the field name and the field value are both correct, then determining that the format of the field information is correct; otherwise, determining that the format of the field information is incorrect; a recording module, used to store the field information in a standard cache if the format of the field information is correct; otherwise, storing the field information in a non-standard cache.

[0013] The present invention also provides an electronic 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 program, any of the road data format detection methods described above is implemented.

[0014] The present invention also provides a non-transitory computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the road data format detection method described in any one of the above is implemented.

[0015] The present invention also provides a computer program product, comprising a computer program, wherein when the computer program is executed by a processor, the road data format detection method described in any one of the above is implemented.

[0016] The road data format detection method, device, equipment, storage medium and product provided by the present invention parse the collected road data to be detected to obtain multiple field information; perform format detection on the field name and field value in each field information to determine the field information with incorrect format, thereby realizing automatic detection of the road data format; and store the field information with correct format and the field information with incorrect format in a standard cache library and a non-standard cache library respectively, thereby facilitating the subsequent management of the road data. The solution of the present invention can realize automatic detection of the road data format without manual operation, thereby improving the accuracy and efficiency of road data management. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0018] Figure 1 This is one of the flow charts of the road data format detection method provided by the present invention.

[0019] Figure 2 This is the second flow chart of the road data format detection method provided by the present invention.

[0020] Figure 3 This is the third flow chart of the road data format detection method provided by the present invention.

[0021] Figure 4 It is a structural schematic diagram of the road data format detection device provided by the present invention.

[0022] Figure 5 It is a structural schematic diagram of the electronic device provided by the present invention. DETAILED DESCRIPTION

[0023] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0024] In practical applications, in order to ensure the reliability and stability of the intelligent driving system, it is necessary to perform format detection on the collected road data and process the road data with incorrect format in a timely manner. In related technologies, manual format detection of the collected road data is required, and the efficiency and accuracy of road data management are low.

[0025] In view of the above technical problems, the present invention proposes the following technical concept: parsing the collected roads to be detected into multiple field information; detecting whether the format of each field information is correct; storing the field information with correct format into a standard cache, and storing the field information with incorrect format into a non-standard cache, so as to realize automatic detection of the road data format, thereby improving the accuracy and efficiency of road data management.

[0026] The technical solution of the present application and how the technical solution of the present application solves the above-mentioned technical problems are described in detail below with specific embodiments. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present application will be described below in conjunction with the accompanying drawings.

[0027] Figure 1 is one of the flow charts of the road data format detection method provided by the present invention, such as Figure 1 As shown, the method includes the following steps 101 to 103.

[0028] In practical applications, the execution subject of the road data format detection method can be a road data format detection device, and there are many ways to implement the road data format detection device, for example, it can be implemented through a computer program, such as application software, etc.; or, for example, a chip, etc. It can also be implemented as a medium storing relevant computer programs, such as a USB disk, a cloud disk, etc.; or, it can also be implemented through a physical device integrated or installed with relevant computer programs, such as a server, etc.

[0029] Step 101: parse the collected road data to be detected to obtain multiple field information; wherein each field information includes a field name and a field value.

[0030] The road data to be detected is collected in real time, and includes multiple field information. The multiple field information in the road data to be detected can be separated according to a preset separation rule. Exemplarily, the multiple field information includes a preset symbol separation, for example, different field information is separated by a comma. The field name and field value in the field information can also be separated according to a preset separation rule. Exemplarily, in each field information, the field name is in front and the field value is in the back, and the field name and field value are separated by a colon.

[0031] Specifically, step 101 includes: splitting the road data to be detected according to rows; for each row of data, parsing the road data to be detected according to the separation rules between field information to obtain multiple field information; further, according to the separation rules between field names and field values, the field names and field values ​​in the field information can be determined.

[0032] Step 102: Perform format detection processing on each field information to determine whether the format of each field information is correct.

[0033] The format detection process includes: detecting whether the field name is correct; detecting whether the format of the field value is correct; if the formats of the field name and the field value are correct, determining that the format of the field information is correct; otherwise, determining that the format of the field information is incorrect.

[0034] In this embodiment, the field name and field value are detected separately. Only when the formats of the field name and the field value are correct, the format of the field information is determined to be correct. In practical applications, the field name is corresponding to the field value. The field name is a clear and definite name. The field values ​​corresponding to different field names are different. Therefore, the road data to be detected is parsed into multiple field information. Each field information is detected, which can comprehensively and accurately realize the format detection of the road data to be detected.

[0035] It is understandable that road data includes all data related to vehicle driving. As an example, road data includes timestamp, vehicle status data, location information, sensor data, environmental condition data, and event information. Among them, the timestamp refers to the time point when the road data is collected. Vehicle status data includes vehicle speed, acceleration, angular velocity, etc. Location information records the location of the vehicle, usually including longitude and latitude coordinates. Sensor data includes data collected by various sensors carried by the vehicle, such as camera images, radar data, lidar data, etc. Environmental condition data records the environmental conditions of the vehicle, such as weather, road conditions, etc. Time information records events that occur to the vehicle, such as collision, sudden braking, lane change, etc.

[0036] In actual applications, field name specifications and field value specifications are preset. As an example, the field name specifications include the correct spelling and naming rules corresponding to the field names of different types of fields. Taking into account the correspondence between field names and field values, corresponding field value specifications can be set for field values ​​corresponding to different field names. As an example, the field value specifications include: reference data type, field value range, abnormal value judgment standard, associated field value judgment standard, etc. Specifically, step 102 includes: according to the preset field name specifications and field value specifications, format detection is performed on each field information to determine whether the format of each field information is correct.

[0037] In combination with actual application scenarios, examples are given for field name specifications and field value specifications. For example, the field name is timestamp, and the field value specifications corresponding to the timestamp field include the time format, for example, the ISO 8601 format. For another example, the field name is vehicle speed, and the field value specifications corresponding to the vehicle speed field include: the data type is a floating point type and a vehicle speed range. For another example, the field name is location information, and the field value specifications corresponding to the location information field include: the data type is a floating point type. For another example, the field name is camera image, and the field value specifications corresponding to the camera image field include: image format and image size.

[0038] Step 103: If the format of the field information is correct, the field information is stored in the standard cache.

[0039] Step 104: If the format of the field information is incorrect, the field information is stored in a non-standard cache.

[0040] In this embodiment, the implementation forms of the standard cache and the non-standard cache are not limited. For example, the standard cache and the non-standard cache can be a cache database, a dictionary, a queue, a log, a cache, etc. It is understandable that after each field information is detected and processed, it can be determined whether the format of the field information is correct, and the field information with the correct format and the field information with the incorrect format are stored in the standard cache and the non-standard cache respectively, so as to facilitate the subsequent management personnel to manage the road data.

[0041] In this embodiment, the collected road data to be detected is parsed to obtain multiple field information; the format of the field name and field value in each field information is detected to determine the field information with incorrect format, thereby realizing automatic detection of the road data format; the field information with correct format and the field information with incorrect format are stored in the standard cache library and the non-standard cache library respectively, so as to facilitate the subsequent management of the road data. The solution of this embodiment can realize automatic detection of the road data format without manual operation, thereby improving the accuracy and efficiency of road data management.

[0042] In combination with the above description, it is possible to detect whether the field name is correct based on the pre-set field name specifications. In actual applications, the pre-set field name specifications can be stored, and when it is necessary to detect whether the field name is correct, the corresponding field name specifications can be queried. Optionally, in one example, the specification list includes the correct spelling and naming specifications corresponding to the field name. Specifically, based on the correct spelling and naming specifications stored in the specification list, it is possible to detect whether the spelling of the field name is correct and whether the naming is consistent. If the field name is spelled correctly and the naming is consistent, the field name is determined to be correct.

[0043] As an example, in one possible implementation, detecting whether the field name is correct in the above step 102 includes: comparing the field name with each reference field name in the specification list, and determining whether the specification list includes a reference field name that is consistent with the field name; wherein the specification list includes reference field names corresponding to all field names that may exist in the road data; if the specification list includes a reference field name that is consistent with the field name, then the field name is determined to be correct; otherwise, then the field name is determined to be incorrect.

[0044] Exemplarily, the multiple field information parsed in step 101 can be stored in a field information cache, for example, the field name and field value can be stored in a dictionary named "data". Specifically, each field name is extracted from the "data" dictionary in turn. The field name is compared with each reference field name in the specification list. If the specification list includes a reference field name that matches the field name, the field name is determined to be correct. Correspondingly, the specification list does not include a reference field name that matches the field name, and the field name is determined to be incorrect.

[0045] In combination with the above description, only when the formats of the field name and the field value are correct, the format of the field information is determined to be correct; otherwise, the format of the field information is determined to be incorrect. In one example, when it is determined that the field name is incorrect, the format of the field information can be determined to be incorrect, and the field information can be stored in the non-standard cache.

[0046] In practical applications, field names correspond to field values, and field names can clearly and unambiguously represent field values. In one example, after determining that the field name is incorrect, determine whether the format of the field value is correct based on the type of the field name. For example, if the field name is a numeric field, check whether the field value is a numeric type; if the field name is a text field, check whether the field value is a string type. If the format of the field name is correct, mark the field name as incorrect; if the format of the field name is correct, store the field information in a non-standard cache; if the format of the field name is incorrect, mark both the field name and the field name as incorrect, and store the field information in a non-standard cache.

[0047] In this implementation, the collected road data to be detected is parsed to obtain multiple field information; for the field name in each field information, the field name is compared with each reference field name in the specification list, so that the field name can be detected quickly and accurately.

[0048] Combined with the above description, only when the formats of the field name and the field value are correct, the format of the field information is determined to be correct; otherwise, the format of the field information is determined to be incorrect. In practical applications, in order to further save the detection efficiency of field information, after detecting that the field name is wrong, the format of the field information can be determined to be wrong, and the field information can be added to the non-standard cache. Correspondingly, after detecting that the field name is correct, it can be further determined whether the format of the field value is correct. If the format of the field value is correct, the format of the field information is determined to be correct; otherwise, the format of the field information is determined to be incorrect.

[0049] In actual applications, there are differences in the field values ​​corresponding to different field names, and the format of the field value is set corresponding to the field name. Therefore, the field value specification corresponding to the field value can be stored according to the field name. As an example, in one possible implementation, the specification list also includes the field value specification corresponding to each reference field name; detecting whether the format of the field value is correct in the above step 102 includes: if it is determined that the field name is correct, querying the specification list according to the field name to obtain the field value specification corresponding to the field value; judging whether the field value meets the field value specification; if it meets, judging that the format of the field value is correct, otherwise, judging that the format of the field value is incorrect.

[0050] Specifically, the specification list includes multiple reference field names and field value specifications corresponding to each reference field name. The reference field names correspond to the field value specifications one by one. In practical applications, for each field information, the field name is compared with each reference field name in the specification list to determine whether the specification list includes a reference field name that is consistent with the field name; if the specification list includes a reference field name that is consistent with the field name, the field name is determined to be correct.

[0051] It can be understood that if the field name is correct, it means that the specification list includes a reference field name that is consistent with the field name. On this basis, the specification list can be queried according to the field name to determine the field value specification corresponding to the field value. Further, according to the field value specification corresponding to the field value, it is determined whether the format of the field value is correct.

[0052] Specifically, if the standard list does not include a reference field name that is consistent with the field name, the field name is determined to be incorrect. Further, based on the type of the field name, it is determined whether the format of the field value is correct. If the format of the field value is incorrect, it is noted that both the format of the field name and the field value are incorrect; if the format of the field value is correct, it is noted that the field name is incorrect and the format of the field value is correct; the field information is stored in the non-standard cache.

[0053] Correspondingly, if the specification list includes a reference field name that is consistent with the field name, the field name is determined to be correct. At this time, the specification list can be queried according to the field name to obtain the field value specification corresponding to the field value; according to the field value specification, the format of the field value is detected; if the format of the field value is correct, the field information is added to the standard cache; if the format of the field value is incorrect, the field name is marked as correct and the format of the field value is incorrect, and the field information is stored in the non-standard cache.

[0054] In this embodiment, multi-dimensional field value verification is supported, including detection of field value type, field value integrity, field value range, field value consistency, etc., to ensure the integrity and accuracy of field values. As an example, the above field value specification includes at least one of the following: reference data type, field value range, abnormal value judgment standard, and associated field value judgment standard.

[0055] The reference data type can be a numeric type, a string type, an image format, etc. In practice, the data type of the field value is checked to ensure that the data type of the field value is consistent with the reference data type. For example, for a numeric field, check whether the field value is a numeric type; for a text field, check whether the field value is a string type, etc.

[0056] For numeric field values, you can set the field value range. Perform a value range check on the field value to ensure that the field value range is within the specified range. For example, check whether the vehicle speed field is within a reasonable range, check whether the sensor data exceeds the normal range, etc.

[0057] The outlier judgment standard is used to detect outliers in field values, identify and mark outliers for subsequent processing. Outliers may be caused by sensor failure, data collection errors, etc., and need to be identified and processed in a timely manner.

[0058] The association field judgment standard is used to check the consistency between field information to ensure that the association relationship and logical relationship between field information meet the association field judgment standard. For example, check the consistency between the timestamp field and the location information field to ensure that the location information corresponding to the timestamp is correct.

[0059] In actual applications, according to multiple detection specifications in the field value specification, the field value is detected in turn, and the detection results corresponding to each detection specification are recorded. It can be understood that only when the field value meets all field value specifications can the format of the field value be determined to be correct. Specifically, if the format of the field value is correct and the field name is correct, the detection results of each detection specification of the field value, the field name detection results, and the field information are stored in the standard cache; if the format of the field value is incorrect or the field name is incorrect, the detection results of each detection specification of the field value, the field name detection results, and the field information are stored in the non-standard cache.

[0060] In this implementation, the collected road data to be detected is parsed to obtain multiple field information; for the field name in each field information, the field name is compared with each reference field name in the specification list to determine whether the field name is correct; the specification list is queried according to the field name to obtain the field value specification corresponding to the field value, and the format of the field value is detected according to the field value specification, so that the field information can be detected quickly and accurately.

[0061] In addition, in order to further improve the efficiency of road data management, field information with format problems can be sent to users, so that users can process road data in a timely manner and find the cause of road data errors. For example, a report can be generated based on all field information stored in the non-standard cache, and the report can be sent to users, so that users can manage road data in a timely manner. As an example, in one possible implementation, Figure 2 FIG. 2 is a flow chart of the road data format detection method provided by the present invention. Figure 2 As shown, before the above step 101, the above road data format detection method further includes: step 201. After the above step 104, the above road data format detection method further includes: step 202.

[0062] Step 201: Initialize the standard cache and the non-standard cache.

[0063] Step 202: Send all field information stored in the non-standard cache and the standard cache to the road data management system.

[0064] In this embodiment, before parsing the road data to be detected, the standard cache and the non-standard cache are initialized to avoid the influence of the previous road data detection on the current road data detection. By parsing the collected road data to be detected, multiple field information is obtained; the format detection is performed on the field name and field value in each field information, and the field information with incorrect format can be determined, thereby realizing the automatic detection of the road data format; the field information with correct format and the field information with incorrect format are stored in the standard cache library and the non-standard cache library respectively. All the field information stored in the non-standard cache and the standard cache is sent to the road data management system, so that the user can manage the road data in a timely manner. The scheme of this embodiment can realize the automatic detection of the road data format without manual operation, thereby improving the accuracy and efficiency of road data management.

[0065] In addition, in order to save time in detecting the road data format, the road data to be detected can be detected before the format detection of each field information is performed; when there is a format error in the road data to be detected, the format detection is performed on each field information to determine the field information with the format error; when there is no format error in the road data to be detected, the format detection is not performed on each field information.

[0066] As an example, in one possible implementation, Figure 3 FIG. 3 is a flow chart of the road data format detection method provided by the present invention. Figure 3 As shown, before the above step 102, the above road data format detection method further includes: step 301 and step 302. The above step 102 includes: step 303 and step 304.

[0067] Step 301: Generate a feature vector corresponding to the road data to be detected according to multiple field information.

[0068] Step 302: Input the feature vector into the format detection model to obtain the format detection result corresponding to the road data to be detected output by the format detection model; wherein the format detection model is constructed based on a logistic regression model and trained based on a training set; the training set includes a feature matrix and a target variable vector corresponding to the historical road data.

[0069] Step 303: determine whether the format detection result corresponding to the road data to be detected is that there is a format error.

[0070] Step 304: If the format detection result corresponding to the road data to be detected is that there is a format error, then a format detection process is performed on each field information to determine whether the format of each field information is correct.

[0071] In practical applications, for the format detection of field information, it is necessary to detect the field name, field value type, field value integrity, field value range, field value consistency, etc. Specifically, a training set including multiple features is constructed, and the training set includes a feature matrix and a target variable vector corresponding to the historical road data. Among them, the feature matrix corresponding to the historical road data includes the field name, field value data type, field value range and other features corresponding to each field information of the historical road data, and the target variable indicates whether the historical road data conforms to the expected data format. The format detection problem of road data is modeled as a binary classification problem, and an initial format detection model is constructed based on the logistic regression model. The initial format detection model is trained based on the training set until the format detection model is obtained.

[0072] Specifically, feature extraction is performed on the historical road data to obtain a feature matrix X and a target variable vector Y corresponding to the historical road data. The expressions of the feature matrix X and the target variable vector Y are as follows.

[0073] Among them, m represents the number of samples, n represents the number of features, and x ij represents the jth feature of the i-th sample, y i represents the target variable of the i-th sample.

[0074] In practical applications, the logistic regression model is used for training to obtain the model parameters θ. The probability value h predicted by the model is calculated. θ (x), according to the probability value h predicted by the model θ (x) Verify the road data to be detected. Specifically, input the feature vector into the format detection model, obtain the format detection result corresponding to the road data to be detected output by the format detection model, and calculate the probability value h predicted by the model. θ (x), when the probability value is greater than or equal to the preset threshold, it is determined that the format of the road data to be detected is correct. When the probability value is less than the preset threshold, it is determined that the format of the road data to be detected is incorrect, and format detection processing is performed on each field information to determine whether the format of each field information is correct. Among them, the probability value h θ The expression of (x) is as follows.

[0075] In this embodiment, before format detection is performed on each field information, a feature vector corresponding to the road data to be detected is generated based on multiple field information. The feature vector is input into the format detection model to obtain the format detection result corresponding to the road data to be detected output by the format detection model. If the format detection result corresponding to the road data to be detected is that there is a format error, format detection processing is performed on each field information to determine whether the format of each field information is correct, which saves the time of road data detection and improves the efficiency of road data management.

[0076] The road data format detection method provided in this embodiment parses the collected road data to be detected to obtain multiple field information; performs format detection on the field name and field value in each field information to determine the field information with incorrect format, thereby realizing automatic detection of the road data format; and stores the field information with correct format and the field information with incorrect format in the standard cache library and the non-standard cache library respectively, thereby facilitating the subsequent management of the road data. The solution of this embodiment can realize automatic detection of the road data format without manual operation, thereby improving the accuracy and efficiency of road data management.

[0077] The road data format detection device provided by the present invention is described below. The road data format detection device described below and the road data format detection method described above can be referred to each other.

[0078] Figure 4 Schematic diagram of the structure of the road data format detection device provided by the present invention. Figure 4 As shown, the road data format detection device includes: a parsing module 41, a detection module 42 and a recording module 43.

[0079] The parsing module 41 is used to parse the collected road data to be detected to obtain a plurality of field information; wherein each field information includes a field name and a field value.

[0080] The road data to be detected is collected in real time, and includes multiple field information. The multiple field information in the road data to be detected can be separated according to a preset separation rule. Exemplarily, the multiple field information includes a preset symbol separation, for example, different field information is separated by a comma. The field name and field value in the field information can also be separated according to a preset separation rule. Exemplarily, in each field information, the field name is in front and the field value is in the back, and the field name and field value are separated by a colon.

[0081] Specifically, the parsing module 41 is specifically used to: split the road data to be detected according to rows; for each row of data, parse the road data to be detected according to the separation rules between field information to obtain multiple field information; further, according to the separation rules between field names and field values, the field names and field values ​​in the field information can be determined.

[0082] The detection module 42 is used to perform format detection processing on each field information to determine whether the format of each field information is correct.

[0083] The format detection process includes: detecting whether the field name is correct; detecting whether the format of the field value is correct; if the formats of the field name and the field value are correct, determining that the format of the field information is correct; otherwise, determining that the format of the field information is incorrect.

[0084] In this embodiment, the field name and field value are detected separately. Only when the formats of the field name and the field value are correct, the format of the field information is determined to be correct. In practical applications, the field name is corresponding to the field value. The field name is a clear and definite name. The field values ​​corresponding to different field names are different. Therefore, the road data to be detected is parsed into multiple field information. Each field information is detected, which can comprehensively and accurately realize the format detection of the road data to be detected.

[0085] It is understandable that road data includes all data related to vehicle driving. As an example, road data includes timestamp, vehicle status data, location information, sensor data, environmental condition data, and event information. Among them, the timestamp refers to the time point when the road data is collected. Vehicle status data includes vehicle speed, acceleration, angular velocity, etc. Location information records the location of the vehicle, usually including longitude and latitude coordinates. Sensor data includes data collected by various sensors carried by the vehicle, such as camera images, radar data, lidar data, etc. Environmental condition data records the environmental conditions of the vehicle, such as weather, road conditions, etc. Time information records events that occur to the vehicle, such as collision, sudden braking, lane change, etc.

[0086] In practical applications, field name specifications and field value specifications are preset. As an example, the field name specifications include the correct spelling and naming rules corresponding to the field names of different types of fields. Taking into account the correspondence between field names and field values, corresponding field value specifications can be set for field values ​​corresponding to different field names. As an example, the field value specifications include: reference data type, field value range, abnormal value judgment standard, associated field value judgment standard, etc. Specifically, the detection module 42 is specifically used to: perform format detection on each field information according to the preset field name specifications and field value specifications, and determine whether the format of each field information is correct.

[0087] The recording module 43 is used to store the field information in the standard cache if the format of the field information is correct; otherwise, store the field information in the non-standard cache.

[0088] In this embodiment, the implementation forms of the standard cache and the non-standard cache are not limited. For example, the standard cache and the non-standard cache can be a cache database, a dictionary, a queue, a log, a cache, etc. It is understandable that after each field information is detected and processed, it can be determined whether the format of the field information is correct, and the field information with the correct format and the field information with the incorrect format are stored in the standard cache and the non-standard cache respectively, so as to facilitate the subsequent management personnel to manage the road data.

[0089] In this embodiment, the parsing module 41 parses the collected road data to be detected to obtain multiple field information; the detection module 42 performs format detection on the field name and field value in each field information, and can determine the field information with incorrect format, thereby realizing automatic detection of the road data format; the recording module 43 stores the field information with correct format and the field information with incorrect format in the standard cache library and the non-standard cache library respectively, so as to facilitate the subsequent management of the road data. The solution of this embodiment can realize automatic detection of the road data format without manual operation, thereby improving the accuracy and efficiency of road data management.

[0090] In combination with the above description, it is possible to detect whether the field name is correct based on the pre-set field name specifications. In actual applications, the pre-set field name specifications can be stored, and when it is necessary to detect whether the field name is correct, the corresponding field name specifications can be queried. Optionally, in one example, the specification list includes the correct spelling and naming specifications corresponding to the field name. Specifically, based on the correct spelling and naming specifications stored in the specification list, it is possible to detect whether the spelling of the field name is correct and whether the naming is consistent. If the field name is spelled correctly and the naming is consistent, the field name is determined to be correct.

[0091] As an example, in one possible implementation, the detection module 42 is used to detect whether a field name is correct, and is specifically used to: compare the field name with each reference field name in the specification list to determine whether the specification list includes a reference field name that is consistent with the field name; wherein the specification list includes reference field names corresponding to all field names that may exist in the road data; if the specification list includes a reference field name that is consistent with the field name, then the field name is determined to be correct; otherwise, then the field name is determined to be incorrect.

[0092] Exemplarily, the multiple field information parsed by the parsing module 41 can be stored in the field information cache, for example, the field name and the field value are stored in a dictionary named "data". Specifically, each field name is extracted from the "data" dictionary in turn. The field name is compared with each reference field name in the specification list. If the specification list includes a reference field name that matches the field name, the field name is determined to be correct. Correspondingly, the specification list does not include a reference field name that matches the field name, and the field name is determined to be incorrect.

[0093] In combination with the above description, only when the formats of the field name and the field value are correct, the format of the field information is determined to be correct; otherwise, the format of the field information is determined to be incorrect. In one example, when it is determined that the field name is incorrect, the format of the field information can be determined to be incorrect, and the field information can be stored in the non-standard cache.

[0094] In practical applications, field names correspond to field values, and field names can clearly and unambiguously represent field values. In one example, after determining that the field name is incorrect, determine whether the format of the field value is correct based on the type of the field name. For example, if the field name is a numeric field, check whether the field value is a numeric type; if the field name is a text field, check whether the field value is a string type. If the format of the field name is correct, mark the field name as incorrect; if the format of the field name is correct, store the field information in a non-standard cache; if the format of the field name is incorrect, mark both the field name and the field name as incorrect, and store the field information in a non-standard cache.

[0095] In this implementation, the collected road data to be detected is parsed to obtain multiple field information; for the field name in each field information, the field name is compared with each reference field name in the specification list, so that the field name can be detected quickly and accurately.

[0096] Combined with the above description, only when the formats of the field name and the field value are correct, the format of the field information is determined to be correct; otherwise, the format of the field information is determined to be incorrect. In practical applications, in order to further save the detection efficiency of field information, after detecting that the field name is wrong, the format of the field information can be determined to be wrong, and the field information can be added to the non-standard cache. Correspondingly, after detecting that the field name is correct, it can be further determined whether the format of the field value is correct. If the format of the field value is correct, the format of the field information is determined to be correct; otherwise, the format of the field information is determined to be incorrect.

[0097] In actual applications, there are differences in the field values ​​corresponding to different field names, and the format of the field value is set corresponding to the field name. Therefore, the field value specification corresponding to the field value can be stored according to the field name. As an example, in a possible implementation, the specification list also includes the field value specification corresponding to each reference field name; when the above-mentioned detection module 42 is used to detect whether the format of the field value is correct, it is specifically used to: if it is determined that the field name is correct, query the specification list according to the field name to obtain the field value specification corresponding to the field value; determine whether the field value meets the field value specification; if it meets, then determine that the format of the field value is correct, otherwise, then determine that the format of the field value is incorrect.

[0098] Specifically, the specification list includes multiple reference field names and field value specifications corresponding to each reference field name. The reference field names correspond to the field value specifications one by one. In practical applications, for each field information, the field name is compared with each reference field name in the specification list to determine whether the specification list includes a reference field name that is consistent with the field name; if the specification list includes a reference field name that is consistent with the field name, the field name is determined to be correct.

[0099] It can be understood that if the field name is correct, it means that the specification list includes a reference field name that is consistent with the field name. On this basis, the specification list can be queried according to the field name to determine the field value specification corresponding to the field value. Further, according to the field value specification corresponding to the field value, it is determined whether the format of the field value is correct.

[0100] Specifically, if the standard list does not include a reference field name that is consistent with the field name, the field name is determined to be incorrect. Further, based on the type of the field name, it is determined whether the format of the field value is correct. If the format of the field value is incorrect, it is noted that both the format of the field name and the field value are incorrect; if the format of the field value is correct, it is noted that the field name is incorrect and the format of the field value is correct; the field information is stored in the non-standard cache.

[0101] Correspondingly, if the specification list includes a reference field name that is consistent with the field name, the field name is determined to be correct. At this time, the specification list can be queried according to the field name to obtain the field value specification corresponding to the field value; according to the field value specification, the format of the field value is detected; if the format of the field value is correct, the field information is added to the standard cache; if the format of the field value is incorrect, the field name is marked as correct and the format of the field value is incorrect, and the field information is stored in the non-standard cache.

[0102] In this embodiment, multi-dimensional field value verification is supported, including detection of field value type, field value integrity, field value range, field value consistency, etc., to ensure the integrity and accuracy of field values. As an example, the above field value specification includes at least one of the following: reference data type, field value range, abnormal value judgment standard, and associated field value judgment standard.

[0103] The reference data type can be a numeric type, a string type, an image format, etc. In practice, the data type of the field value is checked to ensure that the data type of the field value is consistent with the reference data type. For example, for a numeric field, check whether the field value is a numeric type; for a text field, check whether the field value is a string type, etc.

[0104] For numeric field values, you can set the field value range. Perform a value range check on the field value to ensure that the field value range is within the specified range. For example, check whether the vehicle speed field is within a reasonable range, check whether the sensor data exceeds the normal range, etc.

[0105] The outlier judgment standard is used to detect outliers in field values, identify and mark outliers for subsequent processing. Outliers may be caused by sensor failure, data collection errors, etc., and need to be identified and processed in a timely manner.

[0106] The association field judgment standard is used to check the consistency between field information to ensure that the association relationship and logical relationship between field information meet the association field judgment standard. For example, check the consistency between the timestamp field and the location information field to ensure that the location information corresponding to the timestamp is correct.

[0107] In actual applications, according to multiple detection specifications in the field value specification, the field value is detected in turn, and the detection results corresponding to each detection specification are recorded. It can be understood that only when the field value meets all field value specifications can the format of the field value be determined to be correct. Specifically, if the format of the field value is correct and the field name is correct, the detection results of each detection specification of the field value, the field name detection results, and the field information are stored in the standard cache; if the format of the field value is incorrect or the field name is incorrect, the detection results of each detection specification of the field value, the field name detection results, and the field information are stored in the non-standard cache.

[0108] In this implementation, the collected road data to be detected is parsed to obtain multiple field information; for the field name in each field information, the field name is compared with each reference field name in the specification list to determine whether the field name is correct; the specification list is queried according to the field name to obtain the field value specification corresponding to the field value, and the format of the field value is detected according to the field value specification, so that the field information can be detected quickly and accurately.

[0109] In addition, in order to further improve the efficiency of road data management, field information with format problems can be sent to the user, so that the user can find the cause of the road data error. Exemplarily, a report can be generated based on all field information stored in the non-standard cache, and the report can be sent to the user, so that the user can manage the road data in time. As an example, in a possible implementation, the above-mentioned road data format detection device also includes: an initialization module and a sending module.

[0110] Initialization module, used to initialize standard cache and non-standard cache.

[0111] The sending module is used to send all field information stored in the non-standard cache and the standard cache to the road data management system.

[0112] In this embodiment, before parsing the road data to be detected, the standard cache and the non-standard cache are initialized to avoid the influence of the previous road data detection on the current road data detection. By parsing the collected road data to be detected, multiple field information is obtained; the format detection is performed on the field name and field value in each field information, and the field information with incorrect format can be determined, thereby realizing the automatic detection of the road data format; the field information with correct format and the field information with incorrect format are stored in the standard cache library and the non-standard cache library respectively. All the field information stored in the non-standard cache and the standard cache is sent to the road data management system, so that the user can manage the road data in a timely manner. The scheme of this embodiment can realize the automatic detection of the road data format without manual operation, thereby improving the accuracy and efficiency of road data management.

[0113] In addition, in order to save time in detecting the road data format, the road data to be detected can be detected before the format detection of each field information is performed; when there is a format error in the road data to be detected, the format detection is performed on each field information to determine the field information with the format error; when there is no format error in the road data to be detected, the format detection is not performed on each field information.

[0114] As an example, in a possible implementation manner, the road data format detection device further includes: a generation module and an input module.

[0115] The generation module is used to generate a feature vector corresponding to the road data to be detected based on multiple field information.

[0116] The input module is used to input the feature vector into the format detection model to obtain the format detection result corresponding to the road data to be detected output by the format detection model; wherein the format detection model is constructed based on the logistic regression model and trained based on the training set; the training set includes the feature matrix and target variable vector corresponding to the historical road data.

[0117] The detection module 42 is specifically used to: determine whether the format detection result corresponding to the road data to be detected is a format error; if the format detection result corresponding to the road data to be detected is a format error, perform format detection processing on each field information to determine whether the format of each field information is correct.

[0118] In practical applications, for the format detection of field information, it is necessary to detect the field name, field value type, field value integrity, field value range, field value consistency, etc. Specifically, a training set including multiple features is constructed, and the training set includes a feature matrix and a target variable vector corresponding to the historical road data. Among them, the feature matrix corresponding to the historical road data includes the field name, field value data type, field value range and other features corresponding to each field information of the historical road data, and the target variable indicates whether the historical road data conforms to the expected data format. The format detection problem of road data is modeled as a binary classification problem, and an initial format detection model is constructed based on the logistic regression model. The initial format detection model is trained based on the training set until the format detection model is obtained.

[0119] Specifically, feature extraction is performed on the historical road data to obtain a feature matrix X and a target variable vector Y corresponding to the historical road data. The expressions of the feature matrix X and the target variable vector Y are as follows.

[0120] Among them, m represents the number of samples, n represents the number of features, and x ij represents the jth feature of the i-th sample, y i represents the target variable of the i-th sample.

[0121] In practical applications, the logistic regression model is used for training to obtain the model parameters θ. The probability value h predicted by the model is calculated. θ (x), according to the probability value h predicted by the model θ (x) Verify the road data to be detected. Specifically, input the feature vector into the format detection model, obtain the format detection result corresponding to the road data to be detected output by the format detection model, and calculate the probability value h predicted by the model. θ(x), when the probability value is greater than or equal to the preset threshold, it is determined that the format of the road data to be detected is correct. When the probability value is less than the preset threshold, it is determined that the format of the road data to be detected is incorrect, and format detection processing is performed on each field information to determine whether the format of each field information is correct. Among them, the probability value h θ The expression of (x) is as follows.

[0122] In this embodiment, before format detection is performed on each field information, a feature vector corresponding to the road data to be detected is generated based on multiple field information. The feature vector is input into the format detection model to obtain the format detection result corresponding to the road data to be detected output by the format detection model. If the format detection result corresponding to the road data to be detected is that there is a format error, format detection processing is performed on each field information to determine whether the format of each field information is correct, which saves the time of road data detection and improves the efficiency of road data management.

[0123] The road data format detection device provided by this embodiment has a parsing module that parses the collected road data to be detected to obtain multiple field information; the detection module performs format detection on the field name and field value in each field information, and can determine the field information with incorrect format, thereby realizing automatic detection of the road data format; the recording module stores the field information with correct format and the field information with incorrect format into the standard cache library and the non-standard cache library respectively, so as to facilitate the subsequent management of the road data. The solution of this embodiment can realize automatic detection of the road data format without manual operation, thereby improving the accuracy and efficiency of road data management.

[0124] Figure 5 is a schematic diagram of the structure of the electronic device provided by the present invention, such as Figure 5As shown, the electronic device may include: a processor 510, a communication interface 520, a memory 530 and a communication bus 540, wherein the processor 510, the communication interface 520 and the memory 530 communicate with each other through the communication bus 540. The processor 510 may call the logic instructions in the memory 530 to execute the road data format detection method, which includes: parsing the collected road data to be detected to obtain multiple field information; wherein each field information includes a field name and a field value; performing format detection processing on each field information to determine whether the format of each field information is correct; wherein the format detection processing includes: detecting whether the field name is correct; detecting whether the format of the field value is correct; if the format of the field name and the field value are both correct, then determining that the format of the field information is correct; otherwise, determining that the format of the field information is incorrect; if the format of the field information is correct, then storing the field information in a standard cache; otherwise, storing the field information in a non-standard cache.

[0125] In addition, the logic instructions in the above-mentioned memory 530 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art or the part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program codes.

[0126] On the other hand, the present invention also provides a computer program product, which includes a computer program, and the computer program can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer can execute the road data format detection method provided by the above methods, and the method includes: parsing the collected road data to be detected to obtain multiple field information; wherein each field information includes a field name and a field value; performing format detection processing on each field information to determine whether the format of each field information is correct; wherein the format detection processing includes: detecting whether the field name is correct; detecting whether the format of the field value is correct; if the formats of the field name and the field value are both correct, then determining that the format of the field information is correct; otherwise, determining that the format of the field information is incorrect; if the format of the field information is correct, then storing the field information in a standard cache; otherwise, storing the field information in a non-standard cache.

[0127] On the other hand, the present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, is implemented to execute the road data format detection method provided by the above-mentioned methods, the method comprising: parsing the collected road data to be detected to obtain multiple field information; wherein each field information comprises a field name and a field value; performing format detection processing on each field information to determine whether the format of each field information is correct; wherein the format detection processing comprises: detecting whether the field name is correct; detecting whether the format of the field value is correct; if the formats of the field name and the field value are both correct, determining that the format of the field information is correct; otherwise, determining that the format of the field information is incorrect; if the format of the field information is correct, storing the field information in a standard cache; otherwise, storing the field information in a non-standard cache.

[0128] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed 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 modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative labor.

[0129] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.

[0130] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A road data format detection method, characterized in that: include: Parsing the collected road data to be detected to obtain multiple field information; wherein each field information includes a field name and a field value; Performing format detection processing on each field information to determine whether the format of each field information is correct; wherein the format detection processing includes: detecting whether the field name is correct; detecting whether the format of the field value is correct; if the formats of the field name and the field value are both correct, determining that the format of the field information is correct; otherwise, determining that the format of the field information is incorrect; If the format of the field information is correct, the field information is stored in a standard cache; otherwise, the field information is stored in a non-standard cache.

2. The road data format detection method according to claim 1, characterized in that: The detecting whether the field name is correct includes: Compare the field name with each reference field name in the specification list to determine whether the specification list includes a reference field name consistent with the field name; wherein the specification list includes reference field names corresponding to all field names that may exist in the road data; If the standard list includes a reference field name that is consistent with the field name, the field name is determined to be correct; otherwise, the field name is determined to be incorrect.

3. The road data format detection method according to claim 2, characterized in that: The specification list also includes a field value specification corresponding to each reference field name; and the step of detecting whether the format of the field value is correct includes: If it is determined that the field name is correct, query the specification list according to the field name to obtain the field value specification corresponding to the field value; Determine whether the field value meets the field value specification; if so, determine that the format of the field value is correct; otherwise, determine that the format of the field value is incorrect.

4. The road data format detection method according to claim 3, characterized in that: The field value specification includes at least one of the following: a reference data type, a field value range, an abnormal value determination standard, and an associated field value determination standard.

5. The road data format detection method according to any one of claims 1 to 4, characterized in that: Before parsing the collected road data to be detected to obtain a plurality of field information, the method further includes: Initializing the standard cache and the non-standard cache; If the format of the field information is correct, the field information is stored in a standard cache; otherwise, after the field information is stored in a non-standard cache, the method includes: All field information stored in the non-standard cache and the standard cache is sent to a road data management system.

6. The road data format detection method according to any one of claims 1 to 4, characterized in that: Before performing format detection processing on each field information to determine whether the format of each field information is correct, the method further includes: Generating a feature vector corresponding to the road data to be detected according to the plurality of field information; The feature vector is input into a format detection model to obtain a format detection result corresponding to the road data to be detected output by the format detection model; wherein the format detection model is constructed based on a logistic regression model and trained based on a training set; the training set includes a feature matrix and a target variable vector corresponding to the historical road data; The performing format detection processing on each field information to determine whether the format of each field information is correct includes: If the format detection result corresponding to the road data to be detected is that there is a format error, a format detection process is performed on each field information to determine whether the format of each field information is correct.

7. A road data format detection device, characterized in that: include: The parsing module is used to parse the collected road data to be detected to obtain multiple field information; wherein each field information includes a field name and a field value; A detection module is used to perform format detection processing on each field information to determine whether the format of each field information is correct; wherein the format detection processing includes: detecting whether the field name is correct; detecting whether the format of the field value is correct; if the formats of the field name and the field value are both correct, then determining that the format of the field information is correct; otherwise, determining that the format of the field information is incorrect; The recording module is used for storing the field information in a standard cache if the format of the field information is correct; otherwise, storing the field information in a non-standard cache.

8. An electronic 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 program, the road data format detection method according to any one of claims 1 to 6 is implemented.

9. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the road data format detection method according to any one of claims 1 to 6 is implemented.

10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the road data format detection method according to any one of claims 1 to 6 is implemented.