PET crystal positioning method and system, electronic equipment and storage medium
By clustering the effective pixel points in the image to be processed in the PET device, the positioning difficulties caused by uneven distribution of positron emission points in the PET device are solved, and automatic positioning of PET crystals and efficient and accurate position determination are achieved.
Patent Information
- Application Number
- CN202311280381.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-09-28
- Publication Date
- 2025-03-28
AI Technical Summary
The uneven distribution of positron emission points in PET equipment, which results in the manual positioning of the position with the largest number of flickering photons consumes a lot of manpower and increases the possibility of errors, and it is difficult to achieve automatic positioning.
By acquiring the to-process image scanned by the target detection module, clustering the effective pixel points is performed to form clustering clusters to determine the position of the PET crystal. This method does not rely on a large amount of labeled data and does not require multiple iterations of calculations.
It realizes automatic positioning of PET crystals, improves positioning accuracy and efficiency, reduces the possibility of manual intervention and errors, and is suitable for the positioning of aging PET crystals.
Smart Images

Figure CN119722564A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of medical imaging technology, and in particular to a PET crystal positioning method, system, electronic device and storage medium. Background Art
[0002] In positron emission tomography (PET) technology, PET crystals are used to absorb gamma rays and emit scintillation photons.
[0003] The position where the number of scintillation photons emitted by the PET crystal is the largest is related to the positron emission position. In the PET device, a PET crystal position lookup table (LUT) is usually used to store the correspondence between the known positron emission positions and the position where the number of scintillation photons is the largest. That is, the position of the PET crystal corresponding to the positron emission position can be determined by looking up the positron emission position corresponding to the number of scintillation photons detected by the detector in the LUT.
[0004] However, due to the uneven distribution of positron emission points in PET equipment, manually locating the position with the largest number of scintillation photons is a huge workload, which is not only labor-intensive but also increases the possibility of error. In addition, due to the limitations of the hardware structure of the PET equipment and the arrangement of PET crystals, it is difficult to automatically locate the position with the largest number of scintillation photons. Summary of the invention
[0005] In order to solve the above technical problems, the present disclosure provides a PET crystal positioning method, system, electronic device and storage medium.
[0006] The present invention solves the above technical problems through the following technical solutions:
[0007] In a first aspect, the present disclosure provides a method for positioning a PET crystal, the positioning method comprising:
[0008] Acquire an image to be processed based on scanning by a target detection module; wherein the target detection module includes a plurality of the PET crystals;
[0009] Clustering is performed on a number of valid pixel points in the image to be processed to obtain a cluster corresponding to each of the PET crystals; wherein the valid pixel point is a pixel point corresponding to the scintillation photon emitted by the PET crystal;
[0010] According to the clustering clusters, the positions of the corresponding PET crystals are determined.
[0011] Optionally, the step of clustering a number of valid pixels in the image to be processed includes:
[0012] For a preset area centered on each of the effective pixels in the image to be processed, the point density of the preset area is calculated; wherein the point density is positively correlated with the number of the effective pixels in the preset area;
[0013] According to the point density, determining a number of central pixel points from a number of the effective pixel points;
[0014] Determine a non-central pixel point that matches each of the central pixel points to form the corresponding cluster; wherein the non-central pixel point belongs to the valid pixel point.
[0015] Optionally, the step of determining a plurality of central pixel points from the plurality of valid pixel points comprises:
[0016] Selecting the effective pixel point at the center of the preset area whose point density is greater than a first set value as the central pixel point;
[0017] and / or,
[0018] The valid pixel points in the center of the preset area are sorted from large to small according to the point density, and the valid pixel point sorted before the second set value is selected as the center pixel point, or the valid pixel points in the center of the preset area are sorted from small to large according to the point density, and the valid pixel point sorted after the third set value is selected as the center pixel point.
[0019] Optionally, the step of determining a non-central pixel point matching each central pixel point comprises:
[0020] Match the non-central pixel point to the central pixel point that is closest to it.
[0021] Optionally, the step of determining non-central pixel points matching each central pixel point further includes:
[0022] If the distances between the non-central pixel point and at least two of the central pixel points are the same, the non-central pixel point is matched to the central pixel point at the center of the preset area with the largest point density.
[0023] Optionally, the step of determining the position of the corresponding PET crystal comprises:
[0024] The centroid position of the cluster is obtained as the corresponding position of the PET crystal.
[0025] Optionally, before the step of clustering a number of valid pixels in the image to be processed, the method further includes:
[0026] The image to be processed is binarized.
[0027] In a second aspect, the present disclosure provides a PET crystal positioning system, the positioning system comprising:
[0028] An image acquisition module, used to acquire an image to be processed based on scanning by a target detection module; wherein the target detection module includes a plurality of the PET crystals;
[0029] An image analysis module, used for clustering a number of effective pixel points in the image to be processed to obtain a cluster corresponding to each of the PET crystals; wherein the effective pixel point is a pixel point corresponding to the scintillation photon emitted by the PET crystal;
[0030] A positioning module is used to determine the position of the corresponding PET crystal according to the cluster.
[0031] Optionally, the image analysis module is used to:
[0032] For a preset area centered on each of the effective pixels in the image to be processed, the point density of the preset area is calculated; wherein the point density is positively correlated with the number of the effective pixels in the preset area;
[0033] According to the point density, determining a number of central pixel points from a number of the effective pixel points;
[0034] Determine a non-central pixel point that matches each of the central pixel points to form the corresponding cluster; wherein the non-central pixel point belongs to the valid pixel point.
[0035] Optionally, the image analysis module is used to:
[0036] Selecting the effective pixel point at the center of the preset area whose point density is greater than a first set value as the central pixel point;
[0037] and / or,
[0038] The valid pixel points in the center of the preset area are sorted from large to small according to the point density, and the valid pixel point sorted before the second set value is selected as the center pixel point, or the valid pixel points in the center of the preset area are sorted from small to large according to the point density, and the valid pixel point sorted after the third set value is selected as the center pixel point.
[0039] Optionally, the image analysis module is used to:
[0040] Match the non-central pixel point to the central pixel point that is closest to it.
[0041] Optionally, the image analysis module is used to:
[0042] If the distances between the non-central pixel point and at least two of the central pixel points are the same, the non-central pixel point is matched to the central pixel point at the center of the preset area with the largest point density.
[0043] Optionally, the positioning module is used to:
[0044] The centroid position of the cluster is obtained as the corresponding position of the PET crystal.
[0045] Optionally, the positioning system further includes an image preprocessing module, and the image preprocessing module is used to:
[0046] The image to be processed is binarized.
[0047] In a third aspect, the present disclosure provides a PET device, wherein the PET device comprises the PET crystal positioning system described in the second aspect.
[0048] In a fourth aspect, the present disclosure provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and used to run on the processor, and when the processor executes the computer program, the PET crystal positioning method of the first aspect is implemented.
[0049] In a fifth aspect, the present disclosure provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the method for positioning the PET crystal of the first aspect is implemented.
[0050] Based on the common sense in the art, the above-mentioned implementation modes can be arbitrarily combined to obtain the preferred embodiments of the present disclosure.
[0051] The positive and progressive effect of the present disclosure is that the present disclosure is based on the image to be processed obtained by scanning the target detection module, and by clustering the pixel points corresponding to the scintillation photons emitted by the PET crystal in the image to be processed, the effective pixel points and clustering clusters corresponding to each PET crystal can be analyzed, and then the position of the PET crystal can be determined. The present disclosure does not need to rely on a large amount of labeled data for training, nor does it need to perform multiple iterative calculations. Moreover, as the number of times the detection module is used increases and time passes, even if the PET crystal gradually ages, the present disclosure can also successfully locate the position of the PET crystal by analyzing the distribution of the effective pixel points corresponding to the scintillation photons emitted by the PET crystal, and analyzing the point density of the preset area centered on the effective pixel point, thereby improving the positioning accuracy, automation and efficiency of the PET crystal. BRIEF DESCRIPTION OF THE DRAWINGS
[0052] Figure 1 A schematic diagram of a process of positioning a PET crystal provided by the present disclosure;
[0053] Figure 2 A schematic diagram of an image scanned by a detection module provided in the present disclosure;
[0054] Figure 3 A schematic diagram of positioning of a PET crystal provided by the present disclosure;
[0055] Figure 4 A schematic diagram of a module of a PET crystal positioning system provided by the present disclosure;
[0056] Figure 5 A schematic diagram of the structure of an electronic device provided by the present invention. DETAILED DESCRIPTION
[0057] The present disclosure is further described below by way of examples, but the present disclosure is not limited to the scope of the examples.
[0058] It should be noted that if there are descriptions involving "first", "second", etc. in the embodiments of the present disclosure, the descriptions of "first", "second", etc. are only for descriptive purposes and cannot be understood as indicating or implying their relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" or "second" may explicitly or implicitly include at least one of the features.
[0059] In addition, the technical solutions between the various implementation methods can be combined with each other, but they must be based on the fact that they can be implemented by ordinary technicians in this field. When the combination of technical solutions is contradictory or cannot be implemented, it should be deemed that such combination of technical solutions does not exist and is not within the scope of protection required by this disclosure.
[0060] The embodiment of the present disclosure provides a method for positioning a PET crystal, which automatically determines the position of the PET crystal included in the detection module by analyzing an image scanned by the detection module.
[0061] As a feasible implementation method, Figure 1 As shown, the positioning method of the PET crystal includes:
[0062] S101, obtaining an image to be processed based on scanning by a target detection module; wherein the target detection module includes a plurality of PET crystals;
[0063] S102, clustering a number of valid pixel points in the image to be processed to obtain a cluster corresponding to each PET crystal; wherein the valid pixel point is a pixel point corresponding to the scintillation photon emitted by the PET crystal;
[0064] S103: Determine the position of the corresponding PET crystal according to the cluster.
[0065] Optionally, gamma rays from a radiation source enter the PET crystal and generate corresponding scintillation photons, which are processed by a photoelectric conversion element to obtain an electrical signal, and then processed by a coincidence circuit to obtain imaging data. The imaging data corresponds to a pixel point.
[0066] In the above embodiment, based on the image to be processed obtained by scanning the target detection module, by clustering the pixel points corresponding to the scintillation photons emitted by the PET crystal in the image to be processed, the effective pixel points and clustering clusters corresponding to each PET crystal can be analyzed, and then the position of the PET crystal can be determined.
[0067] In step S102, the purpose of clustering is to divide the effective pixels into a plurality of clusters to correspond to each PET crystal respectively.
[0068] When clustering valid pixels in the image to be processed, color, brightness, grayscale value, distance between valid pixels, etc. can be selected as features of the valid pixels for clustering.
[0069] In order to make the position of the effective pixel points clearer, the image to be processed can be preprocessed before step S102, which can not only reduce the amount of data that needs to be calculated later and improve the accuracy of the algorithm, but also highlight the pixel points corresponding to the scintillation photons emitted by the PET crystal, that is, the effective pixel points, and distinguish the effective pixel points from the pixel points corresponding to the background.
[0070] As a feasible implementation manner, before step S102, the method further includes: performing binarization processing on the image to be processed.
[0071] Specifically, in the image B to be processed after the binarization process, the pixel values of the valid pixel points p are all greater than 0, and the pixel values of the remaining pixels are all 0. A is the set of valid pixel points in the image B to be processed, so A can be expressed as:
[0072] A={p|p>0,p∈B}.
[0073] Exemplarily, the pixel value of each pixel in the image to be processed is compared with the pixel value threshold. If the pixel value of the pixel does not exceed the pixel value threshold, the pixel is regarded as a valid pixel. If the pixel value of the pixel is greater than the pixel value threshold, the pixel is regarded as a pixel corresponding to the background.
[0074] The pixel value threshold can be set as needed. In a specific embodiment, the pixel value threshold binary_threshold can be calculated according to the following formula:
[0075] binary_threshold=mean(B)+2×std(B);
[0076] Wherein, mean(B) is the mean of the pixel values of all pixels in the image B to be processed, and std(B) is the standard deviation of the pixel values of all pixels in the image B to be processed.
[0077] In the above implementation manner, after the image to be processed is binarized, noise and unnecessary details in the image to be processed can also be reduced, making it easier to distinguish between valid pixels and pixels corresponding to the background in the image to be processed in subsequent processes.
[0078] As a feasible implementation, step S102 includes:
[0079] S1021, for a preset area centered on each valid pixel in the image to be processed, calculate the point density of the preset area; wherein the point density is positively correlated with the number of valid pixels in the preset area;
[0080] S1022, determining a number of central pixel points from a number of valid pixel points according to the point density;
[0081] S1023, determining non-central pixel points that match each central pixel point to form corresponding clusters; wherein the non-central pixel points are valid pixel points.
[0082] In the above implementation, it is equivalent to forming corresponding preset areas with each effective pixel point as the center, calculating the point density of the preset area according to the number of effective pixels in each preset area, and using the point density of each preset area as an evaluation index for selecting the central pixel point to determine a specified number of central pixel points, and then directly determining the non-central pixel points matching each central pixel point to form a corresponding cluster.
[0083] In step S1021, the point density of the preset area is mainly used to characterize the density of the effective pixel points around the effective pixel point at the center of the preset area.
[0084] Exemplarily, the distance between all valid pixels is first calculated, where the distance may be a Euclidean distance, and then a corresponding circular area is formed with each valid pixel as the center and a preset threshold as the radius.
[0085] Take the calculation of the point density D of the first preset area centered at the first valid pixel point p(x1,y1) as an example:
[0086] The distance between other valid pixel points q(x2,y2) and the first valid pixel point p pq , and compared with the preset threshold threshold respectively, other valid pixel points whose distance is less than the preset threshold are considered to be in the first preset area, and the number of other valid pixel points in the first preset area except the first valid pixel point is counted, and the number is used as the point density of the first preset area.
[0087] Specifically:
[0088]
[0089]
[0090] in, is the indicator function, when distance pq When the value is less than the threshold, output 1. pq When it is greater than the threshold, the output is 0. A is the set of valid pixels in the image to be processed. The threshold can be defined as 2% of the maximum value among the distances between all valid pixels.
[0091] It should be understood that the greater the point density of the first preset area, the greater the number of other valid pixels gathered around the first valid pixel. Then in step S1022, the valid pixel at the center of the preset area with a larger point density can be selected as the central pixel.
[0092] As a feasible implementation manner, a valid pixel point at the center of a preset area with a point density greater than a first set value is selected as the central pixel point.
[0093] As another feasible implementation, the valid pixel points in the center of the preset area are sorted from large to small according to the point density, and the valid pixel point ranked before the second set value is selected as the center pixel point, or the valid pixel points in the center of the preset area are sorted from small to large according to the point density, and the valid pixel point ranked after the third set value is selected as the center pixel point.
[0094] In step S1023, each non-central pixel point is matched to the nearest central pixel point to form a corresponding cluster.
[0095] If the distance between a non-central pixel and at least two central pixels is the same, the non-central pixel is usually randomly matched to one of the central pixels.
[0096] However, the present disclosure takes into account that the shape formed by the pixel points corresponding to the scintillation photons emitted by the PET crystal in the image to be processed can be regarded as the aperture formed by the scintillation photons emitted by the PET crystal in the image to be processed. If the distance from the non-center pixel point to the center of the aperture is the same, the larger the aperture radius, the smaller the ratio between the distance from the non-center pixel point to the center of the aperture and the aperture radius. Conversely, the smaller the aperture radius, the larger the ratio between the distance from the non-center pixel point to the center of the aperture and the aperture radius. This ratio can reflect the distance ratio between the non-center pixel point and the center of the aperture and the edge of the aperture. The smaller the ratio, the closer the non-center pixel point is to the center of the aperture, and the larger the ratio, the closer the non-center pixel point is to the edge of the aperture.
[0097] In the aperture formed by the scintillation photons emitted by the PET crystal in the image to be processed, the closer to the center of the aperture, the larger the number of surrounding effective pixels should be.
[0098] As another feasible implementation, if the distances between a non-central pixel point and at least two central pixel points are the same, the non-central pixel point is matched to the central pixel point at the center of a preset area with the highest point density.
[0099] In step S103, as a feasible implementation, the central pixel point of the cluster can be directly used as the position of the corresponding PET crystal. As another feasible implementation, the centroid position of the cluster can also be obtained as the position of the corresponding PET crystal.
[0100] For example, for Figure 2 The image to be processed shown in FIG. 1 is analyzed and positioned according to the above-mentioned PET crystal positioning method, and the position of each PET crystal can be determined as follows: Figure 3 As shown, Figure 3 The center position of each white aperture is the position of the PET crystal obtained by positioning.
[0101] In a specific embodiment, the positioning method of the above PET crystal is specifically as follows:
[0102] S201, obtaining an image to be processed based on scanning by a target detection module;
[0103] S202, performing binarization processing on the image to be processed;
[0104] S203, calculating the distance between effective pixels in the image to be processed, and then obtaining the point density of a preset area centered on each effective pixel according to the distance calculation;
[0105] S204, sorting the preset areas according to point density from large to small, and selecting the valid pixel points in the center of the first K preset areas as the cluster center pixel points;
[0106] S205, matching all remaining non-central pixels with the nearest cluster central pixels to form multiple clusters;
[0107] S206: Determine the position of the corresponding PET crystal according to the cluster.
[0108] Here, K is a positive integer, and the specific value can be determined as needed. For example, if it is known that the target detection module includes 16 PET crystals, K can be set to 16.
[0109] On this basis, a LUT (PET crystal position lookup table) is generated based on the position of the PET crystal, which not only improves the positioning accuracy of the PET crystal, but also improves the automation and efficiency of generating the LUT.
[0110] The PET crystal positioning method provided by the embodiment of the present disclosure does not need to rely on a large amount of labeled data for training, nor does it need to perform multiple iterative calculations. Moreover, as the detection module is used more and more times and as time goes by, even if the PET crystal gradually ages, the PET crystal positioning method provided by the embodiment of the present disclosure can also successfully locate the position of the PET crystal by analyzing the distribution of effective pixel points corresponding to the scintillation photons emitted by the PET crystal, and analyzing the point density of a preset area centered on the effective pixel point, and then automatically generate a LUT, thereby improving the positioning accuracy, automation and efficiency of the PET crystal.
[0111] Based on the same concept, the embodiment of the present disclosure also provides a PET crystal positioning system.
[0112] As a feasible implementation method, the positioning system of the PET crystal is as follows Figure 4As shown, including:
[0113] An image acquisition module 401 is used to acquire an image to be processed based on scanning by a target detection module; wherein the target detection module includes a plurality of PET crystals;
[0114] The image analysis module 402 is used to perform clustering processing on a number of valid pixel points in the image to be processed to obtain a cluster corresponding to each PET crystal; wherein the valid pixel point is the pixel point corresponding to the scintillation photon emitted by the PET crystal;
[0115] The positioning module 403 is used to determine the position of the corresponding PET crystal according to the cluster.
[0116] In the above embodiment, the PET crystal positioning system is based on the image to be processed obtained by scanning the target detection module, and clusters the pixel points corresponding to the scintillation photons emitted by the PET crystal in the image to be processed to analyze the valid pixel points and clustering clusters corresponding to each PET crystal, thereby determining the position of the PET crystal.
[0117] The purpose of clustering the effective pixels by the image analysis module 402 is to divide the effective pixels into a plurality of clusters corresponding to each PET crystal.
[0118] When clustering valid pixels in the image to be processed, color, brightness, grayscale value, distance between valid pixels, etc. can be selected as features of the valid pixels for clustering.
[0119] In order to make the position of effective pixels clearer, the image to be processed can also be preprocessed, which can not only reduce the amount of data that needs to be calculated later and improve the accuracy of the algorithm, but also highlight the pixels corresponding to the flashing photons emitted by the PET crystal, that is, the effective pixels, and distinguish the effective pixels from the pixels corresponding to the background.
[0120] As a feasible implementation, the above positioning system further includes an image preprocessing module, and the image preprocessing module is used to perform binarization processing on the image to be processed.
[0121] Specifically, in the image B to be processed after the binarization process, the pixel values of the valid pixel points p are all greater than 0, and the pixel values of the remaining pixels are all 0. A is the set of valid pixel points in the image B to be processed, so A can be expressed as:
[0122] A={p|p>0,p∈B}.
[0123] Exemplarily, the pixel value of each pixel in the image to be processed is compared with the pixel value threshold. If the pixel value of the pixel does not exceed the pixel value threshold, the pixel is regarded as a valid pixel. If the pixel value of the pixel is greater than the pixel value threshold, the pixel is regarded as a pixel corresponding to the background.
[0124] The pixel value threshold can be set as needed. In a specific embodiment, the pixel value threshold binary_threshold can be calculated according to the following formula:
[0125] binary_threshold=mean(B)+2×std(B);
[0126] Wherein, mean(B) is the mean of the pixel values of all pixels in the image B to be processed, and std(B) is the standard deviation of the pixel values of all pixels in the image B to be processed.
[0127] In the above implementation manner, after the image to be processed is binarized, noise and unnecessary details in the image to be processed can also be reduced, making it easier to distinguish between valid pixels and pixels corresponding to the background in the image to be processed in subsequent processes.
[0128] As a feasible implementation, the image analysis module 402 is specifically used for:
[0129] For a preset area centered on each effective pixel in the image to be processed, the point density of the preset area is calculated; wherein the point density is positively correlated with the number of effective pixels in the preset area;
[0130] According to the point density, a number of central pixel points are determined from a number of valid pixel points;
[0131] Determine the non-central pixel points that match each central pixel point to form a corresponding cluster; wherein the non-central pixel points are valid pixel points.
[0132] In the above embodiment, it is equivalent to forming corresponding preset areas with each effective pixel point as the center. The image analysis module 402 calculates the point density of the preset area according to the number of effective pixels in each preset area, and uses the point density of each preset area as an evaluation index for selecting the central pixel point to determine a specified number of central pixel points, and then directly determines the non-central pixel points matching each central pixel point to form a corresponding cluster.
[0133] The point density of the preset area is mainly used to characterize the density of the effective pixel points around the effective pixel point at the center of the preset area.
[0134] Exemplarily, the image analysis module 402 first calculates the distance between all valid pixels, where the distance may be a Euclidean distance, and then forms a corresponding circular area with each valid pixel as the center and a preset threshold as the radius.
[0135] Take the calculation of the point density D of the first preset area centered at the first valid pixel point p(x1,y1) as an example:
[0136] The distance between other valid pixel points q(x2,y2) and the first valid pixel point pq , and compared with the preset threshold threshold respectively, other valid pixel points whose distance is less than the preset threshold are considered to be in the first preset area, and the number of other valid pixel points in the first preset area except the first valid pixel point is counted, and the number is used as the point density of the first preset area.
[0137] Specifically:
[0138]
[0139]
[0140] in, is the indicator function, when distance pq When the value is less than the threshold, output 1. pq When it is greater than the threshold, the output is 0. A is the set of valid pixels in the image to be processed. The threshold can be defined as 2% of the maximum value among the distances between all valid pixels.
[0141] It should be understood that the greater the point density of the first preset area, the greater the number of other valid pixels gathered around the first valid pixel. Therefore, the image analysis module 402 can select the valid pixel at the center of the preset area with a larger point density as the central pixel.
[0142] As a feasible implementation manner, the image analysis module 402 is used to select a valid pixel point at the center of a preset area with a point density greater than a first set value as the central pixel point.
[0143] As another feasible implementation, the image analysis module 402 is used to sort the valid pixel points in the center of the preset area according to the point density from large to small, and select the valid pixel point sorted before the second set value as the center pixel point, or sort the valid pixel points in the center of the preset area according to the point density from small to large, and select the valid pixel point sorted after the third set value as the center pixel point.
[0144] Finally, the image analysis module 402 matches each non-central pixel point to the nearest central pixel point to form a corresponding cluster.
[0145] If the distance between a non-central pixel and at least two central pixels is the same, the non-central pixel is usually randomly matched to one of the central pixels.
[0146] However, the present disclosure takes into account that the shape formed by the pixel points corresponding to the scintillation photons emitted by the PET crystal in the image to be processed can be regarded as the aperture formed by the scintillation photons emitted by the PET crystal in the image to be processed. If the distance from the non-center pixel point to the center of the aperture is the same, the larger the aperture radius, the smaller the ratio between the distance from the non-center pixel point to the center of the aperture and the aperture radius. Conversely, the smaller the aperture radius, the larger the ratio between the distance from the non-center pixel point to the center of the aperture and the aperture radius. This ratio can reflect the distance ratio between the non-center pixel point and the center of the aperture and the edge of the aperture. The smaller the ratio, the closer the non-center pixel point is to the center of the aperture, and the larger the ratio, the closer the non-center pixel point is to the edge of the aperture.
[0147] In the aperture formed by the scintillation photons emitted by the PET crystal in the image to be processed, the closer to the center of the aperture, the larger the number of surrounding effective pixels should be.
[0148] As another feasible implementation, the image analysis module 402 is used to match the non-central pixel point to the central pixel point at the center of the preset area with the highest point density if the non-central pixel point is at the same distance from at least two central pixel points.
[0149] As for the positioning module 403, as a feasible implementation, the positioning module 403 is used to use the central pixel point of the cluster as the position of the corresponding PET crystal. As another feasible implementation, the positioning module 403 is used to obtain the centroid position of the cluster as the position of the corresponding PET crystal.
[0150] For example, for Figure 2 The image to be processed shown in FIG. 1 is analyzed and positioned according to the positioning system of the PET crystals described above, and the position of each PET crystal can be determined as follows: Figure 3 As shown, Figure 3 The center position of each white aperture is the position of the PET crystal obtained by positioning.
[0151] In a specific embodiment, the positioning system of the PET crystal is specifically used to: first obtain the image to be processed obtained by scanning based on the target detection module, perform binarization processing on the image to be processed, calculate the distance between the effective pixels in the image to be processed, and then calculate the point density of the preset area centered on each effective pixel according to the distance. Then, the preset areas are sorted from large to small according to the point density, and the effective pixel points at the center of the first K preset areas are selected as the cluster center pixel points. For all the remaining non-center pixel points, they are matched with the cluster center pixel points closest to each other to form multiple clusters. Finally, the position of the corresponding PET crystal is determined according to the cluster clusters.
[0152] Here, K is a positive integer, and the specific value can be determined as needed. For example, if it is known that the target detection module includes 16 PET crystals, K can be set to 16.
[0153] On this basis, LUT is generated based on the position of the PET crystal, which not only improves the positioning accuracy of the PET crystal, but also improves the automation and efficiency of generating LUT.
[0154] The PET crystal positioning system provided by the embodiment of the present disclosure does not need to rely on a large amount of labeled data for training, nor does it need to perform multiple iterative calculations. Moreover, as the detection module is used more and more times and as time goes by, even if the PET crystal gradually ages, the PET crystal positioning system provided by the embodiment of the present disclosure can also successfully locate the position of the PET crystal by analyzing the distribution of effective pixel points corresponding to the scintillation photons emitted by the PET crystal, and analyzing the point density of the preset area centered on the effective pixel point, and then automatically generate a LUT, thereby improving the positioning accuracy, automation and efficiency of the PET crystal.
[0155] Figure 5 The structure of one electronic device disclosed in the present invention is shown. The electronic device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, the above-mentioned PET crystal positioning method is implemented. Figure 5 The electronic device 50 shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.
[0156] like Figure 5 As shown, the electronic device 50 may also be in the form of a general-purpose computing device, for example, it may be a server device. The components of the electronic device 50 may include, but are not limited to: at least one processor 51, at least one memory 52, and a bus 53 connecting different system components (including the memory 52 and the processor 51).
[0157] The bus 53 includes a data bus, an address bus, and a control bus.
[0158] The memory 52 may include a volatile memory, such as a random access memory (RAM) 521 and / or a cache memory 522 , and may further include a read-only memory (ROM) 523 .
[0159] The memory 52 may also include a program / utility 525 having a set (at least one) of program modules 524, such program modules 524 including but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment.
[0160] The processor 51 executes various functional applications and data processing by running the computer programs stored in the memory 52, such as the positioning method of the PET crystal disclosed above.
[0161] The electronic device 50 may also communicate with one or more external devices 54 (e.g., keyboards, pointing devices, etc.). Such communication may be performed via an input / output (I / O) interface 55. Furthermore, the model generating device 50 may also communicate with one or more networks (e.g., a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) via a network adapter 56. Figure 5 As shown, the network adapter 56 communicates with other modules of the model-generated device 50 via the bus 53. It should be understood that, although not shown in the figure, other hardware and / or software modules can be used in conjunction with the model-generated device 50, including but not limited to: microcode, device drivers, redundant processors, external disk drive arrays, RAID (disk array) systems, tape drives, and data backup storage systems, etc.
[0162] It should be noted that although several units / modules or sub-units / modules of the electronic device are mentioned in the above detailed description, this division is merely exemplary and not mandatory. In fact, according to the embodiments of the present disclosure, the features and functions of two or more units / modules described above can be embodied in one unit / module. Conversely, the features and functions of one unit / module described above can be further divided into multiple units / modules to be embodied.
[0163] The present disclosure also provides a computer-readable storage medium having a computer program stored thereon, and when the program is executed by a processor, the above-mentioned PET crystal positioning method is implemented.
[0164] The readable storage medium may include but is not limited to: a portable disk, a hard disk, a random access memory, a read-only memory, an erasable programmable read-only memory, an optical storage device, a magnetic storage device or any suitable combination of the above.
[0165] In a possible implementation, the present disclosure may also be implemented in the form of a program product, which includes a program code. When the program product is run on a terminal device, the program code is used to enable the terminal device to execute and implement the above-mentioned PET crystal positioning method.
[0166] Among them, the program code for executing the present disclosure can be written in any combination of one or more programming languages, and the program code can be executed completely on the user device, partially on the user device, as an independent software package, partially on the user device and partially on a remote device, or completely on the remote device.
[0167] Although the specific embodiments of the present disclosure are described above, those skilled in the art should understand that this is only an example, and the protection scope of the present disclosure is defined by the appended claims. Those skilled in the art may make various changes or modifications to these embodiments without departing from the principles and essence of the present disclosure, but these changes and modifications all fall within the protection scope of the present disclosure.
Claims
1. A method for positioning a PET crystal, characterized in that: The positioning method comprises: Acquire an image to be processed based on scanning by a target detection module; wherein the target detection module includes a plurality of the PET crystals; Clustering is performed on a number of valid pixel points in the image to be processed to obtain a cluster corresponding to each of the PET crystals; wherein the valid pixel points are pixel points corresponding to the scintillation photons emitted by the PET crystals; According to the clustering clusters, the positions of the corresponding PET crystals are determined.
2. The positioning method according to claim 1, characterized in that: The step of clustering a number of valid pixels in the image to be processed comprises: For a preset area centered at each of the effective pixels in the image to be processed, the point density of the preset area is calculated; According to the point density, determining a number of central pixel points from a number of the effective pixel points; A non-central pixel point matching each of the central pixel points is determined to form the cluster.
3. The positioning method according to claim 2, characterized in that: The step of determining a plurality of central pixel points from the plurality of valid pixel points comprises: Selecting the effective pixel point at the center of the preset area whose point density is greater than a first set value as the central pixel point; and / or, According to the point density from large to small, the effective pixel points in the center of each preset area are sorted, and the effective pixel point sorted before the second set value is selected as the center pixel point, or according to the point density from small to large, the effective pixel points in the center of each preset area are sorted, and the effective pixel point sorted after the third set value is selected as the center pixel point.
4. The positioning method according to claim 2, characterized in that: The step of determining a non-central pixel point matching each central pixel point comprises: Match the non-central pixel point to the central pixel point that is closest to it.
5. The positioning method according to claim 4, characterized in that: The step of determining non-central pixel points matching each of the central pixel points further comprises: If the distances between the non-central pixel point and at least two of the central pixel points are the same, the non-central pixel point is matched to the central pixel point at the center of the preset area with the largest point density.
6. The positioning method according to any one of claims 1 to 5, characterized in that: The step of determining the position of the corresponding PET crystal comprises: Obtaining the centroid position of the cluster as the corresponding position of the PET crystal; and / or, Before the step of clustering a number of valid pixels in the image to be processed, the method further includes: The image to be processed is binarized.
7. A PET crystal positioning system, characterized in that: The positioning system comprises: An image acquisition module, used to acquire an image to be processed based on scanning by a target detection module; wherein the target detection module includes a plurality of the PET crystals; An image analysis module, used for clustering a number of effective pixel points in the image to be processed to obtain a cluster corresponding to each of the PET crystals; wherein the effective pixel point is a pixel point corresponding to the scintillation photon emitted by the PET crystal; A positioning module is used to determine the position of the corresponding PET crystal according to the cluster.
8. A PET device, characterized in that: The PET device comprises the positioning system for the PET crystal according to claim 7.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and used to run on the processor, characterized in that: When the processor executes the computer program, the method for positioning the PET crystal according to any one of claims 1 to 6 is implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method for positioning a PET crystal as described in any one of claims 1 to 6 is implemented.