CN117707471A - Environment acquisition equipment, target equipment and data processing method and system thereof - Google Patents

Environment acquisition equipment, target equipment and data processing method and system thereof Download PDF

Info

Publication number
CN117707471A
CN117707471A CN202311810394.2A CN202311810394A CN117707471A CN 117707471 A CN117707471 A CN 117707471A CN 202311810394 A CN202311810394 A CN 202311810394A CN 117707471 A CN117707471 A CN 117707471A
Authority
CN
China
Prior art keywords
data
target data
integer
target
processing
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202311810394.2A
Other languages
Chinese (zh)
Inventor
蒋加平
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hangzhou Micro Image Software Co ltd
Original Assignee
Hangzhou Micro Image Software Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hangzhou Micro Image Software Co ltd filed Critical Hangzhou Micro Image Software Co ltd
Priority to CN202311810394.2A priority Critical patent/CN117707471A/en
Publication of CN117707471A publication Critical patent/CN117707471A/en
Pending legal-status Critical Current

Links

Landscapes

  • Complex Calculations (AREA)

Abstract

The application discloses an environment acquisition device and a target device, and a data processing method, a data analysis system, a storage medium and an electronic device thereof, comprising: for target data represented by a floating point data type in an environment acquisition device, multiplying the target data by 2 N Then integer cutting is carried out to obtain the integer expression form of the target data; utilizing the integer expression form of the target data to participate in the processing and cross-platform transmission of the target data; wherein N is a positive integer determined based on the accuracy requirement for the target data. By the application of the method and the device, the consistency of the data can be optimized.

Description

Environment acquisition equipment, target equipment and data processing method and system thereof
Technical Field
The present invention relates to a data processing technology, and in particular, to an environment collection device and a data processing method thereof, a target device and a processing method thereof, a data analysis system of the environment collection device, a storage medium of the data processing methods of the environment collection device and the target device, and an electronic device.
Background
In the application of the existing environment acquisition equipment, the environment acquisition equipment can process the acquisition equipment and other input data to obtain some analysis results, for example, a thermal imaging instrument processes the acquired data of various sensors on the equipment to obtain a temperature measurement result and generate a thermal imaging image; meanwhile, in order to realize secondary analysis of data in the environment acquisition equipment, the data of the environment acquisition equipment is required to be sent to other target equipment (such as a PC), and then corresponding secondary analysis processing is carried out, for example, the acquisition data of various sensors can be transmitted to the PC by a thermal imager, the data processing is carried out again on the PC, and a temperature measurement result is calculated or a thermal imaging image is generated. In such applications, when data processing is required to be performed on the environment collection device and when secondary analysis processing is required to be performed on the target device, the consistency of the data can be maintained, but since many measurement parameters, collected data and the like which are input from outside in the data collection device are stored in the form of floating point data, when the environment collection device and the target device are implemented based on different hardware platforms, the calculation results can be different due to possible differences of the different platforms for the processing of the floating point data, so that the consistency of the data cannot be ensured.
In addition, in the internal data processing process of the environment acquisition device, there may be a case that only the whole data can be processed due to condition limitation in each aspect, in this case, the acquisition data, the intermediate operation data or the external input parameters and the like represented by the floating point data form need to be processed after the shaping conversion, and accordingly, the consistency of the data may not be ensured due to the processing problem of the shaping conversion in the target device.
In addition to the problem of inconsistent data in the secondary data analysis of the thermal imager, corresponding problems, such as secondary data analysis of the acoustic imager, can also occur in the secondary data analysis of other environmental acquisition devices.
Disclosure of Invention
The application provides environment acquisition equipment, target equipment, a data processing method, a system, a storage medium and electronic equipment thereof, which can optimize consistency of floating point data.
In order to achieve the above purpose, the present application adopts the following technical scheme:
a data processing method of an environmental collection device, comprising:
for target data represented by floating point data type in environment acquisition equipment, the method comprises the following steps ofThe target data is multiplied by 2 N Then integer cutting is carried out to obtain the integer expression form of the target data;
Utilizing the integer expression form of the target data to participate in the processing and cross-platform transmission of the target data;
wherein N is a positive integer determined based on the accuracy requirement for the target data.
Preferably, the utilizing the integer expression form of the target data to participate in cross-platform transmission of the target data includes:
and transmitting the integer expression form of the target data to target equipment in a cross-platform manner.
Preferably, the utilizing the integer expression form of the target data to participate in cross-platform transmission of the target data includes:
converting the integer representation of the target data into floating point data divided by 2 N Obtaining corrected target data;
and transmitting the corrected target data to target equipment in a cross-platform manner.
Preferably, the processing of the target data using the integer expression form of the target data includes:
converting the integer expression of the target data into floating point data and dividing the floating point data by 2 N Obtaining corrected target data;
and carrying out the processing on the corrected target data.
Preferably, the processing of the target data using the integer expression form of the target data includes:
When the processing can only be performed on integer data, performing corresponding processing on the integer expression form of the target data, converting the processing result into floating point data, and dividing the converted floating point data by 2 N
Preferably, the environment acquisition device is a thermal imager or an acoustic imager.
Preferably, the target data is external input data, acquisition data of the environment acquisition device, intermediate operation data of the environment acquisition device or output data of the environment acquisition device.
Preferably, the external input data is a configuration parameter or a measurement parameter.
A data processing method of a target device, comprising:
receiving an integer expression form of target data sent by acquisition equipment;
converting the integer expression of the target data into floating point data and dividing the floating point data by 2 N Obtaining corrected target data;
analyzing and processing the corrected target data;
wherein N is a positive integer determined based on the accuracy requirement for the target data.
A data processing method of a target device, comprising:
receiving target data sent by environment acquisition equipment;
analyzing and processing the target data;
wherein when the analysis processing can only be performed on integer data in the environment acquisition device, the analysis processing on the target data includes:
Determining an integer representation of the target data, the integer representation of the target data being the target data multiplied by 2 N Then shaping and cutting to obtain the finished product;
the analysis processing is carried out on the integer expression form of the target data, the processing result is converted into floating point data, and the converted floating point data is divided by 2 N
Wherein N is a positive integer determined based on the accuracy requirement for the target data.
Preferably, the determining the integer expression form of the target data includes:
when the target data sent by the environment acquisition equipment is in an integer expression form of the target data, determining the received data as the integer expression form of the target data;
when the house is atWhen the target data sent by the environment acquisition equipment is corrected target data, multiplying the received corrected target data by 2 N And then integer cutting is carried out, and a cutting result is used as an integer expression form of the target data.
An environmental harvesting device, comprising: a target data preprocessing unit and a data processing unit;
the target data preprocessing unit is used for multiplying target data represented by floating point data type in the environment acquisition equipment by 2 N Then integer cutting is carried out to obtain the integer expression form of the target data;
the data processing unit is used for participating in processing and cross-platform transmission of the target data by utilizing the integer expression form of the target data;
wherein N is a positive integer determined based on the accuracy requirement for the target data.
Preferably, in the data processing unit, the using the integer expression form of the target data to participate in cross-platform transmission of the target data includes:
and transmitting the integer expression form of the target data to target equipment in a cross-platform manner.
Preferably, the data processing unit comprises a target data repairing subunit and a processing subunit;
the target data restoring subunit is used for converting the integer expression form of the target data into floating point data and dividing the floating point data by 2 N Obtaining corrected target data;
the processing subunit is configured to transmit the modified target data to a target device in a cross-platform manner.
Preferably, the data processing unit comprises a target data repairing subunit and a processing subunit;
the target data restoring subunit is used for converting the integer expression form of the target data into floating point data and dividing the floating point data by 2 N Obtaining corrected target data;
the processing subunit is used for performing the processing on the corrected target data.
Preferably, the data processing unit comprises a target data repairing subunit and a processing subunit;
the processing subunit is used for performing the processing on the integer expression form of the target data when the processing can only be performed on the shaping data;
the target data restoring subunit is configured to convert the processing result of the processing subunit into floating point data and divide the floating point data by 2 when the processing can only be performed on integer data N
Preferably, the environment acquisition device is a thermal imager or an acoustic imager.
A target device, comprising: the device comprises a receiving unit, a target data restoration unit and a data processing unit;
the receiving unit is used for receiving the integer expression form of the target data sent by the acquisition equipment;
the target data restoring unit is used for converting the integer expression form of the target data into floating point data and dividing the floating point data by 2 N Obtaining corrected target data;
the data processing unit is used for analyzing and processing the corrected target data;
wherein N is a positive integer determined based on the accuracy requirement for the target data.
A target device, comprising: a receiving unit and a data processing unit;
the receiving unit is used for receiving target data sent by the environment acquisition equipment;
the data processing unit is used for analyzing and processing the target data;
wherein the data processing unit comprises a target data preprocessing subunit and an analysis processing subunit,
the target data preprocessing subunit is used for determining an integer expression form of target data when the analysis processing can only be performed on integer data in the environment acquisition equipment; the target numberIn the form of an integer representation of the target data multiplied by 2 N Then, shaping and cutting are carried out, wherein N is a positive integer determined based on the precision requirement on the target data;
the analysis processing subunit is configured to perform the analysis processing on the integer expression form of the target data determined by the target data preprocessing subunit when the analysis processing is only performed on the shaping data in the environment acquisition device, convert the processing result into floating point data, and divide the converted floating point data by 2 N
Preferably, in the target data preprocessing subunit, the determining the integer expression form of the target data includes: if the receiving unit receives the target data in the form of integer expression, the received data is determined to be the target data in the form of integer expression, and if the receiving unit receives the target data in the form of floating point data, the target data received by the receiving unit is multiplied by 2 N And then integer cutting is carried out, and the cutting result is determined to be an integer expression form of the target data.
A data analysis system of an environmental collection device, comprising: an environment acquisition device and a target device;
the environment acquisition device is used for multiplying the target data represented by the floating point data type in the device by 2 N Then integer cutting is carried out to obtain the integer expression form of the target data; the method is also used for transmitting the integer expression form of the target data to target equipment;
the target device is used for converting the integer expression form of the target data sent by the environment acquisition device into floating point data and dividing the floating point data by 2 N Obtaining corrected target data; the method is also used for analyzing and processing the corrected target data;
wherein N is a positive integer determined based on the accuracy requirement for the target data.
A data analysis system of an environmental collection device, comprising: an environment acquisition device and a target device;
the environment acquisition device is used for multiplying the target data expressed in the floating point data type in the device by 2 N Then integer cutting is carried out to obtain the integer expression form of the target data; the system is also used for participating in the processing of the target data in the integer expression form of the target data and transmitting the target data to the target equipment in a cross-platform manner;
The target device is used for determining the integer expression form of the target data based on the target data sent by the environment acquisition device before the analysis processing which can only be carried out on the integer data in the environment acquisition device is carried out; the method is also used for carrying out the analysis processing on the integer expression form of the target data, converting the analysis processing result into floating point data, and dividing the converted floating point data by 2 N
Wherein N is a positive integer determined based on the accuracy requirement of the target data, and the integer expression form of the target data is the target data multiplied by 2 N And then shaping and cutting.
Preferably, in the target device, the determining the integer expression form of the target data includes: if the device receives the target data in the form of integer expression, the received data is determined to be the target data in the form of integer expression, if the device receives the target data in the form of floating point data, the received target data is multiplied by 2 N And then integer cutting is carried out, and the cutting result is determined to be an integer expression form of the target data.
A computer readable storage medium having stored thereon computer instructions which, when executed by a processor, implement a data processing method of an environmental harvesting device as described in any of the above or implement a data processing method of a target device as described in any of the above.
An electronic device comprising at least a computer readable storage medium, further comprising a processor;
the processor is configured to read executable instructions from the computer readable storage medium and execute the instructions to implement the data processing method of the environmental collection device of any one of the above.
As can be seen from the above technical solution, in the present application, in the environment collection device, for the target data represented by the floating point data type, multiplication is performed by 2 N Then integer cutting is carried out to obtain an integer expression form of the target data, wherein N is a positive integer determined based on the precision requirement of the target data, so that conversion of floating point data into integer data is realized, the whole conversion process only involves shifting operation and cutting operation, and the precision requirement is met; and then, the integer expression form of the target data is utilized to participate in the processing and cross-platform transmission of the corresponding target data, and because the process of the integer typing of the floating point data only involves the shift operation and the cut-off operation, correspondingly, the operation of converting the converted integer data back to the floating point data in the environment acquisition equipment or the target equipment at the opposite transmission end also only involves the forced conversion and shift operation of the data, thereby ensuring that the decimal part within the precision requirement is kept unchanged and the decimal part outside the precision requirement is set to 0.
Drawings
FIG. 1 is a schematic diagram of a basic flow of a data processing method of an environmental collection device in the present application;
FIG. 2 is a schematic diagram of floating point data before and after the floating point data is shaped in the present application;
FIG. 3 is a schematic diagram of an exemplary thermal imager of the present application performing a temperature unit conversion process;
fig. 4 is a basic flow diagram of a data processing method of a target device provided in the present application;
FIG. 5 is a schematic diagram of a basic flow of a data processing method of another target device provided in the present application;
FIG. 6 is a schematic diagram of the basic structure of the environmental collection device in the present application;
FIG. 7 is a schematic diagram of a basic structure of a target device according to the present application;
FIG. 8 is a schematic diagram of the basic structure of another target device according to the present application;
FIG. 9 is a schematic diagram of the basic structure of the data analysis system in the present application;
fig. 10 is a schematic diagram of a basic structure of an electronic device in the present application.
Detailed Description
In order to make the objects, technical means and advantages of the present application more apparent, the present application is further described in detail below with reference to the accompanying drawings.
First, a description will be given of processing differences that may occur in different hardware platforms for floating point numbers. Different floating point representations may be used on different hardware platforms (e.g., PCs and embedded systems). A common floating point representation is the IEEE 754 standard, but there are many variations in implementation.
There are many variations in implementation that mean that in an actual computer system, there may be some differences and variations to the specific implementation of the IEEE 754 standard. These variants may involve the following aspects:
* Precision: the IEEE 754 standard defines single precision (32-bit) and double precision (64-bit) floating point formats, but in some cases hardware implementations may use other numbers of floating point formats. For example, some embedded systems may use a 16-bit half-precision (floating-point) format.
* The range is as follows: the IEEE 754 standard specifies a range of floating-point number representations, including maximum, minimum, and minimum normalized numbers, among others. In actual implementation, some systems may extend or retract in scope to accommodate specific needs or hardware limitations.
* Rounding rules: the IEEE 754 standard defines four rounding modes: rounding to the nearest even, to zero, to positive infinity, and to negative infinity. In actual implementations, some systems may provide other rounding modes or variants, such as truncated rounding or custom rounding approaches.
* Special value processing: the IEEE 754 standard specifies special floating point values such as positive infinity, negative infinity, and non-number (NaN). In practical implementations, some systems may have differences in how these particular values are handled, such as how overflow or invalid operations are handled.
* Hardware support: different processors and floating point units may have varying degrees of support for the IEEE 754 standard. Some systems may provide hardware acceleration or optimized floating point units, while other systems may rely on software implementations.
Based on different expression modes of floating point numbers and variants thereof by different platforms, the applicant analyzes the problem of inconsistent data, which occurs when the existing environment acquisition equipment performs cross-platform floating point data transmission processing, as follows:
firstly, floating data transmission is carried out by adopting float data types; in this way, the hardware platforms of the environment collection device and the target device are different, for example, the hardware implementation of the PC and the embedded system may be different, including the processor architecture, the floating point unit performance, etc., and the rounding error and the calculation sequence in the calculation process may be different due to these hardware differences, so that the final calculation result is affected, and the consistency of the data cannot be ensured; meanwhile, besides different hardware platforms, the environment acquisition equipment and the target equipment may have optimization and compiler differences, specifically, when the compiler converts the source code into executable code, the compiler on different platforms may adopt different optimization strategies and floating point number optimization options, which may cause minor differences in the calculation process and further affect the consistency of the final result;
The second mode is to adopt double data type to carry out cross-platform transmission of floating point data; the probability of error is reduced in the mode compared with the mode one, but the problem of overlarge memory and calculation cost is introduced at the same time, particularly, the larger memory and calculation cost is brought by double-precision floating point operation, particularly, in the thermal imaging service, the memory limitation is always an industry common disease when temperature results are transmitted across platforms, and if a double-precision data type is adopted, the problem of memory limitation is increased more seriously due to direct double cost;
scheme III, adopting the type of the int data to carry out cross-platform transmission of floating point data; in this way, the floating point data needs to be truncated in decimal, specifically, after the floating point data is multiplied by a multiple of 10, integer truncation is adopted, but after the integer data is transmitted to the opposite end target device, the final processing link still needs to restore the integer data into the floating point data (i.e. decimal), that is, the integer data is forcedly converted into the floating point data, and then the floating point data is divided by the multiple of 10 correspondingly, and the division operation itself can cause errors. That is, in the transmission, precise values can be transferred, but in the end, the inconsistency of floating point number representations for different platforms is faced with resulting accuracy errors. For example, 0.01 is transmitted with 100 times of int, while data 1 is generally used for transmission, the PC may be 0.010000001 and the embedded system may be 0.009999999 when the last conversion is back to 0.01; meanwhile, besides errors caused by calculation introduced in data conversion, the decimal calculation is higher in calculation power consumption than binary calculation, so that extra system calculation power is consumed when data inconsistency is caused.
Based on the above analysis, the applicant has summarized that, for both the first and second modes, there is a possibility that the data inconsistency will occur before the floating point data is transferred, while the third mode can achieve the accuracy of transfer, but the integer processing of the floating point data (i.e. the data type conversion mode) will cause the data inconsistency and the problem of extra power consumption.
Based on the method, the data processing method of the environment acquisition equipment is provided, the integer processing process of floating point data is improved on the basis of the third mode, and the data consistency problem in the whole data processing process is optimized.
Fig. 1 is a basic flow diagram of a data processing method of an environmental collection device in the present application. As shown in fig. 1, the method includes:
step 101, for target data represented by floating point data type in environment collection equipment, multiplying target data by 2 N Then shaping and cutting off to obtain the whole target dataNumber expression form.
The target data refers to data which has a consistency requirement in the environment acquisition equipment and is represented by a floating point data type, and can be externally input parameters (such as distance, ambient temperature, ambient humidity, configuration parameters representing emissivity to external radiation conditions, measurement parameters and the like), acquisition data of various sensors in the environment acquisition equipment (such as distance, ambient temperature, ambient humidity, sound wave intensity and the like), intermediate operation data of the environment acquisition equipment (such as temperature compensation results and the like), output data of the environment acquisition equipment and the like. The floating point data types can be float or double and other floating point data types. N is a positive integer determined based on the accuracy requirements for the target data, which may be different for different target data. For any target data, the decimal place after the precision requirement may be set to 0 as long as its data representation meets the precision requirement.
The step is used for carrying out integer processing on the target data on the premise of ensuring the precision requirement of the target data, namely converting the floating point data type of the target data into an integer type, so that the step is used for carrying out the processing of data type conversion. The specific treatment comprises the following steps: multiplying target data represented in floating point data type by 2 N Then, integer cutting is carried out, and the result after integer cutting is called as the integer expression form of the target data. In a specific implementation, the data is processed internally in binary form, thus multiplying the target data by 2 N That is, it is equivalent to shifting the binary form of the target data by N bits to the left and then performing integer truncation, that is, shifting the result by N bits to the left retains only the integer part. The integer cut-off processing described above may be implemented by forcibly converting floating point data into integer data.
Some examples of program implementations of the data type conversion process performed by this step, which typically requires precision, are given below:
1)#define FloatToIntd1(fValue)(mintd1)((fValue)*(1<<6))
the FloatToIntd1 represents a custom function, fValue represents an input parameter, namely target data in the application, mintd1 is also the custom function, the operation realized by mintd1 is int (), namely the input parameter is forcedly converted into the type of int, (fValue) is (fValue) 1< < 6), and fValue is shifted to the left by 6 bits; the corresponding left shift of 6 bits indicates that the 1 bit after decimal point of decimal number is reserved, the precision requirement of corresponding target data is 1 bit after decimal point, the markers of FloatToIntd1 and mintd1 are used for enhancing readability, and d1 is used for indicating that the 1 bit after decimal point is reserved; since 6 bits are shifted left and integer truncation is performed, 6 bits in the converted integer data are used for representing the decimal part of the floating point data, so that the value range of the integer part used for representing the floating point data is [ -33554431,33554431];
2)#define FloatToIntd2(fValue)(mintd2)((fValue)*(1<<9))
The FloatToIntd2 represents a custom function, mintd2 is also a custom function, the operation realized by mintd2 is int (), namely, the input parameters are forcedly converted into the type of int, (fValue) < 1< < 9) represents that fValue is shifted to the left by 9 bits; the corresponding left shift of 9 bits indicates that the decimal point post 2 bits are reserved, the precision requirement of corresponding target data is that the decimal point post 2 bits are reserved, the markers FloatToIntd2 and mintd2 are used for enhancing the readability, and d2 is used for indicating that the decimal point post 2 bits are reserved; since 9 bits are shifted left and integer truncation is performed, 9 bits in the converted integer data are used for representing the decimal part of the floating point data, so that the value range of the integer part used for representing the floating point data is [ -4194303,4194303];
3)#define FloatToIntd3(fValue)(mintd3)((fValue)*(1<<13))
the FloatToIntd3 represents a custom function, mintd3 is also a custom function, the operation realized by mintd3 is int (), namely, the input parameters are forcedly converted into the type of int, (fValue) < 1< < 13) represents that fValue is shifted to the left by 13 bits; the corresponding left shift of 13 bits indicates that the decimal point post-3 bits are reserved, the precision requirement of corresponding target data is that the decimal point post-3 bits are reserved, the markers FloatToIntd3 and mintd3 are used for enhancing the readability, and d3 is used for indicating that the decimal point post-3 bits are reserved; since 13 bits are shifted left and integer truncation is performed, 13 bits in the converted integer data are used for representing the decimal part of the floating point data, so that the value range of the integer part used for representing the floating point data is [ -262143,262143];
4)#define FloatToIntd(fValue)(mintdd)((fValue)*(1<<15))
The FloatToIntd represents a custom function, mintdd is also a custom function, the operation realized by mintdd is int (), namely, the input parameters are forcedly converted into the type of int, and (fValue) < 1< < 15) represents that fValue is shifted left by 15 bits; the corresponding representation of 15 bits shifted left here is that the converted data range just corresponds to the value range of the short data type, which is the case in some scenes focusing on the value range of the integer data, and the markers floatttointd and mintdd are used for enhancing the readability, and dd is used for representing the value range corresponding to the short data type; since 15 bits are shifted left and integer truncation is performed, 15 bits in the converted integer data are used for representing the decimal part of the floating point data, so that the value range of the integer part used for representing the floating point data is [ -65535,65535];
5)#define FloatToIntd4(fValue)(mintd4)((fValue)*(1<<16))
the FloatToIntd4 represents a custom function, mintd4 is also a custom function, the operation realized by mintd2 is int (), namely, the input parameters are forcedly converted into the type of int, (fValue) < 1< < 16) represents that fValue is shifted to the left by 16 bits; the left shift of 16 bits correspondingly represents that the decimal point post 4 bits are reserved, the precision requirement of corresponding target data is that the decimal point post 4 bits are reserved, the markers FloatToIntd4 and mintd4 are used for enhancing the readability, and d4 represents that the decimal point post 4 bits are reserved; since 16 bits are shifted left, 16 bits in the converted integer data are used for representing the decimal part of the floating point data and integer truncation is performed, so that the value range for representing the integer part of the floating point data is [ -32767,32767];
6)#define FloatToIntd5(fValue)(mintd5)((fValue)*(1<<19))
The FloatToIntd5 represents a custom function, mintd5 is also a custom function, the operation realized by mintd5 is int (), namely, the input parameters are forcedly converted into the type of int, (fValue) < 1< < 19) represents that fValue is shifted to the left by 19 bits; the left shift 19 bit correspondingly indicates that the decimal point post 5 bits are reserved, the precision requirement of corresponding target data is that the decimal point post 5 bits are reserved, the markers FloatToIntd5 and mintd5 are used for enhancing the readability, and d5 is used for indicating that the decimal point post 5 bits are reserved; since 19 bits are shifted left and integer truncation is performed, 19 bits in the converted integer data are used to represent the fraction of the floating point data, and thus the range of values used to represent the integer portion of the floating point data is [ -4095,4095].
As above, based on the precision requirement of the target data, the target data represented by the floating point data type is converted into the integer type, namely, the integer expression form of the target data is obtained, in the whole processing process, only binary shift operation and truncation operation are involved, the operation, transmission or platform optimization is carried out on the integer data, the mantissa before the truncated part is not affected, and the precision requirement of the target data can be met.
Step 102, using the integer expression form of the target data to participate in the processing and cross-platform transmission of the target data.
After converting the target data into integer data types based on the accuracy requirements of the target data, the integer representation of the target data may be used in the internal processing of the environmental collection device and the cross-platform transmission of the target data. The conversion of the floating point data into the integer type is directly realized by left shift N bits and integer truncation, and correspondingly, the conversion is also realized by forcibly converting the result into the floating point data and right shift N bits when the result is required to be converted back into the floating point data, the data within the precision requirement is not changed in the bidirectional data conversion process, and the consistency requirement of the data is effectively ensured in the data conversion process; meanwhile, the decimal part outside the precision requirement is set to 0, so that the consistency of the data can be effectively optimized based on the processing of the corresponding data.
Specifically, several typical integer representations of target data are presented below in terms of how the target data is handled and transported across platforms:
the first mode), when the integer expression form of the target data participates in cross-platform transmission, the integer expression form of the target data can be directly transmitted to the target equipment in a cross-platform mode;
In the simplest processing mode, the integer expression form of the target data can be transmitted to the target equipment in a cross-platform manner; accordingly, the target device needs to perform corresponding processing, which specifically may include: after the target device receives the data, the target device can operate reversely to convert the received integer data back to floating point data, and divide the floating point data by 2 N (i.e., shift N bits to the right) the processing result is referred to as corrected target data, and the target device performs corresponding processing with the corrected target data as target data.
As can be seen from the above processing, the modified target data in the target device is obtained based on the integer representation of the original target data, and the processing of the target data based on this is equivalent to the processing based on the integer representation of the target data. Comparing the corrected target data with original target data, setting the decimal part after the precision requirement to 0, wherein the decimal part within the precision requirement is completely the same as the original target data, and carrying out operation and platform optimization based on the decimal part, wherein the mantissa before the truncated part is not affected, and the precision requirement of the target data can be met; correspondingly, the environment acquisition equipment also participates in the processing of the target data in an integer expression form of the target data (the realization that the integer expression form of the target data participates in the processing of the target data in the specific environment acquisition equipment can be performed in the third or fourth mode), so that the processing of the target data in the data acquisition equipment and the target equipment is ensured to be based on the integer expression form of the target data, and the requirement of data consistency is met;
Some typical precision requirements are given below "convert integer data back to floating point data divided by 2 N "a program implementation example of the operation of which corresponds to the implementation example of the series of steps 101 given above:
1) The # definition Intd1ToFloat (iValue) (float (ivaue)/(1 < < 6)) corresponds to the precision requirement that 1 bit after the decimal point is reserved;
2) The # definition Intd2ToFloat (iValue) (float (ivaue)/(1 < < 9)) corresponds to the precision requirement to reserve the 2 bits after decimal point;
3) The # definition Intd3ToFloat (iValue) (float (ivaue)/(1 < < 13)) corresponds to the precision requirement to reserve the 3 bits after decimal point;
4) # define IntdToFloat (ivaue) (float (ivaue)/(1 < < 15)) corresponds to the integer data in a value range consistent with the short data type;
5) The # definition Intd4ToFloat (iValue) (float (ivaue)/(1 < < 16)) corresponds to the precision requirement to reserve 4 bits after decimal point;
6) The # definition Intd5ToFloat (iValue) (float (ivaue)/(1 < < 19)) corresponds to the precision requirement that 5 bits after the decimal point is reserved;
here, "convert integer data back to floating point data divided by 2 N The processing of "is combined with the processing of the target data integer in the foregoing step 101, that is, the purpose of setting the decimal part after the precision requirement to zero and keeping the decimal part within the precision requirement unchanged is achieved. For example, as shown in fig. 2, for float data type, data is represented by 32 bits, 1 st bit is a sign bit, sign of target data is represented, 8 bits are an exponent, exponent when target data is represented by binary scientific count method, and the last 23 bits are mantissa, base when target data is represented by binary scientific count method, and target data is multiplied by 2 in integer processing 9 Namely, the target data is shifted to the left by 9 bits, and integer truncation is realized by forcedly converting the target data into integer data, so that an integer expression form of the target data is obtained; the integer expression form is forcedly converted into the float data type, and the converted float data is shifted to the right by 9 bits to realize division by 2 9 The final processing result is equal to the first N bits of the sign bit, the exponent and the mantissa to be unchanged compared with the original float data, and the other mantissa is set to 0, so that the integer and the decimal part within the precision requirement are ensured to be unchanged, and the decimal part outside the precision requirement is set to 0.
Mode two), integer expression form parameter of target dataWhen in cross-platform transmission, the integer expression form of the target data can be converted into floating point data and divided by 2 N Obtaining corrected target data, and transmitting the corrected target data to target equipment in a cross-platform manner;
considering that the above-mentioned first) mode requires adjustment of the data transmission type between the environment collection device and the target device, and at the same time, additional processing of the received target data is required at the target device, in order to simplify the above-mentioned change, the applicant gives a second mode) to omit the transmission change between the environment collection device and the target device and the additional processing of the target device. Specifically, in the environment acquisition device, the integer representation of the target data is converted back to floating point data and then divided by 2 N (i.e., shift floating point data N bits to the right), refer to the processing result as modified target data, that is, refer to mode one) in which additional operations that need to be performed at the target device are completed in the environment collection device, and then the result is transmitted to the target device; therefore, the target data can be reserved in the environment acquisition equipment for the part with the precision requirement, and the decimal part outside the precision requirement is set to 0 and then transmitted; correspondingly, the data received by the target device is floating point data after the decimal part outside the precision requirement is set to 0, namely the corrected target data, and the corrected target data can be used as target data for corresponding processing in the follow-up.
The above processing can be seen that the environment acquisition device realizes the integer processing of the target data, and the data is converted back to the floating point data and then transmitted to the target device, the data received by the target device is the floating point data converted back based on the integer expression form of the target data, and the processing of the target data based on the floating point data is equivalent to the processing based on the integer expression form of the target data; correspondingly, the environment acquisition equipment also participates in the processing of the target data in an integer expression form of the target data (the realization that the integer expression form of the target data participates in the processing of the target data in the specific environment acquisition equipment can be performed in the third or fourth mode), so that the processing of the target data in the environment acquisition equipment and the target equipment is ensured to be based on the integer expression form of the target data, and the requirement of data consistency is met;
Mode three), when the integer expression form of the target data participates in the processing of the target data by the environment acquisition equipment, the integer expression form of the target data can be converted into floating point data and divided by 2 N Obtaining corrected target data, and then carrying out corresponding processing on the corrected target data;
specifically, when the processing performed on the target data in the data collection device is processing that can be performed on floating point data (for example, temperature unit conversion processing in a thermal imager), then the processing of the target data can be performed in the third mode); the specific treatment comprises the following steps: converting the integer representation of the target data back to a floating point data type, and dividing by 2 N And obtaining corrected target data, and performing corresponding processing by using the corrected target data.
In more detail, the floating point data may be manipulated in such a process, and then the integer representation of the target data may be converted back to the floating point data type, and since the fraction satisfying the precision requirement has been reserved in the previous process of shaping the target data in step 101, setting the subsequent fraction to 0 may also satisfy the precision requirement of the target data, and then the reverse operation is performed to convert the target data back to the floating point data and then divided by 2 N (i.e., shift floating point data by N bits to the right), refer to the processing result as modified target data, and then use the modified target data as current target data to perform corresponding processing, such as temperature unit conversion processing (as shown in fig. 3); in this way, the processing of the target data in the environment acquisition equipment is to actually process the data of which the decimal part outside the precision requirement is set to 0 and the decimal part within the precision requirement is kept unchanged; correspondingly, by combining the cross-platform transmission processing in the first mode) or the second mode), the target equipment can acquire the corrected target data, so that the target data used when the target data are processed in the target equipment and the environment acquisition equipment are consistent, and the requirement of data consistency is met;
mode four), when the integer expression form of the target data participates in the processing of the environment acquisition equipment, the integer expression form of the target data can be correspondingly processed, the processing result is converted into floating point data, and then the converted floating point data is divided by 2 N
Specifically, when the processing performed on the target data in the data acquisition device is processing that can only be performed on the entire data (for example, processing performed with an FPGA in a thermal imager), then the processing of the target data may be performed in the fourth mode); specific treatments may include: and carrying out corresponding processing on the integer expression form of the target data. In this case, corresponding processing needs to be performed in the target device, which specifically includes: for processing A which can only operate on integer data in environment acquisition equipment, determining the integer expression form of target data, performing corresponding processing A, converting the processing result into floating point data after processing A, and dividing the converted floating point data by 2 N The method comprises the steps of carrying out a first treatment on the surface of the When determining the integer expression form of the target data, the transmission processing may be directly receiving the integer expression form of the target data sent by the environment acquisition device (corresponding to the first mode), or the modified target data sent by the environment acquisition device may be received (that is, the integer expression form of the target data is converted back to floating point data and divided by 2 N The result obtained, i.e. corresponding to the transmission process of the second mode) above) is then multiplied by 2 N And performing integer cutting, namely converting the integer cutting into integer types to obtain integer expression forms of the target data.
In more detail, since some processes in the environment collection device can only be performed on integer data, it is necessary to perform corresponding processes on integer expression form of the target data, in fact, it is equivalent to implementing the integer process of the target data by using step 101, then directly performing corresponding processes on the processing result of step 101, converting back to floating point data after the processing is completed, and dividing by 2 N (i.e., shift the floating point data to the right by N bits), thereby restoring the result to floating point data and maintaining the accuracy of the value; next, on the corresponding target device side, first determining the integer of the target data Expression forms (including directly receiving integer expression forms, or multiplying received floating point data by 2 N And then shaping and cutting off), and then adopting the same processing mode as that in the environment acquisition equipment, namely processing the shaping data. Through the processing, the data acquisition equipment and the target equipment can be guaranteed to carry out the same processing A aiming at integer data, meanwhile, the target data used in the processing A is the same, the integer process is binary integer, the multiplication and division operation is not involved, and the shift operation is only involved, so that the consistency of the data can be effectively optimized.
The above given integer expression forms of the target data participate in the cross-platform transmission mode (i.e., mode one) or mode two) of the target data and the integer expression forms of the target data participate in the processing mode (i.e., mode three) and mode four) of the target data may be arbitrarily combined.
To this end, the method flow shown in fig. 1 ends. The method can be applied to various environment acquisition devices, such as a thermal imager, a sound image instrument and the like. By the data processing method in the environment acquisition equipment, only data type conversion and shift operation are involved in the process of data conversion, so that the decimal part within the precision requirement is ensured not to change, and the precision requirement is met, and therefore, the consistency of input is ensured in the processing inside the environment acquisition equipment and the processing in opposite terminal target equipment; meanwhile, the decimal part outside the precision requirement is set to be 0, so that the consistency of addition and subtraction operation results in operation on floating point data is ensured, errors imported by multiplication and division operation are reduced to the greatest extent, and the consistency of the data is effectively optimized.
In the data processing method of the environmental collection device provided in the present application, in some embodiments, the processing of the target device may not be changed, for example, the combination of the second mode) and the third mode); in some embodiments, the processing of the target device needs to be correspondingly changed, for example, corresponding to the first mode) or the fourth mode). Based on this, the present application further provides two data processing methods of the target device, where a flow chart of the first data processing method of the target device is shown in fig. 4, and the data processing method may correspond to the transmission in the first mode), and specifically includes:
step 401, receiving an integer expression form of target data sent by acquisition equipment;
step 402, converting the integer representation of the target data into floating point data and dividing by 2 N Obtaining corrected target data;
wherein N is a positive integer determined based on the accuracy requirement for the target data;
and step 403, analyzing and processing the corrected target data.
Fig. 5 shows a flow chart of a data processing method of another target device, where the data processing method specifically may include:
step 501, receiving target data sent by environment acquisition equipment;
Step 502, judging whether the processing of the target data can only be performed on integer data in the environment acquisition equipment, if so, executing steps 503 and 504, otherwise, executing step 505;
step 503, determining an integer expression form of the target data;
if the target data sent by the environment acquisition equipment is in the integer expression form of the target data, namely, the method corresponds to the first mode, the received data is determined to be in the integer expression form of the target data; if the target data sent from the environment collection device is modified target data, i.e. corresponds to the second mode, the received data may be multiplied by 2 N And then integer cutting is carried out to obtain the integer expression form of the target data.
Step 504, analyzing the integer expression form of the target data, converting the processed result into floating point data, and dividing the converted floating point data by 2 N
And 505, analyzing and processing the target data.
If the target data sent by the environment acquisition device is in the form of integer expression of the target data, i.e. corresponds to the first mode, the step can convert the received data into floating point data and divide the floating point dataAt 2 N Then, corresponding analysis treatment is carried out; if the target data sent by the environment collection device is modified target data, that is, the modified target data corresponds to the second mode, the step directly performs corresponding analysis processing on the received data, that is, the target device can process according to the existing mode in this case.
The data processing method of the target equipment provided by the application can be applied to various equipment for performing secondary analysis of the data of the environment acquisition equipment, such as a PC (personal computer) and the like. The environment acquisition equipment and the target equipment are matched with each other, so that the problem of data consistency can be effectively optimized.
An example of implementing the processing method in the present application in a typical scenario is given below. In the current overseas CNPP authentication, the temperature measurement result of the handheld thermal imager needs to be compared with the temperature measurement result of the PC secondary analysis, and the problem that two temperature measurement results are inconsistent often occurs when the two temperature measurement results are compared in the existing mode is solved by the analysis of the temperature measurement processing process of the applicant, in the temperature measurement processing process, the input floating point data or intermediate data needs to be amplified, the maximum amplification factor is 1000000 (namely 10-6), one single-precision floating point data can express an effective decimal number of 7 bits, if the temperature is required to be 2 bits after the decimal point is reserved for the result, the corresponding mantissa part of the floating point data can only have 5 bits, the result is introduced after the 5 bits of the mantissa part in the actual floating point data is amplified, correspondingly, the difference of the result after the 5 bits of the mantissa part caused by different expressions or variants of the floating point data in the handheld thermal imager and the PC is introduced, and the error is basically exposed, so that the temperature measurement result of the handheld thermal imager and the PC is inconsistent. In this case, the processing of the present application can be performed as follows to improve the problem of inconsistency in the temperature measurement results.
The method comprises the following steps: the hand-held thermal imager receives one type of temperature measurement parameters input by a user, and acquires two types of temperature measurement parameters through a sensor, wherein the two types of temperature measurement parameters are usually in a floating point data form, and the thermal imager takes the corresponding temperature measurement parameters as target data and takes the target numbers as target dataMultiplied by 2 N Then integer cutting (N is a positive integer determined based on the precision requirement of the temperature measurement parameter) to obtain an integer expression form of the temperature measurement parameter, then converting the integer expression form of the temperature measurement parameter back to floating point data, and dividing by 2 N Obtaining corrected temperature measurement parameters, and then carrying out temperature measurement processing by utilizing the corrected temperature measurement parameters to obtain a temperature measurement result; meanwhile, the handheld thermal imager sends integer expression forms of various temperature measurement parameters to a PC for secondary analysis, and the PC converts the received integer expression forms of the temperature measurement parameters back to floating point data and divides the floating point data by 2 N The corrected temperature measurement parameters are obtained, and then the corrected temperature measurement parameters are utilized to carry out temperature measurement treatment, so that a temperature measurement result is obtained;
the second method is as follows: the hand-held thermal imager receives one type of temperature measurement parameters input by a user, and acquires two types of temperature measurement parameters through a sensor, wherein the two types of temperature measurement parameters are usually in the form of floating point data, the thermal imager takes the corresponding temperature measurement parameters as target data, and the target data are multiplied by 2 N Then integer cutting (N is a positive integer determined based on the precision requirement of the temperature measurement parameter) to obtain an integer expression form of the temperature measurement parameter, then converting the integer expression form of the temperature measurement parameter back to floating point data, and dividing by 2 N Obtaining corrected temperature measurement parameters, and performing temperature measurement processing by using the corrected temperature measurement parameters to obtain a temperature measurement result; meanwhile, the handheld thermal imager sends various corrected temperature measurement parameters to a PC for secondary analysis, and the PC performs temperature measurement processing by using the corrected temperature measurement parameters to obtain a temperature measurement result;
by any one of the two methods, the same temperature measurement parameters input during the temperature measurement processing in the hand-held thermal imager and the PC machine can be ensured, and the decimal part exceeding the precision requirement is zero, so that the consistency of the addition and subtraction operation results in the temperature measurement processing is ensured, the influence of errors led in by multiplication and division operation is reduced to the greatest extent, and the condition that the temperature measurement results of two devices are inconsistent is effectively improved. However, if the processing is performed in the conventional manner, errors are caused in the process of inputting the representation of the floating point data and the processing of the floating point data in the thermometric processing.
The above is a specific implementation of the data processing method of the environment acquisition device and the corresponding target device processing method in the application. The application also provides an environment acquisition device, a target device and a data analysis system consisting of the environment acquisition device and the target device, which can be used for implementing the method.
Specifically, as shown in fig. 6, the basic structure of the environment acquisition device provided by the application includes a target data preprocessing unit and a data processing unit;
wherein, the target data preprocessing unit is used for multiplying target data expressed by floating point data type in the environment acquisition equipment by 2 N Then integer cutting is carried out to obtain the integer expression form of the target data;
the data processing unit is used for participating in processing and cross-platform transmission of the target data by utilizing the integer expression form of the target data;
wherein N is a positive integer determined based on the accuracy requirement for the target data.
Optionally, the data processing unit includes a target data repair subunit and a processing subunit;
the target data restoring subunit is used for converting the integer expression form of the target data into floating point data and dividing the floating point data by 2 N Obtaining corrected target data;
the processing subunit is used for performing the processing on the corrected target data.
Optionally, the data processing unit includes a target data repair subunit and a processing subunit;
the processing subunit is used for performing the processing on the integer expression form of the target data when the processing can only be performed on the shaping data;
The target data restoring subunit is configured to convert the processing result of the processing subunit into floating point data and divide the floating point data by 2 when the processing can only be performed on the shaping data N
Optionally, in the data processing unit, the processing of cross-platform transmission of the target data using the integer expression form of the target data may specifically include:
and transmitting the integer expression form of the target data to target equipment in a cross-platform manner.
Optionally, the data processing unit may include a target data repair subunit and a processing subunit;
wherein the target data restoring subunit is used for converting the integer expression form of the target data into floating point data and dividing the floating point data by 2 N Obtaining corrected target data;
and the processing subunit is used for transmitting the corrected target data to target equipment in a cross-platform manner.
Alternatively, the environmental capture device may be a thermal imager or an acoustic imager.
The application provides a target device, the basic structure of which is shown in fig. 7, comprising: the device comprises a receiving unit, a target data restoration unit and a data processing unit;
the receiving unit is used for receiving the integer expression form of the target data sent by the acquisition equipment;
The target data restoring unit is used for converting the integer expression form of the target data into floating point data and dividing the floating point data by 2 N Obtaining corrected target data;
the data processing unit is used for analyzing and processing the corrected target data;
wherein N is a positive integer determined based on the accuracy requirement for the target data.
The present application also provides a target device, whose basic structure is shown in fig. 8, including: a receiving unit and a data processing unit;
the receiving unit is used for receiving the target data sent by the environment acquisition equipment;
the data processing unit is used for analyzing and processing the target data;
wherein the data processing unit comprises a target data preprocessing subunit and an analysis processing subunit,
the target data preprocessing subunit is used for determining an integer expression form of the target data when analysis processing can only be performed on the shaping data in the environment acquisition equipment; the integer representation of the target data is the target data multiplied by 2 N Then shaping and cutting the result, wherein N is a positive integer determined based on the precision requirement on the target data;
an analysis processing subunit, configured to perform analysis processing on the integer expression form of the target data determined by the target data preprocessing subunit when the analysis processing can only be performed on the shaping data in the environment acquisition device, convert the processing result into floating point data, and divide the converted floating point data by 2 N
In the target data preprocessing subunit, the process of determining the integer expression form of the target data may specifically include:
if the receiving unit receives the integer expression form of the target data, the received data is determined to be the integer expression form of the target data, and if the receiving unit receives the target data of the floating point data type, the receiving unit receives the target data multiplied by 2 N And then integer cutting is carried out, and the cutting result is determined to be an integer expression form of the target data.
The application provides a data analysis system of environment acquisition equipment, the basic structure of which is shown in fig. 9, comprising: an environment acquisition device and a target device;
environment acquisition equipment for multiplying target data represented by floating point data type in the equipment by 2 N Then integer cutting is carried out to obtain an integer expression form of the target data; the method is also used for transmitting the integer expression form of the target data to the target equipment;
the target device is used for converting the integer expression form of the target data sent by the environment acquisition device into floating point data and dividing the floating point data by 2 N Obtaining corrected target data; the method is also used for analyzing and processing the corrected target data;
Where N is a positive integer determined based on the accuracy requirements for the target data.
The application also provides a data analysis system of the environment collection device, the basic structure of which is also shown in fig. 9, comprising: an environment acquisition device and a target device;
environment acquisition device for multiplying 2 by target data represented by floating point data type in the device N Then integer cutting is carried out to obtain an integer expression form of the target data; the system is also used for participating in the processing of the target data and the transmission of the target data to the target equipment in the integer expression form of the target data;
the target device is used for determining the integer expression form of the target data based on the target data sent by the environment acquisition device before the analysis processing of the shaping data in the environment acquisition device is performed; the method is also used for carrying out the analysis processing on the integer expression form of the target data, converting the analysis processing result into floating point data, and dividing the converted floating point data by 2 N
Wherein N is a positive integer determined based on the accuracy requirement of the target data, and the integer expression form of the target data is the target data multiplied by 2 N And then shaping and cutting.
Optionally, in the target device, the process of determining the integer expression form of the target data may specifically include: if the device receives the integer expression form of the target data, the received data is determined to be the integer expression form of the target data, and if the device receives the target data of the floating point data type, the received target data is multiplied by 2 N And then integer cutting is carried out, and the cutting result is determined to be an integer expression form of the target data.
The present application also provides a computer readable storage medium storing instructions that, when executed by a processor, perform steps as described above in implementing a data processing method of an environmental acquisition device or a data processing method in a target device. In practice, the computer readable medium may be comprised by or separate from the apparatus/device/system of the above embodiments, and may not be incorporated into the apparatus/device/system. Wherein the instructions stored in the computer readable storage medium, which stored instructions, when executed by the processor, may perform the steps in a data processing method of an environmental acquisition device or a data processing method in a target device as described above.
According to embodiments disclosed herein, the computer-readable storage medium may be a non-volatile computer-readable storage medium, which may include, for example, but is not limited to: portable computer diskette, hard disk, random Access Memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), portable compact disc read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination of the foregoing, but are not intended to limit the scope of the protection herein. In the embodiments disclosed herein, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
Fig. 10 is a schematic diagram of an electronic device according to the present application. As shown in fig. 10, a schematic structural diagram of an electronic device according to an embodiment of the present application is shown, specifically:
the electronic device can include a processor 1001 of one or more processing cores, a memory 1002 of one or more computer-readable storage media, and a computer program stored on the memory and executable on the processor. When the program of the memory 1002 is executed, a data processing method of the environment acquisition device can be implemented.
Specifically, in practical application, the electronic device may further include a power supply 1003, an input/output unit 1004, and other components. It will be appreciated by those skilled in the art that the structure of the electronic device shown in fig. 10 is not limiting of the electronic device and may include more or fewer components than shown, or may combine certain components, or a different arrangement of components. Wherein:
the processor 1001 is a control center of the electronic device, connects various parts of the entire electronic device using various interfaces and lines, and performs various functions of a server and processes data by running or executing software programs and/or modules stored in the memory 1002 and calling data stored in the memory 1002, thereby performing overall monitoring of the electronic device.
Memory 1002 may be used to store software programs and modules, i.e., the computer-readable storage media described above. The processor 1001 executes various functional applications and data processing by executing software programs and modules stored in the memory 1002. The memory 1002 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, application programs required for at least one function, and the like; the storage data area may store data created according to the use of the server, etc. In addition, memory 1002 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid-state storage device. Accordingly, the memory 1002 may also include a memory controller to provide the processor 1001 with access to the memory 1002.
The electronic device further includes a power supply 1003 for supplying power to the respective components, and may be logically connected to the processor 1001 through a power management system, so that functions of managing charging, discharging, power consumption management, and the like are implemented through the power management system. The power supply 1003 may also include one or more of any of a direct current or alternating current power supply, a recharging system, a power failure detection circuit, a power converter or inverter, a power status indicator, and the like.
The electronic device may also include an input output unit 1004, which input unit output 1004 may be used to receive input numeric or character information and to generate keyboard, mouse, joystick, optical signal inputs related to user settings and function control. The input unit output 1004 may also be used to display information entered by a user or provided to a user as well as various graphical user interfaces that may be composed of graphics, text, icons, video, and any combination thereof.
The foregoing description of the preferred embodiments of the invention is not intended to be limiting, but rather to enable any modification, equivalent replacement, improvement or the like to be made within the spirit and principles of the invention.

Claims (18)

1. A method of data processing for an environmental collection device, comprising:
for target data represented by a floating point data type in an environment acquisition device, multiplying the target data by 2 N Then integer cutting is carried out to obtain the integer expression form of the target data;
utilizing the integer expression form of the target data to participate in the processing and cross-platform transmission of the target data;
Wherein N is a positive integer determined based on the accuracy requirement for the target data.
2. The method of claim 1, wherein the utilizing the integer representation of the target data to participate in cross-platform transmission of the target data comprises:
and transmitting the integer expression form of the target data to target equipment in a cross-platform manner.
3. The method of claim 1, wherein the utilizing the integer representation of the target data to participate in cross-platform transmission of the target data comprises:
converting the integer representation of the target data into floating point data divided by 2 N Obtaining corrected target data;
and transmitting the corrected target data to target equipment in a cross-platform manner.
4. The method of claim 1, wherein the utilizing the integer representation of the target data to participate in processing the target data comprises:
converting the integer expression of the target data into floating point data and dividing the floating point data by 2 N Obtaining corrected target data;
and carrying out the processing on the corrected target data.
5. The method of claim 1, wherein the utilizing the integer representation of the target data to participate in processing the target data comprises:
When the processing can only be performed on integer data, performing corresponding processing on the integer expression form of the target data, converting the processing result into floating point data, and dividing the converted floating point data by 2 N
6. The method of any one of claims 1 to 5, wherein the environmental acquisition device is a thermal imager or a sound imager.
7. The method according to any one of claims 1 to 5, wherein the target data is external input data, acquisition data of an environmental acquisition device, intermediate operation data of an environmental acquisition device or output data of an environmental acquisition device.
8. The method of claim 7, wherein the external input data is a configuration parameter or a measurement parameter.
9. A data processing method of a target device, comprising:
receiving an integer expression form of target data sent by acquisition equipment;
converting the integer expression of the target data into floating point data and dividing the floating point data by 2 N Obtaining corrected target data;
analyzing and processing the corrected target data;
wherein N is a positive integer determined based on the accuracy requirement for the target data.
10. A data processing method of a target device, comprising:
receiving target data sent by environment acquisition equipment;
analyzing and processing the target data;
wherein when the analysis processing can only be performed on integer data in the environment acquisition device, the analysis processing on the target data includes:
determining an integer representation of the target data, the integer representation of the target data being the target data multiplied by 2 N Then shaping and cutting to obtain the finished product;
the analysis processing is carried out on the integer expression form of the target data, the processing result is converted into floating point data, and the converted floating point data is divided by 2 N
Wherein N is a positive integer determined based on the accuracy requirement for the target data.
11. The method of claim 10, wherein said determining an integer representation of said target data comprises:
when the target data sent by the environment acquisition equipment is in an integer expression form of the target data, determining the received data as the integer expression form of the target data;
when the target data sent by the environment acquisition equipment is corrected target data, multiplying the received corrected target data by 2 N And then integer cutting is carried out, and a cutting result is used as an integer expression form of the target data.
12. An environmental harvesting device, comprising: a target data preprocessing unit and a data processing unit;
the target data preprocessing unit is used for multiplying target data represented by floating point data type in the environment acquisition equipment by 2 N Then integer cutting is carried out to obtain the integer expression form of the target data;
the data processing unit is used for participating in processing and cross-platform transmission of the target data by utilizing the integer expression form of the target data;
wherein N is a positive integer determined based on the accuracy requirement for the target data.
13. A target device, comprising: the device comprises a receiving unit, a target data restoration unit and a data processing unit;
the receiving unit is used for receiving the integer expression form of the target data sent by the acquisition equipment;
the target data restoring unit is used for converting the integer expression form of the target data into floating point data and dividing the floating point data by 2 N Obtaining corrected target data;
the data processing unit is used for analyzing and processing the corrected target data;
Wherein N is a positive integer determined based on the accuracy requirement for the target data.
14. A target device, comprising: a receiving unit and a data processing unit;
the receiving unit is used for receiving target data sent by the environment acquisition equipment;
the data processing unit is used for analyzing and processing the target data;
wherein the data processing unit comprises a target data preprocessing subunit and an analysis processing subunit,
the target data preprocessing subunit is used for determining an integer expression form of target data when the analysis processing can only be performed on integer data in the environment acquisition equipment; the integer expression of the target data is the target data multiplied by 2 N Then, shaping and cutting are carried out, wherein N is a positive integer determined based on the precision requirement on the target data;
the analysis processing subunit is used for performing the analysis processing on the integer expression form of the target data determined by the target data preprocessing subunit when the analysis processing can only be performed on the shaping data in the environment acquisition equipmentThe analysis and processing are carried out, the processing result is converted into floating point data, and the converted floating point data is divided by 2 N
15. A data analysis system for an environmental collection device, comprising: an environment acquisition device and a target device;
the environment acquisition device is used for multiplying the target data represented by the floating point data type in the device by 2 N Then integer cutting is carried out to obtain the integer expression form of the target data; the method is also used for transmitting the integer expression form of the target data to target equipment;
the target device is used for converting the integer expression form of the target data sent by the environment acquisition device into floating point data and dividing the floating point data by 2 N Obtaining corrected target data; the method is also used for analyzing and processing the corrected target data;
wherein N is a positive integer determined based on the accuracy requirement for the target data.
16. A data analysis system for an environmental collection device, comprising: an environment acquisition device and a target device;
the environment acquisition device is used for multiplying the target data expressed in the floating point data type in the device by 2 N Then integer cutting is carried out to obtain the integer expression form of the target data; the system is also used for participating in the processing of the target data in the integer expression form of the target data and transmitting the target data to the target equipment in a cross-platform manner;
The target device is used for determining the integer expression form of the target data based on the target data sent by the environment acquisition device before the analysis processing which can only be carried out on the integer data in the environment acquisition device is carried out; the method is also used for carrying out the analysis processing on the integer expression form of the target data, converting the analysis processing result into floating point data, and dividing the converted floating point data by 2 N
Wherein the N isFor positive integers determined based on the accuracy requirement of the target data, the integer representation of the target data is the target data multiplied by 2 N And then shaping and cutting.
17. A computer readable storage medium having stored thereon computer instructions, which when executed by a processor, implement a data processing method of an environmental harvesting device according to any of claims 1-8 or implement a data processing method of a target device according to any of claims 9-11.
18. An electronic device comprising at least a computer-readable storage medium and a processor;
the processor is configured to read executable instructions from the computer readable storage medium and execute the instructions to implement the data processing method of the environmental collection device of any one of the preceding claims 1 to 8.
CN202311810394.2A 2023-12-26 2023-12-26 Environment acquisition equipment, target equipment and data processing method and system thereof Pending CN117707471A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311810394.2A CN117707471A (en) 2023-12-26 2023-12-26 Environment acquisition equipment, target equipment and data processing method and system thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311810394.2A CN117707471A (en) 2023-12-26 2023-12-26 Environment acquisition equipment, target equipment and data processing method and system thereof

Publications (1)

Publication Number Publication Date
CN117707471A true CN117707471A (en) 2024-03-15

Family

ID=90153217

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311810394.2A Pending CN117707471A (en) 2023-12-26 2023-12-26 Environment acquisition equipment, target equipment and data processing method and system thereof

Country Status (1)

Country Link
CN (1) CN117707471A (en)

Similar Documents

Publication Publication Date Title
US20210216314A1 (en) Performing Rounding Operations Responsive To An Instruction
EP4080351A1 (en) Arithmetic logic unit, and floating-point number multiplication calculation method and device
US7890558B2 (en) Apparatus and method for precision binary numbers and numerical operations
US20160092168A1 (en) Apparatus and method for converting floating-point operand into a value having a different format
KR101718817B1 (en) Apparatus for converting between floating point number and integer, and method thereof
WO2010051298A2 (en) Instruction and logic for performing range detection
US20140172936A1 (en) Floating-point error detection and correction
CN112527239B (en) Floating point data processing method and device
CN106997284B (en) Method and device for realizing floating point operation
CN117707471A (en) Environment acquisition equipment, target equipment and data processing method and system thereof
JP6646350B2 (en) Model calculation unit for calculating a function model based on data using data of various numerical formats, and control device
CN117056651A (en) Approximate calculation method and approximate calculation state machine of Sigmoid function
CN111310909B (en) Floating point number conversion circuit
JP2018524706A (en) Apparatus and method for processing floating point values
CN114691082A (en) Multiplier circuit, chip, electronic device, and computer-readable storage medium
CN117221747B (en) SOPC-based single-period dead pixel compensation and non-uniform correction method
US9141586B2 (en) Method, apparatus, system for single-path floating-point rounding flow that supports generation of normals/denormals and associated status flags
JP2513354B2 (en) Floating point arithmetic auxiliary circuit
JPS6126135A (en) Conversion circuit of floating point data
CN111313905A (en) Floating point number conversion method and device
CN116860202A (en) Data processing method, processor and storage medium
JP2005031847A (en) Method, program, and device for integer arithmetic operation
CN113625990A (en) Floating point-to-fixed point conversion device, method, electronic equipment and storage medium
CN117420982A (en) Chip comprising a fused multiply-accumulator, device and control method for data operations
CN117270813A (en) Arithmetic unit, processor, and electronic apparatus

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination