Pathological tissue image processing method and device, equipment and storage medium
The two-dimensional pathological image is constructed into three-dimensional data through the pathological tissue image processing method, which solves the problem of two-dimensional parameter limitations in the existing technology and improves the accuracy of diagnosis and understanding of pathological conditions.
Patent Information
- Application Number
- CN202311341685.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2023-02-28
- Filing Date
- 2023-10-16
- Publication Date
- 2024-08-30
AI Technical Summary
Existing pathological sectioning technology can only obtain two-dimensional parameters, which results in the inability to fully reflect the patient's pathological condition, thereby reducing the accuracy of diagnosis.
Through the pathological tissue image processing method, the two-dimensional pathological image data is constructed into three-dimensional data, the section operation data is generated and re-cut, the coordinate data and parameters of the target area are obtained, and the three-dimensional construction and multi-angle stereoscopic parameters of the pathological tissue are realized. of acquisition.
It improves the accuracy of diagnosis, provides more comprehensive pathological tissue information, and enhances the ability to understand and analyze pathological conditions.
Smart Images

Figure CN118570363A
Abstract
Description
[0001] The present invention relates to the technical field of pathological sections, and in particular to a pathological tissue image processing method, device, equipment and storage medium. Background Art
[0002] At present, the existing pathological section technology is to make a tissue wax block through the steps of fixation, dehydration, waxing, embedding, etc., cut into thin slices by a slicer, and then spread and bake the slices. After dewaxing, it is stained with hematoxylin and eosin to make conventional H&E staining, and finally dehydrated, transparent, and sealed. After the above series of histological methods, the final sealing is made into a pathological section. Because the parameters obtained by the existing pathological section technology are limited to the two-dimensional parameters of the section, the patient's pathological condition cannot be fully reflected, which leads to a decrease in the accuracy of diagnosis. Summary of the invention
[0003] The present invention aims to solve at least one of the technical problems existing in the prior art. To this end, the present invention proposes a pathological tissue image processing method, which can construct a three-dimensional pathological tissue through a pathological slice image and obtain volume visual parameters of the pathological tissue at different angles.
[0004] The invention also provides a pathological tissue image processing device.
[0005] The invention also provides a pathological tissue image processing device.
[0006] The present invention also provides a computer-readable storage medium.
[0007] In a first aspect, an embodiment of the present invention provides a pathological tissue image processing method, comprising:
[0008] Reading the pre-input two-dimensional pathological image file to obtain two-dimensional pathological image data;
[0009] Performing three-dimensional construction based on the two-dimensional pathological image data to obtain three-dimensional pathological data;
[0010] Acquire section operation data, and re-cut the three-dimensional pathological data according to the section operation data to obtain re-cut image data; wherein the section operation data is generated according to the parameters of the custom section on the three-dimensional pathological data;
[0011] Acquire target area data, and extract target coordinate data from the recut image data according to the target area data; wherein the target area data is determined according to a customized selected area on the three-dimensional pathological data;
[0012] Parameters of the selected area of the re-cut image data are calculated according to the target coordinate data to obtain target pathological tissue parameters.
[0013] The pathological tissue image processing method of the embodiment of the present invention has at least the following beneficial effects: reading a pre-input two-dimensional pathological image file, obtaining the two-dimensional pathological image data stored in the two-dimensional pathological image file, importing the two-dimensional pathological image data into a three-dimensional construction model based on VTK for three-dimensional construction, and obtaining three-dimensional pathological data, generating section operation data according to the parameters of the customized section on the three-dimensional pathological data, and re-cutting the three-dimensional pathological data into a section image according to the section operation data to obtain re-cut image data, determining target area data according to a selected area customized on the three-dimensional pathological data, and extracting corresponding coordinate data in the area from the re-cut image data according to the target area data to obtain target coordinate data, performing parameter calculation on the selected area of the re-cut image data according to the target coordinate data to obtain target pathological tissue parameters. The two-dimensional pathology image data is obtained by reading the two-dimensional pathology image file, the three-dimensional pathology data is constructed according to the two-dimensional pathology image data, the three-dimensional pathology data is re-cut according to the section operation data to obtain the re-cut image data, the target coordinate data is extracted from the re-cut image data according to the target area data, and the target pathology tissue parameters of the selected area are calculated according to the target coordinate data. The three-dimensional pathology tissue can be constructed through the pathology slice image, and the volume visual parameters of the pathology tissue at different angles can be obtained.
[0014] According to some other embodiments of the pathological tissue image processing method of the present invention, the three-dimensional construction is performed based on the two-dimensional pathological image data to obtain the three-dimensional pathological data, including:
[0015] Performing three-dimensional pathological tissue image processing according to the two-dimensional pathological image data to obtain target three-dimensional parameters;
[0016] Performing data conversion on the two-dimensional pathological image data according to the target three-dimensional parameters to obtain target pathological image data;
[0017] A three-dimensional volume is constructed according to the target pathological image data to obtain the three-dimensional volume pathological data.
[0018] According to some other embodiments of the pathological tissue image processing method of the present invention, before acquiring the section operation data and re-cutting the three-dimensional pathological data according to the section operation data to obtain the re-cut image data, the pathological tissue image processing method further includes:
[0019] Rendering the three-dimensional pathological data step by step to a preset window layer to obtain window layer data;
[0020] Setting target interaction rules according to the window layer data and a preset interaction template;
[0021] The section operation data and the target area data are acquired according to the target interaction rule.
[0022] According to some other embodiments of the pathological tissue image processing method of the present invention, the section operation data includes re-cutting operation data and moving distance data, and the section operation data is obtained, and the three-dimensional pathological data is re-cut according to the section operation data to obtain the re-cut image data, including:
[0023] Acquiring the recutting operation data and the moving distance data;
[0024] Selecting a section on the three-dimensional pathological data according to the re-cutting operation data to obtain a target section;
[0025] The three-dimensional pathological data is recut according to the moving distance data and the target section plane to obtain the recut image data.
[0026] According to some other embodiments of the pathological tissue image processing method of the present invention, the target pathological tissue parameter includes volume data, and the parameter calculation of the selected area of the re-cut image data according to the target coordinate data to obtain the target pathological tissue parameter includes:
[0027] Acquire the region coordinates corresponding to the remaining sections according to the target coordinate data and the preset image recognition segmentation rule to obtain the remaining coordinate data;
[0028] Performing area calculation according to the target coordinate data and the remaining coordinate data to obtain area data;
[0029] The area data is discretely integrated to obtain the volume data.
[0030] According to some other embodiments of the pathological tissue image processing method of the present invention, performing area calculation according to the target coordinate data and the remaining coordinate data to obtain area data includes:
[0031] Performing area marking according to the target coordinate data and the remaining coordinate data to obtain a curve area;
[0032] Performing line smoothing processing on the curve region according to a preset interpolation value to obtain a smooth curve region;
[0033] The area of the smooth curve region is calculated to obtain the area data.
[0034] According to some other embodiments of the pathological tissue image processing method of the present invention, the target pathological tissue parameter also includes length data, and the parameter calculation of the selected area of the re-cut image data according to the target coordinate data to obtain the target pathological tissue parameter also includes:
[0035] Acquire selected first coordinate data and second coordinate data from the target coordinate data and the remaining coordinate data;
[0036] The length data is obtained by performing length calculation according to the first coordinate data and the second coordinate data.
[0037] In a second aspect, an embodiment of the present invention provides a pathological tissue image processing device, comprising:
[0038] A data reading module is used to read the pre-input two-dimensional pathological image file to obtain two-dimensional pathological image data;
[0039] A three-dimensional construction module, used for performing three-dimensional construction according to the two-dimensional pathological image data to obtain three-dimensional pathological data;
[0040] An image re-cutting module, used for acquiring section operation data, and re-cutting the three-dimensional pathological data according to the section operation data to obtain re-cut image data; wherein the section operation data is generated according to the parameters of the custom section on the three-dimensional pathological data;
[0041] A coordinate acquisition module, used to acquire target area data, and extract target coordinate data from the recut image data according to the target area data; wherein the target area data is determined according to a customized selected area on the three-dimensional pathological data;
[0042] A parameter calculation module is used to perform parameter calculation on a selected area of the re-cut image data according to the target coordinate data to obtain target pathological tissue parameters.
[0043] The pathological tissue image processing device of the embodiment of the present invention has at least the following beneficial effects: the data reading module reads a pre-input two-dimensional pathological image file to obtain the two-dimensional pathological image data stored in the two-dimensional pathological image file; the three-dimensional construction module imports the two-dimensional pathological image data into a three-dimensional construction model based on VTK for three-dimensional construction to obtain three-dimensional volume pathological data; the image re-cutting module generates section operation data according to the parameters of the custom section on the three-dimensional volume pathological data, and re-cuts the three-dimensional volume pathological data into a section image according to the section operation data to obtain re-cut image data; the coordinate acquisition module determines the target area data according to the selected area customized on the three-dimensional volume pathological data, and extracts the corresponding coordinate data in the area from the re-cut image data according to the target area data to obtain the target coordinate data; the parameter calculation module performs parameter calculation on the selected area of the re-cut image data according to the target coordinate data to obtain the target pathological tissue parameters. The two-dimensional pathology image data is obtained by reading the two-dimensional pathology image file, the three-dimensional pathology data is constructed according to the two-dimensional pathology image data, the three-dimensional pathology data is re-cut according to the section operation data to obtain the re-cut image data, the target coordinate data is extracted from the re-cut image data according to the target area data, and the target pathology tissue parameters of the selected area are calculated according to the target coordinate data. The three-dimensional pathology tissue can be constructed through the pathology slice image, and the volume visual parameters of the pathology tissue at different angles can be obtained.
[0044] In a third aspect, an embodiment of the present invention provides a pathological tissue image processing device, comprising:
[0045] at least one processor, and
[0046] a memory communicatively connected to the at least one processor; wherein,
[0047] The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can perform the pathological tissue image processing method as described in the first aspect.
[0048] In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute the pathological tissue image processing method as described in the first aspect.
[0049] Other features and advantages of the present application will be described in the following description, and partly become apparent from the description, or understood by practicing the present application. The purpose and other advantages of the present application can be realized and obtained through the structures particularly pointed out in the description and the drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0050] Figure 1It is a schematic flow chart of a specific embodiment of the pathological tissue image processing method in an embodiment of the present invention;
[0051] Figure 2 yes Figure 1 A schematic flow chart of a specific embodiment of step S102;
[0052] Figure 3 is a schematic flow chart of another specific embodiment of the pathological tissue image processing method in an embodiment of the present invention;
[0053] Figure 4 yes Figure 1 A schematic flow chart of a specific embodiment of step S103;
[0054] Figure 5 yes Figure 1 A schematic flow chart of a specific embodiment of step S105;
[0055] Figure 6 yes Figure 5 A schematic flow chart of a specific embodiment of step S502;
[0056] Figure 7 yes Figure 1 Another specific embodiment of step S105 is shown in the flowchart;
[0057] Figure 8 It is a module block diagram of a specific embodiment of the pathological tissue image processing device in an embodiment of the present invention;
[0058] Fig. 9 It is a schematic diagram of a specific embodiment of three-dimensional construction in an embodiment of the present invention;
[0059] Fig.10 is a schematic diagram of a specific embodiment of a smooth curve area in an embodiment of the present invention;
[0060] Fig.11 It is a schematic diagram of a specific embodiment of the smooth curve area of the cut surface in an embodiment of the present invention.
[0061] Description of reference numerals:
[0062] Data reading module 801, three-dimensional construction module 802, image re-cutting module 803, coordinate acquisition module 804, parameter calculation module 805. DETAILED DESCRIPTION
[0063] The following will be combined with the embodiments to clearly and completely describe the concept of the present invention and the technical effects produced, so as to fully understand the purpose, characteristics and effects of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of them. Based on the embodiments of the present invention, other embodiments obtained by those skilled in the art without creative work are all within the scope of protection of the present invention.
[0064] In the description of the present invention, if it involves a description of orientation, for example, the orientation or position relationship indicated by "upper", "lower", "front", "back", "left", "right", etc. is based on the orientation or position relationship shown in the drawings, which is only for the convenience of describing the present invention and simplifying the description, and does not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as a limitation of the present invention. If a feature is referred to as being "set", "fixed", "connected", or "installed" on another feature, it can be directly set, fixed, or connected to the other feature, or it can be indirectly set, fixed, connected, or installed on the other feature.
[0065] In the description of the embodiments of the present invention, if "several" is involved, it means more than one, if "multiple" is involved, it means more than two, if "greater than", "less than" or "exceed" is involved, it should be understood as not including the number itself, if "above", "below" or "within" is involved, it should be understood as including the number itself. If "first" or "second" is involved, it should be understood as being used to distinguish technical features, and cannot be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features or implicitly indicating the order of the indicated technical features.
[0066] Traditional pathology obtains tissue samples from patients, processes them, stains them, seals them with wax, slices them, and prepares slides, and then observes them under a microscope to obtain single two-dimensional cross-sectional data. Since the samples have been sliced, there is loss of samples. If the section is not suitable, the remaining tissue samples can only be re-sliced. In the re-slicing process, wax sealing, slicing, and slide preparation are required, which is time-consuming and labor-intensive. In addition, due to the loss of samples, the ideal section may not be obtained.
[0067] At present, the existing pathological section technology is to make a tissue wax block through the steps of fixation, dehydration, waxing, embedding, etc., cut into thin slices by a slicer, and then spread and bake the slices. After dewaxing, it is stained with hematoxylin and eosin to make conventional H&E staining, and finally dehydrated, transparent, and sealed. After the above series of histological methods, the final sealing is made into a pathological section. Because the parameters obtained by the existing pathological section technology are limited to the two-dimensional parameters of the section, the patient's pathological condition cannot be fully reflected, which leads to a decrease in the accuracy of diagnosis.
[0068] The present invention aims to solve at least one of the technical problems existing in the prior art. To this end, the present invention proposes a pathological tissue image processing method, which can construct a three-dimensional pathological tissue through a pathological slice image and obtain volume visual parameters of the pathological tissue at different angles.
[0069] Please refer to Figure 1 , Figure 1 The schematic diagram of the process of the pathological tissue image processing method in the embodiment of the present invention is shown. In some embodiments, the pathological tissue image processing method specifically includes but is not limited to steps S101 to S105.
[0070] Step S101, reading the pre-input two-dimensional pathological image file to obtain two-dimensional pathological image data;
[0071] Step S102, performing three-dimensional construction based on the two-dimensional pathological image data to obtain three-dimensional pathological data;
[0072] Step S103, obtaining section operation data, and re-cutting the three-dimensional pathological data according to the section operation data to obtain re-cut image data; wherein the section operation data is generated according to the parameters of the custom section on the three-dimensional pathological data;
[0073] Step S104, acquiring target region data, and extracting target coordinate data from the recut image data according to the target region data; wherein the target region data is determined according to a customized selected region on the three-dimensional pathological data;
[0074] Step S105 , performing parameter calculation on the selected area of the re-cut image data according to the target coordinate data to obtain target pathological tissue parameters.
[0075] In steps S101 to S105 shown in this embodiment, a pre-input two-dimensional pathological image file is read to obtain the two-dimensional pathological image data stored in the two-dimensional pathological image file, and the two-dimensional pathological image data is imported into the three-dimensional construction model based on VTK for three-dimensional construction to obtain three-dimensional pathological data. The section operation data is generated according to the parameters of the custom section on the three-dimensional pathological data, and the three-dimensional pathological data is recut into a section image according to the section operation data to obtain the recut image data. The target area data is determined according to the selected area customized on the three-dimensional pathological data, and the corresponding coordinate data in the area is extracted from the recut image data according to the target area data to obtain the target coordinate data, and the parameters of the selected area of the recut image data are calculated according to the target coordinate data to obtain the target pathological tissue parameters. The two-dimensional pathology image data is obtained by reading the two-dimensional pathology image file, the three-dimensional pathology data is constructed according to the two-dimensional pathology image data, the three-dimensional pathology data is re-cut according to the section operation data to obtain the re-cut image data, the target coordinate data is extracted from the re-cut image data according to the target area data, and the target pathology tissue parameters of the selected area are calculated according to the target coordinate data. The three-dimensional pathology tissue can be constructed through the pathology slice image, and the volume visual parameters of the pathology tissue at different angles can be obtained.
[0076] In step S101, after the tissue sample is made transparent, a light sheet illumination scan is performed to obtain a two-dimensional pathological image, and the two-dimensional pathological image is uploaded to the device to convert the two-dimensional pathological image into a two-dimensional pathological image file. The two-dimensional pathological image file is input into the VTK-based algorithm model, and the method for reading the file is screened in the corresponding visualization tool library. The two-dimensional pathological image file is read by the file reading method to obtain the two-dimensional pathological image data. Among them, the method for obtaining the two-dimensional pathological image can also be: continuously slicing the sample of the pathological tissue, placing the slice under a traditional microscope, and then photographing the image displayed under the microscope to obtain the two-dimensional pathological image.
[0077] It should be noted that the pathological tissue image processing method applied in the present invention is based on three-dimensional optical imaging technology, and is applied to the post-processing and visualization part of three-dimensional optical imaging technology, and is used to perform three-dimensional reconstruction of the pathological image slice sequence produced by the depth scanning microscope, and perform visual interaction and measurement. By acquiring a two-dimensional cross-sectional data sequence to construct a three-dimensional pathological model, the obtained three-dimensional data has a large free observation space, and the three-dimensional pathological model can be re-cut at any angle, and stereological parameters (length, area, volume) and other measurements can be performed, so that pathologists can re-cut the pathological tissue data obtained by scanning at any angle and measure parameters, thereby improving the accuracy of clinical diagnosis.
[0078] Please refer to Figure 2 , Figure 2The flowchart of the pathological tissue image processing method in the embodiment of the present invention is shown. In some embodiments, three-dimensional construction is performed based on two-dimensional pathological image data to obtain three-dimensional pathological data, which specifically includes but is not limited to steps S201 to S203.
[0079] Step S201, performing three-dimensional pathological tissue image processing according to the two-dimensional pathological image data to obtain target three-dimensional parameters;
[0080] Step S202, performing data conversion on the two-dimensional pathological image data according to the target three-dimensional parameters to obtain target pathological image data;
[0081] Step S203: construct a three-dimensional volume according to the target pathological image data to obtain three-dimensional pathological data.
[0082] In steps S201 to S203 shown in this embodiment, data for pathological tissue image processing is screened from the two-dimensional pathological image data, and parameters of the three-dimensional body are set according to the data to obtain target three-dimensional parameters. The basic data of the model in the two-dimensional pathological image data is screened, and the basic data is converted according to the target three-dimensional parameters to convert the two-dimensional basic data into target pathological image data for three-dimensional body construction, and the structure of the three-dimensional body is built according to the target pathological image data to obtain three-dimensional body pathological data. The target three-dimensional parameters are set by reading the two-dimensional pathological image data, and the corresponding data in the two-dimensional pathological image data is converted into the target pathological image data according to the target three-dimensional parameters. The three-dimensional body is constructed according to the target pathological image data to obtain three-dimensional body pathological data, and the three-dimensional body structure can be constructed by the two-dimensional pathological image data.
[0083] In step S201 of some embodiments, the data used for pathological tissue image processing includes: the size of the two-dimensional pathological image, the resolution of the two-dimensional pathological image, the ratio information of the two-dimensional pathological image, and the interval between the two-dimensional pathological image data, etc. Among them, the ratio adjustment of the three-dimensional structure can be achieved by the method of pathological tissue image processing.
[0084] Please refer to Figure 3 , Figure 3 The schematic flow chart of the pathological tissue image processing method in the embodiment of the present invention is shown. In some embodiments, before obtaining the section operation data and re-cutting the three-dimensional pathological data according to the section operation data to obtain the re-cut image data, the pathological tissue image processing method further includes but is not limited to steps S301 to S303.
[0085] Step S301, gradually rendering the three-dimensional pathological data to a preset window layer to obtain window layer data;
[0086] Step S302, setting target interaction rules according to the window layer data and the preset interaction template;
[0087] Step S303, obtaining slice operation data and target area data according to the target interaction rule.
[0088] In steps S301 to S303 shown in this embodiment, a scene is constructed in a preset window layer according to the three-dimensional pathology data, so as to gradually render the three-dimensional pathology data to the window layer to obtain the window layer data, input the window layer data into the preset interaction template, and call the corresponding interaction function according to the window layer data to set the interaction rules of the interaction template to obtain the target interaction rules, implement the interaction with the user according to the target interaction rules, and obtain the section operation data and target area data in the interaction process. By gradually rendering the three-dimensional pathology data to obtain the window layer data, setting the target interaction rules according to the window layer data, and interacting according to the target interaction rules to obtain the section operation data and the target area data, it is possible to implement the interaction with the user based on the three-dimensional pathology data and obtain the data generated by the interaction.
[0089] Please refer to Figure 4 , Figure 4 The schematic flow chart of the pathological tissue image processing method in an embodiment of the present invention is shown. In some embodiments, the section operation data includes re-cutting operation data and moving distance data, the section operation data is obtained, and the three-dimensional pathological data is re-cut according to the section operation data to obtain the re-cut image data, specifically including but not limited to steps S401 to S403.
[0090] Step S401, obtaining re-cutting operation data and moving distance data;
[0091] Step S402, selecting a section on the three-dimensional pathological data according to the re-cutting operation data to obtain a target section;
[0092] Step S403, re-cutting the three-dimensional pathological data according to the moving distance data and the target section plane to obtain re-cut image data.
[0093] In steps S401 to S403 shown in this embodiment, the pre-obtained re-cutting operation data and moving distance data are obtained, and the section selected by the user is selected on the three-dimensional pathology data according to the re-cutting operation data to obtain the target section, and the re-cutting process is performed on the three-dimensional pathology data according to the moving distance data to cut off several target sections selected by the user to obtain re-cut image data. By obtaining the interactive re-cutting operation data and moving distance data, selecting the target section according to the re-cutting operation data, and re-cutting on the three-dimensional pathology data according to the moving distance data to obtain the re-cut image data, it is possible to perform corresponding re-cutting according to the interactive operation of the user and obtain image data.
[0094] It should be noted that the present invention provides a visual interactive tool, where users can see the angle of the cross section and the cutting effect with their naked eyes, and the data coordinates are fixed and known, and are fixed and unchanged after the three-dimensional data is imported. Among them, the main function of re-cutting is to find the optimal section for diagnosis.
[0095] In some embodiments, reference Fig. 9 , Fig. 9 The flowchart of the three-dimensional construction in the embodiment of the present invention is shown. The algorithm model based on VTK includes: vtkImageReader class, vtkVolumeMapper class, vtkImplicitPlaneWidget class, vtkPlane class, vtkVolume class, vtkRender class, vtkRenderWindow class and vtkRenderWindowInteractor class. Among them, the rendering pipeline of the VTK algorithm model includes two parts: the visualization pipeline and the rendering engine. The visualization pipeline is responsible for reading and generating data, and the rendering engine renders the obtained three-dimensional pathological data into objects in the window.
[0096] The vtkImageReader class provides a method for reading two-dimensional pathology image data from a two-dimensional pathology image file and can convert the input two-dimensional pathology image data; the vtkVolumeMapper class is used to store data information in three-dimensional pathology data in a matrix form, wherein the vtkVolumeMapper class includes DataSpacing, DataExtent, and ClippingPlane attributes, the DataSpacing attribute is used to set the interval of three-dimensional pathology data, the DataExtent attribute is used to set the ratio of three-dimensional pathology data, and the ClippingPlane attribute is used to add sections to three-dimensional pathology data; the vtkImplicitPlaneWidget class is used to extract the control method of any section; the vtkPlane class is used to store section information.
[0097] The vtkVolume class is used to display images; the vtkRenderWindow class is responsible for managing window creation and rendering. The vtkRenderWindow class contains vtkRender objects, which are used for collection and rendering parameters; vtkRender is responsible for managing the rendering process of the scene. A vtkRender object that makes up a scene includes vtkActor properties, camera properties (VTKCamera), and lighting properties (vtkLight). A vtkRenderwindow can contain multiple vtkRender objects.
[0098] The two-dimensional pathological image data is read in using the vtkImageReader class, the target three-dimensional parameters are set according to the spacing and scale information provided by the two-dimensional pathological image data, the read two-dimensional pathological image data is converted into vtkVolumeMapper data to obtain the target pathological image data, and a three-dimensional volume structure is constructed according to the target pathological image data to obtain the three-dimensional volume pathological data; the target pathological image data is gradually rendered to the window layer vtkRenderWindow, and the corresponding target interaction rules are screened out in the pre-written interaction function, and the corresponding interaction method vtkRenderWindowInteractor is obtained by setting the target interaction rules. According to the interaction method vtkRenderWindowInteractor, the vtkImplicitPlaneWidget control is called to obtain the user-selected recut operation data and moving distance data. The recut operation data includes the origin, normal vector, etc. The obtained recut operation data is gradually set as the ClippingPlane attribute of vtkVolumeMapper, and the final section is calculated according to the moving distance data, and the recut image data is obtained through recut processing.
[0099] It should be noted that corresponding interactive functions are written in the back end of the VTK-based 3D construction model, which mainly use the left and right mouse buttons and some keyboard shortcuts to drag, scale the 3D body and select points in the 3D body.
[0100] “Step-by-step setting” means completing the pathological tissue image processing through a series of function instructions. Due to the characteristics of the visualization tool library, the pathological tissue image processing cannot be set up through a single function instruction.
[0101] In step S104 of some embodiments, the area selected by the user, i.e., target area data, is obtained based on the user's mouse interaction, and the coordinates of the target point selected by the user or a set of points in the target area are acquired from the re-cut image data based on the target area data to obtain the target coordinate data.
[0102] Please refer to Figure 5 , Figure 5 The schematic diagram of the process of the pathological tissue image processing method in the embodiment of the present invention is shown. In some embodiments, the target pathological tissue parameter includes volume data, and the parameter calculation of the selected area of the recut image data is performed according to the target coordinate data to obtain the target pathological tissue parameter, including but not limited to steps S501 to S503.
[0103] Step S501, obtaining the region coordinates corresponding to the remaining sections according to the target coordinate data and the preset image recognition segmentation rule to obtain the remaining coordinate data;
[0104] Step S502, performing area calculation according to the target coordinate data and the remaining coordinate data to obtain area data;
[0105] Step S503: discretely integrate the area data to obtain volume data.
[0106] In steps S501 to S503 shown in this embodiment, according to the target coordinate data and the preset image recognition segmentation rules, the pathological region is automatically searched on the remaining sections, and the corresponding coordinates of the pathological region are obtained to obtain the remaining coordinate data, the area of the pathological region of the selected section is calculated according to the target coordinate data, the area of the pathological region of the remaining sections is calculated according to the remaining coordinate data, the area of the pathological region of the selected section and the area of the pathological region of the remaining sections are summarized to obtain area data, and the area data is discretely integrated to obtain volume data. The remaining sections are outlined by the target coordinate data of the selected section, and the remaining coordinate data are obtained, the area data of the pathological region of each section is calculated according to the target coordinate data and the remaining coordinate data, and the volume data is obtained according to the discrete integration of the area data, and the length of the corresponding area can be obtained to calculate the area parameter and volume parameter of the pathological region.
[0107] In step S501 of some embodiments, the preset image recognition and segmentation rules include but are not limited to traditional image segmentation algorithms (threshold, region growing) and deep learning image recognition and segmentation algorithms (Res-Net, U-Net).
[0108] Please refer to Figure 6 , Figure 6 The schematic diagram of the process of the pathological tissue image processing method in the embodiment of the present invention is shown. In some embodiments, the area is calculated according to the target coordinate data and the remaining coordinate data to obtain the area data, which specifically includes but is not limited to steps S601 to S603.
[0109] Step S601, performing region marking according to target coordinate data and remaining coordinate data to obtain a curve region;
[0110] Step S602, performing line smoothing processing on the curve region according to a preset interpolation value to obtain a smooth curve region;
[0111] Step S603, calculating the area of the smooth curve region to obtain area data.
[0112] In steps S601 to S603 shown in the present embodiment, the coordinates of the corresponding points are connected by lines according to the target coordinate data to mark the pathological area of the selected section, and the coordinates of the corresponding points are connected according to the target coordinate data to mark the pathological areas of the remaining sections, and the pathological areas of the selected section and the pathological areas of the remaining sections are summarized to obtain a curve area. Coordinate interpolation is performed according to a preset interpolation value, and the interpolated coordinates are connected to the curve area to make the lines of the curve area smooth to obtain a smooth curve area, and the area of the smooth curve area is calculated to obtain area data. The curve area is marked by the target coordinate data and the remaining coordinate data, and the lines of the curve area are smoothed according to the interpolation value to obtain a smooth curve area, and the area data of the smooth curve area is calculated. The corresponding pathological area can be marked according to the coordinate data, and the area parameters of the pathological area can be calculated.
[0113] It should be noted that interpolation means inserting values, and the calculation methods of the inserted coordinate points include but are not limited to mean value, Bezier curve, etc.
[0114] In some embodiments, reference Fig.10 , Fig.10 A schematic diagram of a smooth curve area in an embodiment of the present invention is shown. A series of contour point sets are picked up interactively by the user's mouse, and a smooth curve is formed by interpolation, and the area enclosed by the smooth curve is calculated. If the volume is calculated, a closed figure enclosed by a smooth curve is generated on each section and the area of the closed figure is calculated, and then the area of each region is discretely integrated according to the spacing between the sections, and finally the volume is calculated.
[0115] In some embodiments, reference Fig.11 , Fig.11 A schematic diagram of the smooth curve area of the section in the embodiment of the present invention is shown. A three-dimensional body is composed of a series of two-dimensional sections, like a stack of paper. After the user outlines the corresponding area on a certain section, the algorithm automatically finds the relevant area outlined by the user on the remaining sections. After the area of each section is obtained, the area set can be obtained, and these sections are parallel to each other, and then the volume can be calculated by discrete integration.
[0116] The area solution formula is as follows (1):
[0117]
[0118] Please refer to Figure 7 , Figure 7 The flowchart of the pathological tissue image processing method in the embodiment of the present invention is shown. In some embodiments, the target pathological tissue parameter also includes length data, and the parameter calculation of the selected area of the recut image data is performed according to the target coordinate data to obtain the target pathological tissue parameter, which also includes but is not limited to steps S701 to S702.
[0119] Step S701, obtaining selected first coordinate data and second coordinate data from the target coordinate data and the remaining coordinate data;
[0120] Step S702, performing length calculation according to the first coordinate data and the second coordinate data to obtain length data.
[0121] In steps S701 to S702 shown in this embodiment, the first coordinate point and the second coordinate point selected during the user interaction are obtained from the target coordinate data and the remaining coordinate data, and the first coordinate data and the second coordinate data in the length direction are obtained. After the difference between the first coordinate data and the second coordinate data is calculated, the absolute value of the difference is calculated to obtain the length data. By obtaining the first coordinate data and the second coordinate data from the target coordinate data and the remaining coordinate data, and calculating the length data according to the first coordinate data and the second coordinate data, the corresponding length parameter can be calculated according to the coordinate data.
[0122] It should be noted that if the first coordinate point and the second coordinate point are both in the selected section, the first coordinate data of the first coordinate point and the second coordinate data of the second coordinate point are obtained in the target coordinate data; if the first coordinate point and the second coordinate point are both in the remaining sections, the first coordinate data of the first coordinate point and the second coordinate data of the second coordinate point are obtained in the remaining coordinate data; if one of the first coordinate point and the second coordinate point is located in the selected section and the other is located in the remaining section, the first coordinate data of the first coordinate point and the second coordinate data of the second coordinate point are obtained in the target coordinate data and the remaining coordinate data respectively.
[0123] In some embodiments, the target pathological tissue parameter also includes depth data, and the first coordinate point and the second coordinate point selected during the user interaction are obtained from the target coordinate data and the remaining coordinate data, and the first coordinate data and the second coordinate data in the depth direction are obtained. After performing a difference calculation based on the first coordinate data and the second coordinate data, the absolute value of the difference is calculated to obtain the depth data. By obtaining the first coordinate data and the second coordinate data from the target coordinate data and the remaining coordinate data, and calculating the depth data based on the first coordinate data and the second coordinate data, the corresponding depth parameter can be calculated based on the coordinate data.
[0124] In some embodiments, the target pathological tissue parameter also includes percentage data, which is obtained by performing a proportional calculation based on the length data and the depth data.
[0125] In addition, the present application also discloses a pathological tissue image processing device, please refer to Figure 8 , Figure 8 The present invention discloses a block diagram of a pathological tissue image processing device according to an embodiment of the present invention. The pathological tissue image processing device can implement the pathological tissue image processing method described above, and the pathological tissue image processing device includes: a data reading module 801, a three-dimensional construction module 802, an image re-cutting module 803, a coordinate acquisition module 804, and a parameter calculation module 805. The data reading module 801, the three-dimensional construction module 802, the image re-cutting module 803, the coordinate acquisition module 804, and the parameter calculation module 805 are all communication-connected.
[0126] The data reading module 801 reads the pre-input two-dimensional pathology image file to obtain two-dimensional pathology image data. The three-dimensional construction module 802 performs three-dimensional construction based on the two-dimensional pathology image data to obtain three-dimensional pathology data. The image re-cutting module 803 obtains the section operation data, and re-cuts the three-dimensional pathology data according to the section operation data to obtain re-cut image data; wherein the section operation data is generated according to the parameters of the custom section on the three-dimensional pathology data. The coordinate acquisition module 804 obtains the target area data, and extracts the target coordinate data from the re-cut image data according to the target area data; wherein the target area data is determined according to the custom selected area on the three-dimensional pathology data. The parameter calculation module 805 performs parameter calculation on the selected area of the re-cut image data according to the target coordinate data to obtain the target pathological tissue parameters.
[0127] The data reading module 801 reads the pre-input two-dimensional pathology image file and obtains the two-dimensional pathology image data stored in the two-dimensional pathology image file. The three-dimensional construction module 802 imports the two-dimensional pathology image data into the three-dimensional construction model based on VTK for three-dimensional construction to obtain three-dimensional volume pathology data. The image re-cutting module 803 generates section operation data according to the parameters of the custom section on the three-dimensional volume pathology data, and re-cuts the three-dimensional volume pathology data into a section image according to the section operation data to obtain re-cut image data. The coordinate acquisition module 804 determines the target area data according to the selected area customized on the three-dimensional volume pathology data, and extracts the corresponding coordinate data in the area from the re-cut image data according to the target area data to obtain the target coordinate data. The parameter calculation module 805 performs parameter calculation on the selected area of the re-cut image data according to the target coordinate data to obtain the target pathological tissue parameters. The two-dimensional pathology image data is obtained by reading the two-dimensional pathology image file, the three-dimensional pathology data is constructed according to the two-dimensional pathology image data, the three-dimensional pathology data is re-cut according to the section operation data to obtain the re-cut image data, the target coordinate data is extracted from the re-cut image data according to the target area data, and the target pathology tissue parameters of the selected area are calculated according to the target coordinate data. The three-dimensional pathology tissue can be constructed through the pathology slice image, and the volume visual parameters of the pathology tissue at different angles can be obtained.
[0128] The operation process of the pathological tissue image processing device of this embodiment is specifically described as above. Figure 1 , Figure 2 , Figure 3 , Figure 4 , Figure 5 , Figure 6 and Figure 7 The pathological tissue image processing method steps S101 to S105, steps S201 to S203, steps S301 to S303, steps S401 to S403, steps S501 to S503, steps S601 to S603 and steps S701 and S702 are not repeated here.
[0129] Another embodiment of the present invention discloses a pathological tissue image processing device, comprising: at least one processor, and a memory connected to the at least one processor in communication; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the following steps: Figure 1 The control method steps S101 to S105, Figure 2 The control method steps S201 to S203, Figure 3 The control method steps S301 to S303, Figure 4 The control method steps S401 to S403, Figure 5The control method steps S501 to S503, Figure 6 The control method steps S601 to S603 and Figure 7 The pathological tissue image processing method of step S701 and step S702 in the control method.
[0130] Another embodiment of the present invention discloses a computer-readable storage medium, the storage medium comprising: the storage medium stores computer-executable instructions, the computer-executable instructions are used to enable a computer to execute Figure 1 The control method steps S101 to S105, Figure 2 The control method steps S201 to S203, Figure 3 The control method steps S301 to S303, Figure 4 The control method steps S401 to S403, Figure 5 The control method steps S501 to S503, Figure 6 The control method steps S601 to S603 and Figure 7 The pathological tissue image processing method of step S701 and step S702 in the control method.
[0131] 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.
[0132] It will be appreciated by those skilled in the art that all or some of the steps and systems in the disclosed method above may be implemented as software, firmware, hardware and appropriate combinations thereof. Some physical components or all physical components may be implemented as software executed by a processor, such as a central processing unit, a digital signal processor or a microprocessor, or may be implemented as hardware, or may be implemented as an integrated circuit, such as an application specific integrated circuit. Such software may be distributed on a computer-readable medium, which may include a computer storage medium (or a non-transitory medium) and a communication medium (or a temporary medium). As known to those skilled in the art, the term computer storage medium includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storing information (such as computer-readable instructions, data structures, program modules or other data). Computer storage media include, but are not limited to, RAM, ROM, EEPROM, flash memory or other memory technologies, CD-ROM, digital versatile disks (DVD) or other optical disk storage, magnetic cassettes, magnetic tapes, disk storage or other magnetic storage devices, or any other medium that may be used to store desired information and may be accessed by a computer. Furthermore, it is well known to those skilled in the art that communication media typically embodies computer readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism, and may include any information delivery media.
[0133] The embodiments of the present invention are described in detail above in conjunction with the accompanying drawings, but the present invention is not limited to the above embodiments. Various changes can be made within the knowledge of ordinary technicians in the relevant technical field without departing from the purpose of the present invention. In addition, the embodiments of the present invention and the features in the embodiments can be combined with each other without conflict.
Claims
1. A pathological tissue image processing method, characterized in that: include: Reading the pre-input two-dimensional pathological image file to obtain two-dimensional pathological image data; Performing three-dimensional construction based on the two-dimensional pathological image data to obtain three-dimensional pathological data; Acquire section operation data, and re-cut the three-dimensional pathological data according to the section operation data to obtain re-cut image data; wherein the section operation data is generated according to the parameters of the custom section on the three-dimensional pathological data; Acquire target area data, and extract target coordinate data from the recut image data according to the target area data; wherein the target area data is determined according to a customized selected area on the three-dimensional pathological data; Parameters of the selected area of the re-cut image data are calculated according to the target coordinate data to obtain target pathological tissue parameters.
2. The pathological tissue image processing method according to claim 1, characterized in that: The three-dimensional construction is performed based on the two-dimensional pathological image data to obtain three-dimensional pathological data, including: Performing three-dimensional pathological tissue image processing according to the two-dimensional pathological image data to obtain target three-dimensional parameters; Performing data conversion on the two-dimensional pathological image data according to the target three-dimensional parameters to obtain target pathological image data; A three-dimensional volume is constructed according to the target pathological image data to obtain the three-dimensional volume pathological data.
3. The pathological tissue image processing method according to claim 1, characterized in that: Before acquiring the section operation data and re-cutting the three-dimensional pathological data according to the section operation data to obtain the re-cut image data, the pathological tissue image processing method further includes: Rendering the three-dimensional pathological data step by step to a preset window layer to obtain window layer data; Setting target interaction rules according to the window layer data and a preset interaction template; The section operation data and the target area data are acquired according to the target interaction rule.
4. The pathological tissue image processing method according to claim 2, characterized in that: The section operation data includes re-cutting operation data and moving distance data. The section operation data is acquired, and the three-dimensional pathological data is re-cut according to the section operation data to obtain re-cut image data, including: Acquiring the recutting operation data and the moving distance data; Selecting a section on the three-dimensional pathological data according to the re-cutting operation data to obtain a target section; The three-dimensional pathological data is recut according to the moving distance data and the target section plane to obtain the recut image data.
5. The pathological tissue image processing method according to claim 1, characterized in that: The target pathological tissue parameter includes volume data, and the parameter calculation of the selected area of the re-cut image data according to the target coordinate data to obtain the target pathological tissue parameter includes: Acquire the region coordinates corresponding to the remaining sections according to the target coordinate data and the preset image recognition segmentation rule to obtain the remaining coordinate data; Performing area calculation according to the target coordinate data and the remaining coordinate data to obtain area data; The area data is discretely integrated to obtain the volume data.
6. The pathological tissue image processing method according to claim 5, characterized in that: The performing area calculation according to the target coordinate data and the remaining coordinate data to obtain area data includes: Performing area marking according to the target coordinate data and the remaining coordinate data to obtain a curve area; Performing line smoothing processing on the curve region according to a preset interpolation value to obtain a smooth curve region; The area of the smooth curve region is calculated to obtain the area data.
7. The pathological tissue image processing method according to claim 1, characterized in that: The target pathological tissue parameter also includes length data, and the parameter calculation of the selected area of the re-cut image data according to the target coordinate data to obtain the target pathological tissue parameter also includes: Acquire selected first coordinate data and second coordinate data from the target coordinate data and the remaining coordinate data; The length data is obtained by performing length calculation according to the first coordinate data and the second coordinate data.
8. A pathological tissue image processing device, characterized in that: include: A data reading module is used to read the pre-input two-dimensional pathological image file to obtain two-dimensional pathological image data; A three-dimensional construction module, used for performing three-dimensional construction according to the two-dimensional pathological image data to obtain three-dimensional pathological data; An image re-cutting module, used for acquiring section operation data, and re-cutting the three-dimensional pathological data according to the section operation data to obtain re-cut image data; wherein the section operation data is generated according to the parameters of the custom section on the three-dimensional pathological data; A coordinate acquisition module, used to acquire target area data, and extract target coordinate data from the recut image data according to the target area data; wherein the target area data is determined according to a customized selected area on the three-dimensional pathological data; A parameter calculation module is used to perform parameter calculation on a selected area of the re-cut image data according to the target coordinate data to obtain target pathological tissue parameters.
9. A pathological tissue image processing device, characterized in that: include: at least one processor, and a memory communicatively connected to the at least one processor; wherein, The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the pathological tissue image processing method according to any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute the pathological tissue image processing method according to any one of claims 1 to 7.
