X-ray machine ray dose adjusting method and device, electronic equipment and medium
By dynamically adjusting the current in the X-ray exposure mode, the problem of uneven ray dose output is solved and the imaging quality is improved.
Patent Information
- Application Number
- CN202510028621.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-08
- Publication Date
- 2025-05-27
- Estimated Expiration
- 2045-01-08
AI Technical Summary
In actual use, existing X-ray machines have uneven ray dose output due to bulb differences and rising oil tank temperature, which affects the imaging quality.
By dynamically sampling and adjusting the feedback current when the X-ray machine is in exposure mode, the current adjustment value is calculated to determine the new current value, ensuring uniformity of the radiation dose.
Improves the uniformity of the X-ray machine ray dose, thereby improving imaging quality and reducing imaging instability due to device differences and temperature changes.
Smart Images

Figure CN120036802A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of artificial intelligence, and in particular to a method, device, electronic equipment and medium for adjusting the radiation dose of an X-ray machine. Background Art
[0002] Conventional X-ray machines control the radiation dose by setting the voltage and current of the high-voltage tube. However, in the actual process of the tube outputting X-rays, the voltage and current will vary due to the differences in the tube itself. Under the control of the same current and voltage values, the actual radiation dose output by the X-ray machine will deviate. In addition, during long-term exposure, as the temperature of the X-ray machine's oil tank rises, the radiation dose emitted by the X-ray machine will tend to rise or fall linearly with the increase of exposure time, resulting in uneven radiation dose output of the X-ray machine, thereby affecting the imaging effect.
[0003] Therefore, the existing X-ray machine has the problem of uneven radiation dose output, which leads to poor imaging quality of the X-ray machine. Summary of the invention
[0004] The main purpose of the embodiments of the present application is to propose an X-ray machine radiation dose adjustment method, device, electronic device and medium, which can dynamically adjust the current value input to the X-ray machine based on the current value output by the X-ray machine to improve the uniformity of the X-ray machine radiation dose, thereby improving the imaging quality of the X-ray machine.
[0005] To achieve the above-mentioned purpose, a first aspect of an embodiment of the present application provides a method for adjusting the dose of an X-ray machine, the method comprising:
[0006] When the X-ray machine is in an exposure mode, inputting a first current into the X-ray machine to control the radiation dose of the X-ray machine;
[0007] Sampling the current fed back by the X-ray machine to obtain a set of sampling values of this round of iteration, wherein the sampling values include a plurality of current values of the second current;
[0008] Determining a current adjustment value for this round of iteration according to a plurality of current values of the second current;
[0009] Determining a current value of a third current according to the current adjustment value of the current iteration;
[0010] If the exposure time of the exposure mode has not ended, the third current is used as the first current, and the process jumps to the step of inputting the first current into the X-ray machine until the exposure time of the exposure mode ends.
[0011] In some implementations, determining the current adjustment value of this iteration according to the current values of the plurality of second currents includes:
[0012] Calculating the difference between each current value of the second current and the current value of the target current to obtain a plurality of first difference values, wherein the target current is the current first input to the X-ray machine in the exposure mode;
[0013] The current adjustment value of this round of iteration is determined according to the multiple first differences.
[0014] In some implementations, determining the current adjustment value of this iteration according to the plurality of first differences includes:
[0015] The sum of the multiple first difference values obtained in this round of iteration is used as the first value;
[0016] Calculate the average of the first differences in this round of iteration to obtain a second value;
[0017] The sum of the multiple first difference values obtained in the previous iteration is used as the third value;
[0018] A weighted sum is performed on the first value, the second value and the third value to obtain the current adjustment value of the current iteration.
[0019] In some implementations, determining the current value of the third current according to the current adjustment value of the current iteration includes:
[0020] The current value of the third current is obtained according to the current adjustment value of the current iteration and the current working time of the X-ray machine, and the current working time is the time length that the X-ray machine is in the exposure mode.
[0021] In some embodiments, when the X-ray machine is in exposure mode, before inputting the first current into the X-ray machine, the method further includes:
[0022] Acquiring a fourth current, where the fourth current is a preset current for starting the X-ray machine;
[0023] inputting a fourth current into the X-ray machine;
[0024] Sampling the current fed back by the X-ray machine to obtain a current value of a fifth current;
[0025] Calculating an absolute value of a difference between a current value of the fifth current and a preset standard current value to obtain a second difference value;
[0026] If the second difference is greater than a preset error value, the fourth current is adjusted according to the second difference to obtain a sixth current, the sixth current is used as the fourth current, and the process jumps to the step of inputting the fourth current into the X-ray machine for execution;
[0027] If the second difference is less than or equal to the preset error value, the fifth current is determined as the first current.
[0028] In some implementations, obtaining the current value of the third current according to the current adjustment value of the current iteration and the current working time of the X-ray machine includes:
[0029] Determine, according to a pre-acquired first relationship, a target deviation slope corresponding to the current working time of the X-ray machine, wherein the first relationship includes a relationship between the current working time of the X-ray machine and the deviation slope, and the deviation slope is used to indicate a degree of deviation between a radiation dose output by the X-ray machine and a standard radiation dose;
[0030] The sum of the current adjustment value of the current iteration and the target deviation slope is used as the current value of the third current.
[0031] In some embodiments, determining the target deviation slope corresponding to the current operating time of the X-ray machine according to the pre-acquired first relationship includes:
[0032] When the current working time of the X-ray machine is less than the preset time threshold, the product of the current working time of the X-ray machine and the preset coefficient is used as the fourth value;
[0033] The sum of the fourth value and the preset minimum error value is used as the target deviation slope corresponding to the current working time of the X-ray machine;
[0034] or,
[0035] When the current operating time of the X-ray machine is greater than or equal to the preset time threshold, the preset maximum error value is used as the target deviation slope corresponding to the current operating time of the X-ray machine.
[0036] To achieve the above-mentioned purpose, a second aspect of an embodiment of the present application provides an X-ray machine ray dose adjustment device, the device comprising:
[0037] A current input module, used for inputting a first current into the X-ray machine when the X-ray machine is in an exposure mode, so as to control the radiation dose of the X-ray machine;
[0038] A current sampling module, used for sampling the current fed back by the X-ray machine to obtain a set of sampling values of this iteration, wherein the sampling values include a plurality of current values of the second current;
[0039] A first determining module, configured to determine a current adjustment value of this iteration according to a plurality of current values of the second current;
[0040] A second determination module, configured to determine a current value of a third current according to the current adjustment value of the current iteration;
[0041] A loop execution module is used to use the third current as the first current and jump to the step of inputting the first current to the X-ray machine if the exposure time of the exposure mode has not ended until the exposure time of the exposure mode ends.
[0042] To achieve the above-mentioned purpose, the third aspect of an embodiment of the present application proposes an electronic device, which includes a memory and a processor, the memory stores a computer program, and the processor implements the X-ray machine ray dose adjustment method described in the first aspect when executing the computer program.
[0043] To achieve the above objectives, the fourth aspect of an embodiment of the present application proposes a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, it implements the X-ray machine ray dose adjustment method described in the first aspect above.
[0044] The X-ray machine radiation dose adjustment method, device, electronic device and medium proposed in the present application, when the X-ray machine is in exposure mode, input a first current into the X-ray machine to control the radiation dose of the X-ray machine; sample the current fed back by the X-ray machine to obtain a set of sampling values of this round of iteration, and the sampling values include current values of multiple second currents; determine the current adjustment value of this round of iteration according to the current values of the multiple second currents; determine the current value of the third current according to the current adjustment value of this round of iteration; if the exposure time of the exposure mode has not ended, use the third current as the first current and jump to the step of inputting the first current into the X-ray machine until the exposure time of the exposure mode ends; dynamically adjust the current value input to the X-ray machine by the current value output by the X-ray machine to improve the uniformity of the radiation dose of the X-ray machine, thereby improving the imaging quality of the X-ray machine. BRIEF DESCRIPTION OF THE DRAWINGS
[0045] Figure 1 It is a flow chart of a method for adjusting the dose of X-ray machine provided in an embodiment of the present application;
[0046] Figure 2 is another flow chart of the method for adjusting the dose of X-ray machine provided in an embodiment of the present application;
[0047] Figure 3 It is a structural schematic diagram of an X-ray machine ray dose adjustment device provided in an embodiment of the present application;
[0048] Figure 4 It is a schematic diagram of the hardware structure of the electronic device provided in the embodiment of the present application. DETAILED DESCRIPTION
[0049] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0050] It should be noted that, although the functional modules are divided in the device schematic diagram and the logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than the module division in the device or the order in the flowchart. The terms "first", "second", etc. in the specification, claims and the above drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence.
[0051] 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 are only for the purpose of describing the embodiments of this application and are not intended to limit this application.
[0052] Conventional X-ray machines control the radiation dose by setting the voltage and current of the high-voltage tube. However, in the actual process of the tube outputting X-rays, the voltage and current will vary due to the differences in the tube itself. Under the control of the same current and voltage values, the actual radiation dose output by the X-ray machine will deviate. In addition, during long-term exposure, as the temperature of the X-ray machine's oil tank rises, the radiation dose emitted by the X-ray machine will tend to rise or fall linearly with the increase of exposure time, resulting in uneven radiation dose output of the X-ray machine, thereby affecting the imaging effect.
[0053] Therefore, the existing X-ray machine has the problem of uneven radiation dose output, which leads to poor imaging quality of the X-ray machine.
[0054] Based on this, the embodiments of the present application provide an X-ray machine radiation dose adjustment method, device, electronic device and medium, which aim to dynamically adjust the current value input to the X-ray machine through the current value output by the X-ray machine, so as to improve the uniformity of the X-ray machine radiation dose, thereby improving the imaging quality of the X-ray machine.
[0055] The X-ray machine ray dose adjustment method, device, electronic device and medium provided in the embodiments of the present application are specifically described through the following embodiments. First, the X-ray machine ray dose adjustment method in the embodiments of the present application is described.
[0056] The embodiments of the present application can acquire and process relevant data based on artificial intelligence technology. Among them, artificial intelligence (AI) is the theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results.
[0057] AI basic technologies generally include sensors, dedicated AI chips, cloud computing, distributed storage, big data processing technology, operation / interaction systems, mechatronics, etc. AI software technologies mainly include computer vision technology, robotics technology, biometrics technology, speech processing technology, natural language processing technology, and machine learning / deep learning.
[0058] The X-ray machine ray dose adjustment method provided in the embodiment of the present application relates to the field of artificial intelligence. The X-ray machine ray dose adjustment method provided in the embodiment of the present application can be applied to the terminal, can also be applied to the server side, and can also be software running in the terminal or the server side. In some embodiments, the terminal can be a smart phone, a tablet computer, a laptop computer, a desktop computer, etc.; the server side can be configured as an independent physical server, or it can be configured as a server cluster or distributed system composed of multiple physical servers, and can also be configured as a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms; the software can be an application that implements the X-ray machine ray dose adjustment method, etc., but is not limited to the above forms.
[0059] The present application can be used in many general or special computer system environments or configurations. For example: personal computers, server computers, handheld or portable devices, tablet devices, multiprocessor systems, microprocessor-based systems, set-top boxes, programmable consumer electronics, network PCs, minicomputers, mainframe computers, distributed computing environments including any of the above systems or devices, etc. The present application can be described in the general context of computer executable instructions executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform specific tasks or implement specific abstract data types. The present application can also be practiced in distributed computing environments, in which tasks are performed by remote processing devices connected through a communication network. In a distributed computing environment, program modules can be located in local and remote computer storage media including storage devices.
[0060] It should be noted that in each specific implementation of the present application, when it comes to the need to perform relevant processing based on data related to user identity or characteristics such as user information, user behavior data, user historical data, and user location information, the user's permission or consent will be obtained first, and the collection, use, and processing of these data will comply with relevant laws, regulations, and standards. In addition, when the embodiment of the present application needs to obtain the user's sensitive personal information, the user's separate permission or consent will be obtained through a pop-up window or by jumping to a confirmation page. After clearly obtaining the user's separate permission or consent, the necessary user-related data for the normal operation of the embodiment of the present application will be obtained.
[0061] Figure 1 is a flow chart of the method for adjusting the dose of X-ray machine provided in the embodiment of the present application, please refer to Figure 1 The X-ray machine dose adjustment method provided in the embodiment of the present application may include but is not limited to steps S101 to S105.
[0062] Step S101: When the X-ray machine is in an exposure mode, a first current is input into the X-ray machine to control the radiation dose of the X-ray machine.
[0063] In this step, the operating mode of the X-ray machine is divided into a correction mode and an exposure mode. The correction mode is used to correct the target current input to the X-ray machine in the user mode (i.e., exposure mode) before the X-ray machine is applied in the target application scenario. The exposure mode is the mode of the X-ray machine when it is actually used in the target application scenario. The exposure mode start instruction can be sent to the X-ray machine through the host computer, or the exposure mode of the X-ray machine can be manually started by a technician. When the X-ray machine is in the exposure mode, a first current and a voltage corresponding to the first current are input into the X-ray machine to control the radiation dose emitted by the X-ray machine, wherein the first current is a pre-calibrated current that makes the radiation dose emitted by the X-ray machine meet the requirements of the application scenario. The application scenario can be an X-ray machine on a security inspection machine, an X-ray machine in a hospital imaging device, or any device that uses an X-ray machine to shoot, and is not limited here.
[0064] Step S102: sampling the current fed back by the X-ray machine to obtain a set of sampling values of this iteration, wherein the sampling values include current values of multiple second currents.
[0065] In this step, after the current has completed climbing and leveling, the current feedback from the X-ray machine is sampled at preset sampling times to obtain multiple temporary second currents, and each temporary second current is filtered and denoised to obtain current values of multiple second currents. An iteration is performed according to the preset number of samplings, and the current values of the second current corresponding to the N continuously sampled temporary second currents are taken as a group of sampling values, where N is the preset number of samplings, and N is a positive integer. N can be set according to actual conditions.
[0066] Exemplarily, the preset sampling time is set to 1ms, that is, after the current of the X-ray machine completes climbing and leveling in 20ms when the X-ray machine is in exposure mode, the current feedback from the X-ray machine is sampled every 1ms, and the preset sampling number is 5 times, that is, each five samplings are regarded as one round of iteration, and the current values of the second current obtained by these five samplings are regarded as a set of sampling values.
[0067] Step S103: determining a current adjustment value for this round of iteration according to a plurality of current values of the second current.
[0068] In this step, the current adjustment value of this round of iteration is determined based on the difference between the current value of each second current obtained in this round of iteration and the current value input to the X-ray machine for the first time, and the difference between the current value of each second current obtained in the previous round of iteration and the current value input to the X-ray machine for the first time, and the current value input to the X-ray machine is adjusted using the current adjustment value.
[0069] Step S104: determining a current value of the third current according to the current adjustment value of the current iteration.
[0070] In this step, the current value input to the X-ray machine is adjusted by the current adjustment value of this round of iteration to determine the current value of the third current.
[0071] Step S105: if the exposure time of the exposure mode has not ended, use the third current as the first current and jump to the step of inputting the first current into the X-ray machine until the exposure time of the exposure mode ends.
[0072] In this step, the exposure time of the exposure mode can be set according to the exposure task. When the exposure time of the exposure mode has not ended, the third current is used as the first current, and the first current is repeatedly input into the X-ray machine, and the current fed back by the X-ray machine is sampled to obtain a set of sampling values for this round of iteration, wherein the sampling values include current values of multiple second currents; the current adjustment value of this round of iteration is determined according to the current values of the multiple second currents; the current value of the third current is determined according to the current adjustment value of this round of iteration; and the step of using the third current as the first current is performed until the exposure time of the exposure mode ends, that is, until the exposure task is completed.
[0073] Through the above steps S101 to S105, when the X-ray machine is in the exposure mode, the electronic device inputs the first current into the X-ray machine to control the radiation dose of the X-ray machine; samples the current fed back by the X-ray machine to obtain a set of sampling values of this round of iteration, and the sampling values include current values of multiple second currents; determines the current adjustment value of this round of iteration according to the current values of the multiple second currents; determines the current value of the third current according to the current adjustment value of this round of iteration; if the exposure time of the exposure mode has not ended, uses the third current as the first current, jumps to the step of inputting the first current into the X-ray machine, and executes until the exposure time of the exposure mode ends; dynamically adjusts the current value input to the X-ray machine according to the current value output by the X-ray machine to improve the uniformity of the radiation dose of the X-ray machine, thereby improving the imaging quality of the X-ray machine.
[0074] In some embodiments, determining the current adjustment value of the current iteration according to the current values of the plurality of second currents in step S103 may include but is not limited to the following steps:
[0075] Calculating the difference between each current value of the second current and the current value of the target current to obtain a plurality of first difference values, wherein the target current is the current first input to the X-ray machine in the exposure mode;
[0076] The current adjustment value of this round of iteration is determined according to the multiple first differences.
[0077] In this implementation, the target current is pre-calibrated, and the target current is the current that makes the radiation dose emitted by the X-ray machine meet the requirements of the application scenario; each round of iteration calculates the difference between the current value of each second current in this round of iteration and the target current to obtain the first difference, and the current adjustment value of this round of iteration is determined by the first difference corresponding to each second current in each round of iteration.
[0078] Exemplarily, the target current is 3mA, and this round of iteration includes five second currents, whose current values are 2.7mA, 2.8mA, 2.6mA, 2.7mA and 2.5mA respectively. By calculating the difference between each second current and the target current, it can be obtained that the first difference corresponding to each second current is 0.3mA, 0.2mA, 0.4mA, 0.3mA and 0.5mA. Based on the above multiple first differences, the current adjustment value of this round of iteration is determined.
[0079] In this embodiment, by continuously calculating the difference between each second current and the target current, the radiation dose of the X-ray machine can be more accurately controlled to meet the needs of specific application scenarios; and through iteration, the current of the X-ray machine gradually approaches the target current in each iteration, without the need for manual operation, thereby improving operational efficiency.
[0080] In some implementations, determining the current adjustment value of this round of iteration according to the multiple first differences may include, but is not limited to, the following steps:
[0081] The sum of the multiple first difference values obtained in this round of iteration is used as the first value;
[0082] Calculate the average of the first differences in this round of iteration to obtain a second value;
[0083] The sum of the multiple first difference values obtained in the previous iteration is used as the third value;
[0084] A weighted sum is performed on the first value, the second value and the third value to obtain the current adjustment value of the current iteration.
[0085] In this implementation, multiple first difference values obtained in this round of iteration are added together to obtain a first value; the average value of the multiple first difference values obtained in this round of iteration is calculated to obtain a second value; the multiple first difference values obtained in the previous round of iteration are added together to obtain a third value, and the above-mentioned first value, second value, and third value are multiplied by corresponding coefficients to obtain the current adjustment value of this round of iteration.
[0086] Specifically, the calculation formula of the above current adjustment value can be shown as follows:
[0087] PID=pid.Kp*error+pid.Ki*pid.integral+pid.Kd*derivative
[0088] Among them, PID represents the current adjustment value, error represents the first value, pid.integral represents the second value, derivative represents the third value, pid.Kp represents the coefficient corresponding to the first value, pid.Ki represents the coefficient corresponding to the second value, and pid.Kd represents the coefficient corresponding to the third value.
[0089] It should be noted that pid.Kp, pid.Ki and pid.Kd can be set according to actual conditions and are not limited here.
[0090] In this embodiment, the sum of the differences between this round of iteration and the previous round of iteration, as well as the mean of the differences in this round of iteration, are used to reduce fluctuations in the current adjustment process, making the current adjustment smoother. In addition, by calculating multiple first differences, the influence of individual abnormal values on the current adjustment value is reduced, thereby improving the accuracy of current adjustment.
[0091] In some implementations, determining the current value of the third current according to the current adjustment value of this round of iteration in step S104 may include, but is not limited to, the following steps:
[0092] The current value of the third current is obtained according to the current adjustment value of the current iteration and the current working time of the X-ray machine, and the current working time is the time length that the X-ray machine is in the exposure mode.
[0093] In this implementation, the length of time the X-ray machine is in exposure mode is recorded, that is, the current working time of the X-ray machine. Since the working time of the X-ray machine will cause changes in equipment performance, such as thermal drift, component aging, etc., the compensation current parameters of the X-ray machine are determined according to the working time of the X-ray machine.
[0094] According to the current adjustment parameters of this round of iteration and the compensation current parameters corresponding to the current working time of the X-ray machine, the current value of the third current is obtained, and the current value of the third current is used as the current value input to the X-ray machine at the beginning of the next round of iteration.
[0095] Specifically, the calculation formula of the current value of the third current can be shown as follows:
[0096] I=PID+f(x)
[0097] Among them, I represents the current value of the third current, PID represents the current adjustment parameter of this round of iteration, and f(x) represents the compensation current parameter corresponding to the current working time of the X-ray machine.
[0098] In this embodiment, the current working time of the X-ray machine can be used to more accurately predict and compensate for performance changes caused by the long-term operation of the X-ray machine, thereby improving the control accuracy of the radiation dose, and by adjusting the current in real time, the working performance of the X-ray machine can be optimized to ensure that the radiation dose of the X-ray machine can be stably output under different working times of the X-ray machine, thereby providing the best imaging effect.
[0099] In some embodiments, Figure 2 As shown, when the X-ray machine is in exposure mode in step S101, before the first current is input into the X-ray machine, the X-ray machine radiation dose adjustment method provided in the embodiment of the present application may include but is not limited to steps S201 to S206.
[0100] Step S201, obtaining a fourth current, where the fourth current is a preset current for starting the X-ray machine.
[0101] Step S202: input a fourth current into the X-ray machine.
[0102] Step S203: sampling the current fed back by the X-ray machine to obtain a current value of the fifth current.
[0103] Step S204: Calculate the absolute value of the difference between the current value of the fifth current and the preset standard current value to obtain a second difference.
[0104] Step S205: If the second difference is greater than a preset error value, the fourth current is adjusted according to the second difference to obtain a sixth current, the sixth current is used as the fourth current, and the process jumps to the step of inputting the fourth current into the X-ray machine for execution.
[0105] Step S206: If the second difference is less than or equal to the preset error value, determine the fifth current as the first current.
[0106] In this implementation, the fourth current is a preset current for starting the X-ray machine, and the fourth current can be set according to actual conditions and is not limited here. The fourth current and the voltage corresponding to the fourth current are input into the X-ray machine to start the X-ray machine, and the current fed back after the X-ray machine is started is sampled to obtain the current value of the fifth current, and the difference between the current value of the fifth current and the preset standard current value is calculated, and the absolute value thereof is taken to obtain the second difference.
[0107] Determine whether the second difference is greater than a preset error value. If the second difference is greater than the preset error value, it means that the current is not within the expected range. Adjust the fourth current according to the second difference to obtain a new current, namely, the sixth current. Use the sixth current as the fourth current, and repeat the process of inputting the fourth current into the X-ray machine. Sample the current fed back by the X-ray machine to obtain the current value of the fifth current. Calculate the absolute value of the difference between the current value of the fifth current and the preset standard current value to obtain the second difference. If the second difference is greater than the preset error value, adjust the fourth current according to the second difference to obtain the sixth current. Use the sixth current as the fourth current. Repeat the process until the second difference is less than the preset error value. Use the fifth current as the first current, that is, the fifth current is a current that enables the radiation dose emitted by the X-ray machine to meet the requirements of the application scenario.
[0108] It should be noted that both the preset error value and the preset standard current can be set according to actual conditions and are not limited here.
[0109] Exemplarily, the preset standard current value is 2mA, and the exposure time is set to 100ms, 20ms to 80ms is set as the sampling time period, the preset error value is 0.5mA, the current value fed back by the X-ray machine from 20ms to 80ms is intercepted, and the current in the above sampling time period is calculated by the median average method to obtain the current value of the fifth current, and the difference between the current value of the fifth current and the preset standard current value is calculated. If the absolute value of the difference between the current value of the fifth current and the preset standard current value is greater than 0.5mA, based on the current value last input to the X-ray machine, the fifth current is calculated according to the difference between the current value of the fifth current and the preset standard current value. Set the standard current value difference for adjustment. For example, if the difference between the current value of the fifth current and the preset standard current value is greater than 0.5mA, the current value input to the X-ray machine will be adaptively reduced based on the current value input to the X-ray machine last time. If the difference between the current value of the fifth current and the preset standard current value is less than -0.5mA, the current value input to the X-ray machine will be adaptively increased based on the current value input to the X-ray machine last time, until the absolute value of the difference between the current value of the fifth current and the preset standard current value is less than 0.5mA, the fifth current will be used as the target current and will take effect when the X-ray machine is in exposure mode.
[0110] In this embodiment, the target current input to the X-ray machine in the exposure mode is corrected to compensate for the error in the radiation dose emitted by the X-ray machine caused by the hardware difference among different batches of X-ray machines, thereby greatly improving the consistency of X-ray machine products.
[0111] In some embodiments, obtaining the current value of the third current according to the current adjustment value of the current iteration and the current working time of the X-ray machine may include but is not limited to the following steps:
[0112] Determine, according to a pre-acquired first relationship, a target deviation slope corresponding to the current working time of the X-ray machine, wherein the first relationship includes a relationship between the current working time of the X-ray machine and the deviation slope, and the deviation slope is used to indicate a degree of deviation between a radiation dose output by the X-ray machine and a standard radiation dose;
[0113] The sum of the current adjustment value of the current iteration and the target deviation slope is used as the current value of the third current.
[0114] In this implementation, the length of time the X-ray machine is in exposure mode is recorded, that is, the current working time of the X-ray machine. Since the working time of the X-ray machine will cause changes in equipment performance, such as thermal drift, component aging, etc., the deviation slope of the X-ray machine is determined according to the working time of the X-ray machine, that is, the compensation current parameter of the X-ray machine.
[0115] According to the current adjustment parameter of this round of iteration and the deviation slope corresponding to the current working time of the X-ray machine, the current value of the third current is obtained, and the current value of the third current is used as the current value input to the X-ray machine at the beginning of the next round of iteration.
[0116] In this embodiment, the current working time of the X-ray machine can be used to more accurately predict and compensate for performance changes caused by the long-term operation of the X-ray machine, thereby improving the control accuracy of the radiation dose, and by adjusting the current in real time, the working performance of the X-ray machine can be optimized to ensure that the radiation dose of the X-ray machine can be stably output under different working times of the X-ray machine, thereby providing the best imaging effect.
[0117] In some implementations, determining the target deviation slope corresponding to the current operating time of the X-ray machine according to the pre-acquired first relationship may include, but is not limited to, the following steps:
[0118] When the current working time of the X-ray machine is less than the preset time threshold, the product of the current working time of the X-ray machine and the preset coefficient is used as the fourth value;
[0119] The sum of the fourth value and the preset minimum error value is used as the target deviation slope corresponding to the current working time of the X-ray machine;
[0120] or,
[0121] When the current operating time of the X-ray machine is greater than or equal to the preset time threshold, the preset maximum error value is used as the target deviation slope corresponding to the current operating time of the X-ray machine.
[0122] In this implementation, when the current working time of the X-ray machine is less than the preset time threshold, the current working time of the X-ray machine is multiplied by the preset coefficient to obtain a fourth value, and the fourth value is added to the preset minimum error value to obtain the target deviation slope corresponding to the current working time of the X-ray machine; when the current working time of the X-ray machine is greater than or equal to the preset time threshold, the preset maximum error value is used as the target deviation slope corresponding to the current working time of the X-ray machine.
[0123] Specifically, when the current working time of the X-ray machine is less than the preset time threshold, the calculation formula of the target deviation slope of the X-ray machine can be shown as follows:
[0124] f(x)=a(x)*t+f(x)min
[0125] Among them, f(x) represents the target deviation slope, a(x) represents the preset coefficient, t represents the current working time of the X-ray machine, and f(x)min represents the preset minimum error value.
[0126] When the current working time of the X-ray machine is greater than or equal to the preset time threshold, the calculation formula of the target deviation slope of the X-ray machine can be shown as follows:
[0127] f(x)=f(x)max
[0128] Wherein, f(x)max represents the preset maximum error value.
[0129] Exemplarily, the preset duration threshold is 250s, the preset coefficient is 0.0018, the preset minimum error value is 0.2, and the preset maximum error value is 0.65.
[0130] That is, when the current working time of the X-ray machine is less than 250s, the target deviation slope of the X-ray machine can be calculated using the following formula:
[0131] f(x)=0.0018*t+0.2
[0132] When the current working time of the X-ray machine is greater than or equal to 250s, the calculation formula of the target deviation slope of the X-ray machine can be calculated using the following formula:
[0133] f(x)=0.65
[0134] It should be noted that the preset coefficient, the preset minimum error value, and the preset maximum error value can be set according to actual conditions and are not limited here.
[0135] In this embodiment, in the initial stage of the operation of the X-ray machine, by using a smaller target deviation slope, excessive adjustment can be avoided and the stable performance of the X-ray machine can be maintained. As the working time of the X-ray machine increases, the target deviation slope can be appropriately increased to compensate for the degradation of the performance of the X-ray machine, thereby improving the accuracy of current control to improve the stability and accuracy of the output radiation dose of the X-ray machine.
[0136] Figure 3 This is a schematic diagram of the structure of the X-ray machine radiation dose adjustment device provided in the embodiment of the present application. Figure 3 The embodiment of the present application further provides an X-ray machine ray dose adjustment device 800, which can implement the above-mentioned X-ray machine ray dose adjustment method. The X-ray machine ray dose adjustment device 800 includes:
[0137] A current input module 801 is used to input a first current into the X-ray machine when the X-ray machine is in an exposure mode, so as to control the radiation dose of the X-ray machine;
[0138] A current sampling module 802 is used to sample the current fed back by the X-ray machine to obtain a set of sampling values of this iteration, wherein the sampling values include a plurality of current values of the second current;
[0139] A first determination module 803, configured to determine a current adjustment value of this iteration according to a plurality of current values of the second current;
[0140] A second determination module 804, configured to determine a current value of a third current according to the current adjustment value of the current iteration;
[0141] The loop execution module 805 is used to use the third current as the first current and jump to the step of inputting the first current to the X-ray machine if the exposure time of the exposure mode has not ended until the exposure time of the exposure mode ends.
[0142] In some implementations, the first determining module 803 includes:
[0143] a first calculation submodule, configured to respectively calculate the difference between the current value of each second current and the current value of a target current to obtain a plurality of first difference values, wherein the target current is the current first input to the X-ray machine in the exposure mode;
[0144] The first determination submodule is used to determine the current adjustment value of this round of iteration according to the multiple first differences.
[0145] In some implementations, the first determining submodule includes:
[0146] A first calculation unit, configured to take a sum of the plurality of first difference values obtained in this round of iteration as a first value;
[0147] A second calculation unit, configured to perform mean calculation on a plurality of the first difference values in this round of iteration to obtain a second value;
[0148] A third calculation unit, configured to take the sum of the plurality of first difference values obtained in the previous round of iteration as a third value;
[0149] The first determining unit is used to perform weighted summation on the first value, the second value and the third value to obtain the current adjustment value of the current iteration.
[0150] In some implementations, the second determining module 804 includes:
[0151] The second determination unit is used to obtain the current value of the third current according to the current adjustment value of the current iteration and the current working time of the X-ray machine, and the current working time is the time length that the X-ray machine is in the exposure mode.
[0152] In some embodiments, the X-ray machine ray dose adjustment device 800 further includes:
[0153] A first acquisition module, used for acquiring a fourth current, where the fourth current is a preset current for starting the X-ray machine;
[0154] A first input module, used for inputting a fourth current into the X-ray machine;
[0155] A first sampling module, used for sampling the current fed back by the X-ray machine to obtain a current value of a fifth current;
[0156] A first calculation module, used for calculating the absolute value of the difference between the current value of the fifth current and a preset standard current value to obtain a second difference;
[0157] A third determining module is used for adjusting the fourth current according to the second difference to obtain a sixth current if the second difference is greater than a preset error value, taking the sixth current as the fourth current, and jumping to the step of inputting the fourth current into the X-ray machine for execution;
[0158] The fourth determination module is configured to determine the fifth current as the first current if the second difference is less than or equal to the preset error value.
[0159] In some implementations, the second determining unit includes:
[0160] a first determining subunit, configured to determine a target deviation slope corresponding to a current operating time of the X-ray machine according to a pre-acquired first relationship, wherein the first relationship includes a relationship between a current operating time of the X-ray machine and a deviation slope, wherein the deviation slope is used to indicate a degree of deviation between a radiation dose output by the X-ray machine and a standard radiation dose;
[0161] The second determining subunit uses the sum of the current adjustment value of the current iteration and the target deviation slope as the current value of the third current.
[0162] In some embodiments, the first determining subunit includes:
[0163] A first calculation sub-subunit is used to take the product of the current working time of the X-ray machine and the preset coefficient as the fourth value when the current working time of the X-ray machine is less than the preset time threshold;
[0164] A second calculation sub-subunit is used to use the sum of the fourth value and the preset minimum error value as the target deviation slope corresponding to the current working time of the X-ray machine;
[0165] or,
[0166] The third secondary subunit is used to use the preset maximum error value as the target deviation slope corresponding to the current working time of the X-ray machine when the current working time of the X-ray machine is greater than or equal to the preset time threshold.
[0167] The specific implementation of the X-ray machine ray dose adjustment device 800 is the same as the specific implementation of the above-mentioned X-ray machine ray dose adjustment method, and will not be repeated here.
[0168] When the X-ray machine is in exposure mode, a first current is input into the X-ray machine to control the radiation dose of the X-ray machine; the current fed back by the X-ray machine is sampled to obtain a set of sampling values of this iteration, and the sampling values include current values of multiple second currents; according to the current values of the multiple second currents, a current adjustment value of this iteration is determined; according to the current adjustment value of this iteration, a current value of a third current is determined; if the exposure time of the exposure mode has not ended, the third current is used as the first current, and the step of inputting the first current into the X-ray machine is jumped to execute until the exposure time of the exposure mode ends; the current value input into the X-ray machine is dynamically adjusted by the current value output by the X-ray machine to improve the uniformity of the radiation dose of the X-ray machine, thereby improving the imaging quality of the X-ray machine.
[0169] The embodiment of the present application also provides an electronic device, the electronic device includes a memory and a processor, the memory stores a computer program, and the processor implements the above-mentioned X-ray machine ray dose adjustment method when executing the computer program. The electronic device can be any intelligent terminal including a desktop computer, a tablet computer, a mobile phone, and a car computer.
[0170] See also Figure 4 , Figure 4 A schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present application, wherein the electronic device includes:
[0171] The processor 901 may be implemented by a general-purpose CPU (Central Processing Unit), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of the present application;
[0172] The memory 902 can be implemented in the form of a read-only memory (ROM), a static storage device, a dynamic storage device, or a random access memory (RAM). The memory 902 can store an operating system and other application programs. When the technical solution provided in the embodiment of this specification is implemented by software or firmware, the relevant program code is stored in the memory 902, and the processor 901 calls and executes the X-ray machine ray dose adjustment method of the embodiment of this application;
[0173] Input / output interface 903, used to implement information input and output;
[0174] Communication interface 904, used to realize communication interaction between the device and other devices, which can be realized by wired mode (such as USB, network cable, etc.) or wireless mode (such as mobile network, WIFI, Bluetooth, etc.);
[0175] A bus 905 that transmits information between various components of the device (e.g., the processor 901, the memory 902, the input / output interface 903, and the communication interface 904);
[0176] The processor 901 , the memory 902 , the input / output interface 903 and the communication interface 904 are connected to each other in communication within the device via a bus 905 .
[0177] An embodiment of the present application also provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, the above-mentioned X-ray machine radiation dose adjustment method is implemented.
[0178] The memory, as a non-transient computer-readable storage medium, can be used to store non-transient software programs and non-transient computer executable programs. In addition, the memory may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some embodiments, the memory may optionally include a memory remotely disposed relative to the processor, and these remote memories may be connected to the processor via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0179] The embodiments of the present application provide an X-ray machine radiation dose adjustment method, device, electronic device and medium. When the X-ray machine is in exposure mode, a first current is input into the X-ray machine to control the radiation dose of the X-ray machine; the current fed back by the X-ray machine is sampled to obtain a set of sampling values of this round of iteration, and the sampling values include current values of multiple second currents; the current adjustment value of this round of iteration is determined according to the current values of the multiple second currents; the current value of the third current is determined according to the current adjustment value of this round of iteration; if the exposure time of the exposure mode has not ended, the third current is used as the first current, and the step of inputting the first current into the X-ray machine is executed until the exposure time of the exposure mode ends; the current value input into the X-ray machine is dynamically adjusted by the current value output by the X-ray machine to improve the uniformity of the radiation dose of the X-ray machine, thereby improving the imaging quality of the X-ray machine.
[0180] The embodiments described in the embodiments of the present application are intended to more clearly illustrate the technical solutions of the embodiments of the present application and do not constitute a limitation on the technical solutions provided in the embodiments of the present application. Those skilled in the art will appreciate that with the evolution of technology and the emergence of new application scenarios, the technical solutions provided in the embodiments of the present application are also applicable to similar technical problems.
[0181] Those skilled in the art will appreciate that the technical solutions shown in the figures do not constitute a limitation on the embodiments of the present application, and may include more or fewer steps than shown in the figures, or a combination of certain steps, or different steps.
[0182] The device embodiments described above are merely illustrative, and the units described as separate components may or may not be physically separated, that is, they may be located in one place or distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0183] Those skilled in the art will appreciate that all or some of the steps in the methods disclosed above, and the functional modules / units in the systems and devices may be implemented as software, firmware, hardware, or a suitable combination thereof.
[0184] The terms "first", "second", "third", "fourth", etc. (if any) in the specification of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0185] It should be understood that in the present application, "at least one (item) at least refers to one or more, and "plurality" refers to two or more. "And / or" is used to describe the association relationship of associated objects, indicating that three relationships may exist. For example, "and / or B" can be used to represent: only A exists, only B exists, and A and B exist at the same time, where A and B can be singular or plural. The character " is generally used to indicate that the associated objects before and after are in an "or" relationship. "At least one of the following" or similar expressions refer to any combination of these items, including any combination of single or plural items. For example, at least one of a, b or c can be expressed as: a, b, c, "and b", "and c", "and c", or "or and b and c", where a, b, c can be single or plural.
[0186] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the above units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0187] The units described above as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0188] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0189] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including multiple instructions to enable a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of various embodiments of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, referred to as ROM), random access memory (Random Access Memory, referred to as RAM), disk or optical disk and other media that can store programs.
[0190] The preferred embodiments of the present invention are described above with reference to the accompanying drawings, but the scope of the rights of the present invention is not limited thereto. Any modification, equivalent substitution and improvement made by a person skilled in the art without departing from the scope and essence of the present invention should be within the scope of the rights of the present invention.
Claims
1. A method for adjusting the dose of X-ray machine, characterized in that: The method comprises: When the X-ray machine is in an exposure mode, inputting a first current into the X-ray machine to control the radiation dose of the X-ray machine; Sampling the current fed back by the X-ray machine to obtain a set of sampling values of this round of iteration, wherein the sampling values include a plurality of current values of the second current; Determining a current adjustment value for this round of iteration according to a plurality of current values of the second current; Determining a current value of a third current according to the current adjustment value of the current iteration; If the exposure time of the exposure mode has not ended, the third current is used as the first current, and the process jumps to the step of inputting the first current into the X-ray machine until the exposure time of the exposure mode ends.
2. The method according to claim 1, characterized in that The step of determining the current adjustment value of the current iteration according to the current values of the plurality of second currents includes: Calculating the difference between each current value of the second current and the current value of the target current to obtain a plurality of first difference values, wherein the target current is the current first input to the X-ray machine in the exposure mode; The current adjustment value of this round of iteration is determined according to the multiple first differences.
3. The method according to claim 2, characterized in that The step of determining the current adjustment value of this round of iteration according to the plurality of first differences includes: The sum of the multiple first difference values obtained in this round of iteration is used as the first value; Calculate the average of the first differences in this round of iteration to obtain a second value; The sum of the multiple first difference values obtained in the previous iteration is used as the third value; A weighted sum is performed on the first value, the second value and the third value to obtain the current adjustment value of the current iteration.
4. The method according to claim 1, characterized in that: The step of determining the current value of the third current according to the current adjustment value of the current iteration includes: The current value of the third current is obtained according to the current adjustment value of the current iteration and the current working time of the X-ray machine, and the current working time is the time length that the X-ray machine is in the exposure mode.
5. The method according to claim 1, characterized in that When the X-ray machine is in an exposure mode, before inputting the first current into the X-ray machine, the method further includes: Acquiring a fourth current, where the fourth current is a preset current for starting the X-ray machine; inputting a fourth current into the X-ray machine; Sampling the current fed back by the X-ray machine to obtain a current value of a fifth current; Calculating an absolute value of a difference between a current value of the fifth current and a preset standard current value to obtain a second difference value; If the second difference is greater than a preset error value, the fourth current is adjusted according to the second difference to obtain a sixth current, the sixth current is used as the fourth current, and the process jumps to the step of inputting the fourth current into the X-ray machine for execution; If the second difference is less than or equal to the preset error value, the fifth current is determined as the first current.
6. The method according to claim 4, characterized in that The step of obtaining the current value of the third current according to the current adjustment value of the current iteration and the current working time of the X-ray machine includes: Determine, according to a pre-acquired first relationship, a target deviation slope corresponding to the current working time of the X-ray machine, wherein the first relationship includes a relationship between the current working time of the X-ray machine and the deviation slope, and the deviation slope is used to indicate a degree of deviation between a radiation dose output by the X-ray machine and a standard radiation dose; The sum of the current adjustment value of the current iteration and the target deviation slope is used as the current value of the third current.
7. The method according to claim 6, characterized in that The step of determining the target deviation slope corresponding to the current working time of the X-ray machine according to the pre-acquired first relationship includes: When the current working time of the X-ray machine is less than the preset time threshold, the product of the current working time of the X-ray machine and the preset coefficient is used as the fourth value; The sum of the fourth value and the preset minimum error value is used as the target deviation slope corresponding to the current working time of the X-ray machine; or, When the current operating time of the X-ray machine is greater than or equal to the preset time threshold, the preset maximum error value is used as the target deviation slope corresponding to the current operating time of the X-ray machine.
8. An X-ray machine radiation dose adjustment device, characterized in that: The device comprises: A current input module, used for inputting a first current into the X-ray machine when the X-ray machine is in an exposure mode, so as to control the radiation dose of the X-ray machine; A current sampling module, used for sampling the current fed back by the X-ray machine to obtain a set of sampling values of this iteration, wherein the sampling values include a plurality of current values of the second current; A first determining module, configured to determine a current adjustment value of this iteration according to a plurality of current values of the second current; A second determination module, configured to determine a current value of a third current according to the current adjustment value of the current iteration; A loop execution module is used to use the third current as the first current and jump to the step of inputting the first current to the X-ray machine if the exposure time of the exposure mode has not ended until the exposure time of the exposure mode ends.
9. An electronic device, characterized in that: The electronic device comprises a memory and a processor, wherein the memory stores a computer program, and the processor implements the X-ray machine ray dose adjustment method according to any one of claims 1 to 7 when executing the computer program.
10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the X-ray machine ray dose adjustment method according to any one of claims 1 to 7 is implemented.
Citation Information
Patent Citations
Exposure dose correction method and equipment, storage medium and X-ray medical system
CN110432917A
Image exposure brightness adjusting method and system and related component
CN110475079A
X-ray system, exposure time compensation method and system training method
CN115209601A
Output intensity control method and system of X-ray source
CN115413101A
X-ray machine exposure dose control method and electronic device
CN116035602A