Element detection method and device, computer equipment and computer readable storage medium

By obtaining the energy window information of elements and determining the comparison threshold, and directly comparing the pulse signal, the real-time processing and efficient data transmission problems of high-energy ray detection in complex application scenarios in the prior art are solved, and the effect of quickly calculating element proportion information and reducing power consumption is achieved.

CN120010001APending Publication Date: 2025-05-16RAYCAN TECH CO LTD SU ZHOU
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311527354.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-11-16
Publication Date
2025-05-16

AI Technical Summary

Technical Problem

The existing high-energy ray detection methods are difficult to achieve real-time processing and efficient data transmission in complex application scenarios, especially in high temperature and deep well environments. The traditional MVT method has high requirements for chip computing power and large bandwidth occupies.

Method used

By obtaining the energy window information of elements, determining the comparison threshold, and comparing the pulse peak of the pulse signal with these thresholds, the acquisition of element counting and proportional information is achieved, simplifying the data processing and transmission process.

Benefits of technology

This method does not require complex fitting calculations, and can quickly calculate element proportion information on limited hardware resources, reduce power consumption, improve adaptability to high-temperature environments, and reduce bandwidth usage of data transmission.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120010001A_ABST
    Figure CN120010001A_ABST
Patent Text Reader

Abstract

The invention discloses an element detection method and device, computer equipment, a storage medium and a program product. The element detection method comprises the steps of obtaining first energy window information of a first element and second energy window information of a second element; determining a comparison threshold according to the first energy window information and the second energy window information; comparing the pulse peak value of the pulse signal with the comparison threshold value, counting the pulse peak value meeting a preset condition, and obtaining an element count value; and determining element proportion information of the pulse signal according to the element count value. By means of the element detection method, complex fitting calculation does not need to be carried out on the pulse waveform, even the process of drawing an energy spectrum is omitted, element proportion information can be directly obtained, and the process of obtaining the number of pulses of different energies is simplified.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of signal detection technology, and in particular to an element detection method, device, computer equipment and computer-readable storage medium. Background Art

[0002] In high-energy ray detection, the energy of high-energy rays can be deposited by scintillation crystals to generate visible light, and the photoelectric conversion device converts the visible light into an electrical signal to obtain information such as the energy of the high-energy rays. The corresponding scintillation pulse can be obtained through the probe, and the energy spectrum and time spectrum of the gamma ray can be obtained after digitization and subsequent signal processing. The MVT (Multi-Voltage Threshold) method is a method for digitizing scintillation pulses. It sets multiple fixed threshold voltages and only digitally samples the time when the scintillation pulse passes through the threshold voltage, thereby obtaining multiple sampling points in the fast rising edge stage and the relatively slow falling edge stage. After obtaining a series of time-voltage pair information, the pulse fitting method is used to accurately obtain the particle energy deposition information based on the scintillation pulse shape information based on the prior.

[0003] Although the MVT method saves the number of samples compared to the traditional ADC method, in some special applications, the MVT matching algorithm is still relatively complex and has high requirements for chip computing power. Therefore, it is difficult to complete on embedded chips such as FPGA (Field Programmable Gate Array), STM32, and DSP (Digital Signal Processing). However, in practical applications, computing devices with high computing power cannot penetrate into some usage scenarios. For example, in the usage scenario of oil exploration, the downhole depth is as high as tens of thousands of meters and the ambient temperature is high (such as 175°C). At the same time, in the process of oil logging, the flash time shows the characteristics of periodic bursts, and the data volume of the original sampling point will reach 10Mbps~1Gbps. In the existing methods, transmitting a large number of original sampling points to the host computer for processing will undoubtedly occupy a very high bandwidth, resulting in a decrease in the count rate. In addition, during fitting, due to repeated iterations, fitting each pulse will require an extremely high computing time. Summary of the invention

[0004] Based on this, it is necessary to provide an element detection method, device, computer equipment and computer-readable storage medium to address at least one of the above problems.

[0005] According to the first aspect of the present application, a method for element detection is provided, including obtaining first energy window information of a first element and second energy window information of a second element; determining a comparison threshold based on the first energy window information and the second energy window information; comparing a pulse peak value of a pulse signal with the comparison threshold, counting the pulse peak values ​​that meet preset conditions, and obtaining an element count value; and determining the element proportion information of the pulse signal based on the element count value.

[0006] In one embodiment, determining the comparison threshold based on the first energy window information and the second energy window information includes obtaining a first upper limit energy and a first lower limit energy of the first energy window information, and a second upper limit energy and a second lower limit energy of the second energy window information; determining a first upper limit threshold, a first lower limit threshold, a second upper limit threshold and a second lower limit threshold based on the correspondence between the pre-acquired pulse energy and the pulse peak, and the first upper limit energy, the first lower limit energy, the second upper limit energy and the second lower limit energy; and setting the first upper limit threshold, the first lower limit threshold, the second upper limit threshold and the second lower limit threshold as the comparison threshold.

[0007] In one embodiment, the element count value includes a first count value corresponding to a first element, and the comparison threshold is compared with the pulse peak value of the pulse signal, and counting the pulse peak values ​​that meet the preset conditions includes comparing the pulse peak value with the first lower threshold value and the first upper threshold value; in response to the comparison result that the pulse peak value is greater than or equal to the first lower threshold value, and the pulse peak value is less than or equal to the first upper threshold value, the first count value is counted.

[0008] In one embodiment, the element count value also includes a second count value corresponding to a second element, and comparing the comparison threshold with the pulse peak value of the pulse signal, and counting the pulse peak values ​​that meet the preset conditions also includes comparing the pulse peak value with the second lower threshold value and the second upper threshold value; in response to the comparison result that the pulse peak value is greater than or equal to the second lower threshold value, and the pulse peak value is less than or equal to the second upper threshold value, the second count value is counted.

[0009] In one embodiment, determining the comparison threshold based on the first energy window information and the second energy window information includes obtaining a first upper limit energy and a first lower limit energy of the first energy window information, and a second lower limit energy of the second energy window information; determining a first upper limit threshold, a first lower limit threshold, and a second lower limit threshold based on the correspondence between the pre-acquired pulse energy and the pulse peak, as well as the first upper limit energy, the first lower limit energy, and the second lower limit energy; and setting the first upper limit threshold, the first lower limit threshold, and the second lower limit threshold as the comparison threshold.

[0010] In one embodiment, the element count value includes a first count value corresponding to the first element and a second count value corresponding to the second element, and the comparing the pulse peak value of the pulse signal with the comparison threshold and counting the pulse peak values ​​that meet the preset conditions include: comparing the pulse peak value with the first lower threshold value and the first upper threshold value; in response to the comparison result that the pulse peak value is greater than or equal to the first lower threshold value, and the pulse peak value is less than or equal to the first upper threshold value, counting the first count value; comparing the pulse peak value with the second lower threshold value; in response to the pulse peak value being greater than or equal to the second lower threshold value, counting the second count value.

[0011] In one embodiment, determining the comparison threshold based on the first energy window information and the second energy window information includes obtaining a first lower limit energy of the first energy window information, and a second upper limit energy and a second lower limit energy of the second energy window information; determining a first lower limit threshold, a second upper limit threshold and a second lower limit threshold based on the correspondence between the pre-acquired pulse energy and the pulse peak, and the first lower limit energy, the second upper limit energy and the second lower limit energy; and setting the first lower limit threshold, the second upper limit threshold and the second lower limit threshold as the comparison threshold.

[0012] In one embodiment, the element count value includes a first count value corresponding to the first element and a second count value corresponding to the second element, and the pulse peak value of the pulse signal is compared with the comparison threshold, and counting the pulse peak values ​​that meet the preset conditions includes comparing the pulse peak value with the first lower limit threshold; performing a first count in response to the pulse peak value being greater than or equal to the first lower limit threshold; comparing the pulse peak value with the second lower limit threshold; counting the second count value in response to the comparison result that the pulse peak value is greater than or equal to the second lower limit threshold and the pulse peak value is less than or equal to the second upper limit threshold, and the first count value is determined by subtracting the second count value from the result of the first count.

[0013] In one embodiment, determining the comparison threshold based on the first energy window information and the second energy window information includes obtaining a first lower limit energy of the first energy window information, and a second lower limit energy of the second energy window information; determining a first lower limit threshold and a second lower limit threshold based on a correspondence between a pre-acquired pulse energy and a pulse peak, and the first lower limit energy and the second lower limit energy; and setting the first lower limit threshold and the second lower limit threshold as the comparison threshold.

[0014] In one embodiment, the element count value includes a first count value corresponding to the first element and a second count value corresponding to the second element, and the pulse peak value of the pulse signal is compared with the comparison threshold, and counting the pulse peak values ​​that meet the preset conditions includes comparing the pulse peak value with the first lower limit threshold; performing a first count in response to the pulse peak value being greater than or equal to the first lower limit threshold; comparing the pulse peak value with the second lower limit threshold; performing a second count in response to the pulse peak value being greater than or equal to the second lower limit threshold, and using the value of the second count as the second count value, and subtracting the second count value from the result of the first count as the first count value.

[0015] In one embodiment, the element proportion information is a ratio of the first count value to the second count value.

[0016] In one of the embodiments, before obtaining the first energy window information of the first element and the second energy window information of the second element, the element detection method also includes setting a standard threshold; outputting a correction signal based on the standard threshold; determining a correction parameter according to the deviation between the correction signal and the standard threshold; and performing threshold correction on the comparison threshold according to the correction parameter.

[0017] In one embodiment, the first element is carbon, and the second element is oxygen.

[0018] According to the second aspect of the present application, an element detection device is provided, including a control module, which is used to obtain first energy window information of a first element and second energy window information of a second element, determine a comparison threshold according to the first energy window information and the second energy window information, and generate a control signal according to the comparison threshold; a comparison module, which is connected to the control module, and is used to set the comparison threshold according to the control signal, and compare the pulse peak value of a pulse signal with the comparison threshold; a counting module, which is respectively connected to the control module and the comparison module, and is used to count the pulse peak values ​​that meet preset conditions to obtain the element count value; the control module is also used to determine the element proportion information of the pulse signal according to the element count value.

[0019] In one embodiment, the control module includes a first analysis unit, which is used to obtain a first upper limit energy and a first lower limit energy of the first energy window information, and a second upper limit energy and a second lower limit energy of the second energy window information; a second analysis unit, which is connected to the first analysis unit, is used to determine a first upper limit threshold, a first lower limit threshold, a second upper limit threshold and a second lower limit threshold according to the correspondence between the pre-acquired pulse energy and the pulse peak, and the first upper limit energy, the first lower limit energy, the second upper limit energy and the second lower limit energy; a main control unit, which is connected to the second analysis unit, is used to generate a first control signal according to the first upper limit threshold, generate a second control signal according to the first lower limit threshold, generate a third control signal according to the second upper limit threshold, and generate a fourth control signal according to the second lower limit threshold.

[0020] In one embodiment, the comparison module includes a first comparator connected to the main control unit, and used to set the first upper limit threshold according to the first control signal; a second comparator connected to the main control unit, and used to set the first lower limit threshold according to the second control signal; a third comparator connected to the main control unit, and used to set the second upper limit threshold according to the third control signal; and a fourth comparator connected to the main control unit, and used to set the second lower limit threshold according to the fourth control signal.

[0021] In one embodiment, the first comparator is also used to compare the pulse peak value of the pulse signal with the first upper threshold value, and output a first counting signal when the pulse peak value is less than or equal to the first upper threshold value; the second comparator is also used to compare the pulse peak value with the first lower threshold value, and output a second counting signal when the pulse peak value is greater than or equal to the first lower threshold value; the third comparator is also used to compare the pulse peak value with the second upper threshold value, and output a third counting signal when the pulse peak value is less than or equal to the second upper threshold value; the fourth comparator is also used to compare the pulse peak value with the second lower threshold value, and output a fourth counting signal when the pulse peak value is greater than or equal to the second lower threshold value.

[0022] In one embodiment, the counting module includes a first counter connected to the first comparator and the second comparator respectively, and configured to count a first counting value corresponding to the first element according to the first counting signal and the second counting signal.

[0023] In one embodiment, the counting module includes a second counter connected to the third comparator and the fourth comparator respectively, and configured to count a second counting value corresponding to the second element according to the third counting signal and the fourth counting signal.

[0024] In one embodiment, the control module includes a first analysis unit, which is used to obtain a first upper limit energy and a first lower limit energy of the first energy window information, and a second lower limit energy of the second energy window information; a second analysis unit, which is connected to the first analysis unit, is used to determine a first upper limit threshold, a first lower limit threshold, and a second lower limit threshold based on the correspondence between the pre-acquired pulse energy and the pulse peak, as well as the first upper limit energy, the first lower limit energy, and the second lower limit energy; a main control unit, which is connected to the second analysis unit, is used to generate a first control signal according to the first upper limit threshold, generate a second control signal according to the first lower limit threshold, and generate a fourth control signal according to the second lower limit threshold.

[0025] In one embodiment, the comparison module includes a first comparator connected to the main control unit, used to set the first upper threshold value according to the first control signal, and also used to compare the pulse peak value of the pulse signal with the first upper threshold value, and output a first counting signal when the pulse peak value is less than or equal to the first upper threshold value; a second comparator connected to the main control unit, used to set the first lower threshold value according to the second control signal, and also used to compare the pulse peak value with the first lower threshold value, and output a second counting signal when the pulse peak value is greater than or equal to the first lower threshold value; a fourth comparator connected to the main control unit, used to set the second lower threshold value according to the fourth control signal, and also used to compare the pulse peak value with the second lower threshold value, and output a fourth counting signal when the pulse peak value is greater than or equal to the second lower threshold value.

[0026] In one embodiment, the counting module includes a first counter, which is respectively connected to the first comparator and the second comparator, and is used to count the first count value corresponding to the first element according to the first count signal and the second count signal; and a second counter, which is connected to the fourth comparator, and is used to count the second count value corresponding to the second element according to the fourth count signal.

[0027] In one embodiment, the control module includes a first analysis unit, which is used to obtain a first lower limit energy of the first energy window information, and a second upper limit energy and a second lower limit energy of the second energy window information; a second analysis unit, which is connected to the first analysis unit, is used to determine a first lower limit threshold, a second upper limit threshold and a second lower limit threshold based on the correspondence between the pre-acquired pulse energy and the pulse peak, and the first lower limit energy, the second upper limit energy and the second lower limit energy; a main control unit, which is connected to the second analysis unit, generates a second control signal according to the first lower limit threshold, generates a third control signal according to the second upper limit threshold, and generates a fourth control signal according to the second lower limit threshold.

[0028] In one embodiment, the comparison module includes a second comparator connected to the main control unit, used to set the first lower threshold according to the second control signal, and also used to compare the pulse peak value with the first lower threshold value, and output a second counting signal when the pulse peak value is greater than or equal to the first lower threshold value; a third comparator connected to the main control unit, used to set the second upper threshold value according to the third control signal, and also used to compare the pulse peak value of the pulse signal with the second upper threshold value, and output a third counting signal when the pulse peak value is less than or equal to the second upper threshold value; a fourth comparator connected to the main control unit, used to set the second lower threshold value according to the fourth control signal, and also used to compare the pulse peak value with the second lower threshold value, and output a fourth counting signal when the pulse peak value is greater than or equal to the second lower threshold value.

[0029] In one embodiment, the counting module includes a first counter connected to the second comparator, and used to perform a first count according to the second counting signal; a second counter connected to the third comparator and the fourth comparator, respectively, and used to count the second count value corresponding to the second element according to the third counting signal and the fourth counting signal; the first counter is also used to determine the first count value by subtracting the second count value from the result of the first count.

[0030] In one embodiment, the control module includes a first analysis unit, used to obtain a first lower limit energy of the first energy window information, and a second lower limit energy of the second energy window information; a second analysis unit, connected to the first analysis unit, used to determine a first lower limit threshold and a second lower limit threshold based on the correspondence between the pre-acquired pulse energy and the pulse peak, and the first lower limit energy and the second lower limit energy; a main control unit, connected to the second analysis unit, generates a second control signal according to the first lower limit threshold, and generates a fourth control signal according to the second lower limit threshold.

[0031] In one embodiment, the comparison module includes a second comparator connected to the main control unit, used to set the first lower limit threshold according to the second control signal, and also used to compare the pulse peak value with the first lower limit threshold, and output a second counting signal when the pulse peak value is greater than or equal to the first lower limit threshold; a fourth comparator connected to the main control unit, used to set the second lower limit threshold according to the fourth control signal, and also used to compare the pulse peak value with the second lower limit threshold, and output a fourth counting signal when the pulse peak value is greater than or equal to the second lower limit threshold.

[0032] In one embodiment, the counting module includes a first counter connected to the second comparator, and used to perform a first count according to the second counting signal; a second counter connected to the fourth comparator, and used to perform a second count according to the fourth counting signal, and use the result of the second count as the second count value; the first counter is also used to determine the first count value by subtracting the second count value from the result of the first count.

[0033] In one of the embodiments, the main control unit is also connected to the first counter and the second counter respectively, and the main control unit is further used to determine the element ratio information of the pulse signal according to the ratio of the first count value to the second count value.

[0034] In one embodiment, the element detection device also includes a correction module, which is connected to the comparison module and is used to set a standard threshold, output a correction signal based on the standard threshold, determine a correction parameter according to a deviation between the correction signal and the standard threshold, and perform threshold correction on the comparison threshold according to the correction parameter.

[0035] According to a third aspect of the present application, there is provided an element detection device, the device comprising a pulse signal processing circuit board, the pulse signal processing circuit board being used to acquire a pulse signal and implement the steps of the element detection method described in any one of the above embodiments.

[0036] According to a fourth aspect of the present application, a computer device is provided, comprising a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps of the element detection method described in any one of the above embodiments when executing the computer program.

[0037] According to a fifth aspect of the present application, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps of the element detection method described in any one of the above embodiments are implemented.

[0038] According to a sixth aspect of the present application, a computer program product is provided, comprising a computer program, wherein when the computer program is executed by a processor, the steps of the element detection method described in any one of the above embodiments are implemented.

[0039] The element detection method, device, computer equipment and computer-readable storage medium provided by the present application determine a comparison threshold based on the first energy window information of the first element and the second energy window information of the second element, and count the pulse peaks that meet the preset conditions by comparing the pulse peak value of the pulse signal with the comparison threshold value to obtain the element count value, and the element proportion information of the pulse signal can be determined according to the element count value. Using the above-mentioned element detection method, there is no need to perform complex fitting calculations on the pulse waveform, and even the process of drawing the energy spectrum is omitted, and the element proportion information can be directly obtained, which simplifies the process of obtaining the number of pulses of different energies. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0041] Figure 1 This is a flow chart of an element detection method in one of the embodiments of the present application;

[0042] Figure 2 This is a flow chart of a method for determining a comparison threshold in one of the embodiments of the present application;

[0043] Figure 3 A flow chart of a method for counting pulse peak values ​​that meet preset conditions in one embodiment of the present application;

[0044] Figure 4 A flow chart of a method for counting pulse peak values ​​that meet preset conditions in another embodiment of the present application;

[0045] Figure 5 This is a flow chart of a threshold correction method in one of the embodiments of the present application;

[0046] Figure 6 This is a schematic diagram of the structure of an element detection device in one of the embodiments of the present application;

[0047] Figure 7 This is a schematic diagram of the structure of a control module in one of the embodiments of the present application;

[0048] Figure 8This is a schematic diagram of the connection structure of the comparison module and the counting module in one embodiment of the present application;

[0049] Fig. 9 This is a schematic diagram of the connection structure of the comparison module and the counting module in another embodiment of the present application;

[0050] Fig.10 This is a schematic diagram of the connection structure of the comparison module and the counting module in another embodiment of the present application;

[0051] Fig.11 This is a schematic diagram of the connection structure of the comparison module and the counting module in another embodiment of the present application;

[0052] Fig.12 This is a schematic diagram of the connection structure of the comparison module, the counting module and the correction module in one embodiment of the present application;

[0053] Fig.13 This is a schematic diagram of an element detection device for implementing an element detection method in one embodiment of the present application;

[0054] Fig.14 This is a diagram of the internal structure of a computer device in one of the embodiments of the present application. DETAILED DESCRIPTION

[0055] In order to make the above-mentioned purposes, features and advantages of the present application more obvious and easy to understand, the specific implementation methods of the present application are described in detail below in conjunction with the accompanying drawings. In the following description, many specific details are set forth to facilitate a full understanding of the present application. However, the present application can be implemented in many other ways different from those described herein, and those skilled in the art can make similar improvements without violating the connotation of the present application, so the present application is not limited by the specific embodiments disclosed below.

[0056] It should be noted that when an element is referred to as being "fixed to" another element, it may be directly fixed to the other element or there may be an element in the middle. When an element is considered to be "connected to" another element, it may be directly connected to the other element or there may be an element in the middle at the same time. The terms "vertical", "horizontal", "left", "right" and similar expressions used herein are for illustrative purposes only.

[0057] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein in the specification of this application are only for the purpose of describing specific embodiments and are not intended to limit this application. The terms "and / or" or "and / or" used herein include any and all combinations of one or more related listed items.

[0058] In the existing MVT digitization method, energy calculation is completed through the following steps:

[0059] 1) According to the coupled scintillation crystal and the photoelectric conversion device, the corresponding scintillation pulse shape characteristic model is obtained; for example, when the LaBr3 scintillation crystal is coupled with the photoelectric conversion device, without considering the influence of noise, the scintillation pulse shape can be characterized by a fast rising edge and a slow falling edge. The scintillation pulse shape characteristic model can be considered to be expressed by the following function:

[0060] y=e a x c e bx ,

[0061] Among them, y represents the amplitude of the scintillation pulse, such as the voltage amplitude, x represents different moments, e is a natural constant, and the three parameters a, b, and c are all to be determined. That is, a scintillation pulse signal generated by LaBr3 / PMT coupling can be determined by three characteristic values ​​a, b, and c;

[0062] 2) The detector collects a series of time-voltage data, which are fit and restored on the FPGA according to the scintillation pulse characteristic model of the above function. This process is implemented in the hardware circuit. The FPGA fits the function of the pulse waveform and then integrates the pulse waveform in a cumulative manner, thereby calculating the energy information of the pulse;

[0063] 3) After FPGA completes the calculation of pulse energy, it sends the energy information to DSP, which then draws the energy spectrum.

[0064] However, when using the above energy calculation method to obtain the energy spectrum of the scintillation pulse, it is necessary to perform pulse fitting on the above mathematical model in hardware circuits such as FPGA and ASIC (Application Specific Integrated Circuit), restore the pulse waveform by solving the equation, and then obtain the energy information by integrating the fitted function to draw the energy spectrum. This will take up a lot of hardware resources, and the pulse fitting process will cause the chip to consume huge power. At the same time, the high temperature resistance of the chip will be affected by the power consumption of the program running on the chip, and the logging equipment needs to be suitable for application scenarios with ambient temperatures as high as 175°C. An overly complex pulse fitting process will cause the chip to be less tolerant to high temperatures due to excessive power consumption.

[0065] In addition, when the amount of collected data is too large, the computing power of embedded chips such as FPGA, STM32, and DSP is insufficient to complete the existing MVT fitting algorithm. This requires that the original sampling points obtained by the MVT method must be transmitted to a computer or server with strong computing power through Ethernet, serial port, WiFi, etc., and then the energy is calculated through the software iteration algorithm. During the logging process, the scintillation pulse event may show periodic outbreaks, and the data volume of the original sampling point will reach 10Mbps~1Gbps. However, due to the use scenario, such as the characteristics of the downhole depth of tens of thousands of meters and the high ambient temperature, the transmission method can only use the carrier communication method, and its bandwidth is only about 100Kbps. In the existing method, the transmission of numerous original sampling points will undoubtedly occupy a very high bandwidth, resulting in a decrease in the count rate. When fitting on the host computer, due to repeated iterations, fitting each pulse will take up an extremely high computing time.

[0066] The present application provides an element detection method, which can quickly calculate the element proportion information on hardware and realize board-level fitting, that is, realize the calculation on chip boards such as FPGA and DSP. Some preferred embodiments of the present application are described in conjunction with the following reference drawings. It should be noted that the following description is for illustrative purposes and is not intended to limit the scope of protection of the present application.

[0067] In some embodiments, the element detection method can be performed by an element detection device. For example, the element detection method can be stored in a storage device (such as a built-in storage unit or an external storage device of the element detection device) in the form of a program or instruction, and the program or instruction can implement the element detection method when executed. The element detection device disclosed in the present application for implementing the above-mentioned element detection method can be a device with a large amount of computing resources (for example, a computer, a server, cloud computing, etc.), or a device with limited computing resources (for example, a hardware circuit such as an FPGA chip board, an ASIC chip board, etc.).

[0068] Figure 1 This is a flow chart of an element detection method in one embodiment of the present application. The element detection method may include steps S100 to S400.

[0069] Step S100: Acquire first energy window information of a first element and second energy window information of a second element.

[0070] In C / O (carbon / oxygen) spectrum logging, the properties of downhole materials are judged based on the ratio of the number of pulses in the energy ranges corresponding to the carbon element and the oxygen element on the obtained spectrum. In short, this logging method needs to obtain the number of two types of pulses respectively. Therefore, when the above-mentioned element detection method is applied to C / O spectrum logging, the first element can be carbon and the second element can be oxygen. When the first element is carbon and the second element is oxygen, the first energy window information is the carbon energy window and the second energy window information is the oxygen energy window.

[0071] According to the prior information, the energy ranges corresponding to the gamma rays generated by the carbon element / oxygen element can be determined. At the same time, according to the accuracy requirements of different application scenarios, suitable energy ranges can be selected as carbon energy windows and oxygen energy windows, that is, the first energy window information and the second energy window information. Among them, the first energy window information and the second energy window information can be obtained in a variety of ways. For example, it can be obtained from the host computer through wired / wireless communication, or it can be input through human-computer interaction and other methods.

[0072] Step S200: determining a comparison threshold according to the first energy window information and the second energy window information.

[0073] According to the collected prior information, it is found that the energy of the scintillation pulse has a relatively obvious linear relationship with the amplitude of the scintillation pulse, that is, the energy information of the scintillation pulse can be obtained by acquiring the amplitude information of the scintillation pulse. Therefore, in some embodiments of the present application, a scintillation pulse energy amplitude lookup table can be prepared using the prior information. The energy amplitude lookup table includes the mapping relationship between the pulse peak value of the scintillation pulse and the energy information.

[0074] The first energy window information is the energy range corresponding to the first element, and the second energy window information is the energy range corresponding to the second element. The energy has a relatively obvious linear relationship with the amplitude of the scintillation pulse. Therefore, the amplitude range corresponding to the first element and the amplitude range corresponding to the second element can be determined respectively according to the first energy window information and the second energy window information. The comparison threshold can be selected by selecting appropriate values ​​in the amplitude range corresponding to the first element and the amplitude range corresponding to the second element as the comparison threshold, for example, using the endpoint value or the middle value as the comparison threshold. Exemplarily, when the amplitude range corresponding to the gamma ray generated by the first element is 50mV-60mV, 50mV and / or 60mV can be selected as the comparison threshold, or 54mV and / or 56mV can be selected as the comparison threshold.

[0075] Step S300: Compare the pulse peak value of the pulse signal with the comparison threshold, count the pulse peak values ​​that meet the preset conditions, and obtain the element count value.

[0076] In some embodiments, the pulse signal may be a scintillation pulse, which may be obtained by a detection device. For example, a scintillation detector. The scintillation detector may include mutually coupled scintillation crystals and photoelectric conversion devices. The scintillation crystals are used to convert the detected high-energy rays into visible light signals, and the photoelectric conversion devices are used to convert the visible light signals into electrical signals, which are output in the form of scintillation pulses through electronic devices connected to the photoelectric conversion devices. The scintillation crystals may be crystals such as BGO, PWO, LYSO:Ce, GAGG:Ce, NaI:TI, CsI:TI, LaBr3:Ce, BaF2, etc., the high-energy rays may be rays such as gamma rays and neutron rays, and the photoelectric conversion devices may be devices such as photomultiplier tubes (PMT, photomultiplier tubes), silicon photomultiplier tubes (SiPM, Silicon photomultiplier), etc.

[0077] By comparing the pulse peak value of the pulse signal with the comparison threshold, the pulse peak values ​​that meet the conditions can be counted according to the comparison result, thereby determining the element count value. The element count value can be a value used to characterize the number of pulses in the energy range corresponding to the first element in the pulse signal, or a value used to characterize the number of pulses in the energy range corresponding to the second element in the pulse signal.

[0078] Step S400: determining element proportion information of the pulse signal according to the element count value.

[0079] The element ratio information of the pulse signal can be determined based on the element count value. When the above element detection method is applied to C / O spectrum logging, the element ratio information can be the C / O value, that is, the ratio of the number of pulses in the energy range corresponding to the carbon element to the number of pulses in the energy range corresponding to the oxygen element. The properties of the downhole material can be judged based on the C / O value.

[0080] Compared with the traditional MVT method, the present application does not need to fit the pulse waveform by solving the equation group to obtain the function curve in the process of processing the pulse signal, and even more, it does not need to obtain the energy spectrum of the pulse. The number of pulses with different energies in the pulse signal can be determined by selecting a suitable comparison threshold and comparing it with the pulse signal. The ratio of different elements can be directly obtained, which greatly simplifies the structure and work of the detector in oil well logging, and can save more hardware resources when FPGA resources are limited, reduce the power consumption of FPGA, and improve the chip's tolerance to high temperatures.

[0081] In addition, the traditional MVT method requires complex fitting calculations, and the system cannot process new pulses within a specific period of time after each pulse ends. This time can be called the dead time of the acquisition device. The embodiment of the present application can directly obtain the ratio of different elements through simple threshold comparison, without performing a complex calculation process for pulse waveform fitting, and without accumulating the collected voltage values. Therefore, the dead time of the work can be greatly shortened, and the continuous pulse processing can be basically completed. The system has no dead time or the dead time is very small.

[0082] Figure 2 This is a flow chart of a method for determining a comparison threshold in one of the embodiments of the present application. In one of the embodiments, determining the comparison threshold according to the first energy window information and the second energy window information may include steps S210 to S230.

[0083] Step S210: obtaining a first upper limit energy and a first lower limit energy of the first energy window information, and a second upper limit energy and a second lower limit energy of the second energy window information.

[0084] The first energy window information obtained in step S100 may be the energy range corresponding to the gamma rays generated by the first element. Therefore, two endpoint values ​​may be obtained according to the first energy window information, which are the first upper limit energy and the first lower limit energy corresponding to the gamma rays generated by the first element. For example, when the amplitude range corresponding to the gamma rays generated by the first element is 50mV-60mV, the first upper limit energy may be 60mV, and the first lower limit energy may be 50mV. Similarly, the second upper limit energy and the second lower limit energy may also be determined according to the second energy window information.

[0085] Step S220: Determine the first upper limit threshold, the first lower limit threshold, the second upper limit threshold and the second lower limit threshold according to the correspondence between the pre-acquired pulse energy and the pulse peak, as well as the first upper limit energy, the first lower limit energy, the second upper limit energy and the second lower limit energy.

[0086] In some embodiments, the prior information can be used to obtain the corresponding relationship between the pulse energy and the pulse peak value in advance. By using a high-speed sampling device such as an oscilloscope, a large number of scintillation pulses generated by γ photons are collected at the highest possible sampling frequency, and each scintillation pulse is integrated using software such as MATLAB to obtain the energy information of the scintillation pulse, and the pulse peak value of the scintillation pulse is recorded at the same time. The energy information and pulse peak value of the scintillation pulse are plotted as a scatter plot and fitted, and the linear relationship between the pulse energy and the pulse peak value can be obtained, and a lookup table of the energy amplitude of the scintillation pulse can also be formed.

[0087] The pulse amplitude corresponding to the first upper limit energy can be determined based on the energy amplitude lookup table, and the pulse amplitude can be determined as the first upper limit threshold VCmax Similarly, the first lower limit threshold V can also be determined based on the energy amplitude lookup table, the first lower limit energy, the second upper limit energy, and the second lower limit energy. Cmin , the second upper threshold V Omax and the second lower threshold V Omin .

[0088] Furthermore, the upper threshold and the lower threshold can be further selected based on the linear relationship between the pulse energy and the pulse peak value or the energy amplitude lookup table, for example, the endpoint value of any interval is selected within the endpoint value range corresponding to the first upper limit energy, the first lower limit energy, the second upper limit energy, and the second lower limit energy as the first upper limit threshold V Cmax , the first lower threshold V Cmin , the second upper threshold V Omax and the second lower threshold V Omin For example, when the amplitude range of the gamma ray energy generated by the first element is 50mV-60mV, 54mV or 56mV can be selected as the first upper limit threshold V Cmax , the first lower threshold V Cmin By selecting more suitable intervals within the endpoint value range as the upper and lower thresholds, the count values ​​corresponding to different elements can be further screened, which is conducive to the detection of elements with different specifications and different precisions.

[0089] Step S230: setting the first upper threshold, the first lower threshold, the second upper threshold and the second lower threshold as comparison thresholds.

[0090] By setting the first upper threshold V Cmax , the first lower threshold V Cmin , the second upper threshold V Omax and the second lower threshold V Omin It is set as a comparison threshold, and subsequently the ratio of the number of pulses in the energy ranges corresponding to the first element and the second element can be obtained based on the comparison between the pulse peak value of the pulse signal and the comparison threshold.

[0091] Figure 3 This is a flow chart of a method for counting pulse peaks that meet preset conditions in one embodiment of the present application. In one embodiment, the element count value may include a first count value corresponding to the first element, and the first count value may be the number of pulse peaks that meet the first energy window information. Comparing the comparison threshold with the pulse peak value of the pulse signal, and counting the pulse peak values ​​that meet the preset conditions may include steps S310 to S320.

[0092] Step S310: Compare the pulse peak value with a first lower threshold and a first upper threshold.

[0093] Since the first lower threshold V Cmin and the first upper threshold V Cmax is the comparison threshold value corresponding to the energy values ​​at the two energy window endpoints of the first energy window information. Therefore, by comparing the pulse peak value with the first lower limit threshold V Cmin and the first upper threshold V Cmax By comparison, it can be determined whether the pulse peak falls within the first energy window information.

[0094] Step S320: In response to the comparison result that the pulse peak value is greater than or equal to the first lower threshold value, and the pulse peak value is less than or equal to the first upper threshold value, counting the first count value.

[0095] When the pulse peak of the pulse signal exceeds the first lower threshold V Cmin , without crossing the first upper threshold V Cmax Based on the judgment result of this situation, it can be determined that the pulse peak value falls into the energy range corresponding to the first element, and the first count value is increased by 1. When the pulse peak values ​​corresponding to all the pulse signals to be tested are equal to the first lower limit threshold V Cmin and the first upper threshold V Cmax After comparison, the number of pulses in the energy range corresponding to the first element can be determined according to the first count value.

[0096] Figure 4 This is a flow chart of a method for counting pulse peaks that meet preset conditions in another embodiment of the present application. In one embodiment, the element count value may include a second count value corresponding to the second element, and the second count value may be the number of pulse peaks that meet the second energy window information. Comparing the comparison threshold with the pulse peak value of the pulse signal, and counting the pulse peak values ​​that meet the preset conditions may also include steps S330 to S340.

[0097] Step S330: Compare the pulse peak value with the second lower threshold and the second upper threshold.

[0098] Since the second lower threshold V Omin and the second upper threshold V Omax is the comparison threshold corresponding to the energy values ​​at the two energy window endpoints of the second energy window information. Therefore, by comparing the pulse peak value with the second lower limit threshold V Omin and the second upper threshold V Omax By comparison, it can be determined whether the pulse peak falls within the second energy window information.

[0099] Step S320: In response to the comparison result that the pulse peak value is greater than or equal to the second lower threshold value, and the pulse peak value is less than or equal to the second upper threshold value, counting the second count value.

[0100] When the pulse peak of the pulse signal exceeds the second lower threshold VOmin , without crossing the second upper threshold V Omax Based on the judgment result of this situation, it can be determined that the pulse peak value falls into the energy range corresponding to the second element, and the second count value is increased by 1. When the pulse peak values ​​corresponding to all the pulse signals to be tested are consistent with the second lower limit threshold V Omin and the second upper threshold V Omax After comparison, the number of pulses in the energy range corresponding to the second element can be determined according to the second count value.

[0101] In one embodiment, for other comparison results, the element count value may not be counted. For example, when the pulse peak value is less than the second lower limit threshold V Omin or greater than the second upper threshold V Omax In this case, the first count value is not counted.

[0102] Based on the above, it should be understood by those skilled in the art that in some application requirements, such as application requirements where the accuracy is not very high, the first upper limit threshold V Cmax , the first lower threshold V Cmin The second lower threshold V Omin Counting is performed, at this time the second lower limit threshold V Omin Usually higher than the first upper threshold V Cmax At this time, it is considered that the pulse peak exceeds the second lower threshold V Omin When the second element is counted, it is considered that all energies meet the second lower limit threshold V Omin The required pulses are counted according to the second element; or the first lower threshold V Cmin and the second upper threshold V Omax , the second lower threshold V Omin Compare the counts, at this time due to the first lower limit threshold V Cmin Small, any pulse peak counted by the second element must be the first lower threshold V Cmin Count, so when calculating the first count value, the first lower limit threshold V Cmin The count value of the first element is subtracted from the count value corresponding to the second element. This method is suitable for detecting elements with large energy differences, and can further reduce the logic resources required for counting and speed up the detection process.

[0103] Based on the above, it should be understood by those skilled in the art that in some application requirements, such as application requirements where the accuracy is not very high, only the first lower limit threshold V Cmin Or the second lower threshold V Omin When the pulse peak value crosses the first lower threshold V Cmin Or the second lower threshold V OminWhen the corresponding ones are counted, at this time, since the first lower limit threshold V Cmin and the second lower threshold V Omin There is a size relationship, for example, the second lower limit threshold V Omin Greater than the first lower threshold V Cmin , then it crosses the second lower threshold V Omin The pulse must cross the first lower threshold V Cmin , therefore, will cross the second lower threshold V Omin The count value of the second element will cross the first lower threshold V Cmin The count value minus the second count value is taken as the count value corresponding to the first element, that is, all pulses whose energies meet the lower limit requirement are regarded as being counted according to the first element or the second element. This method is suitable for detecting elements with large energy differences, and can further reduce the logic resources required for counting and speed up the detection process.

[0104] In one embodiment, the element ratio information may be a ratio of the first count value to the second count value. When the pulse peaks corresponding to the pulse signal to be measured are both equal to the first upper limit threshold V Cmax , the first lower threshold V Cmin , the second upper threshold V Omax and the second lower threshold V Omin After comparison, the element proportion information can be obtained according to the ratio of the first count value to the second count value. When the above element detection method is applied to C / O spectrum logging, the element proportion information can be the C / O value, that is, the ratio of the number of pulses in the energy range corresponding to the carbon element to the number of pulses in the energy range corresponding to the oxygen element. Based on the C / O value, the properties of the downhole material can be judged.

[0105] The above-mentioned element detection method can directly determine the ratio of the number of pulses in the energy range corresponding to different elements by simple threshold comparison. In the process of processing the pulse signal, there is no need to fit the pulse waveform by solving a group of equations to obtain a function curve, nor is there a need to obtain the energy spectrum of the pulse, which simplifies the process of obtaining the number of pulses of different energies.

[0106] Figure 5 This is a flow chart of a threshold correction method in one of the embodiments of the present application. In one of the embodiments, before obtaining the first energy window information of the first element and the second energy window information of the second element, the element detection method may further include steps S10 to S40.

[0107] Step S10: Setting a standard threshold.

[0108] Considering that in actual application scenarios, devices usually operate in an environment with changing temperatures and generally high temperatures, and temperature is often an important factor that affects the working state of electronic devices. In order to enable the instrument to obtain more accurate data when working in different temperature environments, a threshold calibration process can be set. Determine the output difference of the DAC (Digital to Analog Converter) at different temperatures based on prior information, and adjust the comparison threshold accordingly based on the output difference. A standard threshold can be determined based on prior information, for example, the standard threshold is 3V.

[0109] Step S20: Outputting a correction signal based on a standard threshold.

[0110] The DAC output voltage value is set to be a correction signal of a standard threshold, such as outputting a 3V correction signal.

[0111] Step S30: determining a correction parameter according to a deviation between the correction signal and a standard threshold.

[0112] When the temperature changes, the actual correction signal output by the DAC may deviate from the standard threshold. Therefore, the correction parameter can be obtained by subtracting the correction signal output by the DAC from the standard threshold. For example, when the voltage value of the correction signal output by the DAC is actually 3.5V, and the difference between the voltage value of the correction signal and the standard threshold is 0.5V, the correction parameter is 0.5V. That is, the temperature change at this time causes the output of the DAC to produce a 0.5V offset. Therefore, adjusting the comparison threshold based on the correction parameter can prevent the offset of the comparison threshold from affecting the accuracy of the detection result.

[0113] Step S40: performing threshold correction on the comparison threshold according to the correction parameter.

[0114] The comparison threshold is corrected according to the correction parameter. For example, when the correction parameter is +0.5V, the comparison thresholds of all outputs are reduced by 0.5V; when the correction parameter is -0.5V, the comparison thresholds of all outputs are increased by 0.5V.

[0115] In the above-mentioned element detection method, before comparing the pulse signal with the comparison threshold, the comparison threshold can be calibrated first. The output difference of the DAC at different temperatures is determined based on prior information, and the comparison threshold is adjusted accordingly based on the output difference. By calibrating the comparison threshold, the accuracy of the detection result can be guaranteed, and the negative impact of voltage offset caused by changes in temperature or other environmental factors on the detection can be reduced.

[0116] Based on the description of the above-mentioned element detection method embodiment, the present application also provides an element detection device. The device can be a device for executing the method (including distributed system), software (application), module, component, server, client, etc. described in the embodiment of this specification and combined with necessary implementation hardware. Based on the same innovative concept, the device in one or more embodiments provided in the embodiment of the present application is as described in the following embodiments. Since the implementation scheme and method for solving the problem of the device are similar, the implementation of the specific element detection device of the embodiment of this specification can refer to the implementation of the aforementioned element detection method, and the repetitions will not be repeated.

[0117] The present application also provides an element detection device, which can be applied to the element detection device described in any one of the above embodiments. Figure 6 This is a schematic diagram of the structure of an element detection device in one embodiment of the present application. In one embodiment, the element detection device may include a control module 100, a comparison module 200 and a counting module 300.

[0118] The control module 100 can be used to obtain first energy window information of a first element and second energy window information of a second element, determine a comparison threshold according to the first energy window information and the second energy window information, and generate a control signal according to the comparison threshold.

[0119] The control module 100 can obtain the first energy window information of the first element and the second energy window information of the second element in a variety of ways. For example, the control module 100 can establish communication with the host computer through a communication unit to obtain the first energy window information and the second energy window information. The control module 100 can also be connected to a human-computer interaction module, which can include information sensing devices such as a touch screen and / or a keyboard. The user can input the first energy window information and the second energy window information into the control module 100 by touching and / or pressing buttons.

[0120] The first energy window information is the energy range corresponding to the first element, and the second energy window information is the energy range corresponding to the second element. The energy has a relatively obvious linear relationship with the amplitude of the scintillation pulse, so the control module 100 can determine the amplitude range corresponding to the first element and the amplitude range corresponding to the second element respectively according to the first energy window information and the second energy window information. The comparison threshold can be selected by selecting appropriate values ​​in the amplitude range corresponding to the first element and the amplitude range corresponding to the second element as the comparison threshold.

[0121] The control module 100 may output a control signal according to the comparison threshold, wherein the control signal may be used to control other functional modules to output a comparison signal of a corresponding threshold based on the comparison threshold.

[0122] The comparison module 200 may be connected to the control module 100. The comparison module 200 may set a comparison threshold according to the control signal to compare the pulse peak value of the pulse signal with the comparison threshold. The comparison module 200 may also output different signals according to different comparison results.

[0123] The counting module 300 can be connected to the control module 100 and the comparison module 200 respectively. The counting module 300 can be used to count the pulse peaks that meet the preset conditions to obtain the element count value. When the counting module 300 determines that the pulse peak of the pulse signal meets the preset conditions according to the signal output by the comparison module 200, it counts it. The control module 100 can also determine the element proportion information of the pulse signal according to the element count value.

[0124] The above-mentioned element detection device, the control module 100, the comparison module 200 and the counting module 300 work together to determine the comparison threshold based on the first energy window information of the first element and the second energy window information of the second element. By comparing the pulse peak value of the pulse signal with the comparison threshold, the pulse peak value that meets the preset conditions can be counted to obtain the element count value. Furthermore, the element proportion information of the pulse signal can be determined according to the element count value. Using the above-mentioned element detection device, there is no need to perform complex fitting calculations on the pulse waveform, and even the process of drawing the energy spectrum is omitted. The element proportion information can be directly obtained, which simplifies the process of obtaining the number of pulses of different energies.

[0125] Figure 7 This is a schematic diagram of the structure of a control module in one of the embodiments of the present application. In one of the embodiments, the control module 100 may include a first analysis unit 110 , a second analysis unit 120 and a main control unit 130 .

[0126] The first analysis unit 110 can be used to obtain a first upper limit energy and a first lower limit energy of the first energy window information, and a second upper limit energy and a second lower limit energy of the second energy window information. The first energy window information can be an energy range corresponding to the gamma rays generated by the first element. Therefore, two endpoint values ​​can be obtained according to the first energy window information, which are the first upper limit energy and the first lower limit energy corresponding to the gamma rays generated by the first element. Similarly, the second upper limit energy and the second lower limit energy can also be determined according to the second energy window information.

[0127] The second analysis unit 120 may be connected to the first analysis unit 110. The second analysis unit 120 may be configured to determine a first upper threshold, a first lower threshold, a second upper threshold, and a second lower threshold according to a correspondence between a pulse energy and a pulse peak value acquired in advance, and a first upper energy limit, a first lower energy limit, a second upper energy limit, and a second lower energy limit.

[0128] Since it is found from the collected prior information that the energy of the scintillation pulse has a relatively obvious linear relationship with the amplitude of the scintillation pulse, a scintillation pulse energy amplitude lookup table can also be formed. Based on the energy amplitude lookup table, the pulse amplitude corresponding to the first upper limit energy can be determined, and the pulse amplitude can be determined as the first upper limit threshold V Cmax Similarly, the first lower limit threshold V can also be determined based on the energy amplitude lookup table, the first lower limit energy, the second upper limit energy, and the second lower limit energy. Cmin , the second upper threshold V Omax and the second lower threshold V Omin .

[0129] The main control unit 130 can be connected to the second analysis unit 120. The main control module 130 can be used to generate a first control signal according to the first upper threshold, generate a second control signal according to the first lower threshold, generate a third control signal according to the second upper threshold, and generate a fourth control signal according to the second lower threshold. The first control signal can be used to control the relevant functional module to output the first upper threshold V Cmax To the comparison module 200. For example, the DAC is controlled to output a first upper threshold value V Cmax To the comparison module 200. Similarly, the second control signal can also be used to control the relevant functional module to output the first lower limit threshold V Cmin To the comparison module 200, the third control signal can also be used to control the relevant functional module to output the second upper limit threshold V Omax To the comparison module 200, the fourth control signal can also be used to control the relevant functional module to output the second lower limit threshold V Omin To the comparison module 200.

[0130] The main control unit 130 controls the output of the first upper threshold value V Cmax , the first lower threshold V Cmin , the second upper threshold V Omax and the second lower threshold V Omin To the comparison module 200 , the subsequent counting module 300 can obtain the ratio of the number of pulses in the energy ranges corresponding to the first element and the second element respectively based on the comparison between the pulse peak value of the pulse signal in the comparison module 200 and the comparison threshold.

[0131] Figure 8 This is a schematic diagram of the connection structure of the comparison module and the counting module in one embodiment of the present application. In one embodiment, the comparison module 200 may include a first comparator 210, a second comparator 220, a third comparator 230 and a fourth comparator 240.

[0132] The first comparator 210 may be connected to the main control unit 130. The first comparator 210 may be used to set a first upper threshold value V according to the first control signalCmax , to set the first upper threshold V Cmax Specifically, the pulse signal can be passed into the positive input terminal of the first comparator 210, and the first upper limit threshold V Cmax It can be connected to the negative input terminal of the first comparator 210. The first comparator 210 can output different signals according to different comparison results by comparing the voltages at the positive and negative input terminals.

[0133] Similarly, the second comparator 220 can also be connected to the main control unit 130. The second comparator 220 can be used to set the first lower limit threshold V according to the second control signal Cmin , to set the first lower threshold V Cmin Specifically, the pulse signal can be passed to the positive input terminal of the second comparator 220, and the first lower limit threshold V Cmin It can be connected to the negative input terminal of the second comparator 220. The second comparator 220 can output different signals according to different comparison results by comparing the voltages at the positive and negative input terminals.

[0134] Similarly, the third comparator 230 can be connected to the main control unit 130. The third comparator 230 can be used to set the second upper limit threshold V according to the third control signal Omax , to set the second upper threshold V Omax Specifically, the pulse signal can be passed to the positive input terminal of the third comparator 230, and the second upper limit threshold V Omax It can be connected to the negative input terminal of the third comparator 230. The third comparator 230 can output different signals according to different comparison results by comparing the voltages at the positive and negative input terminals.

[0135] Similarly, the fourth comparator 240 may also be connected to the main control unit 130. The fourth comparator 240 may be used to set the second lower limit threshold V according to the fourth control signal Omin , to set the second lower threshold V Omin Specifically, the pulse signal can be passed into the positive input terminal of the fourth comparator 240, and the second lower limit threshold V Omin It can be connected to the negative input terminal of the fourth comparator 240. The fourth comparator 240 can output different signals according to different comparison results by comparing the voltages at the positive and negative input terminals.

[0136] In one embodiment, when the first comparator 210 is used to compare the pulse peak value of the pulse signal with the first upper threshold value, when the pulse peak value is less than or equal to the first upper threshold value, the first counting signal is output. The first counting signal can be a high level 1 or a low level 0. Exemplarily, when the first comparator 210 determines that the voltage at the positive input terminal is less than or equal to the voltage at the negative input terminal, the high level 1 is output to the counting module 300.

[0137] Similarly, when the second comparator 220 is used to compare the pulse peak value with the first lower threshold value, when the pulse peak value is greater than or equal to the first lower threshold value, the second counting signal is output. The second counting signal may also be a high level 1 or a low level 0. Exemplarily, when the second comparator 220 determines that the voltage at the positive input terminal is greater than or equal to the voltage at the negative input terminal, a high level 1 is output to the counting module 300.

[0138] Similarly, when the third comparator 230 is used to compare the pulse peak value with the second upper limit threshold, when the pulse peak value is less than or equal to the second upper limit threshold, the third counting signal is output. The third counting signal can also be a high level 1 or a low level 0. Exemplarily, when the third comparator 230 determines that the voltage at the positive input terminal is less than or equal to the voltage at the negative input terminal, a high level 1 is output to the counting module 300.

[0139] Similarly, when the fourth comparator 240 is used to compare the pulse peak value with the second lower threshold value, when the pulse peak value is greater than or equal to the second lower threshold value, a fourth counting signal is output. The fourth counting signal may also be a high level 1 or a low level 0. Exemplarily, when the fourth comparator 240 determines that the voltage at the positive input terminal is greater than or equal to the voltage at the negative input terminal, a high level 1 is output to the counting module 300.

[0140] In one embodiment, if Figure 8 As shown, the counting module 300 may include a first counter 310 .

[0141] The first counter 310 can be connected to the first comparator 210 and the second comparator 220 respectively. The first counter 310 can be used to count the first count value corresponding to the first element according to the first count signal and the second count signal. The first count value can be a variable with an initial value of 0. Whenever the first counter 310 receives the first count signal output by the first comparator 210 and the second count signal output by the second comparator 220, the first counter 310 adds N to the first count value. N can be a positive number. For the convenience of calculation, the value of N is usually 1. When the pulse peaks corresponding to all the pulse signals to be measured are equal to the first lower limit threshold V Cmin and the first upper threshold V CmaxAfter comparison, the number of pulses in the energy range corresponding to the first element can be determined according to the first count value.

[0142] In one embodiment, if Figure 8 As shown, the counting module 300 may further include a second counter 320 .

[0143] The second counter 320 can be connected to the third comparator 230 and the fourth comparator 240 respectively. The second counter 320 can be used to count the second count value according to the third count signal and the fourth count signal. Similarly, the second count value can also be a variable with an initial value of 0. Whenever the second counter 320 receives the third count signal output by the third comparator 230 and the fourth count signal output by the fourth comparator 240, the second counter 320 adds N to the second count value. When the pulse peak values ​​corresponding to all the pulse signals to be measured are equal to the second lower limit threshold V Omin and the second upper threshold V Omax After comparison, the number of pulses in the energy range corresponding to the second element can be determined according to the second count value.

[0144] In some embodiments, the four pulse peak endpoint values ​​(V Cmin ,V Cmax ,V Omin ,V Omax ) is set as the threshold voltage of the four comparators. When the pulse signal to be measured enters the element detection device, it will be input into the four comparators in parallel. If the pulse peak of the pulse signal exceeds V Cmin Without crossing V Cmax , the first counter 310 increases by 1; if the pulse peak value of the pulse signal exceeds V Omin Without crossing V Omax , the second counter 320 increases by 1; if it does not meet any of the above two situations, the first counter 310 and the second counter 320 may not make any response.

[0145] When the pulse peaks corresponding to the pulse signal to be measured are both equal to the first upper limit threshold V Cmax , the first lower threshold V Cmin , the second upper threshold V Omax and the second lower threshold V Omin After comparison, the C / O value can be obtained according to the ratio of the first count value to the second count value.

[0146] It can be seen that the above-mentioned element detection device can directly determine the ratio of the number of pulses in the energy range corresponding to different elements by simple threshold comparison. In the process of processing the pulse signal, there is no need to fit the pulse waveform by solving a group of equations to obtain a function curve, nor is there a need to obtain the energy spectrum of the pulse, which simplifies the process of obtaining the number of pulses of different energies.

[0147] In one embodiment, if Figure 8 As shown, the main control unit 130 may also be connected to the first counter 310 and the second counter 320 respectively. The main control unit 130 may also be used to determine the element ratio information of the pulse signal according to the ratio of the first count value to the second count value.

[0148] When the above-mentioned element detection device is applied to C / O spectrum logging, the element ratio information can be the C / O value, that is, the ratio of the number of pulses in the energy range corresponding to the carbon element to the number of pulses in the energy range corresponding to the oxygen element. Therefore, the C / O value is the ratio of the first count value to the second count value. Based on the C / O value, the properties of the downhole material can be judged.

[0149] Based on the above, it should be understood by those skilled in the art that in some application requirements, such as application requirements where the accuracy is not very high, the first upper limit threshold V Cmax , the first lower threshold V Cmin The second lower threshold V Omin Count. Fig. 9 Schematic diagram of the connection structure of the comparison module and the counting module in another embodiment of the present application. In this embodiment, the comparison module 200 may include a first comparator 210, a second comparator 220 and a fourth comparator 240. The first counter 310 may be connected to the first comparator 210 and the second comparator 220 respectively, and the second counter 320 is connected to the fourth comparator 240. The first counter 310 counts the first count value corresponding to the first element according to the first count signal and the second count signal. The second lower limit threshold V Omin Usually higher than the first upper threshold V Cmax At this time, the second counter 320 can be used when the pulse peak value crosses the second lower limit threshold V Omin When the second element is counted, it is considered that all energies meet the second lower limit threshold V Omin The required pulses are counted according to the second element to determine a second count value.

[0150] Similarly, the first lower threshold V Cmin and the second upper threshold V Omax , the second lower threshold V Omin Compare counts. Fig.10Schematic diagram of the connection structure of the comparison module and the counting module in another embodiment of the present application. In this embodiment, the comparison module 200 may include a second comparator 220, a third comparator 230 and a fourth comparator 240. The first counter 310 is connected to the second comparator 220, and the second counter 320 is respectively connected to the third comparator 230 and the fourth comparator 240. The first counter 310 may first perform a first count according to the second counting signal, that is, first count the first lower limit threshold V Cmin The pulse peak value of the first count is counted, and the second counter 320 counts the second count value corresponding to the second element according to the third count signal and the fourth count signal. At this time, due to the first lower limit threshold V Cmin Small, any pulse peak counted by the second element must be the first lower threshold V Cmin Therefore, when the first counter 310 calculates the first count value, the first lower limit threshold V Cmin The first counter 310 can determine the first count value by subtracting the count value corresponding to the second element from the count value of the first count. This method is suitable for detecting elements with large energy differences, and can further reduce the logic resources required for counting and speed up the detection process.

[0151] Based on the above, it should be understood by those skilled in the art that in some application requirements, such as application requirements where the accuracy is not very high, only the first lower limit threshold V Cmin Or the second lower threshold V Omin Make a comparison. Fig.11 2 is a schematic diagram of the connection structure of the comparison module and the counting module in another embodiment of the present application. In this embodiment, the comparison module 200 may include a second comparator 220 and a fourth comparator 240. The first counter 310 is connected to the second comparator 220, and the second counter 320 is connected to the fourth comparator 240.

[0152] When the pulse peak exceeds the first lower threshold V Cmin Or the second lower threshold V Omin The first counter 310 can first count according to the second counting signal, and the second counter 320 can count according to the fourth counting signal. At this time, since the first lower limit threshold V Cmin and the second lower threshold V Omin There is a size relationship, for example, the second lower limit threshold V Omin Greater than the first lower threshold V Cmin , then it crosses the second lower threshold V Omin The pulse must cross the first lower threshold V Cmin, therefore, the second lower threshold V Omin That is, the second counter 320 can use the result of the second count as the second count value corresponding to the second element. At the same time, the first counter 310 can use the result of the second count as the second count value corresponding to the second element. Cmin The count value (the result of the first count) minus the second count value is taken as the first count value corresponding to the first element, that is, all pulses whose energy meets the lower limit requirement are regarded as being counted according to the first element or the second element. This method is suitable for detecting elements with large energy differences, and can further reduce the logic resources required for counting and speed up the detection process.

[0153] Fig.12 This is a schematic diagram of the connection structure of the comparison module, the counting module and the correction module in one of the embodiments of the present application. In one of the embodiments, considering that in actual application scenarios, the equipment usually operates in an environment with changing temperature and generally high temperature, and temperature is often an important factor affecting the working state of electronic devices that cannot be ignored, in order to enable the instrument to obtain more accurate data when working in different temperature environments, the element detection device can also include a correction module 400, and the correction module 400 is used to perform a threshold correction process.

[0154] The correction module 400 may be connected to the comparison module 200. The correction module 400 may be used to set a standard threshold, output a correction signal based on the standard threshold, determine a correction parameter according to a deviation between the correction signal and the standard threshold, and perform threshold correction on the comparison threshold according to the correction parameter.

[0155] In some embodiments, the correction module 400 may be a DAC. Therefore, the output difference of the DAC at different temperatures can be determined based on the prior information, and the comparison threshold can be adjusted accordingly based on the output difference. The correction module 400 determines a standard threshold based on the prior information, for example, the standard threshold is 3V. The correction module 400 outputs a correction signal with a voltage value of the standard threshold, such as outputting a 3V correction signal.

[0156] When the temperature changes, the correction signal actually output by the DAC may deviate from the standard threshold. Therefore, the correction parameter can be obtained by subtracting the correction signal output by the DAC from the standard threshold. For example, when the voltage value of the correction signal output by the DAC is actually 3.5V, and the difference between the voltage value of the correction signal and the standard threshold is 0.5V, the correction parameter is 0.5V. That is, the change in temperature at this time causes the output of the DAC to produce a 0.5V offset. Therefore, the DAC adjusts the comparison threshold based on the correction parameter to prevent the offset of the comparison threshold from affecting the accuracy of the detection result. For example, when the correction parameter is +0.5V, the comparison thresholds of all outputs are reduced by 0.5V; when the correction parameter is -0.5V, the comparison thresholds of all outputs are increased by 0.5V, thereby ensuring the data accuracy of the comparison threshold.

[0157] In the above-mentioned element detection device, before comparing the pulse signal with the comparison threshold, the comparison threshold can be calibrated using the correction module 400. The output difference of the DAC at different temperatures is determined based on the prior information, and the comparison threshold is adjusted accordingly based on the output difference. By calibrating the comparison threshold, the accuracy of the detection result can be guaranteed, and the negative impact of the voltage offset caused by the change of temperature or other environmental factors on the detection can be reduced.

[0158] The present application also provides an element detection device, which includes a pulse signal processing circuit board, and the pulse signal processing circuit board is used to obtain a pulse signal and implement the steps of the element detection method described in any one of the above embodiments.

[0159] It should be understood that Figures 6 to 12 The device and its modules shown can be implemented in various ways. For example, in some embodiments, the device and its modules can be implemented by hardware, software, or a combination of software and hardware. Among them, the hardware part can be implemented using dedicated logic; the software part can be stored in a memory and executed by an appropriate instruction execution device, such as a microprocessor or a dedicated design hardware. Those skilled in the art will understand that the above methods and devices can be implemented using computer executable instructions and / or included in a processor control code, such as a carrier medium such as a disk, CD or DVD-ROM, a programmable memory such as a read-only memory (firmware), or a data carrier such as an optical or electronic signal carrier. Such code is provided on the device and its modules of this specification. Not only can the hardware circuits such as ultra-large-scale integrated circuits or gate arrays, semiconductors such as logic chips, transistors, etc., or programmable hardware devices such as field programmable gate arrays, programmable logic devices, etc. be implemented, they can also be implemented by software such as executed by various types of processors, and can also be implemented by a combination of the above hardware circuits and software (for example, firmware).

[0160] It should be noted that the above description of the modules is only for convenience of description and does not limit this specification to the scope of the embodiments. It is understandable that for those skilled in the art, after understanding the principle of the device, it is possible to arbitrarily combine the modules or form a subsystem connected to other modules without deviating from this principle. For example, the modules may share a storage module, or each module may have its own storage module. Such variations are all within the scope of protection of this specification.

[0161] Fig.13 This is a schematic diagram of an element detection device for implementing an element detection method in one embodiment of the present application. Fig.13 The element detection device 10 may include a processing component 11, which further includes one or more processors, and a memory resource represented by a memory 13, for storing instructions executable by the processing component 11, such as an application. The application stored in the memory 13 may include one or more instructions, and each module corresponds to a group of instructions. In addition, the processing component 11 is configured to execute instructions to perform the above-mentioned element detection method.

[0162] The operations and / or methods implemented by one processor described in the embodiments of this specification may also be implemented jointly or independently by multiple processors. For example, if in this specification, a processor of a processing component performs steps 1 and 2, it should be understood that steps 1 and 2 may also be performed jointly or independently by two different processors of the processing component (for example, the first processor performs step 1, the second processor performs step 2, or the first and second processors perform steps 1 and 2 jointly).

[0163] The element detection device 10 may further include: a power supply component 15 configured to perform power management of the element detection device 10; a wired or wireless network interface 17 configured to connect the element detection device 10 to a network; and an input / output (I / O) interface 19. The element detection device 10 may operate based on an operating system stored in the memory 13, such as Windows Server, Mac OS X, Unix, Linux, FreeBSD or the like.

[0164] In an exemplary embodiment, a computer-readable storage medium including instructions is also provided, such as a memory 13 including instructions, and the above instructions can be executed by a processor of the element detection device 10 to complete the above method. The storage medium can be a computer-readable storage medium, for example, the computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.

[0165] In an exemplary embodiment, a computer program product is also provided. The computer program product includes instructions. The instructions can be executed by a processor of the element detection device 10 to complete the above method.

[0166] In one embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as follows: Fig.14 As shown, Fig.14 This is an internal structure diagram of a computer device in one of the embodiments of the present application. The computer device includes a processor, a memory and a network interface connected via a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store relevant data used in the above-mentioned element detection device method. The network interface of the computer device is used to communicate with an external terminal via a network connection. When the computer program is executed by the processor, an element detection method is implemented.

[0167] Those skilled in the art will understand that Fig.14 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0168] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.

[0169] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the hardware + program embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.

[0170] It should be noted that the above-mentioned devices, electronic devices, servers, etc. may also include other implementation methods according to the description of the method embodiments, and the specific implementation methods may refer to the description of the relevant method embodiments. At the same time, the new embodiments composed of the mutual combination of the features between the various methods and device, equipment, and server embodiments still fall within the scope of implementation covered by this application, and will not be described one by one here.

[0171] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for those of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application. The various technical features of the above-described embodiments can be combined arbitrarily. In order to make the description concise, all possible combinations of the various technical features in the above-described embodiments are not described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of the present specification. Therefore, the scope of protection of the present patent application shall be subject to the attached claims.

[0172] The element detection method provided in the present application can be specifically used in photon detection, and can be applicable to multiple fields, such as medical imaging technology, high-energy physics, laser radar, autonomous driving, precision analysis, optical communication, etc. In a specific example, the element detection method, device, computer equipment, storage medium and program product provided in the present application can be applied to a radiation detection system. In the radiation detection system, the photon data corresponding to the radiation can be collected using the scheme described in the embodiment of the present application and then the dose conversion can be performed.

[0173] The basic concepts have been described herein. It is obvious to those skilled in the art that the above detailed disclosure is merely an example and does not constitute a limitation of this specification. Although not explicitly stated herein, those skilled in the art may make various modifications, improvements and amendments to this specification. Such modifications, improvements and amendments are suggested in this specification, so such modifications, improvements and amendments still fall within the spirit and scope of the exemplary embodiments of this specification.

[0174] At the same time, this specification uses specific words to describe the embodiments of this specification. For example, "one embodiment", "an embodiment", and / or "some embodiments" refer to a certain feature, structure or characteristic related to at least one embodiment of this specification. Therefore, it should be emphasized and noted that "one embodiment" or "an embodiment" or "an alternative embodiment" mentioned twice or more in different positions in this specification does not necessarily refer to the same embodiment. In addition, certain features, structures or characteristics in one or more embodiments of this specification can be appropriately combined.

[0175] In addition, it will be understood by those skilled in the art that various aspects of this specification may be illustrated and described by a number of patentable categories or situations, including any new and useful process, machine, product or combination of substances, or any new and useful improvements thereto. Accordingly, various aspects of this specification may be performed entirely by hardware, entirely by software (including firmware, resident software, microcode, etc.), or by a combination of hardware and software. The above hardware or software may be referred to as "data blocks", "modules", "engines", "units", "components" or "systems". In addition, various aspects of this specification may be represented as a computer product located in one or more computer-readable media, which includes computer-readable program code.

[0176] A computer storage medium may include a propagated data signal containing computer program code, for example, in baseband or as part of a carrier wave. The propagated signal may be in a variety of forms, including electromagnetic, optical, etc., or a suitable combination. A computer storage medium may be any computer-readable medium other than a computer-readable storage medium, which can be connected to an instruction execution system, device or apparatus to communicate, propagate or transmit the program for use. The program code on the computer storage medium may be transmitted via any suitable medium, including radio, cable, fiber optic cable, RF, or similar media, or any combination of the above media.

[0177] The computer program code required for the operation of each part of this specification can be written in any one or more programming languages, including object-oriented programming languages ​​such as Java, Scala, Smalltalk, Eiffel, JADE, Emerald, C++, C#, VB.NET, Python, etc., conventional procedural programming languages ​​such as C language, Visual Basic, Fortran 3003, Perl, COBOL 3002, PHP, ABAP, dynamic programming languages ​​such as Python, Ruby and Groovy, or other programming languages. The program code can be run entirely on the user's computer, or run on the user's computer as an independent software package, or run partially on the user's computer and partially on a remote computer, or run entirely on a remote computer or server. In the latter case, the remote computer can be connected to the user's computer through any network form, such as a local area network (LAN) or a wide area network (WAN), or connected to an external computer (e.g., via the Internet), or in a cloud computing environment, or used as a service such as software as a service (SaaS).

[0178] In addition, unless explicitly stated in the claims, the order of the processing elements and sequences described in this specification, the use of alphanumeric characters, or the use of other names are not intended to limit the order of the processes and methods of this specification. Although the above disclosure discusses some invention embodiments that are currently considered useful through various examples, it should be understood that such details are only for illustrative purposes, and the attached claims are not limited to the disclosed embodiments. On the contrary, the claims are intended to cover all modifications and equivalent combinations that are consistent with the essence and scope of the embodiments of this specification. For example, although the system components described above can be implemented by hardware devices, they can also be implemented only by software solutions, such as installing the described system on an existing server or mobile device.

[0179] Similarly, it should be noted that in order to simplify the description disclosed in this specification and thus help understand one or more embodiments of the invention, in the above description of the embodiments of this specification, multiple features are sometimes combined into one embodiment, figure or description thereof. However, this disclosure method does not mean that the features required by the subject matter of this specification are more than the features mentioned in the claims. In fact, the features of the embodiments are less than all the features of the single embodiment disclosed above.

[0180] In some embodiments, numbers describing the number of components and attributes are used. It should be understood that such numbers used in the description of the embodiments are modified by the modifiers "about", "approximately" or "substantially" in some examples. Unless otherwise specified, "about", "approximately" or "substantially" indicate that the numbers are allowed to vary by ±20%. Accordingly, in some embodiments, the numerical parameters used in the specification and claims are approximate values, which may change according to the required features of individual embodiments. In some embodiments, the numerical parameters should take into account the specified significant digits and adopt the general method of retaining digits. Although the numerical domains and parameters used to confirm the breadth of their range in some embodiments of this specification are approximate values, in specific embodiments, the setting of such numerical values ​​is as accurate as possible within the feasible range.

[0181] Each patent, patent application, patent application publication, and other materials, such as articles, books, specifications, publications, documents, etc., cited in this specification is hereby incorporated by reference in its entirety. Except for application history documents that are inconsistent with or conflicting with the contents of this specification, documents that limit the broadest scope of the claims of this specification (currently or later attached to this specification) are also excluded. It should be noted that if the descriptions, definitions, and / or use of terms in the materials attached to this specification are inconsistent or conflicting with the contents described in this specification, the descriptions, definitions, and / or use of terms in this specification shall prevail.

[0182] Finally, it should be understood that the embodiments described in this specification are only used to illustrate the principles of the embodiments of this specification. Other variations may also fall within the scope of this specification. Therefore, as an example and not a limitation, alternative configurations of the embodiments of this specification may be considered consistent with the teachings of this specification. Accordingly, the embodiments of this specification are not limited to the embodiments explicitly introduced and described in this specification.

Claims

1. A method for detecting an element, characterized in that: include: Acquire first energy window information of the first element and second energy window information of the second element; Determine a comparison threshold according to the first energy window information and the second energy window information; Compare the pulse peak value of the pulse signal with the comparison threshold, count the pulse peak values ​​that meet the preset conditions, and obtain the element count value; The element ratio information of the pulse signal is determined according to the element count value.

2. The element detection method according to claim 1, characterized in that: The determining of a comparison threshold according to the first energy window information and the second energy window information comprises: Acquire a first upper limit energy and a first lower limit energy of the first energy window information, and a second upper limit energy and a second lower limit energy of the second energy window information; Determine a first upper limit threshold, a first lower limit threshold, a second upper limit threshold, and a second lower limit threshold according to a correspondence between pulse energy and pulse peak value acquired in advance, and the first upper limit energy, the first lower limit energy, the second upper limit energy, and the second lower limit energy; The first upper threshold, the first lower threshold, the second upper threshold, and the second lower threshold are set as the comparison thresholds.

3. The element detection method according to claim 2, characterized in that: The element count value includes a first count value corresponding to the first element, and the comparing the pulse peak value of the pulse signal with the comparison threshold value and counting the pulse peak values ​​that meet the preset conditions includes: comparing the pulse peak value with the first lower threshold and the first upper threshold; In response to a comparison result that the pulse peak value is greater than or equal to the first lower threshold value, and the pulse peak value is less than or equal to the first upper threshold value, the first count value is counted.

4. The element detection method according to claim 3, characterized in that: The element count value also includes a second count value corresponding to the second element, and the comparing the pulse peak value of the pulse signal with the comparison threshold value and counting the pulse peak values ​​that meet the preset conditions also includes: comparing the pulse peak value with the second lower threshold and the second upper threshold; In response to a comparison result that the pulse peak value is greater than or equal to the second lower threshold value, and the pulse peak value is less than or equal to the second upper threshold value, the second count value is counted.

5. The element detection method according to claim 1, characterized in that: The determining of a comparison threshold according to the first energy window information and the second energy window information comprises: Acquire a first upper limit energy and a first lower limit energy of the first energy window information, and a second lower limit energy of the second energy window information; Determine a first upper limit threshold, a first lower limit threshold, and a second lower limit threshold according to a correspondence relationship between pulse energy and pulse peak value acquired in advance, as well as the first upper limit energy, the first lower limit energy, and the second lower limit energy; The first upper threshold, the first lower threshold, and the second lower threshold are set as the comparison thresholds.

6. The element detection method according to claim 5, characterized in that: The element count value includes a first count value corresponding to the first element and a second count value corresponding to the second element, and the comparing the pulse peak value of the pulse signal with the comparison threshold value and counting the pulse peak values ​​that meet the preset conditions includes: comparing the pulse peak value with the first lower threshold and the first upper threshold; In response to a comparison result that the pulse peak value is greater than or equal to the first lower threshold value, and the pulse peak value is less than or equal to the first upper threshold value, counting the first count value; Comparing the pulse peak value with the second lower threshold; In response to the pulse peak value being greater than or equal to the second lower threshold, the second count value is counted.

7. The element detection method according to claim 1, characterized in that: The determining of a comparison threshold according to the first energy window information and the second energy window information comprises: Acquire a first lower limit energy of the first energy window information, and a second upper limit energy and a second lower limit energy of the second energy window information; Determine a first lower limit threshold, a second upper limit threshold, and a second lower limit threshold according to a correspondence relationship between pulse energy and pulse peak value acquired in advance, and the first lower limit energy, the second upper limit energy, and the second lower limit energy; The first lower threshold, the second upper threshold, and the second lower threshold are set as the comparison thresholds.

8. The element detection method according to claim 7, characterized in that: The element count value includes a first count value corresponding to the first element and a second count value corresponding to the second element, and the comparing the pulse peak value of the pulse signal with the comparison threshold value and counting the pulse peak values ​​that meet the preset conditions includes: Comparing the pulse peak value with the first lower threshold; In response to the pulse peak value being greater than or equal to the first lower threshold, performing a first counting; Comparing the pulse peak value with the second lower threshold; In response to the comparison result that the pulse peak value is greater than or equal to the second lower threshold and the pulse peak value is less than or equal to the second upper threshold, the second count value is counted, and the first count value is determined by subtracting the second count value from the result of the first count.

9. The element detection method according to claim 1, characterized in that: The determining of a comparison threshold according to the first energy window information and the second energy window information comprises: Acquire a first lower limit energy of the first energy window information and a second lower limit energy of the second energy window information; Determine a first lower limit threshold and a second lower limit threshold according to the correspondence between the pulse energy and the pulse peak value acquired in advance, as well as the first lower limit energy and the second lower limit energy; The first lower limit threshold and the second lower limit threshold are set as the comparison thresholds.

10. The element detection method according to claim 9, characterized in that: The element count value includes a first count value corresponding to the first element and a second count value corresponding to the second element, and the comparing the pulse peak value of the pulse signal with the comparison threshold value and counting the pulse peak values ​​that meet the preset conditions includes: Comparing the pulse peak value with the first lower threshold; In response to the pulse peak value being greater than or equal to the first lower threshold, performing a first counting; Comparing the pulse peak value with the second lower threshold; In response to the pulse peak being greater than or equal to the second lower threshold, a second count is performed, the value of the second count is used as the second count value, and the result of the first count minus the second count value is used as the first count value.

11. The element detection method according to claim 4, 6, 8 or 10, characterized in that: The element proportion information is a ratio of the first count value to the second count value.

12. The element detection method according to claim 1, characterized in that: Before obtaining the first energy window information of the first element and the second energy window information of the second element, the element detection method further includes: Setting standard thresholds; outputting a correction signal based on the standard threshold; determining a correction parameter according to a deviation between the correction signal and the standard threshold; The comparison threshold is corrected according to the correction parameter.

13. An element detection device, characterized in that: include: A control module, configured to obtain first energy window information of a first element and second energy window information of a second element, determine a comparison threshold according to the first energy window information and the second energy window information, and generate a control signal according to the comparison threshold; A comparison module, connected to the control module, for setting the comparison threshold according to the control signal, and comparing the pulse peak value of the pulse signal with the comparison threshold; A counting module, connected to the control module and the comparison module respectively, for counting the pulse peaks meeting the preset conditions to obtain the element count value; The control module is further configured to determine element proportion information of the pulse signal according to the element count value.

14. The element detection device according to claim 13, characterized in that: The control module comprises: A first analysis unit, used to obtain a first upper limit energy and a first lower limit energy of the first energy window information, and a second upper limit energy and a second lower limit energy of the second energy window information; a second analysis unit, connected to the first analysis unit, and configured to determine a first upper limit threshold, a first lower limit threshold, a second upper limit threshold, and a second lower limit threshold according to a correspondence between pulse energy and pulse peak value acquired in advance, and the first upper limit energy, the first lower limit energy, the second upper limit energy, and the second lower limit energy; A main control unit is connected to the second analysis unit, and is used to generate a first control signal according to the first upper threshold, generate a second control signal according to the first lower threshold, generate a third control signal according to the second upper threshold, and generate a fourth control signal according to the second lower threshold.

15. The element detection device according to claim 14, characterized in that: The comparison module comprises: a first comparator, connected to the main control unit, and configured to set the first upper limit threshold according to the first control signal; a second comparator, connected to the main control unit, and configured to set the first lower threshold according to the second control signal; a third comparator, connected to the main control unit, and configured to set the second upper limit threshold according to the third control signal; A fourth comparator is connected to the main control unit, and is used to set the second lower threshold according to the fourth control signal.

16. The element detection device according to claim 15, characterized in that: The first comparator is further used to compare the pulse peak value of the pulse signal with the first upper limit threshold, and output a first counting signal when the pulse peak value is less than or equal to the first upper limit threshold; The second comparator is further used to compare the pulse peak value with the first lower threshold value, and output a second counting signal when the pulse peak value is greater than or equal to the first lower threshold value; The third comparator is further used to compare the pulse peak value with the second upper limit threshold, and output a third counting signal when the pulse peak value is less than or equal to the second upper limit threshold; The fourth comparator is further configured to compare the pulse peak value with the second lower threshold value, and output a fourth counting signal when the pulse peak value is greater than or equal to the second lower threshold value.

17. The element detection device according to claim 16, characterized in that: The counting module comprises: The first counter is connected to the first comparator and the second comparator respectively, and is used to count a first count value corresponding to the first element according to the first count signal and the second count signal.

18. The element detection device according to claim 16, characterized in that: The counting module comprises: The second counter is connected to the third comparator and the fourth comparator respectively, and is used to count the second count value corresponding to the second element according to the third count signal and the fourth count signal.

19. The element detection device according to claim 13, characterized in that: The control module comprises: A first analyzing unit, configured to obtain a first upper limit energy and a first lower limit energy of the first energy window information, and a second lower limit energy of the second energy window information; a second analysis unit, connected to the first analysis unit, and configured to determine a first upper limit threshold, a first lower limit threshold, and a second lower limit threshold according to a correspondence between a pulse energy and a pulse peak value acquired in advance, and the first upper limit energy, the first lower limit energy, and the second lower limit energy; A main control unit is connected to the second analysis unit, and is used to generate a first control signal according to the first upper threshold, generate a second control signal according to the first lower threshold, and generate a fourth control signal according to the second lower threshold.

20. The element detection device according to claim 19, characterized in that: The comparison module comprises: a first comparator, connected to the main control unit, for setting the first upper limit threshold according to the first control signal, and for comparing the pulse peak value of the pulse signal with the first upper limit threshold, and outputting a first counting signal when the pulse peak value is less than or equal to the first upper limit threshold; a second comparator, connected to the main control unit, for setting the first lower threshold according to the second control signal, and for comparing the pulse peak value with the first lower threshold value, and outputting a second counting signal when the pulse peak value is greater than or equal to the first lower threshold value; A fourth comparator is connected to the main control unit, and is used to set the second lower limit threshold according to the fourth control signal, and is also used to compare the pulse peak value with the second lower limit threshold, and output a fourth counting signal when the pulse peak value is greater than or equal to the second lower limit threshold.

21. The element detection device according to claim 20, characterized in that: The counting module comprises: a first counter, connected to the first comparator and the second comparator respectively, and configured to count a first count value corresponding to the first element according to the first count signal and the second count signal; The second counter is connected to the fourth comparator, and is used for counting a second count value corresponding to the second element according to the fourth count signal.

22. The element detection device according to claim 13, characterized in that: The control module comprises: A first analysis unit, used to obtain a first lower limit energy of the first energy window information, and a second upper limit energy and a second lower limit energy of the second energy window information; a second analysis unit, connected to the first analysis unit, and configured to determine a first lower limit threshold, a second upper limit threshold, and a second lower limit threshold according to a correspondence between pulse energy and pulse peak value acquired in advance, and the first lower limit energy, the second upper limit energy, and the second lower limit energy; The main control unit is connected to the second analysis unit, generates a second control signal according to the first lower limit threshold, generates a third control signal according to the second upper limit threshold, and generates a fourth control signal according to the second lower limit threshold.

23. The element detection device according to claim 22, characterized in that: The comparison module comprises: a second comparator, connected to the main control unit, for setting the first lower threshold according to the second control signal, and for comparing the pulse peak value with the first lower threshold value, and outputting a second counting signal when the pulse peak value is greater than or equal to the first lower threshold value; a third comparator, connected to the main control unit, for setting the second upper limit threshold according to the third control signal, and for comparing the pulse peak value of the pulse signal with the second upper limit threshold, and outputting a third counting signal when the pulse peak value is less than or equal to the second upper limit threshold; A fourth comparator is connected to the main control unit, and is used to set the second lower limit threshold according to the fourth control signal, and is also used to compare the pulse peak value with the second lower limit threshold, and output a fourth counting signal when the pulse peak value is greater than or equal to the second lower limit threshold.

24. The element detection device according to claim 23, characterized in that: The counting module comprises: a first counter connected to the second comparator, and configured to perform a first counting according to the second counting signal; a second counter, connected to the third comparator and the fourth comparator respectively, and configured to count a second count value corresponding to the second element according to the third count signal and the fourth count signal; The first counter is further configured to determine the first count value by subtracting the second count value from a result of the first count.

25. The element detection device according to claim 13, characterized in that: The control module comprises: A first analyzing unit, used to obtain a first lower limit energy of the first energy window information and a second lower limit energy of the second energy window information; a second analysis unit, connected to the first analysis unit, and configured to determine a first lower limit threshold and a second lower limit threshold according to a pre-acquired correspondence between pulse energy and pulse peak value, and the first lower limit energy and the second lower limit energy; A main control unit is connected to the second analysis unit, and generates a second control signal according to the first lower limit threshold, and generates a fourth control signal according to the second lower limit threshold.

26. The element detection device according to claim 25, characterized in that: The comparison module comprises: a second comparator, connected to the main control unit, for setting the first lower threshold according to the second control signal, and for comparing the pulse peak value with the first lower threshold value, and outputting a second counting signal when the pulse peak value is greater than or equal to the first lower threshold value; A fourth comparator is connected to the main control unit, and is used to set the second lower limit threshold according to the fourth control signal, and is also used to compare the pulse peak value with the second lower limit threshold, and output a fourth counting signal when the pulse peak value is greater than or equal to the second lower limit threshold.

27. The element detection device according to claim 26, characterized in that: The counting module comprises: a first counter connected to the second comparator, and configured to perform a first counting according to the second counting signal; a second counter connected to the fourth comparator, and configured to perform a second counting according to the fourth counting signal, and use the result of the second counting as the second counting value; The first counter is further configured to determine the first count value by subtracting the second count value from a result of the first count.

28. The element detection device according to claim 18, 21, 24 or 27, characterized in that: The main control unit is also connected to the first counter and the second counter respectively, and the main control unit is further used to determine the element ratio information of the pulse signal according to the ratio of the first count value to the second count value.

29. The element detection device according to claim 13, characterized in that: The element detection device also includes: A correction module is connected to the comparison module and is used to set a standard threshold, output a correction signal based on the standard threshold, determine a correction parameter according to a deviation between the correction signal and the standard threshold, and perform threshold correction on the comparison threshold according to the correction parameter.

30. An element detection device, comprising a pulse signal processing circuit board, characterized in that: The pulse signal processing circuit board is used to obtain the pulse signal and implement the steps of the element detection method described in any one of claims 1 to 12.

31. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, the steps of the element detection method according to any one of claims 1 to 12 are implemented.

32. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the element detection method according to any one of claims 1 to 12 are implemented.