Memory fault detection method, electronic equipment and storage medium

By storing the parameter values ​​of the image processing model in the dynamic storage area of ​​the electronic device and comparing and detecting it, the shortcomings of memory failure detection in the prior art are solved, and accurate fault detection of the dynamic storage area is realized, ensuring the security and reliability of memory data.

CN119669046APending Publication Date: 2025-03-21SUTENG INNOVATION TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311201635.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-09-18
Publication Date
2025-03-21

AI Technical Summary

Technical Problem

The prior art is difficult to accurately detect faults in electronic device memory, especially in dynamic memory areas, with fewer fault detection methods.

Method used

By storing the parameter values ​​of the image processing model in the dynamic storage area of ​​the electronic device, obtaining the current parameter values ​​with the initial parameter values ​​during the idle time of the main program, processing the pre-stored image data using the image processing model, obtaining the current processing results and the reference processing results are compared. If different, it is determined that the memory failure occurs.

Benefits of technology

Accurate fault detection of dynamic memory areas is realized to ensure the security and reliability of memory data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119669046A_ABST
    Figure CN119669046A_ABST
Patent Text Reader

Abstract

The invention is applicable to the technical field of fault detection, and provides a memory fault detection method, electronic equipment and a storage medium, the method comprises the following steps: processing pre-stored image data pre-stored in a dynamic storage area by using an image processing model to obtain a current processing result, determining whether the dynamic storage area fails or not by comparing the current processing result with the reference processing result; calculating a current check code of the current code stored in the static storage area by using the check model, and determining whether the static storage area fails or not by comparing the current check code with the reference check code; determining whether the image storage area has a fault or not in a read-write mode; the memory fault detection method and device achieve the effect of performing fault detection on the memory.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application belongs to the technical field of fault detection, and in particular, relates to a memory fault detection method, an electronic device, and a storage medium. Background Art

[0002] The memory of an electronic device can be divided into a dynamic storage area and a static storage area. The dynamic storage area dynamically allocates storage locations for data objects in the source program during the operation phase of the electronic device; the static storage area allocates a fixed storage location to the data object during compilation and remains unchanged during runtime.

[0003] If the memory of an electronic device fails, the content stored in the memory will change, affecting the use of the electronic device. Therefore, in order to ensure that the electronic device can be used normally, the memory of the electronic device needs to be tested. Therefore, accurate fault detection of the memory is a problem that needs to be solved at present. Summary of the invention

[0004] The embodiments of the present application provide a memory fault detection method, an electronic device, and a storage medium, which can perform fault detection on the memory of the electronic device.

[0005] In a first aspect, an embodiment of the present application provides a method for detecting a memory failure, wherein the memory in the electronic device includes a dynamic storage area, wherein the dynamic storage area stores parameter values ​​of parameters in an image processing model; the image processing model is used to perform data processing on pre-stored image data;

[0006] The above methods include:

[0007] After the main program of the electronic device enters the idle time of the periodic operation, obtaining the current parameter value of the image processing model stored in the dynamic storage area;

[0008] Using the current parameter value and the pre-stored image processing model, the pre-stored image data is processed to obtain a current processing result of the pre-stored image data;

[0009] Comparing whether the current processing result is the same as a reference processing result, wherein the reference processing result is a standard result obtained by performing data processing on the pre-stored image data using the image processing model and the initial parameter value of the image processing model stored in the dynamic storage area;

[0010] If the current processing result is the same as the reference processing result, it is determined that no failure occurs in the dynamic storage area.

[0011] In a possible implementation manner of the first aspect, after calculating the first similarity between the current processing result and the reference processing result, the method further includes:

[0012] If the current processing result is different from the reference processing result, it is determined that a memory of the electronic device fails.

[0013] In a possible implementation manner of the first aspect, the memory in the electronic device includes a static storage area, and the static storage area stores code;

[0014] After the main program of the electronic device enters the idle time of periodic operation, the method further includes:

[0015] Obtaining the current code stored in the static storage area;

[0016] Calculating a current check code of the current code using a pre-stored check model;

[0017] Comparing whether the current check code is the same as a reference check code, wherein the reference check code is a standard check code of the initial code stored in the static storage area calculated using the check model;

[0018] If the current check code is the same as the reference check code, it is determined that no failure has occurred in the static storage area;

[0019] If the current verification code is different from the reference verification code, it is determined that a memory failure of the electronic device occurs.

[0020] In a possible implementation manner of the first aspect, the memory in the electronic device includes an image storage area, and the image storage area is used to store real-time image data collected by the electronic device;

[0021] After the main program of the electronic device enters the idle time of periodic operation, the method further includes:

[0022] Writing a standard check word into the image storage area;

[0023] Reading the content written in the image storage area to obtain a read value;

[0024] Comparing whether the standard check word and the read value are the same;

[0025] If the standard check word and the read value are the same, it is determined that no fault occurs in the image storage area;

[0026] If the standard check word and the read value are not the same, it is determined that a memory of the electronic device fails.

[0027] In a possible implementation manner of the first aspect, before writing the standard check word into the image storage area, the method further includes:

[0028] Acquire a first address in the image storage area, wherein the first address is a storage address of real-time image data detected by the electronic device in the next detection cycle;

[0029] The step of writing a standard check word into the image storage area comprises:

[0030] The standard check word is written into the first address in the image storage area.

[0031] In a possible implementation manner of the first aspect, the image processing model is a point cloud data processing model, and the point cloud data processing model includes a denoising model, a filtering model, and a point cloud completion model;

[0032] The using the current parameter value and the pre-stored image processing model to perform data processing on the pre-stored image data to obtain the current processing result of the pre-stored image data includes:

[0033] Inputting the current parameter value into the image processing model to obtain the denoising model, the filtering model and the point cloud completion model set with the current parameter value;

[0034] Performing denoising processing on the point cloud image data using the denoising model provided with the current parameter value to obtain first image data;

[0035] Performing filtering processing on the first image data using the filtering model provided with the current parameter value to obtain second image data;

[0036] The point cloud completion model provided with the current parameter value is used to perform point cloud completion processing on the second image data to obtain the current processing result.

[0037] In a possible implementation manner of the first aspect, before the main program of the electronic device enters the periodic operation, the method further includes:

[0038] When the electronic device is initialized, the pre-stored image data is processed using the image processing model and the initial parameter value of the image processing model stored in the dynamic storage area to obtain a reference processing result;

[0039] A reference check code of the code calculated using the check model.

[0040] In a second aspect, an embodiment of the present application provides an electronic device, wherein a memory in the electronic device includes a dynamic storage area, wherein the dynamic storage area stores parameter values ​​of parameters in an image processing model; the image processing model is used to perform data processing on pre-stored image data, and the electronic device further includes:

[0041] A parameter acquisition module, used for acquiring the current parameter value of the image processing model stored in the dynamic storage area after the main program of the electronic device enters the idle time of the periodic operation;

[0042] A data processing module, used to perform data processing on the pre-stored image data using the current parameter value and the pre-stored image processing model to obtain a current processing result of the pre-stored image data;

[0043] a parameter comparison module, used for comparing whether the current processing result is the same as a reference processing result, wherein the reference processing result is a standard result obtained by performing data processing on the pre-stored image data using the image processing model and the initial parameter values ​​of the image processing model stored in the dynamic storage area;

[0044] The result output module is used to determine that no failure occurs in the dynamic storage area if the current processing result is the same as the reference processing result.

[0045] In a third aspect, an embodiment of the present application provides an electronic device, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements any of the methods described in the first aspect when executing the computer program.

[0046] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method described in any one of the above-mentioned first aspects is implemented.

[0047] In a fifth aspect, an embodiment of the present application provides a computer program product, which, when executed on a terminal device, enables the terminal device to execute any of the methods described in the first aspect above.

[0048] The beneficial effect of the first aspect of the present application compared with the prior art is that the present application stores the parameter values ​​of the parameters in the image processing model in advance in the dynamic storage area. If the dynamic storage area does not fail, the stored parameter values ​​will not change. If the dynamic storage area fails, the stored parameter values ​​will change. Therefore, during the use of the electronic device, the present application uses the image processing model and the current parameter values ​​of the dynamic storage area to process the pre-stored image data, obtains the current processing result, and compares the current processing result with the reference processing result; if the current processing result is the same as the reference processing result, it is determined that the parameter value stored in the dynamic storage area has not changed, and then it is determined that the dynamic storage area has not failed, thereby achieving the effect of fault detection on the dynamic storage area.

[0049] It can be understood that the beneficial effects of the second to fifth aspects mentioned above can be found in the relevant description of the first aspect mentioned above, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0051] Figure 1 It is a flowchart of a method for detecting a memory failure provided by an embodiment of the present application;

[0052] Figure 2 It is a flowchart of a method for processing point cloud image data using an image processing model provided in an embodiment of the present application;

[0053] Figure 3 It is a flowchart of a static storage area fault detection method provided by an embodiment of the present application;

[0054] Figure 4 It is a flowchart of a method for detecting a fault in an image storage area provided by an embodiment of the present application;

[0055] Figure 5 is a flowchart of a method for detecting a memory failure provided by another embodiment of the present application;

[0056] Figure 6 is a structural schematic diagram of an electronic device provided by an embodiment of the present application;

[0057] Figure 7 It is a structural diagram of a terminal device provided in another embodiment of the present application. DETAILED DESCRIPTION

[0058] It should be understood that when used in the present specification and the appended claims, the term "comprising" indicates the presence of described features, wholes, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or combinations thereof.

[0059] It should also be understood that the term “and / or” used in the specification and appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes these combinations.

[0060] References to "one embodiment" or "some embodiments" etc. described in the specification of this application mean that one or more embodiments of the present application include specific features, structures or characteristics described in conjunction with the embodiment. Therefore, the phrases "in one embodiment", "in some embodiments", "in some other embodiments", "in some other embodiments", etc. appearing in different places in this specification do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways.

[0061] At present, data storage has been applied in various industries, such as automotive electronics, railway electronics, and avionics. The security and reliability of data storage are also receiving more and more attention.

[0062] In order to ensure the security and accuracy of the data stored in the memory, the memory can be tested for faults. If the memory is not faulty, the data in the memory can be determined to be safe; if the memory is faulty, the data in the memory is unsafe. Currently, the detection of the memory is relatively simple, and there are relatively few detection methods for the dynamic memory area.

[0063] Therefore, the present application proposes a method for detecting memory failures. The present application adopts online self-test and adopts different detection methods according to different storage areas in the memory, so as to achieve the purpose of accurately detecting each storage area.

[0064] Specifically, when the electronic device is in an offline state, the memory is first functionally divided to obtain a static storage area, a dynamic storage area, and an image storage area of ​​the memory. Among them, the static storage area mainly stores fixed codes, and the static storage area is a read-only area, that is, data can only be read from the static storage area, and data cannot be written to the static storage area. The dynamic storage area mainly refers to the stack area or the program data area. The dynamic storage area is a readable and writable area, and data can be read from the dynamic storage area, and data can also be written to the dynamic storage area; in addition, the dynamic storage area can store global variables, static variables, and local variables, etc. The local variables include the parameter values ​​of the parameters in the image processing model. The image processing model is used to perform data processing on the pre-stored image data, and the image processing model is a pre-set model. The image storage area is a readable and writable area, which is used to store real-time image data collected by the electronic device. The real-time image data can be point cloud image data and / or two-dimensional image data, etc.

[0065] For the static storage area in the memory, this application adopts a checksum detection method for fault detection; for the dynamic storage area, this application adopts a data processing model detection method for fault detection; for the image storage area, this application adopts a read-write test method for fault detection.

[0066] Next, combine Figure 1The memory failure detection method of the embodiment of the present application is described in detail.

[0067] Figure 1 A schematic flow chart of a memory failure detection method provided by the present application is shown, referring to Figure 1 , the fault detection method of the dynamic storage area is described in detail as follows:

[0068] S101, after the main program of the electronic device enters the idle time of the periodic operation, the current parameter value of the image processing model stored in the dynamic storage area is obtained.

[0069] In this embodiment, the main program of the electronic device can run periodically, and after a cycle of operation, the main program of the electronic device can enter idle time, that is, the time when the main program is not running. When the electronic device is a laser radar, the idle time is related to the operation cycle of the laser radar.

[0070] After the laser radar obtains a complete frame of point cloud data through the scanning device, the scanning device of the laser radar needs to return to the starting position to prepare for the next cycle of scanning. The time it takes for the scanning device to return to the starting position can be recorded as idle time.

[0071] For a laser radar that scans continuously or has no scanning device, there is no time for the scanning device to return to the starting position. The laser radar may stop transmitting and receiving for a detection cycle after a period of time. The idle time is a detection cycle in which the transmission and reception are stopped. The "period of time" mentioned above needs to be less than the FTTI (fault tolerant time interval) time to ensure the reliability and security of the memory data.

[0072] The parameter values ​​of the image processing model are stored in advance in a dynamic storage area of ​​the electronic device, and the parameter values ​​stored initially are recorded as initial parameter values.

[0073] Since the initial parameter values ​​of the image processing model are stored in the dynamic storage area, as time goes by, if the dynamic storage area does not fail, the initial parameter values ​​stored in the dynamic storage area will not change, and the current parameter values ​​obtained at the current time will be the same as the initial parameter values ​​initially stored; if the dynamic storage area fails, the initial parameter values ​​stored in the dynamic storage area will change, and the current parameter values ​​obtained at the current time will be different from the initial parameter values. Therefore, at the current time, it is necessary to obtain the current parameter values ​​of the image processing model from the dynamic storage area for subsequent calculations to obtain the processing results at the current time.

[0074] The parameter values ​​of the image processing model stored in the dynamic storage area are determined according to the image processing model, and different image processing models correspond to different parameter values.

[0075] S102: Perform data processing on the pre-stored image data using the current parameter value and the pre-stored image processing model to obtain a current processing result of the pre-stored image data.

[0076] In this embodiment, the pre-stored image data is defective image data designed for the image processing model, so that the image processing model can traverse all parameter values ​​in the image processing model during processing of the pre-stored image data. For example, the pre-stored image data may have defects such as missing data and noise.

[0077] If the pre-stored image data is point cloud image data, the corresponding image processing model is a point cloud data processing model. For example, the point cloud data processing model may include at least one of a denoising model, a filtering model, and a point cloud completion model; accordingly, data processing may include at least one of denoising processing, filtering processing, and point cloud completion processing.

[0078] If the pre-stored image data is two-dimensional image data, the corresponding image processing model is a two-dimensional data processing model, and the two-dimensional data processing model may include at least one of an image enhancement model, an image segmentation model, and an image classification model; accordingly, data processing may include at least one of image enhancement processing, image segmentation processing, and image classification processing.

[0079] S103, comparing whether the current processing result and the reference processing result are the same, wherein the reference processing result is a standard result obtained by processing the pre-stored image data using the image processing model and the initial parameter value of the image processing model stored in the dynamic storage area.

[0080] In this embodiment, the reference processing result may be obtained before the main program execution cycle is executed.

[0081] Before the main program is periodically run, it means: when the electronic device is in an offline state, or when the electronic device is in an initialization state. Before the main program is periodically run, the pre-stored image data is processed using the image processing model and the initial parameter values ​​stored in the dynamic storage area to obtain a reference processing result, and the reference processing result is used to measure whether the parameter value stored in the dynamic storage has changed.

[0082] In this embodiment, the reference processing result may also be calculated regularly at preset time intervals during the running of the main program.

[0083] Specifically, if the current processing result and the reference processing result both exist in the form of images, in order to more accurately determine whether the two images are the same, comparing whether the current processing result and the reference processing result are the same may include: calculating a first similarity between the current processing result and the reference processing result; if the similarity is greater than or equal to a first preset value, determining that the current processing result and the reference processing result are the same; if the similarity is less than the first preset value, determining that the current processing result and the reference processing result are not the same.

[0084] S104: If the current processing result is the same as the reference processing result, it is determined that no failure occurs in the dynamic storage area.

[0085] In this embodiment, if the current processing result is the same as the reference processing result, it is determined that the reference processing result can still be obtained after processing the pre-stored image data using the current parameter value, indicating that the current reference value is the same as the initial reference value, and finally it is determined that there is no fault in the dynamic storage area.

[0086] S105: If the current processing result is different from the reference processing result, it is determined that a memory of the electronic device fails.

[0087] In this embodiment, if the current processing result is different from the reference processing result, it is determined that the reference processing result cannot be obtained after processing the pre-stored image data using the current parameter value, indicating that the current reference value is different from the initial reference value, and it is determined that a fault occurs in the dynamic storage area.

[0088] In an embodiment of the present application, the parameter values ​​of the parameters in the image processing model are stored in the dynamic storage area in advance. If the dynamic storage area does not fail, the stored parameter values ​​will not change. If the dynamic storage area fails, the stored parameter values ​​will change. Therefore, during the use of the electronic device, the present application uses the image processing model and the current parameter values ​​of the dynamic storage area to process the pre-stored image data to obtain the current processing result, and uses the current processing result and the initial parameter values ​​used before the electronic device is operated to process the pre-stored image data to obtain a reference processing result for comparison; if the current processing result is the same as the reference processing result, it is determined that the parameter values ​​stored in the dynamic storage area have not changed, and then it is determined that the dynamic storage area has not failed, thereby achieving the effect of fault detection on the dynamic storage area.

[0089] like Figure 2 As shown, in a possible implementation, when the image processing model is a point cloud data processing model, and the point cloud data processing model includes a denoising model, a filtering model, and a point cloud completion model, the pre-stored image data is point cloud image data, the above step S102 may specifically include:

[0090] S1021, inputting the current parameter value into the image processing model to obtain the denoising model, the filtering model and the point cloud completion model set with the current parameter value.

[0091] Specifically, during the operation of the image processing model, the current parameter value is read to obtain the denoising model, the filtering model and the point cloud completion model set with the current parameter value.

[0092] S1022: Perform denoising processing on the point cloud image data using the denoising model set with the current parameter value to obtain first image data.

[0093] In this embodiment, the denoising model may be a distance-based denoising method, a normal vector-based denoising method, a clustering-based denoising method, or the like.

[0094] Among them, the distance-based denoising method: This method calculates the distance between each point in the point cloud and its surrounding adjacent points, and removes points whose distance is less than a certain threshold. The basis of this method is that noise points are often isolated or low-density points, and are far away from the surrounding points.

[0095] Normal-based denoising method: This method calculates the normal vector of each point in the point cloud and removes points whose angles between the normal vector direction and the surrounding neighboring points are less than a certain threshold. The basis of this method is that noise points are often protruding points on a plane or curved surface, and the normal vector direction is greatly different from that of the surrounding points.

[0096] Clustering-based denoising method: This method divides the points in the point cloud into different categories according to their spatial positions and attribute characteristics, and removes the categories with fewer points in the clustering results. The basis of this method is that noise points are often isolated or low-density points and will not cluster into one category with other points.

[0097] S1023: Filter the first image data using the filtering model set with the current parameter value to obtain second image data.

[0098] In this embodiment, the filtering model may be bilateral filtering, Gaussian filtering, conditional filtering, or the like.

[0099] Among them, bilateral filtering combines distance and spatial structure to remove noise, which is suitable for ordered point clouds. Gaussian filtering is suitable for point cloud data with normal distribution. Conditional filtering is filtering by setting filtering conditions. If the point cloud is within a certain range, it will be retained, and if it is not within a certain range, it will be discarded.

[0100] Performing filtering on the first image data can make the first image data more regular and smoother.

[0101] S1024: Perform point cloud completion processing on the second image data using the point cloud completion model set with the current parameter value to obtain the current processing result.

[0102] In this embodiment, point cloud completion is intended to generate a complete 3D point cloud based on the observed incomplete point cloud. The point cloud completion model may include a sampling model and a feature extraction model.

[0103] It should be noted that in actual use, the order of the above steps S1022 to S1024 can be set as needed, that is, the order of the above steps S1022 to S1024 can be swapped, for example, filtering processing is performed first, then denoising processing is performed, and finally point cloud completion processing is performed.

[0104] In a possible implementation, the electronic device can also use the verification model to perform fault detection on the static storage area. Figure 3 , a method for fault detection in a static storage area is described.

[0105] Specifically, after the main program of the electronic device enters the idle time of the periodic operation, the method further includes:

[0106] S201, obtaining the current code stored in the static storage area.

[0107] In this embodiment, since the code is stored in the static storage area before the electronic device is run, if the static storage area does not fail, the stored code will not change; if the static storage area fails, the stored code will change. Therefore, in order to calculate the check code of the static storage area at the current time, it is necessary to obtain the current code stored in the static storage area at the current time.

[0108] S202: Calculate a current verification code of the current code using a pre-stored verification model.

[0109] In this embodiment, the verification model may be a CRC (Cyclic Redundancy Check) verification model, an MD5 (Message-Digest algorithm 5) verification model, a Gray code verification model, a Hamming code verification model, or the like.

[0110] Specifically, the current code is input into the verification model to obtain the current verification code of the current code.

[0111] S203, comparing the current check code with a reference check code to see if they are the same, wherein the reference check code is a standard check code of the initial code stored in the static storage area calculated using the check model.

[0112] In this embodiment, the initial code is the code written into the static storage area before the electronic device is operated.

[0113] When the electronic device is in an offline state or in an initialization state, the reference check code of the initial code is calculated using the check model. Alternatively, the reference check code of the initial code is calculated using the check model during the running of the main program.

[0114] S204: If the current check code is the same as the reference check code, it is determined that no failure occurs in the static storage area.

[0115] In this embodiment, if the current check code is the same as the reference check code, it means that the current code in the static storage area is the same as the initial code, and therefore, it is determined that no failure occurs in the static storage area.

[0116] S205: If the current verification code is different from the reference verification code, it is determined that a memory of the electronic device fails.

[0117] In this embodiment, if the current check code is different from the reference check code, it means that the current code in the static storage area is different from the initial code, and therefore, it is determined that a failure occurs in the static storage area.

[0118] In the embodiment of the present application, the current check code of the current code is calculated using the check model, and the current check code is compared with the reference check code. If the current check code and the reference check code are the same, it is determined that the static storage area has not failed; if the current check code and the reference check code are not the same, it is determined that the memory of the electronic device has failed. The present application can determine whether the code in the static storage area has changed through the check code of the code, and then determine whether the static storage area has failed, thereby achieving the effect of fault detection on the static storage area.

[0119] In a possible implementation, the electronic device can also perform fault detection on the image storage area by reading and writing. Figure 4 , a method for fault detection in an image storage area is described.

[0120] Specifically, after the main program of the electronic device enters the idle time of the periodic operation, the method further includes:

[0121] S301, writing a standard check word into a first address in the image storage area.

[0122] In one embodiment, the first address is an image storage area of ​​real-time image data detected by the electronic device in the next detection cycle. The determination of the first address is related to the storage strategy.

[0123] Specifically, the storage method of the image storage area can be: output image data once every N frames (a complete frame of point cloud image data is obtained in one detection cycle); the storage address of the point cloud image data obtained in each detection cycle is preset. For example, the image storage area is divided into N sub-areas, and each sub-area stores one frame of point cloud image data. After the image data is output, the acquired real-time image data can be written and overwritten with the original data. At this time, the first address is the address of the sub-area corresponding to the next detection cycle in the image storage area.

[0124] Specifically, the storage method of the image storage area can also be: each frame of image data is output after it is completely acquired; since each detection point in the point cloud image data is not acquired in time sequence, the acquisition time is discrete, and the detection point at the end of the previous frame of point cloud image data has not been acquired, and the detection point at the beginning of the current frame of point cloud image data has been acquired. Therefore, the image storage area includes at least two sub-areas, the first frame of point cloud image data is stored in the first sub-area, and the second frame of point cloud image data is stored in the second sub-area. After the first frame of point cloud image data is completely acquired, it is output, and the first sub-area is released at this time, and the third frame of point cloud image data is stored in the first sub-area, and so on. At this time, the first address is the address of the sub-area corresponding to the next detection cycle in the image storage area, such as the second sub-area. The image storage area can also include three or more sub-areas, and the real-time image data is stored and output in a rolling output manner. Or when the image storage area includes three or more sub-areas, only the first sub-area and the second sub-area can be enabled, and the other sub-areas can be used as spare storage areas.

[0125] In this embodiment, the standard check word is a preset content, such as 0x55aa or 0xaa55.

[0126] S302, reading the content written in the image storage area to obtain a read value.

[0127] S303, comparing the standard check word and the read value to see if they are the same.

[0128] S304: If the standard check word and the read value are the same, it is determined that no fault occurs in the image storage area.

[0129] S305: If the standard check word and the read value are different, it is determined that a memory of the electronic device fails.

[0130] In the embodiment of the present application, a write and read operation is performed in the image storage area to determine whether the image storage area is faulty by comparing the written data with the read data. If the written data and the read data are the same, it is determined that there is no fault in the image storage area. If the written data and the read data are different, it is determined that the image storage area cannot correctly write or read data, and there is a fault in the image storage area. The present application realizes fault detection of the image storage area.

[0131] In a possible implementation manner, the method for determining the first address further includes:

[0132] Obtain a free address in the image storage area; determine the first address based on the free address and the character length of the standard check word, wherein the first address of the first address is the first address in the free address.

[0133] In this embodiment, after the main program runs for a cycle, the image storage area has stored the real-time image data obtained during the running of the main program, and the free address (address where the real-time image data is not stored) in the image storage area can be obtained. Since the first address of the free address will be used as the address for storing the real-time image data of the main program in the next running cycle, when determining the first address, starting from the first address of the free address, M consecutive free addresses can be used as the first address, so as to verify the image storage area to be used in the subsequent running process of the main program, M ≥ the number of characters of the standard verification word. In addition, since the image storage area is relatively large, the complete image storage area cannot be verified in a single free time. Therefore, in a single free time, the image storage area to be used in the next running cycle can be verified to determine whether the image storage area has a fault, thereby improving the availability and security of memory fault verification.

[0134] In another embodiment, the method for performing fault detection on the image storage area may further include:

[0135] S401, writing a standard check word into a second address in an image storage area, where the second address is an address corresponding to N-bit image data.

[0136] S402, read the content in the second address to obtain a read value.

[0137] S403, comparing the standard check word and the read value to see if they are the same.

[0138] S404: If the standard check word is the same as the read value, it is determined that no fault occurs in the image storage area.

[0139] S405: If the standard check word and the read value are not the same, it is determined that the memory of the electronic device fails.

[0140] S406, writing the N-bit image data into the second address.

[0141] like Figure 5 As shown, in a possible implementation, the memory failure detection method may further include:

[0142] S11, the electronic device is initialized.

[0143] In this embodiment, when the electronic device is initialized, the pre-stored image data can be processed using the image processing model and the initial parameter values ​​of the image processing model stored in the dynamic storage area to obtain a reference processing result; and a reference verification code of the initial code calculated using the verification model.

[0144] S12, the main program runs cyclically.

[0145] S13, after the main program of the electronic device enters the idle time of the periodic operation, the current check code of the current code in the static storage area is calculated using the check model.

[0146] Specifically, the method for calculating the current verification code please refer to the above steps S201 to S203, which will not be repeated here.

[0147] S14, comparing the current check code and the reference check code to see if they are the same.

[0148] S15, if the current check code is the same as the reference check code, the pre-stored image data in the dynamic storage area is processed using the image processing model to obtain a current processing result.

[0149] The method for calculating the current processing result please refer to the above steps S101 to S102, which will not be described in detail here.

[0150] S16, comparing the current processing result and the reference processing result to see if they are the same.

[0151] S17, if the current processing result is the same as the reference processing result, the standard check word is written into the first address and then the content of the first address is read to obtain a read value.

[0152] S18, compare the standard check word and the read value to see if they are the same.

[0153] S19: If the standard check word and the read value are the same, the electronic device continues to execute the above step S12.

[0154] S20, if the current check code is different from the reference check code, or the current processing result is different from the reference processing result, or the standard check word is different from the read value, it is determined that the memory fails.

[0155] The above fault detection of the image storage area can be exchanged in sequence with the fault detection of other storage areas. For example, the fault of the image storage area is checked first, then the fault of the static storage area is detected, and finally the fault of the dynamic storage area is detected.

[0156] It should be noted that, when it is determined in the above method that a memory failure occurs, the electronic device enters a safe state to ensure the safety of the electronic device.

[0157] Finally, taking an electronic device as a sensor as an example, the failure rates of electronic devices using the memory fault detection method of the present application and those not using the memory fault detection method of the present application are compared, as shown in Table 1 below.

[0158] Table 1 Comparison of failure rates of electronic devices using the memory fault detection method of the present application and those not using the memory fault detection method of the present application

[0159]

[0160] SPFM (Single Point Fault Metric) is a single point fault metric; LFM (Latent Fault Metric) is a latent (residual) fault metric; PMHF (Probabilistic Metric for random Hardware Failures) is a random hardware failure probability metric. FIT is the failure rate, which is the sum of the single point fault metric and the latent fault metric.

[0161] As shown in the table above, when the method of the present application is used, the SPFM of the electronic device is greater than the SPFM of the electronic device when the method of the present application is not used, the LFM of the electronic device when the method of the present application is used is greater than the LFM of the electronic device when the method of the present application is not used, and the PMHF of the electronic device when the method of the present application is used is less than the PMHF of the electronic device when the method of the present application is not used. Combined with product requirements, the use of the method of the present application can better meet product requirements.

[0162] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.

[0163] Corresponding to the memory failure detection method described in the above embodiment, Figure 6 A structural block diagram of an electronic device provided in an embodiment of the present application is shown. For ease of explanation, only the parts related to the embodiment of the present application are shown.

[0164] Reference Figure 6The electronic device 500 may include a dynamic storage area, in which parameter values ​​of parameters in the image processing model are stored; the image processing model is used to perform data processing on pre-stored image data, and the electronic device also includes: a parameter acquisition module 510, a data processing module 520, a parameter comparison module 530 and a result output module 540.

[0165] The parameter acquisition module 510 is used to acquire the current parameter value of the image processing model stored in the dynamic storage area after the main program of the electronic device enters the idle time of the periodic operation;

[0166] The data processing module 520 is used to perform data processing on the pre-stored image data using the current parameter value and the pre-stored image processing model to obtain a current processing result of the pre-stored image data;

[0167] a parameter comparison module 530, configured to compare whether the current processing result is identical to a reference processing result, wherein the reference processing result is a standard result obtained by processing the pre-stored image data using the image processing model and the initial parameter values ​​of the image processing model stored in the dynamic storage area;

[0168] The result output module 540 is used to determine that no failure occurs in the dynamic storage area if the current processing result is the same as the reference processing result.

[0169] In a possible implementation, the result output module 540 may be specifically used to:

[0170] If the current processing result is different from the reference processing result, it is determined that a memory of the electronic device fails.

[0171] In a possible implementation, the memory in the electronic device includes a static storage area, the static storage area stores codes, and the electronic device further includes:

[0172] A code acquisition module, used to acquire the current code stored in the static storage area;

[0173] A check code calculation module, used to calculate the current check code of the current code using a pre-stored check model;

[0174] A check code comparison module, used to compare whether the current check code is the same as a reference check code, wherein the reference check code is a standard check code of the initial code stored in the static storage area calculated using the check model;

[0175] A first result determination module, configured to determine that no failure has occurred in the static storage area if the current check code is the same as the reference check code;

[0176] The second result determination module is used to determine that a memory failure of the electronic device occurs if the current verification code is different from the reference verification code.

[0177] In a possible implementation, the memory in the electronic device includes an image storage area, and the image storage area is used to store real-time image data collected by the electronic device. The electronic device also includes:

[0178] A data writing module, used for writing a standard check word into the image storage area;

[0179] A data reading module, used for reading the content written in the image storage area to obtain a read value;

[0180] A data comparison module, used for comparing whether the standard check word and the read value are the same;

[0181] A third result determination module, configured to determine that no fault has occurred in the image storage area if the standard check word and the read value are the same;

[0182] The fourth result determination module is used to determine that a memory of the electronic device fails if the standard check word and the read value are different.

[0183] In a possible implementation, the data writing module may also be used to:

[0184] Acquire a first address in the image storage area, wherein the first address is an image storage area of ​​real-time image data detected by the electronic device in a next detection cycle;

[0185] Accordingly, the data writing module can also be used for:

[0186] The standard check word is written into the first address in the image storage area.

[0187] In a possible implementation, the image processing model is a point cloud data processing model, the point cloud data processing model includes a denoising model, a filtering model and a point cloud completion model, and the pre-stored image data is point cloud image data; the data processing module 520 can be specifically used for:

[0188] Inputting the current parameter value into the image processing model to obtain the denoising model, the filtering model and the point cloud completion model set with the current parameter value;

[0189] Performing denoising processing on the point cloud image data using the denoising model provided with the current parameter value to obtain first image data;

[0190] Performing filtering processing on the first image data using the filtering model provided with the current parameter value to obtain second image data;

[0191] The point cloud completion model provided with the current parameter value is used to perform point cloud completion processing on the second image data to obtain the current processing result.

[0192] In a possible implementation, the parameter acquisition module 510 is also connected to:

[0193] a first preprocessing module, configured to perform data processing on the pre-stored image data by using the image processing model and the initial parameter value of the image processing model stored in the dynamic storage area when the electronic device is initialized, to obtain a reference processing result;

[0194] The second preprocessing module is used to calculate a reference check code of the initial code using the check model.

[0195] It should be noted that the information interaction, execution process, etc. between the above-mentioned devices / units are based on the same concept as the method embodiment of the present application. Their specific functions and technical effects can be found in the method embodiment part and will not be repeated here.

[0196] The technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated in a processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned system can refer to the corresponding process in the aforementioned method embodiment, which will not be repeated here.

[0197] The present application also provides an electronic device, see Figure 7 The electronic device 600 may include: at least one processor 610, a memory 620, and a computer program stored in the memory 620 and executable on the at least one processor 610. When the processor 610 executes the computer program, the steps in any of the above-mentioned method embodiments are implemented, for example: Figure 1Steps S101 to S104 in the illustrated embodiment. Alternatively, when the processor 610 executes the computer program, the functions of each module / unit in the above-mentioned device embodiments are implemented, for example Figure 6 The functions of the parameter acquisition module 510 to the result output module 540 are shown.

[0198] Exemplarily, the computer program may be divided into one or more modules / units, one or more modules / units are stored in the memory 620, and executed by the processor 610 to complete the present application. The one or more modules / units may be a series of computer program segments capable of completing specific functions, and the program segments are used to describe the execution process of the computer program in the electronic device 600.

[0199] Those skilled in the art will understand that Figure 7 These are merely examples of electronic devices and do not constitute a limitation of the electronic device. The electronic device may include more or fewer components than those shown in the figure, or a combination of certain components, or different components, such as input and output devices, network access devices, buses, etc.

[0200] The processor 610 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or the processor may be any conventional processor, etc.

[0201] The memory 620 may be an internal storage unit of the terminal device, or an external storage device of the terminal device, such as a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, etc. The memory 620 is used to store the computer program and other programs and data required by the terminal device. The memory 620 may also be used to temporarily store data that has been output or is to be output.

[0202] The bus may be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, the bus in the drawings of the present application is not limited to only one bus or one type of bus.

[0203] The memory failure detection method provided in the embodiment of the present application can be applied to terminal devices such as computers, tablet computers, laptops, netbooks, personal digital assistants (PDAs), etc. The embodiment of the present application does not impose any restrictions on the specific type of terminal devices.

[0204] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0205] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.

[0206] In the embodiments provided in the present application, it should be understood that the disclosed terminal equipment, devices and methods can be implemented in other ways. For example, the terminal equipment embodiments described above are only schematic. For example, the division of the modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.

[0207] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0208] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0209] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present application implements all or part of the processes in the above-mentioned embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and when the computer program is executed by one or more processors, the steps of each of the above-mentioned method embodiments can be implemented.

[0210] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present application implements all or part of the processes in the above-mentioned embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and when the computer program is executed by one or more processors, the steps of each of the above-mentioned method embodiments can be implemented.

[0211] Similarly, as a computer program product, when the computer program product runs on a terminal device, the terminal device can implement the steps in the above-mentioned method embodiments when executing the computer program product.

[0212] The computer program includes computer program code, which may be in source code form, object code form, executable file or some intermediate form, etc. The computer readable medium may include: any entity or device capable of carrying the computer program code, recording medium, USB flash drive, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electric carrier signal, telecommunication signal and software distribution medium, etc. It should be noted that the content contained in the computer readable medium may be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, computer readable media do not include electric carrier signals and telecommunication signals.

[0213] The embodiments described above are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, a person skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such 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 application, and should all be included in the protection scope of the present application.

Claims

1. A method for detecting memory failure, characterized in that: The memory in the electronic device includes a dynamic storage area, wherein the parameter values ​​of the parameters in the image processing model are stored in the dynamic storage area; The image processing model is used to perform data processing on pre-stored image data; The method comprises: After the main program of the electronic device enters the idle time of the periodic operation, obtaining the current parameter value of the image processing model stored in the dynamic storage area; Using the current parameter value and the pre-stored image processing model, the pre-stored image data is processed to obtain a current processing result of the pre-stored image data; Comparing whether the current processing result is the same as a reference processing result, wherein the reference processing result is a standard result obtained by performing data processing on the pre-stored image data using the image processing model and the initial parameter value of the image processing model stored in the dynamic storage area; If the current processing result is the same as the reference processing result, it is determined that no failure occurs in the dynamic storage area.

2. The method according to claim 1, characterized in that After comparing whether the current processing result is the same as the reference processing result, the method further includes: If the current processing result is different from the reference processing result, it is determined that a memory of the electronic device fails.

3. The method according to claim 1, characterized in that The memory in the electronic device includes a static storage area, and the static storage area stores code; After the main program of the electronic device enters the idle time of periodic operation, the method further includes: Obtaining the current code stored in the static storage area; Calculating a current check code of the current code using a pre-stored check model; Comparing whether the current check code is the same as a reference check code, wherein the reference check code is a standard check code of the initial code stored in the static storage area calculated using the check model; If the current check code is the same as the reference check code, it is determined that no failure has occurred in the static storage area; If the current verification code is different from the reference verification code, it is determined that a memory failure of the electronic device occurs.

4. The method according to any one of claims 1 to 3, characterized in that The memory in the electronic device includes an image storage area, and the image storage area is used to store real-time image data collected by the electronic device; After the main program of the electronic device enters the idle time of periodic operation, the method further includes: Writing a standard check word into the image storage area; Reading the content written in the image storage area to obtain a read value; Comparing whether the standard check word and the read value are the same; If the standard check word and the read value are the same, it is determined that no fault occurs in the image storage area; If the standard check word and the read value are not the same, it is determined that a memory of the electronic device fails.

5. The method according to claim 4, characterized in that Before writing the standard check word into the image storage area, the method further includes: Acquire a first address in the image storage area, wherein the first address is an image storage area of ​​real-time image data detected by the electronic device in a next detection cycle; The step of writing a standard check word into the image storage area comprises: The standard check word is written into the first address in the image storage area.

6. The method according to any one of claims 1 to 3, characterized in that: The image processing model is a point cloud data processing model, the point cloud data processing model includes a denoising model, a filtering model and a point cloud completion model, and the pre-stored image data is point cloud image data; The using the current parameter value and the pre-stored image processing model to perform data processing on the pre-stored image data to obtain the current processing result of the pre-stored image data includes: Inputting the current parameter value into the image processing model to obtain the denoising model, the filtering model and the point cloud completion model set with the current parameter value; Performing denoising processing on the point cloud image data using the denoising model provided with the current parameter value to obtain first image data; Performing filtering processing on the first image data using the filtering model provided with the current parameter value to obtain second image data; The point cloud completion model provided with the current parameter value is used to perform point cloud completion processing on the second image data to obtain the current processing result.

7. The method according to claim 3, characterized in that Before the main program of the electronic device enters the cycle operation, the method further includes: When the electronic device is initialized, the pre-stored image data is processed using the image processing model and the initial parameter value of the image processing model stored in the dynamic storage area to obtain a reference processing result; A reference check code of the initial code calculated using the check model.

8. An electronic device, characterized in that: The memory in the electronic device includes a dynamic storage area, wherein the parameter values ​​of the parameters in the image processing model are stored in the dynamic storage area; The image processing model is used to process pre-stored image data, and the electronic device further includes: A parameter acquisition module, used for acquiring the current parameter value of the image processing model stored in the dynamic storage area after the main program of the electronic device enters the idle time of the periodic operation; A data processing module, used to perform data processing on the pre-stored image data using the current parameter value and the pre-stored image processing model to obtain a current processing result of the pre-stored image data; a parameter comparison module, used for comparing whether the current processing result is the same as a reference processing result, wherein the reference processing result is a standard result obtained by performing data processing on the pre-stored image data using the image processing model and the initial parameter values ​​of the image processing model stored in the dynamic storage area; The result output module is used to determine that no failure occurs in the dynamic storage area if the current processing result is the same as the reference processing result.

9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the method according to any one of claims 1 to 7 is implemented.

10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.