Sensor data processing method, apparatus, electronic device, and storage medium
The method and device improve sensor data processing in electric power steering systems by accurately determining sensor performance through automated sampling and trend analysis, enhancing accuracy and efficiency.
Patent Information
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- SAIC GM WULING AUTOMOBILE CO LTD
- Filing Date
- 2024-12-19
- Publication Date
- 2026-04-15
AI Technical Summary
The accuracy and efficiency of manually selecting N sensor input and output values for determining sensor performance in electric power steering systems are low due to the complexity of organizing and sorting sensor datasets into tables.
A method and device for determining N sensor input sampling values and corresponding output values by acquiring a sensor dataset, identifying adjacent sensor output values, and distinguishing between positive and negative strokes based on trend analysis, without manual operations.
This approach enhances the accuracy and efficiency of determining sensor performance data, ensuring higher precision and reduced computational complexity.
Smart Images

Figure 2026512195000001_ABST
Abstract
Description
Detailed Description of the Invention
[0001] (Related Application) This application claims priority to a Chinese patent application filed with the China National Intellectual Property Administration on January 29, 2024, with an application number of CN202410122441.2 and an application title of "Sensor Data Processing Method, Device, Electronic Device, and Storage Medium", and incorporates all of its content herein by reference.
Technical Field
[0002] This application relates to the field of sensor technology, and more specifically, to a sensor data processing method, device, electronic device, and storage medium.
Background Art
[0003] A sensor is a device that directly senses what is being measured and outputs an electrical signal or other signal that has a predetermined relationship with what is being measured. In the actual use process of a vehicle, there are sensors that collect related signals for the vehicle's Electric Power Steering System (EPS). As an important device of the electric power steering system, the quality of the sensor directly determines the quality of the electric power steering system, so related analysis of the sensor performance is required. Generally, analysis of the sensor performance is performed from the correspondence curve between the sensor input value and the sensor output value. To determine this correspondence curve between the sensor input value and the sensor output value, it is necessary to determine the corresponding data set of the sensor input value and the sensor output value.
[0004] In the prior art, after receiving the sensor output waveform and the sensor input waveform and performing related processing on them, a sensor data set of a set of sensor output values and the corresponding sensor input values can be determined. This sensor data set is organized in a table, sorted with respect to the sensor input value and the corresponding sensor output value, N sensor input values and the corresponding sensor output values are uniformly selected, and finally N sampling data are determined.
[0005] However, if the sensor dataset is organized and sorted into a table, and N sensor input values and their corresponding sensor output values are manually selected, there is a risk that the accuracy of the determined N sample data will be relatively low, and the efficiency of the process for determining the N sample data will be relatively low.
[0006] Furthermore, the information disclosed in the background art portion of this application is intended solely to enhance the overall understanding of the background art of this application, and should not be considered to acknowledge or imply in any way that this information is prior art already known to those skilled in the art. [Overview of the Initiative] [Problems that the invention aims to solve]
[0007] In view of this, this application provides a sensor data processing method, apparatus, electronic device, and storage medium to help solve the problem in the prior art where, when sensor datasets are organized and sorted in a table and N sensor input values and corresponding sensor output values are manually selected, the accuracy of the N final sampled data is relatively low, and the efficiency of the process for determining the N final sampled data is relatively low. [Means for solving the problem]
[0008] In a first aspect, an embodiment of the present application provides a sensor data processing method, the sensor data processing method is A step of acquiring a sensor dataset, wherein the sensor dataset includes M sensor data, and each sensor data includes one sensor input value and one sensor output value. A step of determining N sensor input sampling values, wherein M > N > 1, The step of determining a sensor output sampling value corresponding to each sensor input sampling value in the sensor dataset based on each sensor input sampling value, and obtaining N sampling data, is included. The sensor output sampling value is a sensor output value that corresponds to a sensor input value adjacent to the sensor input sampling value in the sensor dataset.
[0009] In one possible embodiment, after acquiring the sensor dataset, the sensor data processing method is: This further includes determining the positive stroke sensor data and the negative stroke sensor data in the aforementioned sensor dataset.
[0010] In one possible embodiment, determining the positive stroke sensor data and negative stroke sensor data in the sensor dataset is: This includes determining the positive stroke sensor data and negative stroke sensor data in the sensor dataset based on the trend of changes in the sensor output values in the sensor dataset.
[0011] In one possible embodiment, determining the positive stroke sensor data and negative stroke sensor data in the sensor dataset based on the trend of change in the sensor output values in the sensor dataset is: In the aforementioned sensor dataset, sensor data in which the sensor output value is in an increasing interval is determined to be positive stroke sensor data, This includes determining, in the aforementioned sensor dataset, that sensor data in which the sensor output value is in a gradually decreasing interval is negative stroke sensor data.
[0012] In one possible embodiment, determining the positive stroke sensor data and negative stroke sensor data in the sensor dataset based on the trend of change in the sensor output values in the sensor dataset is: In the aforementioned sensor dataset, sensor data whose sensor output value is in an increasing interval is determined to be negative stroke sensor data. This includes determining, in the aforementioned sensor dataset, that sensor data in which the sensor output value is in a gradually decreasing interval is positive stroke sensor data.
[0013] In one possible embodiment, based on each of the sensor input sampling values, a sensor output sampling value corresponding to each of the sensor input sampling values in the sensor dataset is determined, and N sampling data are obtained. Based on each of the aforementioned sensor input sampling values, the positive stroke sensor output sampling values and negative stroke sensor output sampling values corresponding to each of the aforementioned sensor input sampling values are determined in the sensor dataset, and N positive stroke sampling data and N negative stroke sampling data are obtained. The positive stroke sensor output sampling value is a positive stroke sensor output value corresponding to a positive stroke sensor input value adjacent to the sensor input sampling value in the sensor dataset, and the negative stroke sensor output sampling value is a negative stroke sensor output value corresponding to a negative stroke sensor input value adjacent to the sensor input sampling value in the sensor dataset.
[0014] In one possible embodiment, the minimum and maximum values among the N sensor input sampling values are the minimum and maximum values of the sensor range, respectively.
[0015] In one possible embodiment, the difference between any two adjacent sensor input sampling values in N sensor input sampling values is equal.
[0016] In a second aspect, an embodiment of the present application provides a sensor data processing device, the sensor data processing device includes a sensor data set acquisition module, a sensor input sampling value determination module, and a sampling data acquisition module. The sensor data set acquisition module is used to acquire a sensor data set, and the sensor data set includes M sensor data, each of which includes one sensor input value and one sensor output value. The aforementioned sensor input sampling value determination module is used to determine N sensor input sampling values, where M>N>1. The sampling data acquisition module is used to acquire N sampling data by determining the sensor output sampling value corresponding to each sensor input sampling value in the sensor dataset based on each sensor input sampling value. The sensor output sampling value is a sensor output value that corresponds to a sensor input value adjacent to the sensor input sampling value in the sensor dataset.
[0017] In a third aspect, an embodiment of the present application provides an electronic device comprising a processor, memory, and a computer program. The computer program is stored in the memory, and the computer program includes instructions, and when the instructions are executed by the processor, the electronic device performs the method according to any one of the first embodiments.
[0018] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium containing a program to be stored in it, and when the program is executed, the computer-readable storage medium controls the device on which the computer-readable storage medium is located to perform the method described in any one of the first aspects. [Effects of the Invention]
[0019] In an embodiment of the present application, the sensor data processing device acquires a data set of sensors and determines N sensor input sampling values. At the same time, the sensor data processing device further determines, based on each sensor input sampling value, a sensor output sampling value corresponding to each sensor input sampling value in the sensor data set, and acquires N sampling data. Since this process does not involve complicated manual operations, the accuracy of the finally determined N sampling data is relatively high, and the efficiency of the process of determining the N sampling data is relatively high.
Brief Description of the Drawings
[0020] [Figure 1] It is a schematic diagram of an application scenario of EPS provided by such a technology. [Figure 2] It is a schematic flowchart of a sensor data processing method provided by an embodiment of the present application. [Figure 3] [[ID=!4]]It is a schematic diagram of an application scenario of a sensor data processing device provided by such a technology. [Figure 4] It is a schematic flowchart of another sensor data processing method provided by an embodiment of the present application. [Figure 5] It is a schematic structural diagram of a sensor data processing device provided by an embodiment of the present application. [Figure 6] It is a schematic structural diagram of another sensor data processing device provided by an embodiment of the present application. [Figure 7] It is a schematic structural diagram of an electronic device provided by an embodiment of the present application.
Modes for Carrying Out the Invention
[0021] To more clearly explain the technical solutions of the embodiments of the present application, the drawings necessary for the embodiments are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For those skilled in the art, other drawings can be obtained based on these drawings without creative labor. To better understand the technical proposal of this application, embodiments of this application will be described in detail below with reference to the attached drawings. It should be made clear that the embodiments described herein represent only a selection of embodiments, not all embodiments. All other embodiments obtained by a person skilled in the art without creative work based on the embodiments of this application shall be within the scope of protection of this application. The terms used in the embodiments of this application are for the sole purpose of describing specific embodiments and are not intended to limit this application. The singular forms “one kind,” “the said,” and “the said” used in the embodiments of this application and in the appended claims are also intended to include plural forms unless the context clearly indicates otherwise. It is important to understand that the terms "and / or" as used herein refer only to the relationship describing the related objects, and that there may be three types of relationships. For example, A and / or B can refer to three cases: A existing alone, A and B existing together, and B existing alone. Also, the character " / " in the text generally indicates that the preceding and following related objects are in an "or" relationship.
[0022] An electric power steering system is a power steering system that directly provides assist torque using a motor. During actual vehicle use, each sensor collects the steering wheel torque and steering wheel angle applied by the driver to the steering wheel, and transmits the steering wheel angle to the EPS. The EPS calculates the assist torque based on the steering wheel torque and steering wheel angle, converts it into a current command for the assist motor, and controls the assist motor to generate the corresponding assist torque. This assist torque is amplified by a gear reduction mechanism and then acts on the steering. Ultimately, it helps the driver overcome the steering resistance moment and enables the vehicle to steer.
[0023] To facilitate understanding, the following will be explained in detail with reference to drawings and specific examples.
[0024] Figure 1 is a schematic diagram of an application scenario for EPS provided by this technology. As shown in Figure 1, this application scenario includes a steering wheel 101, an electric power steering system 102, a steering shaft 103, a rack and pinion steering gear 104, and a tire 105. Here, the electric power steering system 102 specifically includes an electronic control unit (ECU) 1021, a sensor 1022, an assist motor 1023, and a gear reduction mechanism 1024.
[0025] As shown in Figure 1, the steering wheel 101 controls the steering of the tires 105 by the steering shaft 103 and the rack and pinion steering gear 104, the sensor 1022 is used to collect sensor signals on the steering shaft 103, the ECU 1021 outputs a corresponding assist motor control command based on the received sensor signals, and the assist motor 1023 applies assist torque to the steering shaft 103 by applying assist force to the gear reduction mechanism 1024, thereby assisting the rotation of the steering shaft 103.
[0026] In actual application, when the driver rotates the steering wheel 101, the steering wheel 101 rotates the steering shaft 103, and at this time, the sensor 1022 transmits the sensor signal of the steering shaft 103 that it has collected to the ECU 1021. Based on the received sensor signal, the ECU 1021 controls the assist motor 1023 to rotate the gear reduction mechanism 1024, and further applies assist force to the rotation of the steering shaft 103, and finally drives the rack and pinion steering gear 104 to control the steering of the tires.
[0027] Figure 1 is merely an illustrative description of an application scenario relating to the embodiments of this application and does not limit the scope of protection of this application. Furthermore, to ensure that it is clear that sensor 1022 is merely an illustrative description, and this sensor 1022 may specifically be a torque sensor, an angle sensor, or a torque-angle sensor (a torque-angle sensor being an integration of a torque sensor and an angle sensor), and this application does not specifically limit the type of sensor.
[0028] To understand this, sensors are a crucial component of electric power steering systems, and their performance directly determines the overall performance of the system. Therefore, a correlation analysis of sensor performance is necessary. It is common practice to analyze sensor performance using a correspondence curve between sensor input and output values. To determine this correspondence curve, it is necessary to determine a set of corresponding data points for sensor input and output values.
[0029] In conventional technology, sensor output waveforms and sensor input waveforms are received, and after performing related processing, a sensor dataset consisting of a sensor output value and a corresponding sensor input value can be determined. This sensor dataset is organized into a table, sorted by sensor input value and corresponding sensor output value, and N sensor input values and corresponding sensor output values are uniformly selected to finally determine N sample data.
[0030] For example, if the sensor that needs to be performance tested is an angle sensor, the organized sensor dataset is shown in Table 1. To make it easier to understand, six sensor input values and corresponding sensor output values are equally selected as (0°, 0.1°), (179.5°, 180.2°), (360°, 360.8°)...(1080.4°, 1079.6°) to form six sample data sets. Here, the N sample data sets are represented in the form of coordinate points, where the left side is the angle sensor input value and the right side is the angle sensor output value, i.e., (sensor input value, sensor output value).
[0031] [Table 1]
[0032] Of course, those skilled in the art may, depending on their actual needs, equally select a different number of sensor input values and corresponding sensor output values to construct N sampled data. For example, if there is a relatively high requirement for the accuracy of the correspondence curve between the fitted sensor input values and sensor output values, more sensor input values and corresponding sensor output values may be selected to construct N sampled data. Conversely, if the computational level of the sensor data processing device is relatively low and there is a relatively high requirement for efficiency, fewer sensor input values and corresponding sensor output values may be selected to construct N sampled data. This application is not limited to these exceptions.
[0033] However, since the sensor dataset is organized and sorted into a table, and N sensor input values and their corresponding sensor output values are manually selected, there is a risk that the accuracy of the determined N sample data will be relatively low, and the efficiency of the sampling data selection process will be relatively low. To address the above problem, in the embodiment of this application, the sensor data processing device acquires a sensor dataset and determines N sensor input sampling values. Simultaneously, the sensor data processing device acquires N sampling data by further determining the sensor output sampling value corresponding to each sensor input sampling value in the sensor dataset based on each sensor input sampling value. Since this process does not involve complex manual operations, the accuracy of the N sampling data ultimately determined is relatively high, and the efficiency of the process of determining the N sampling data is relatively high. Specifically, this will be described in detail below with reference to the drawings and specific embodiments.
[0034] Figure 2 is a schematic flowchart of a sensor data processing method provided by one embodiment of this application. As shown in Figure 2, it specifically includes the following steps. Step S201 involves acquiring the sensor dataset. In the embodiments of this application, the sensor data processing device acquires a sensor dataset containing M sensor data, where each sensor data contains one sensor input value and one sensor output value. As can be understood, the sensor dataset contains M sensor input values and a sensor output value corresponding to each sensor input value. In actual applications, the sensor data processing device receives the original sensor dataset, so it is necessary to perform related processing on the original sensor dataset to obtain the sensor dataset. To clarify the explanation further, this application provides more application scenarios for the sensor data processing device. Specifically, this will be described in detail below with reference to the drawings and specific embodiments.
[0035] Figure 3 is a schematic diagram of an application scenario for the sensor data processing device provided by this technology. Figure 3 shows a motor module 301, a sensor 302, a sensor data acquisition device 303, and a sensor data processing device 304. Here, the motor module 301 is electrically connected to the sensor data acquisition device 303, the sensor 302 is used to acquire data from the motor module 301, the sensor 302 is electrically connected to the sensor data acquisition device 303, and the sensor data acquisition device 303 is electrically connected to the sensor data processing device 304.
[0036] In actual applications, the sensor collects data on the motor module's related operation and outputs the collected sensor output signal. The sensor data acquisition device receives the sensor output signal from the sensor and the sensor input signal transmitted from the motor module. The sensor data acquisition device receives the sensor input signal and the sensor output signal, performs related processing on the sensor input signal and the sensor output signal to generate original sensor input data and original sensor output data corresponding to the sensor input signal and the sensor output signal, respectively. Subsequently, the generated original sensor input data and original sensor output data, i.e., the original sensor dataset, is transmitted to the sensor data processing device, which then acquires the sensor dataset based on the original sensor dataset.
[0037] The sensor output signal and sensor input signal are typically pulse width modulation (PWM) signals, while the sensor original dataset consists of the corresponding sensor original input data and sensor original output data. As can be understood, the sensor output signal and sensor input signal are analog signals, while the sensor original input data and sensor original output data are digital signals. As can be understood, in this case, the "sensor original input data" and "sensor original output data" are intermediate quantities, and their units are not the corresponding torque units or angle units. Therefore, the sensor data processing device can perform relevant processing on the sensor original dataset and acquire the sensor dataset.
[0038] Of course, in one possible embodiment, the data transmitted from the sensor data acquisition device to the sensor data processing device is already processed sensor data, and this application is not limited thereto. In one possible embodiment, the sensor corresponding to the "sensor data set" described above may be a torque angle sensor. Of course, it may be a torque sensor or an angle sensor, and this application does not specifically limit it.
[0039] In step S202, N sensor input sampling values are determined. In the embodiments of this application, N sensor input sampling values are determined, where M > N > 1. To make it clear, the number of determined sensor input sampling values is less than the number of sensor input or sensor output values in the sensor data. This is because if the number of sensor input sampling values is greater than the number of sensor input or sensor output values in the sensor data, there will inevitably be cases where different sensor input sampling values correspond to the same sensor output value in the data determined based on the sensor input sampling values. This reduces the accuracy of the determined N sampling data and further affects the performance analysis of the sensor.
[0040] In one possible embodiment, six sensor input sampling values are determined. Of course, those skilled in the art may determine other numbers of sensor input sampling values depending on their actual needs. For example, more sensor input sampling values may be selected if there is a relatively high requirement for the accuracy of the fitted correspondence curve, or fewer sensor input sampling values may be selected if the computational level of the sensor data processing device is relatively low and there is a relatively high requirement for efficiency. This application is not limited to these cases.
[0041] In one possible embodiment, N sensor input sampling values are determined in response to a relevant operation triggered by the user. To understand this, the user can input N sensor input sampling values into the sensor data processing device. Exemplaryly, the user can input six torque sensor input sampling values, namely 0 N·M, 3 N·M, 6 N·M, 9 N·M, 12 N·M, and 15 N·M, into the sensor data processing device, and similarly, the user can input seven angle sensor input sampling values, namely 0°, 180°, 360°, 540°, 720°, 900°, and 1080°, into the sensor data processing device.
[0042] In one possible embodiment, the sensor input sampling values are pre-stored, and after acquiring a sensor dataset, the sensor data processing device determines the pre-stored sensor input sampling values based on the type of sensor dataset. Exemplary examples include pre-stored torque sensor output sampling values of 0 N·M, 3 N·M, 6 N·M, 9 N·M, 12 N·M, and 15 N·M, and pre-stored angle sensor output sampling values of 0°, 180°, 360°, 540°, 720°, 900°, and 1080°. After acquiring a torque sensor dataset, the sensor data processing unit determines, based on the type of the sensor dataset, that the pre-stored sensor input sampling values are 0 N·M, 3 N·M, 6 N·M, 9 N·M, 12 N·M, and 15 N·M. Similarly, after acquiring an angle sensor dataset, the sensor data processing unit determines, based on the type of the sensor dataset, that the pre-stored sensor input sampling values are 0°, 180°, 360°, 540°, 720°, 900°, and 1080°.
[0043] In one possible embodiment, the minimum and maximum values in the N sensor input sampling values are the minimum and maximum values of the sensor range, respectively. For example, if the range of one angle sensor is [0°, 1080°], the minimum and maximum values in the determined N sensor input sampling values are 0° and 1080°, respectively. Similarly, if the range of one torque sensor is [0N·M, 15N·M], the minimum and maximum values in the determined N sensor input sampling values are 0N·M and 15N·M, respectively.
[0044] To make it clear, in the embodiments of this application, the minimum and maximum values of the N sensor input sampling values are set as the minimum and maximum values of the sensor range, respectively, thereby maximizing the acquisition of data in the sensor dataset, further enriching the data information contained in the determined N sampling data, and ultimately ensuring that these N sampling data better reflect the relevant performance of the sensor.
[0045] In one possible embodiment, the difference between any two adjacent sensor input sampling values in N sensor input sampling values is equal, i.e., the sensor input sampling values are uniformly distributed. Exemplarily, when setting six torque sensor input sampling values, they could be 0 N·M, 3 N·M, 6 N·M, 9 N·M, 12 N·M, and 15 N·M; similarly, when setting seven angle sensor input sampling values, they could be 0°, 180°, 360°, 540°, 720°, 900°, and 1080°. This application is not particularly limited thereto.
[0046] To make it clear, in the embodiments of this application, by uniformly setting N sensor input sampling values, the determined N sampling data can carry information from a larger sensor dataset, and furthermore, these N sampling data can better reflect the relevant performance of the sensors.
[0047] In step S203, based on each sensor input sampling value, the sensor output sampling value corresponding to each sensor input sampling value in the sensor dataset is determined, and N sampling data are obtained. In the embodiment of this application, the sensor data processing device determines a sensor output sampling value corresponding to each sensor input sampling value in the sensor dataset based on each sensor input sampling value, and acquires N sampling data. Here, the sensor output sampling value is the sensor output value corresponding to the sensor input value adjacent to the sensor input sampling value in the sensor dataset.
[0048] To make it easier to understand, if a sensor input value similar to the sensor input sampling value exists in the sensor dataset, the determined sensor output sampling value is the sensor output value corresponding to the sensor input sampling value similar to the sensor input sampling value in the sensor dataset. If a sensor input value similar to the sensor input sampling value does not exist in the sensor dataset, the sensor output sampling value is set to the sensor output value corresponding to the sensor input value adjacent to the sensor input sampling value in the sensor dataset, depending on the magnitude of the numerical value.
[0049] Generally, if no sensor input value in the sensor dataset is identical to the sensor input sampling value, each sensor input sampling value will be adjacent to two sensor input values. In one possible embodiment, the sensor output value corresponding to the sensor input value that is closer in distance to the sensor input sampling value among the two sensor input values is set as the sensor output sampling value.
[0050] For example, if no sensor input value exists in the sensor dataset that is identical to the sensor input sampling value, then the sensor input sampling value is 180°. Depending on the magnitude of the value, the two adjacent sensor input values are 180.1° and 179.8°, and the sensor output value corresponding to the sensor input value of 180.1° is selected as the sensor output sampling value.
[0051] To make it clear, the "sampling data" described above includes one sensor input sampling value and a sensor output sampling value corresponding to the sensor input sampling value. Through the sensor data processing method described above, i.e., steps S201 to S203, N sampling data can ultimately be obtained. Here, N sampling data constitutes one set of sample sampling data.
[0052] In one possible embodiment, to ensure that the sensor has more accurate sample sampling data, the sensor data processing method is typically repeated multiple times, i.e., steps S201 to S203 are executed 3 to 5 times, thereby determining 3 to 5 sample sampling data. As can be understood, by performing an average calculation on the 3 to 5 sample sampling data, the determined sample sampling data becomes more accurate.
[0053] In the embodiments of this application, the sensor data processing device acquires a sensor dataset and determines N sensor input sampling values. Simultaneously, the sensor data processing device acquires N sampling data by determining the sensor output sampling value corresponding to each sensor input sampling value in the sensor dataset based on each sensor input sampling value. Since this process does not involve complex manual operations, the accuracy of the N sampling data ultimately determined is relatively high, and the efficiency of the process of determining the N sampling dataset is relatively high.
[0054] In practical applications, when analyzing the relevant performance of a sensor, it is necessary to distinguish between positive stroke and negative stroke, and therefore it is necessary to acquire positive stroke sensor data and negative stroke sensor data. In the embodiments of this application, in order to acquire positive stroke sensor data and negative stroke sample sensor data, after acquiring a sensor dataset, the sensor dataset can be divided into positive stroke sensor data and negative stroke sensor data according to relevant rules. Specifically, this will be described in detail below with reference to the drawings and specific embodiments.
[0055] To make it easier to understand, using the example of an angle sensor collecting angle information of the steering wheel, the positive stroke refers to the process of controlling the steering wheel to rotate it left or right from its initial position, and the negative stroke refers to the process of controlling the steering wheel to return it to its initial position. Here, the initial position is the position of the steering wheel when the vehicle is traveling in a straight line.
[0056] Figure 4 is a schematic flowchart of another sensor data processing method provided by one embodiment of the present application. As shown in Figure 4, it further includes the following steps based on Figure 2. In step S401, the positive stroke sensor data and negative stroke sensor data in the sensor dataset are determined. In the embodiments of this application, after acquiring a sensor dataset, the positive stroke sensor data and negative stroke sensor data in the sensor dataset are determined. Specifically, after acquiring a sensor dataset, the positive stroke sensor data and negative stroke sensor data in the sensor dataset are determined based on the trend of change in the sensor output values in the sensor dataset.
[0057] In one possible embodiment, sensor data in the sensor dataset where the sensor output value is in an increasing interval is determined as positive stroke sensor data, and sensor data in the sensor dataset where the sensor output value is in a decreasing interval is determined as negative stroke sensor data. Specifically, in the embodiment of this application, after acquiring one sensor output value, the acquired sensor output value is compared with the previously acquired sensor output value. If the acquired sensor output value is greater than the previously acquired sensor output value, the sensor output value acquired at this point and the sensor input value corresponding to this sensor output value are positive stroke sensor data. If the acquired sensor output value is less than the previously acquired sensor output value, the sensor output value acquired at this point and the sensor input value corresponding to this sensor output value are negative stroke sensor data.
[0058] To make it easier to understand, generally, the waveform of the sensor output value over time resembles a sine wave, and when a dip value of the sensor output value is identified, it marks the start of a positive stroke, and when a peak value of the sensor output value is identified, it marks the start of a negative stroke. For example, the peak value of the sensor output value is A, and the dip value of the sensor output value is B. If the sensor output value is identified as A and the next determined sensor output value is less than A, it is determined that a negative stroke has started at this time, and the determined sensor output value and the sensor input value corresponding to this sensor output value are negative stroke sensor data. If the sensor output value is identified as B and the next determined sensor output value is greater than B, it is determined that a positive stroke has started at this time, and the determined sensor output value and the sensor input value corresponding to this sensor output value are positive stroke sensor data.
[0059] To make it easier to understand, the peak and dip values mentioned above correspond to the maximum and minimum values of the sensor's full-range output, respectively. Note that since the waveform of the sensor output over time is actually a digital signal, there may be no dip or peak values during the conversion process between positive and negative strokes. Therefore, a first preset value close to the maximum output value of the sensor's full range can be set, and a second preset value close to the minimum output value of the sensor's full range can be set. For example, if the peak value of the sensor output is 6° and the dip value is -6°, the first preset value can be set to 5.8° and the second preset value to -5.8°.
[0060] Specifically, if the sensor output value is identified as being the first preset value or greater than the first preset value, it is determined whether the next sensor output value is less than the current sensor output value. If the next sensor output value is identified as being less than the current sensor output value, it is determined that a negative stroke will begin at this time. The sensor output value determined at this time and the sensor input value corresponding to this sensor output value are the negative stroke sensor data. If the sensor output value is identified as being the second preset value or less than the second preset value, it is determined whether the next sensor output value is greater than the current sensor output value. If the next sensor output value is identified as being greater than the current sensor output value, it is determined that a positive stroke will begin at this time. The sensor output value determined at this time and the sensor input value corresponding to this sensor output value are the positive stroke sensor data.
[0061] Of course, in one possible embodiment, sensor data in the sensor dataset where the sensor output value is in a decreasing interval is determined as positive stroke sensor data, and sensor data in the sensor dataset where the sensor output value is in an increasing interval is determined as negative stroke sensor data. Specifically, in the embodiment of this application, after acquiring one sensor output value, the acquired sensor output value is compared with the previously acquired sensor output value. If the acquired sensor output value is greater than the previously acquired sensor output value, the sensor output value acquired at this point and the sensor input value corresponding to this sensor output value are negative stroke sensor data. If the acquired sensor output value is less than the previously acquired sensor output value, the sensor output value acquired at this point and the sensor input value corresponding to this sensor output value are positive stroke sensor data.
[0062] To make it easier to understand, generally, the waveform of the sensor output value over time resembles a sine wave. When a dip value in the sensor output value is identified, it marks the start of a negative stroke, and when a peak value in the sensor output value is identified, it marks the start of a positive stroke. For example, the peak value of the sensor output value is A, and the dip value of the sensor output value is B. If the sensor output value is identified as A and the next determined sensor output value is less than A, it is determined that a positive stroke has started at this time, and the sensor output value determined at this time and the sensor input value corresponding to this sensor output value are the positive stroke sensor data. If the sensor output value is identified as B and the next determined sensor output value is greater than B, it is determined that a negative stroke has started at this time, and the sensor output value determined at this time and the sensor input value corresponding to this sensor output value are the negative stroke sensor data.
[0063] To make it easier to understand, the peak and dip values mentioned above correspond to the maximum and minimum values of the sensor's full-range output, respectively. Note that since the waveform of the sensor output over time is actually a digital signal, there may be no dip or peak values during the conversion process between positive and negative strokes. Therefore, a first preset value close to the maximum output value of the sensor's full range can be set, and a second preset value close to the minimum output value of the sensor's full range can be set. For example, if the peak value of the sensor output is 6° and the dip value is -6°, the first preset value can be set to 5.8° and the second preset value to -5.8°.
[0064] Specifically, if the sensor output value is identified as being the first preset value or greater than the first preset value, it is determined whether the next sensor output value is less than the current sensor output value. If the next sensor output value is identified as being less than the current sensor output value, it is determined that a positive stroke will begin at this time. The sensor output value determined at this time and the sensor input value corresponding to this sensor output value are the positive stroke sensor data. If the sensor output value is identified as being the second preset value or less than the second preset value, it is determined whether the next sensor output value is greater than the current sensor output value. If the next sensor output value is identified as being greater than the current sensor output value, it is determined that a negative stroke will begin at this time. The sensor output value determined at this time and the sensor input value corresponding to this sensor output value are the negative stroke sensor data.
[0065] As shown in Figure 4, based on Figure 2, step S203 specifically includes the following steps. In step S2031, based on each sensor input sampling value, the positive stroke sensor output sampling value and the negative stroke sensor output sampling value corresponding to each sensor input sampling value are determined in the sensor dataset, and N positive stroke sampling data and N negative stroke sampling data are obtained.
[0066] In the embodiment of this application, the sensor data processing device determines the positive stroke sensor output sampling value and the negative stroke sensor output sampling value corresponding to each sensor input sampling value in the sensor dataset based on each sensor input sampling value, and obtains N positive stroke sampling data and N negative stroke sampling data. Here, the positive stroke sensor output sampling value is the positive stroke sensor output value corresponding to the positive stroke sensor input value adjacent to the sensor input sampling value in the sensor dataset, and the negative stroke sensor output sampling value is the negative stroke sensor output value corresponding to the negative stroke sensor input value adjacent to the sensor input sampling value in the sensor dataset. The specific process will not be described in detail for brevity of explanation, but please refer to step S203 of the method described above.
[0067] In accordance with the above embodiment, this application further provides a sensor data processing device. Figure 5 is a schematic diagram of a sensor data processing device provided in one embodiment of the present application. As shown in Figure 5, a sensor data set acquisition module 501, a sensor input sampling value determination module 503, and a sampling data acquisition module 502 are shown. Here, the sampling data acquisition module 502 is electrically connected to the sensor data set acquisition module 501, and the sampling data acquisition module 502 is electrically connected to the sensor input sampling value determination module 503.
[0068] In the embodiments of this application, a sensor dataset acquisition module is used to acquire a sensor dataset, where the sensor dataset contains M sensor data, each of which contains one sensor input value and one sensor output value. A sensor input sampling value determination module is used to determine N sensor input sampling values, where M>N>1. A sampling data acquisition module determines a sensor output sampling value corresponding to each sensor input sampling value in the sensor dataset based on each sensor input sampling value, and is used to acquire N sampling data, where the sensor output sampling value is the sensor output value corresponding to a sensor input value adjacent to the sensor input sampling value in the sensor dataset. For brevity of this explanation, the specific details of the embodiments of this application will not be described in detail, but please refer to the description of the embodiments of the method described above.
[0069] Figure 6 is a schematic diagram of another sensor data processing device provided by one embodiment of the present application. As shown in Figure 6, the sensor data processing device shown in Figure 5 further includes a positive stroke sensor data and negative stroke sensor data determination module 604, which is electrically connected to a sensor data set acquisition module 501, and the positive stroke sensor data and negative stroke sensor data determination module 604 is electrically connected to a sampling data acquisition module 502.
[0070] In the embodiments of this application, the positive stroke sensor data and negative stroke sensor data determination module is used to determine the positive stroke sensor data and negative stroke sensor data in the sensor dataset. Specifically, the positive stroke sensor data and negative stroke sensor data determination module is used to determine the positive stroke sensor data and negative stroke sensor data in the sensor dataset based on the trend of change in the sensor output value in the sensor dataset.
[0071] In one possible embodiment, the positive stroke sensor data and negative stroke sensor data determination module is used to determine sensor data in the sensor dataset where the sensor output value is in an increasing interval as positive stroke sensor data, and to determine sensor data in the sensor dataset where the sensor output value is in a decreasing interval as negative stroke sensor data.
[0072] In one possible embodiment, the positive stroke sensor data and negative stroke sensor data determination module is used to determine sensor data in the sensor dataset where the sensor output value is in an increasing interval as negative stroke sensor data, and to determine sensor data in the sensor dataset where the sensor output value is in a decreasing interval as positive stroke sensor data.
[0073] In the embodiment of this application, the sampling data acquisition module further determines the positive stroke sensor output sampling value and the negative stroke sensor output sampling value corresponding to each sensor input sampling value in the sensor dataset based on each sensor input sampling value, and uses these to acquire N positive stroke sampling data and N negative stroke sampling data. Here, the positive stroke sensor output sampling value is the positive stroke sensor output value corresponding to the positive stroke sensor input value adjacent to the sensor input sampling value in the sensor dataset, and the negative stroke sensor output sampling value is the negative stroke sensor output value corresponding to the negative stroke sensor input value adjacent to the sensor input sampling value in the sensor dataset. The specific details of the embodiment of this application will not be described in detail for the sake of brevity, but please refer to the description of the embodiment of the method described above.
[0074] In accordance with the above embodiments, this application further provides an electronic device. Figure 7 is a schematic diagram of the structure of an electronic device provided by an embodiment of the present application. The electronic device 700 may include a processor 701, a memory 702, and a communication unit 703. These assemblies communicate via one or more buses, and those skilled in the art will understand that the structure of the electronic device shown in the drawings is not limiting to embodiments of the present invention, and may include a bus-type structure, a star-type structure, more or fewer components than shown, and may combine several components or different component arrangements.
[0075] Here, the communication unit 703 is used to establish a communication channel so that the electronic device can communicate with other devices. It receives user data transmitted from other devices and transmits user data to other devices. The processor 701 is the control center of the electronic device and is connected to various parts of the entire electronic device using various interfaces and lines. It executes or runs software programs, commands and / or modules stored in the memory 702, and retrieves data stored in the memory, thereby executing various functions of the electronic device and / or processing data. The processor may be composed of an integrated circuit (IC), for example, a single-package IC, or it may be composed of multiple package ICs having similar or different functions connected together. For example, the processor 701 may include only a central processing unit (CPU). In embodiments of the present invention, the CPU may be a single arithmetic core or may include multiple arithmetic cores. The memory 702 is used to store execution commands for the processor 701, and the memory 702 can be implemented by any type of volatile or non-volatile storage device, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk, or optical disk, or a combination thereof. When the execution command in memory 702 is executed by processor 701, the electronic device 700 is made to perform some or all of the steps in the embodiment shown in Figure 1.
[0076] In concrete implementation, this application further provides a computer storage medium, which may store a program, and which may include some or all of the steps in each embodiment of the simulation scene generation method provided by the present invention when the program is executed. The storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM), a random access memory (RAM), etc.
[0077] In the embodiments of this application, “at least one” refers to one or more, and “multiple” refers to two or more. “And / or” describes the relationship between related objects and indicates that there may be three types of relationships. For example, A and / or B may refer to A alone, both A and B, or B alone, where A and B may be singular or plural. The letter “ / ” generally indicates that the preceding and following related objects are in an “or” relationship. “At least one of the following” and similar expressions refer to any combination of these terms, including any combination of singular or plural. For example, at least one of a, b, and c may refer to a, b, c, ab, ac, bc, or abc, where a, b, and c may be singular or plural. Those skilled in the art will recognize that each unit and algorithmic step described in the embodiments disclosed herein can be implemented by electronic hardware, computer software, and combinations of electronic hardware. Whether these functions are performed in hardware or software depends on the application and design constraints of the technical proposal. While experts may implement the described functions using different methods for each specific application, such implementations should not be considered beyond the scope of this application. For the sake of clarity and conciseness, and so that it will be clearly understood by those skilled in the art, the specific operating processes of the systems, apparatus, and units described above can be described by referring to the corresponding processes in the previously mentioned method embodiments, and are therefore omitted here.
[0078] In some embodiments provided by this application, if any function is implemented in the form of a software function unit and sold or used as an independent product, this function may be stored on a computer-readable storage medium. Based on this understanding, the essential parts of the proposed invention of this application, parts that contribute to the prior art, or parts of the proposed invention may be embodied in the form of a computer software product, which is stored on a storage medium and includes several instructions for a computer device (which may be a personal computer, server, or network device, etc.) to perform all or part of the steps of the methods described in each embodiment of this application. The aforementioned storage mediums include various media capable of storing program code, such as U disks, removable hard disks, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0079] Similar or identical parts between the embodiments in this specification should be referenced to one another. In particular, the apparatus and terminal embodiments are fundamentally similar to the method embodiments, so their explanation is relatively simple, and relevant parts should be referred to in the explanation of the method embodiments.
Claims
1. A sensor data processing method, wherein the sensor data processing method is A step of acquiring a sensor dataset, wherein the sensor dataset includes M sensor data, and each sensor data includes one sensor input value and one sensor output value. A step of determining N sensor input sampling values, wherein M > N > 1, The step of determining a sensor output sampling value corresponding to each sensor input sampling value in the sensor dataset based on each sensor input sampling value, and acquiring N sampling data, is included. A sensor data processing method characterized in that the sensor output sampling value is a sensor output value corresponding to a sensor input value adjacent to the sensor input sampling value in the sensor dataset.
2. After obtaining the aforementioned sensor dataset, the sensor data processing method is as follows: The sensor data processing method according to claim 1, further comprising determining positive stroke sensor data and negative stroke sensor data in the sensor dataset.
3. Determining the positive stroke sensor data and negative stroke sensor data in the aforementioned sensor dataset is: The sensor data processing method according to claim 2, characterized in that it includes determining positive stroke sensor data and negative stroke sensor data in the sensor dataset based on the trend of change in the sensor output value in the sensor dataset.
4. Determining the positive stroke sensor data and negative stroke sensor data in the sensor dataset based on the trend of changes in the sensor output values in the sensor dataset is: In the aforementioned sensor dataset, sensor data in which the sensor output value is in an increasing interval is determined to be positive stroke sensor data, The sensor data processing method according to claim 3, characterized in that it includes determining sensor data in the sensor dataset where the sensor output value is in a gradually decreasing interval as negative stroke sensor data.
5. Determining the positive stroke sensor data and negative stroke sensor data in the sensor dataset based on the trend of changes in the sensor output values in the sensor dataset is: In the aforementioned sensor dataset, sensor data whose sensor output value is in an increasing interval is determined to be negative stroke sensor data. The sensor data processing method according to claim 3, characterized in that it includes determining sensor data in the sensor dataset where the sensor output value is in a gradually decreasing interval as positive stroke sensor data.
6. Based on each of the aforementioned sensor input sampling values, determining the sensor output sampling value corresponding to each of the aforementioned sensor input sampling values in the sensor dataset and obtaining N sampling data is: Based on each of the aforementioned sensor input sampling values, the positive stroke sensor output sampling values and negative stroke sensor output sampling values corresponding to each of the aforementioned sensor input sampling values are determined in the sensor dataset, and N positive stroke sampling data and N negative stroke sampling data are obtained. The sensor data processing method according to any one of claims 2 to 5, characterized in that the positive stroke sensor output sampling value is a positive stroke sensor output value corresponding to a positive stroke sensor input value adjacent to the sensor input sampling value in the sensor dataset, and the negative stroke sensor output sampling value is a negative stroke sensor output value corresponding to a negative stroke sensor input value adjacent to the sensor input sampling value in the sensor dataset.
7. The sensor data processing method according to claim 1, characterized in that the minimum and maximum values among the N sensor input sampling values are the minimum and maximum values of the sensor range, respectively.
8. The sensor data processing method according to claim 7, characterized in that the difference between any two adjacent sensor input sampling values among the N sensor input sampling values is equal.
9. A sensor data processing device, the sensor data processing device includes a sensor data set acquisition module, a sensor input sampling value determination module, and a sampling data acquisition module, The sensor data set acquisition module is used to acquire a sensor data set, and the sensor data set includes M sensor data, each of which includes one sensor input value and one sensor output value. The aforementioned sensor input sampling value determination module is used to determine N sensor input sampling values, where M > N > 1. The sampling data acquisition module is used to acquire N sampling data by determining the sensor output sampling value corresponding to each sensor input sampling value in the sensor dataset based on each sensor input sampling value. A sensor data processing device characterized in that the sensor output sampling value is a sensor output value corresponding to a sensor input value adjacent to the sensor input sampling value in the sensor dataset.
10. An electronic device comprising a processor, memory, and a computer program, The electronic device is characterized in that the computer program is stored in the memory, the computer program includes a command, and when the command is executed by the processor, the electronic device executes the sensor data processing method according to any one of claims 1 to 8.
11. A computer-readable storage medium, wherein the computer-readable storage medium includes a program to be stored in it. The computer-readable storage medium is characterized in that, when the program is executed, it controls the device on which the computer-readable storage medium is located to execute the sensor data processing method according to any one of claims 1 to 8.
Citation Information
Patent Citations
High-precision temperature measuring method and system
CN113418635A
Temperature sensor and temperature measuring instrument using it
JP2004028629A