CN115082373A - Method, device and equipment for testing medical image positioning line and storage medium - Google Patents

Method, device and equipment for testing medical image positioning line and storage medium Download PDF

Info

Publication number
CN115082373A
CN115082373A CN202110273729.6A CN202110273729A CN115082373A CN 115082373 A CN115082373 A CN 115082373A CN 202110273729 A CN202110273729 A CN 202110273729A CN 115082373 A CN115082373 A CN 115082373A
Authority
CN
China
Prior art keywords
positioning
slice
map
image
image information
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202110273729.6A
Other languages
Chinese (zh)
Inventor
任柳
邓争光
黄智勇
高翔
章婷
赵大平
刘宁
黄克华
陈军华
陈效华
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Winning Health Technology Group Co Ltd
Original Assignee
Winning Health Technology Group Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Winning Health Technology Group Co Ltd filed Critical Winning Health Technology Group Co Ltd
Priority to CN202110273729.6A priority Critical patent/CN115082373A/en
Publication of CN115082373A publication Critical patent/CN115082373A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/0002Inspection of images, e.g. flaw detection
    • G06T7/0012Biomedical image inspection
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/70Determining position or orientation of objects or cameras
    • GPHYSICS
    • G16INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR SPECIFIC APPLICATION FIELDS
    • G16HHEALTHCARE INFORMATICS, i.e. INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR THE HANDLING OR PROCESSING OF MEDICAL OR HEALTHCARE DATA
    • G16H30/00ICT specially adapted for the handling or processing of medical images
    • G16H30/20ICT specially adapted for the handling or processing of medical images for handling medical images, e.g. DICOM, HL7 or PACS
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10072Tomographic images
    • G06T2207/10081Computed x-ray tomography [CT]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10072Tomographic images
    • G06T2207/10088Magnetic resonance imaging [MRI]

Abstract

The application provides a method, a device and equipment for testing a medical image positioning line and a method for storing media, and relates to the technical field of medical image processing. The method comprises the following steps: respectively reading first image information of a group of positioning images and first image information of a section image in a medical image sequence of a detected object; comparing the first image information of the positioning diagram with the first image information of the slice diagram with the second image information of the positioning diagram to be detected and the second image information of the slice diagram to be detected, which are acquired by the software to be detected; if the comparison result is consistent, calculating a first spatial position of a positioning line of the slice image in the positioning image according to the first image information of the positioning image and the first image information of the slice image; and obtaining a test result of the positioning line output by the software to be tested according to the first spatial position of the positioning line and the second spatial position of the positioning line output by the software to be tested. In the scheme, the efficiency of checking the function test of the positioning line is improved, and the test quality is improved.

Description

Method, device and equipment for testing medical image positioning line and storage medium
Technical Field
The application relates to the technical field of medical image processing, in particular to a method, a device, equipment and a storage medium for testing a medical image positioning line.
Background
With the continuous development of medical imaging technology, medical imaging systems such as Computed Tomography (CT) and Magnetic Resonance (MR) have been increasingly used for diagnosing related diseases. For example, although a subject is scanned from a plurality of different angles to obtain a CT/MR two-dimensional slice image sequence of the subject, since there are many two-dimensional slices of one sequence, different sequence images of the same subject may reflect lesion information from different view angles. Therefore, the spatial position relationship between different slice image sequences can be determined according to the positioning line in the CT/MR image sequence, so as to more accurately acquire the spatial position of the detected focus. The positioning line refers to a position of the slice sequence image on the positioning map, that is, an intersection line of the slice image and the positioning map.
Currently, in order to determine whether the location lines of the slice images in the CT/MR image sequence on the location map are accurate, the location lines need to be tested. Specifically, a positioning image and a slice image in an image sequence of a detected body are opened through test software, and a positioning line checking function is clicked, so that manual testing of a positioning line in a CT/MR image sequence is realized.
However, the conventional test method can only test whether a location line can be generated between a location map and a slice map in a CT/MR image sequence, and cannot distinguish whether the location line is accurate.
Disclosure of Invention
The present invention is directed to provide a method, an apparatus, a device and a storage medium for testing a positioning line of a medical image, so as to improve efficiency of testing a function of checking the positioning line and improve testing quality.
In order to achieve the above purpose, the technical solutions adopted in the embodiments of the present application are as follows:
in a first aspect, an embodiment of the present application provides a method for testing a medical image locating line, including:
respectively reading first image information of a group of positioning images and first image information of a section image in a medical image sequence of a detected object; the first image information is information recorded on a positioning map and a slice map by a shooting device, and the first image information comprises: vertex position of the upper left corner, line number, column number and pixel distance;
comparing the first image information of the positioning diagram with the first image information of the slice diagram with the second image information of the positioning diagram to be detected and the second image information of the slice diagram to be detected, which are acquired by software to be detected;
if the comparison result is consistent, calculating a first spatial position of a positioning line of the slice image in the positioning image according to the first image information of the positioning image and the first image information of the slice image;
obtaining a test result of the positioning line output by the software to be tested according to the first spatial position of the positioning line and the second spatial position of the positioning line output by the software to be tested; the first spatial position is used for representing the position information of the positioning line under the medical coordinate system of the shooting device.
Optionally, the calculating a first spatial position of a location line of the slice in the location map according to the first image information of the location map and the first image information of the slice includes:
determining the space position coordinates of the positioning map and the space position coordinates of the slice map according to the first image information of the positioning map and the first image information of the slice map;
calculating an angle value between the positioning diagram and the slice diagram according to the space position coordinates of the positioning diagram and the space position coordinates of the slice diagram;
and if the angle value is larger than a preset angle, calculating a first space position of the positioning line of the slice image in the positioning image.
Optionally, the obtaining, according to the first spatial position of the positioning line and the second spatial position of the positioning line output by the software to be tested, the test result of the positioning line output by the software to be tested includes:
and comparing the first spatial position of the positioning line with the second spatial position of the positioning line output by the software to be tested to obtain a test result of the positioning line output by the software to be tested.
Optionally, after calculating an angle value between the positioning map and the slice map according to the spatial position coordinates of the positioning map and the spatial position coordinates of the slice map, the method further includes:
if the angle value is smaller than or equal to the preset angle, determining that no positioning line exists in the positioning map of the slice map;
obtaining a test result of the positioning line output by the software to be tested according to the first information without the positioning line and the second information of the positioning line output by the software to be tested; the second information is used to indicate whether the slice map has a location line in the location map.
Optionally, the calculating an angle value between the positioning map and the slice map according to the spatial position coordinates of the positioning map and the spatial position coordinates of the slice map includes:
respectively calculating the length and width vector of the positioning map and the length and width vector of the slice map according to the space position coordinate of the positioning map and the space position coordinate of the slice map;
calculating a first plane equation of the positioning map and a second plane equation of the slice map according to the length and width vector of the positioning map, the length and width vector of the slice map and the space position coordinate respectively;
calculating a first plane normal vector of the positioning diagram and a second plane normal vector of the slice diagram according to the first plane equation and the second plane equation respectively;
and calculating an angle value between the positioning picture and the slice picture by using the first plane normal vector and the second plane normal vector.
Optionally, the calculating a first spatial position of a localization line of the slice in the localization map comprises:
and calculating a first space position of a positioning line of the slice image in the positioning image according to the first plane equation, the second plane equation and the vertex positions of the upper left corners of the positioning image and the slice image.
Optionally, after comparing the first image information of the positioning diagram with the first image information of the slice diagram with the second image information of the positioning diagram to be detected and the second image information of the slice diagram to be detected, which are acquired by the software to be detected, the method further includes:
and if the comparison result is inconsistent, obtaining an abnormal test result, wherein the abnormal test result is used for indicating that the positioning line output by the software to be tested does not meet the expected result.
In a second aspect, an embodiment of the present application further provides a device for testing a medical image locating line, where the device includes: the device comprises a reading module, a comparison module, a calculation module and a test module;
the reading module is used for respectively reading first image information of a group of positioning images and first image information of a section image in a medical image sequence of the detected body; the first image information is information recorded on a positioning map and a slice map by a shooting device, and the first image information comprises: vertex position of upper left corner, line number, column number and pixel distance;
the comparison module is used for comparing the first image information of the positioning diagram with the first image information of the slice diagram with the second image information of the positioning diagram to be detected and the second image information of the slice diagram to be detected, which are acquired by software to be detected;
the calculation module is used for calculating a first spatial position of a positioning line of the slice image in the positioning image according to the first image information of the positioning image and the first image information of the slice image if the comparison results are consistent;
the test module is used for obtaining a test result of the positioning line output by the software to be tested according to the first spatial position of the positioning line and the second spatial position of the positioning line output by the software to be tested; the first spatial position is used for representing the position information of the positioning line under the medical coordinate system of the shooting device.
Optionally, the computing module is further configured to:
according to the first image information of the positioning map and the first image information of the slice map, determining the spatial position coordinates of the positioning map and the spatial position coordinates of the slice map;
calculating an angle value between the positioning map and the slice map according to the space position coordinates of the positioning map and the space position coordinates of the slice map;
and if the angle value is larger than a preset angle, calculating a first space position of the positioning line of the slice image in the positioning image.
Optionally, the test module is further configured to:
and comparing the first spatial position of the positioning line with the second spatial position of the positioning line output by the software to be tested to obtain a test result of the positioning line output by the software to be tested.
Optionally, the test module is further configured to:
if the angle value is smaller than or equal to the preset angle, determining that no positioning line exists in the positioning map of the slice map;
obtaining a test result of the positioning line output by the software to be tested according to the first information without the positioning line and the second information of the positioning line output by the software to be tested; the second information is used to indicate whether a location line is present in the location map for the slice map.
Optionally, the computing module is further configured to:
respectively calculating the length and width vector of the positioning map and the length and width vector of the slice map according to the space position coordinate of the positioning map and the space position coordinate of the slice map;
calculating a first plane equation of the positioning map and a second plane equation of the slice map according to the length and width vector of the positioning map, the length and width vector of the slice map and the space position coordinate respectively;
calculating a first plane normal vector of the positioning diagram and a second plane normal vector of the slice diagram according to the first plane equation and the second plane equation respectively;
and calculating an angle value between the positioning picture and the slice picture by using the first plane normal vector and the second plane normal vector.
Optionally, the computing module is further configured to:
and calculating a first space position of a positioning line of the slice image in the positioning image according to the first plane equation, the second plane equation and the vertex positions of the upper left corners of the positioning image and the slice image.
Optionally, the test module is further configured to:
and if the comparison result is inconsistent, obtaining an abnormal test result, wherein the abnormal test result is used for indicating that the positioning line output by the software to be tested does not meet the expected result.
In a third aspect, an embodiment of the present application further provides an electronic device, including: a processor, a storage medium and a bus, the storage medium storing machine-readable instructions executable by the processor, the processor and the storage medium communicating via the bus when the electronic device is operating, the processor executing the machine-readable instructions to perform the steps of the method as provided by the first aspect.
In a fourth aspect, this application further provides a computer-readable storage medium, on which a computer program is stored, which, when executed by a processor, performs the steps of the method as provided in the first aspect.
The beneficial effect of this application is:
the embodiment of the application provides a method, a device, equipment and a storage medium for testing a medical image positioning line, wherein the method comprises the following steps: respectively reading first image information of a group of positioning images and first image information of a section image in a medical image sequence of a detected object; comparing the first image information of the positioning diagram with the first image information of the slice diagram with the second image information of the positioning diagram to be detected and the second image information of the slice diagram to be detected, which are acquired by the software to be detected; if the comparison result is consistent, calculating a first spatial position of a positioning line of the slice image in the positioning image according to the first image information of the positioning image and the first image information of the slice image; and obtaining a test result of the positioning line output by the software to be tested according to the first spatial position of the positioning line and the second spatial position of the positioning line output by the software to be tested. In the scheme, after the comparison result of the first image information of the positioning chart and the first image information of the slice chart is consistent with the comparison result of the second image information of the positioning chart to be tested and the second image information of the slice chart to be tested, which are acquired by the software to be tested, then the second spatial position of the positioning line output by the software to be tested is tested according to the first spatial position of the positioning line of the slice chart in the positioning chart, so as to determine whether the result of the second spatial position of the positioning line output by the software to be tested is accurate, so that whether the positioning line output by the software to be tested is accurate can be tested more quickly, the efficiency of checking the functional test on the positioning line is improved, and the test quality is improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required in the embodiments will be briefly described below, it should be understood that the following drawings only illustrate some embodiments of the present invention and therefore should not be considered as limiting the scope, and those skilled in the art can also obtain other related drawings based on the drawings without inventive efforts.
Fig. 1 is a schematic diagram illustrating a position of a locating line in a medical image according to an embodiment of the present application;
fig. 2 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure;
fig. 3 is a schematic flowchart illustrating a method for testing a medical image locating line according to an embodiment of the present disclosure;
fig. 4 is a schematic flowchart of another medical image alignment line testing method according to an embodiment of the present disclosure;
fig. 5 is a schematic flowchart illustrating a method for testing a medical image locating line according to an embodiment of the present application;
fig. 6 is a schematic flowchart illustrating another method for testing a medical image locating line according to an embodiment of the present application;
fig. 7 is a schematic structural diagram of a medical image alignment line testing apparatus according to an embodiment of the present application.
Detailed Description
In order to make the purpose, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it should be understood that the drawings in the present application are for illustrative and descriptive purposes only and are not used to limit the scope of protection of the present application. Additionally, it should be understood that the schematic drawings are not necessarily drawn to scale. The flowcharts used in this application illustrate operations implemented according to some embodiments of the present application. It should be understood that the operations of the flow diagrams may be performed out of order, and steps without logical context may be performed in reverse order or simultaneously. One skilled in the art, under the guidance of this application, may add one or more other operations to, or remove one or more operations from, the flowchart.
In addition, the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. The components of the embodiments of the present application, generally described and illustrated in the figures herein, can be arranged and designed in a wide variety of different configurations. Thus, the following detailed description of the embodiments of the present application, presented in the accompanying drawings, is not intended to limit the scope of the claimed application, but is merely representative of selected embodiments of the application. All other embodiments, which can be derived by a person skilled in the art from the embodiments of the present application without making any creative effort, shall fall within the protection scope of the present application.
It should be noted that in the embodiments of the present application, the term "comprising" is used to indicate the presence of the features stated hereinafter, but does not exclude the addition of further features.
Before proceeding with a detailed description of the technical solutions provided in the present application, a brief description of some terms referred to in the present application will be provided.
In the aspect of medical image-based disease diagnosis, for example, the number of slice images in medical image sequences such as CT and MR is large, and a plurality of groups of two-dimensional slice images of human tissues and organs at different view angles need to be analyzed, so that the accurate position of a certain slice image in the CT/MR two-dimensional slice image sequence of the subject on the positioning map can be determined according to a plurality of positioning lines in the positioning map, so as to obtain the size and shape of a lesion, thereby facilitating diagnosis.
Fig. 1 is a schematic diagram illustrating a position of a locating line in a medical image according to an embodiment of the present application; as shown in fig. 1, the positional relationship among the positioning map, the slice map, and the positioning line in the medical image is shown.
1. Positioning drawing: refers to a two-dimensional image of the subject in one direction.
2. Section drawing: refers to the two-dimensional sagittal, coronal, and axial planes of the subject.
3. Positioning a line: refers to the position of the slice sequence images on the positioning map, i.e. the intersection line of each slice image and the positioning map.
Fig. 2 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure; the electronic device may be a processing device such as a computer. As shown in fig. 2, the electronic apparatus includes: a processor 201 and a memory 202.
The processor 201 and the memory 202 are electrically connected directly or indirectly to realize data transmission or interaction. For example, electrical connections may be made through one or more communication buses or signal lines.
The processor 201 may be an integrated circuit chip having signal processing capability. The Processor 101 may be a general-purpose Processor including a Central Processing Unit (CPU), a Network Processor (NP), and the like. The various methods, steps, and logic blocks disclosed in the embodiments of the present invention may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The Memory 202 may be, but is not limited to, a Random Access Memory (RAM), a Read Only Memory (ROM), a Programmable Read-Only Memory (PROM), an Erasable Read-Only Memory (EPROM), an electrically Erasable Read-Only Memory (EEPROM), and the like.
The memory 202 is used for storing a program, and the processor 201 calls the program stored in the memory 202 to execute the testing method of the medical image locating line provided by the following embodiment.
It will be appreciated that the configuration depicted in fig. 2 is merely illustrative and that the electronic device may include more or fewer components than shown in fig. 2 or may have a different configuration than shown in fig. 2. The components shown in fig. 2 may be implemented in hardware, software, or a combination thereof.
As follows, the implementation principle and the corresponding beneficial effects of the medical image positioning line testing method provided by the present application will be described by a plurality of specific embodiments.
Fig. 3 is a schematic flowchart illustrating a method for testing a medical image locating line according to an embodiment of the present disclosure; the execution subject of the method may be the electronic device in fig. 2, as shown in fig. 3, and the method includes:
s301, first image information of a set of positioning images and first image information of a slice image in a medical image sequence of the object are read respectively.
The first image information is a known information value recorded on a positioning map and a slice map by a shooting device, and the first image information comprises: vertex position at the top left corner, row number, column number, pixel distance.
The shooting device may refer to a CT device, a magnetic resonance imaging system, or the like, and may acquire different sequence images of the subject using the CT device or the magnetic resonance imaging system.
In this example, the first image information may also be referred to as a Digital Imaging and Communications in Medicine (DICOM) image, which is a common image in the medical field. The DICOM image information is specifically as follows:
image Position (a1, b2, c3) at the top left corner of the Image;
row number — rows (r);
column number-columns (c);
pixel distance-Pixel Spacing(s) (unit: mm);
image Orientation (x1, x2, x3, y1, y2, y3), which is the cosine of the angle between the Image and the coordinate.
In the present embodiment, the first image information DICOM1 of the localization chart and the first image information DICOM2 of the slice chart can be read from the medical image of the subject.
S302, comparing the first image information of the positioning diagram with the first image information of the slice diagram with the second image information of the positioning diagram to be detected and the second image information of the slice diagram to be detected, which are acquired by the software to be detected.
The software to be detected is image processing software in the medical industry, the image processing software has a function of viewing a positioning line, a user can open a positioning image and a slice image in a CT/MR image sequence to be checked by using the image processing software and click to view the positioning line, but due to the complexity and variability of medical image information, the image processing software can only know whether the positioning line exists between a positioning map and the slice map and cannot distinguish whether the position (namely the positioning line) displayed by the slice map in the positioning map is accurate or not.
In general, when the first image information DICOM1 of the location map and the first image information DICOM2 of the slice map are known, the location line L generated in the location map by the slice map is unique.
In order to improve the efficiency and accuracy of the subsequent positioning line test, the first image information DICOM1 of the positioning diagram and the first image information DICOM2 of the slice diagram are firstly compared with the second image information DICOM10 of the positioning diagram to be tested and the second image information DICOM20 of the slice diagram to be tested, which are acquired by the software to be tested, respectively, so as to determine whether the first image information DICOM1 of the positioning diagram is equal to the second image information DICOM10 of the positioning diagram to be tested and the first image information DICOM2 of the slice diagram is equal to the second image information DICOM20 of the slice diagram to be tested.
And S303, if the comparison result is consistent, calculating a first spatial position of the positioning line of the slice image in the positioning image according to the first image information of the positioning image and the first image information of the slice image.
In this embodiment, if the above-mentioned comparison results of the "first image information DICOM1 of the positioning diagram" and the "second image information DICOM10 of the positioning diagram to be measured obtained by the software to be measured" are equal to the comparison results of the "first image information DICOM2 of the slice diagram" and the "second image information DICOM20 of the slice diagram to be measured", the first spatial position P1 of the positioning line L1 of the slice diagram in the positioning diagram can be calculated according to the first image information DICOM1 of the positioning diagram and the first image information DICOM2 of the slice diagram.
S304, obtaining a test result of the positioning line output by the software to be tested according to the first spatial position of the positioning line and the second spatial position of the positioning line output by the software to be tested.
The first spatial position is used to represent the position information of the location line L1 in the medical coordinate system of the filming device.
Based on the above embodiment, after the first spatial position P1 of the positioning line L1 in the positioning map of the slice map is obtained through calculation, the accuracy of the second spatial position P10 of the positioning line L10 output by the software to be tested can be tested according to the first spatial position P1 of the positioning line L1, so as to obtain the test result of the positioning line L10 output by the software to be tested. Wherein, the test result includes: both consistent and inconsistent.
For example, if the "first spatial position P1" of the positioning line L1 is not consistent with the "second spatial position P10" of the positioning line L10 output by the software under test ", it may be determined that the" second spatial position P10 "of the positioning line L10 output by the software under test is inaccurate and has a deviation.
For another example, if the "first spatial position P1" of the positioning line L1 is equal to the "second spatial position P10" of the positioning line L10 output by the software to be tested, the result of the "second spatial position P10" of the positioning line L10 output by the software to be tested may be determined to be accurate, whether the positioning line output by the software to be tested is accurate or not may be tested more quickly, the efficiency of checking the functional test of the positioning line is improved, and the test quality is improved.
In summary, the embodiment of the present application provides a method for testing a medical image locating line, which includes: respectively reading first image information of a group of positioning images and first image information of a section image in a medical image sequence of a detected object; comparing the first image information of the positioning diagram with the first image information of the slice diagram with the second image information of the positioning diagram to be detected and the second image information of the slice diagram to be detected, which are acquired by the software to be detected; if the comparison result is consistent, calculating a first spatial position of a positioning line of the slice image in the positioning image according to the first image information of the positioning image and the first image information of the slice image; and obtaining a test result of the positioning line output by the software to be tested according to the first spatial position of the positioning line and the second spatial position of the positioning line output by the software to be tested. In the scheme, after the comparison result of the first image information of the positioning chart and the first image information of the slice chart is consistent with the comparison result of the second image information of the positioning chart to be tested and the second image information of the slice chart to be tested, which are acquired by the software to be tested, then the second spatial position of the positioning line output by the software to be tested is tested according to the first spatial position of the positioning line of the slice chart in the positioning chart, so as to determine whether the result of the second spatial position of the positioning line output by the software to be tested is accurate, so that whether the positioning line output by the software to be tested is accurate can be tested more quickly, the efficiency of checking the functional test on the positioning line is improved, and the test quality is improved.
Fig. 4 is a schematic flowchart of another medical image alignment line testing method according to an embodiment of the present application; the step S303: calculating a first spatial position of a location line of the slice in the location map based on the first image information of the location map and the first image information of the slice, comprising:
s401, according to the first image information of the positioning map and the first image information of the slice map, determining the space position coordinates of the positioning map and the space position coordinates of the slice map.
The location map and slice map spatial position coordinates can be respectively determined according to the "location map first image information DICOM 1" and "slice map first image information DICOM 2", as follows:
in this embodiment, the vertex coordinates of the top left corner of the positioning map can be determined according to the vertex Position (Image Position (a1, b2, c 3)) in the "first Image information DICOM1 of the positioning map, and then the Position coordinates of the four vertices (denoted as A, B, C, D) of the positioning map can be calculated according to the cosine values of the angles between the images and the coordinates (Image Orientation (x1, x2, x3, y1, y2, y3)), the row numbers (rows (r)), the column numbers (columns (c)), the Pixel distances (Pixel Spacing (s)), and the like in the DICOM1 Image information, and the spatial Position coordinates of the positioning map are specifically shown as follows:
the upper left corner: a ═ a1, b2, c3, top right corner: b ═ a + (Wx1, Wx2, Wx3), lower right corner: c ═ B + (Hy1, Hy2, Hy3), bottom left corner: d ═ a + (Hy1, Hy2, Hy 3).
W, H is the image width and the image height of the positioning map, and can be calculated from the line number, column number, and pixel distance in the DICOM1 image information, specifically: the image width is W ═ cs, and the image height is H ═ rs.
Similarly, the slice space position coordinate P2 may also be obtained from "DICOM 2", which is not described herein again.
S402, calculating an angle value between the positioning diagram and the slice diagram according to the space position coordinates of the positioning diagram and the space position coordinates of the slice diagram.
How to calculate the angle value between the localization diagram and the slice diagram according to the spatial position coordinates of the localization diagram and the spatial position coordinates of the slice diagram will be specifically explained by the following embodiments.
Fig. 5 is a schematic flowchart illustrating a method for testing a medical image locating line according to an embodiment of the present application; as shown in fig. 5, the calculating an angle value between the localization map and the slice map according to the spatial position coordinates of the localization map and the spatial position coordinates of the slice map includes:
and S501, respectively calculating the length and width vectors of the positioning map and the length and width vectors of the slice map according to the space position coordinates of the positioning map and the space position coordinates of the slice map.
For example, taking the calculation of the length and width vectors of the positioning map as an example, the image length vector can be obtained from the position coordinates of the four vertices A, B, C, D of the positioning map:
Figure BDA0002974022940000121
image wide vector:
Figure BDA0002974022940000122
similarly, the long vector and the wide vector of the slice may also be obtained according to the spatial position coordinates of the slice, which are not described herein again.
S502, calculating a first plane equation of the positioning map and a second plane equation of the slice map according to the length and width vector of the positioning map, the length and width vector of the slice map and the space position coordinate.
For example, the first plane equation of the positioning diagramFor example, the image long vector of the localization map may be:
Figure BDA0002974022940000123
image wide vector:
Figure BDA0002974022940000124
and the position coordinates of the four vertices A, B, C, D of the map, and calculates the first Plane equation a x + b y + c z + d of the map Plane1 as 0.
Similarly, the second Plane equation e x + f y + g z + h 0 of the slice Plane2 can also be calculated, and will not be described herein again.
S503, calculating a first plane normal vector of the positioning diagram and a second plane normal vector of the slice diagram according to the first plane equation and the second plane equation respectively.
Based on the above embodiment, the first Plane normal vector of the map Plane1 can be obtained according to the first Plane equation a x + b y + c z + d of the map Plane1 being 0 and the second Plane equation e x + f y + g z + h of the slice Plane2 being 0
Figure BDA0002974022940000125
(a, b, c) second Plane normal vector of the section Plane2
Figure BDA0002974022940000126
(e,f,g)。
And S504, calculating an angle value between the positioning picture and the slice picture by using the first plane normal vector and the second plane normal vector.
For example, in this example, by calculating cosine values between the first plane normal vector and the second plane normal vector, specifically:
Figure BDA0002974022940000131
from this, the angle between the normal vectors of the two planes, the orientation Plane1 and the section Plane2, can be calculated, which is also the angle α 0 between the orientation Plane1 and the section Plane 2.
The processing after calculating the angle value between the scout map and the slice map will be explained in detail by the following steps.
And S403, if the angle value is larger than the preset angle, calculating a first spatial position of the positioning line of the slice image in the positioning image.
On the basis of the above embodiment, if the calculated angle value α 0 between the positioning map and the slice map is greater than the preset angle α 1, it may be determined that a positioning line exists in the positioning map in the slice map, and a spatial position of the positioning line may be calculated.
Optionally, the first spatial position of the positioning line in the positioning map of the slice map may be calculated according to the first plane equation, the second plane equation, and the vertex position of the upper left corner of the positioning map and the slice map, and the specific calculation process is as follows:
from the first Plane equation a x + b y + c z + d 0 of the map Plane1, the second Plane equation e x + f y + g z + h 0 of the slice Plane2, and the coordinates of the upper left corner a of the image in the map Plane1, the equation of the cross line between the map Plane1 and the slice Plane2 can be calculated, and then the spatial position of the location line can be calculated from the length and width vectors of the map Plane1 and the slice Plane2, and the coordinates of the four vertices in the map Plane 1.
Optionally, obtaining a test result of the positioning line output by the software to be tested according to the first spatial position of the positioning line and the second spatial position of the positioning line output by the software to be tested, where the test result includes:
the first spatial position of the positioning line is compared with the second spatial position of the positioning line output by the software to be tested, so that the test result of the positioning line output by the software to be tested is obtained, whether the test result of the positioning line output by the software to be tested is accurate or not is confirmed, the automatic test of the positioning line output by the software to be tested is realized, and the test efficiency is improved.
Fig. 6 is a schematic flowchart illustrating another method for testing a medical image locating line according to an embodiment of the present application; the above step S402: after calculating the angle value between the positioning map and the slice map according to the spatial position coordinates of the positioning map and the spatial position coordinates of the slice map, the method further comprises the following steps:
s601, if the angle value is smaller than or equal to the preset angle, determining that no positioning line exists in the positioning map of the slice map.
For example, if the angle α 1 between the positioning map and the slice map obtained by the above calculation is smaller than or equal to the preset angle α 0, the slice map may not have a positioning line in the positioning map, or may default that the two planes of the positioning map and the slice map are approximately parallel and cannot generate an intersecting line.
S602, obtaining a test result of the positioning line output by the software to be tested according to the first information without the positioning line and the second information of the positioning line output by the software to be tested.
Wherein the second information is used to indicate whether the slice map has a location line in the location map.
In an implementation manner, for example, if the second information indicates that the slice diagram output by the software to be tested does not have a positioning line in the positioning diagram, the second information of the positioning line output by the software to be tested can be automatically tested according to the obtained first information without the positioning line to obtain a test result, the test result in a document form can be generated, the keyword code module for sending the mail is called through the Robot Framework, and the mailbox address is configured, so that the test result can be automatically sent to the mailbox of a tester, and the accuracy of obtaining the test result is improved.
If the second information of the positioning line output by the software to be tested indicates that the positioning line exists, the second information of the positioning line output by the software to be tested can be automatically tested according to the obtained first information without the positioning line, and the test result is obtained, so that the test efficiency of whether the function of the positioning line in the software to be tested is accurate is improved, the reliability of the function of the positioning line in the software to be tested is improved, and the probability of judgment errors is reduced.
Optionally, after comparing the first image information of the positioning diagram with the first image information of the slice diagram, with the second image information of the positioning diagram to be detected and the second image information of the slice diagram to be detected, which are acquired by the software to be detected, the method further includes:
and if the comparison result is inconsistent, obtaining an abnormal test result, wherein the abnormal test result is used for indicating that the positioning line output by the software to be tested does not meet the expected result.
In this embodiment, for example, if "the first image information DICOM1 of the positioning map" is not equal to "the second image information DICOM10 of the positioning map to be tested obtained by the to-be-tested software," or "the first image information DICOM 2" of the slice map is not equal to "the second image information DICOM 20" of the to-be-tested slice map ", or both of them are not equal at the same time, it may be determined that there is an abnormal situation in the image information obtained by the to-be-tested software, and the to-be-tested software needs to obtain" the second image information DICOM10 "of the positioning map to be tested obtained by the to-be-tested software and/or" the second image information DICOM20 "of the to-be-tested slice map again, and may also directly send the DICOM image information comparison result to the tester.
The following describes a device and a storage medium corresponding to the method for testing a medical image positioning line provided by the present application, and specific implementation processes and technical effects thereof are referred to above, and will not be described again below.
Fig. 7 is a schematic structural diagram of a medical image alignment line testing apparatus according to an embodiment of the present disclosure; as shown in fig. 7, the apparatus includes: a reading module 701, an alignment module 702, a calculation module 703 and a test module 704.
A reading module 701, configured to read first image information of a set of scout maps and first image information of a slice map in a medical image sequence of a subject, respectively; the first image information is information recorded on a positioning map and a slice map by a shooting device, and the first image information comprises: vertex position of upper left corner, line number, column number and pixel distance;
a comparison module 702, configured to compare the first image information of the positioning diagram with the first image information of the slice diagram, with the second image information of the positioning diagram to be detected and the second image information of the slice diagram to be detected, which are acquired by the software to be detected;
a calculating module 703, configured to calculate a first spatial position of a positioning line of the slice in the positioning map according to the first image information of the positioning map and the first image information of the slice if the comparison results are consistent;
the testing module 704 is used for obtaining a testing result of the positioning line output by the software to be tested according to the first spatial position of the positioning line and the second spatial position of the positioning line output by the software to be tested; the first spatial position is used for representing the position information of the positioning line under the medical coordinate system of the shooting device.
Optionally, the calculating module 703 is further configured to:
determining the space position coordinates of the positioning map and the space position coordinates of the slice map according to the first image information of the positioning map and the first image information of the slice map;
calculating an angle value between the positioning map and the slice map according to the space position coordinates of the positioning map and the space position coordinates of the slice map;
and if the angle value is larger than the preset angle, calculating a first spatial position of a positioning line of the slice image in the positioning image.
Optionally, the testing module 704 is further configured to:
and comparing the first spatial position of the positioning line with the second spatial position of the positioning line output by the software to be tested to obtain a test result of the positioning line output by the software to be tested.
Optionally, the testing module 704 is further configured to:
if the angle value is smaller than or equal to the preset angle, determining that no positioning line exists in the positioning map of the slice map;
obtaining a test result of the positioning line output by the software to be tested according to the first information without the positioning line and the second information of the positioning line output by the software to be tested; the second information is used to indicate whether the slice map has a location line in the location map.
Optionally, the calculating module 703 is further configured to:
respectively calculating the length and width vectors of the positioning map and the length and width vectors of the slice map according to the space position coordinates of the positioning map and the space position coordinates of the slice map;
calculating a first plane equation of the positioning map and a second plane equation of the slice map according to the length and width vector of the positioning map, the length and width vector of the slice map and the space position coordinate respectively;
calculating a first plane normal vector of the positioning diagram and a second plane normal vector of the slice diagram according to the first plane equation and the second plane equation respectively;
and calculating an angle value between the positioning picture and the slice picture by using the first plane normal vector and the second plane normal vector.
Optionally, the calculating module 703 is further configured to:
and calculating a first spatial position of the positioning line of the slice image in the positioning image according to the first plane equation, the second plane equation and the vertex position of the upper left corner of the positioning image and the slice image.
Optionally, the testing module 704 is further configured to:
and if the comparison result is inconsistent, obtaining an abnormal test result, wherein the abnormal test result is used for indicating that the positioning line output by the software to be tested does not meet the expected result.
The above-mentioned apparatus is used for executing the method provided by the foregoing embodiment, and the implementation principle and technical effect are similar, which are not described herein again.
These above modules may be one or more integrated circuits configured to implement the above methods, such as: one or more Application Specific Integrated Circuits (ASICs), or one or more microprocessors (DSPs), or one or more Field Programmable Gate Arrays (FPGAs), among others. For another example, when one of the above modules is implemented in the form of a Processing element scheduler code, the Processing element may be a general-purpose processor, such as a Central Processing Unit (CPU) or other processor capable of calling program code. For another example, these modules may be integrated together and implemented in the form of a system-on-a-chip (SOC).
Optionally, the invention also provides a program product, for example a computer-readable storage medium, comprising a program which, when being executed by a processor, is adapted to carry out the above-mentioned method embodiments.
In the embodiments provided in the present invention, it should be understood that the disclosed apparatus and method may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, or in a form of hardware plus a software functional unit.
The integrated unit implemented in the form of a software functional unit may be stored in a computer readable storage medium. The software functional unit is stored in a storage medium and includes several instructions to enable a computer device (which may be a personal computer, a server, or a network device) or a processor (processor) to execute some steps of the methods according to the embodiments of the present invention. And the aforementioned storage medium includes: a U disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.

Claims (10)

1. A method for testing a medical image locating line is characterized by comprising the following steps:
respectively reading first image information of a group of positioning images and first image information of a section image in a medical image sequence of a detected object; the first image information is information recorded on a positioning map and a slice map by a shooting device, and the first image information comprises: vertex position of upper left corner, line number, column number and pixel distance;
comparing the first image information of the positioning diagram with the first image information of the slice diagram with the second image information of the positioning diagram to be detected and the second image information of the slice diagram to be detected, which are acquired by software to be detected;
if the comparison result is consistent, calculating a first spatial position of a positioning line of the slice image in the positioning image according to the first image information of the positioning image and the first image information of the slice image;
obtaining a test result of the positioning line output by the software to be tested according to the first spatial position of the positioning line and the second spatial position of the positioning line output by the software to be tested; the first spatial position is used for representing the position information of the positioning line under a medical coordinate system of the shooting device.
2. The method of claim 1, wherein calculating the first spatial position of the location line of the slice in the location map based on the first image information of the location map and the first image information of the slice comprises:
determining the space position coordinates of the positioning map and the space position coordinates of the slice map according to the first image information of the positioning map and the first image information of the slice map;
calculating an angle value between the positioning map and the slice map according to the space position coordinates of the positioning map and the space position coordinates of the slice map;
and if the angle value is larger than a preset angle, calculating a first space position of the positioning line of the slice image in the positioning image.
3. The method according to claim 1, wherein obtaining the test result of the positioning line output by the software to be tested according to the first spatial position of the positioning line and the second spatial position of the positioning line output by the software to be tested comprises:
and comparing the first spatial position of the positioning line with the second spatial position of the positioning line output by the software to be tested to obtain a test result of the positioning line output by the software to be tested.
4. The method of claim 2, wherein after calculating the angle value between the localization map and the slice map according to the spatial position coordinates of the localization map and the spatial position coordinates of the slice map, further comprising:
if the angle value is smaller than or equal to the preset angle, determining that no positioning line exists in the positioning map of the slice map;
obtaining a test result of the positioning line output by the software to be tested according to the first information without the positioning line and the second information of the positioning line output by the software to be tested; the second information is used to indicate whether the slice map has a location line in the location map.
5. The method of claim 2, wherein said calculating an angle value between the localization map and the slice map based on the spatial location coordinates of the localization map and the spatial location coordinates of the slice map comprises:
respectively calculating the length and width vector of the positioning diagram and the length and width vector of the slice diagram according to the spatial position coordinate of the positioning diagram and the spatial position coordinate of the slice diagram;
calculating a first plane equation of the positioning map and a second plane equation of the slice map according to the length and width vector of the positioning map, the length and width vector of the slice map and the spatial position coordinates respectively;
calculating a first plane normal vector of the positioning diagram and a second plane normal vector of the slice diagram according to the first plane equation and the second plane equation respectively;
and calculating an angle value between the positioning picture and the slice picture by using the first plane normal vector and the second plane normal vector.
6. The method of claim 5, wherein said calculating a first spatial position of a localization line of said slice in said localization map comprises:
and calculating a first space position of a positioning line of the slice image in the positioning image according to the first plane equation, the second plane equation and the vertex positions of the upper left corners of the positioning image and the slice image.
7. The method according to any one of claims 1 to 6, wherein after comparing the first image information of the positioning map and the first image information of the slice map with the second image information of the positioning map to be tested and the second image information of the slice map to be tested, which are obtained by software to be tested, the method further comprises:
and if the comparison result is inconsistent, obtaining an abnormal test result, wherein the abnormal test result is used for indicating that the positioning line output by the software to be tested does not meet the expected result.
8. A medical image alignment line testing device, the device comprising: the device comprises a reading module, a comparison module, a calculation module and a test module;
the reading module is used for respectively reading first image information of a group of positioning images and first image information of a section image in a medical image sequence of the detected body; the first image information is information recorded on a positioning map and a slice map by a shooting device, and the first image information comprises: vertex position of the upper left corner, line number, column number and pixel distance;
the comparison module is used for comparing the first image information of the positioning diagram with the first image information of the slice diagram with the second image information of the positioning diagram to be detected and the second image information of the slice diagram to be detected, which are acquired by software to be detected;
the calculation module is used for calculating a first spatial position of a positioning line of the slice image in the positioning image according to the first image information of the positioning image and the first image information of the slice image if the comparison results are consistent;
the test module is used for obtaining a test result of the positioning line output by the software to be tested according to the first spatial position of the positioning line and the second spatial position of the positioning line output by the software to be tested; the first spatial position is used for representing the position information of the positioning line under the medical coordinate system of the shooting device.
9. An electronic device, comprising: a processor, a storage medium and a bus, the storage medium storing machine-readable instructions executable by the processor, the processor and the storage medium communicating via the bus when the electronic device is operating, the processor executing the machine-readable instructions to perform the steps of the method according to any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that the storage medium has stored thereon a computer program which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 7.
CN202110273729.6A 2021-03-12 2021-03-12 Method, device and equipment for testing medical image positioning line and storage medium Pending CN115082373A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110273729.6A CN115082373A (en) 2021-03-12 2021-03-12 Method, device and equipment for testing medical image positioning line and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110273729.6A CN115082373A (en) 2021-03-12 2021-03-12 Method, device and equipment for testing medical image positioning line and storage medium

Publications (1)

Publication Number Publication Date
CN115082373A true CN115082373A (en) 2022-09-20

Family

ID=83241084

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110273729.6A Pending CN115082373A (en) 2021-03-12 2021-03-12 Method, device and equipment for testing medical image positioning line and storage medium

Country Status (1)

Country Link
CN (1) CN115082373A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117116433A (en) * 2023-10-24 2023-11-24 万里云医疗信息科技(北京)有限公司 Labeling method and device for CT (computed tomography) slice images and storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117116433A (en) * 2023-10-24 2023-11-24 万里云医疗信息科技(北京)有限公司 Labeling method and device for CT (computed tomography) slice images and storage medium
CN117116433B (en) * 2023-10-24 2024-02-09 万里云医疗信息科技(北京)有限公司 Labeling method and device for CT (computed tomography) slice images and storage medium

Similar Documents

Publication Publication Date Title
US7778490B2 (en) Method of image registration and medical image data processing apparatus
EP2823765B1 (en) Medical image display device and medical image display method as well as medical image display program
US10417517B2 (en) Medical image correlation apparatus, method and storage medium
CN107123137B (en) Medical image processing method and equipment
US8907952B2 (en) Reparametrized bull's eye plots
US5951571A (en) Method and apparatus for correlating a body with an image of the body
US8045771B2 (en) System and method for automated patient anatomy localization
US10424067B2 (en) Image processing apparatus, image processing method and storage medium
CN107133946B (en) Medical image processing method, device and equipment
US20110262015A1 (en) Image processing apparatus, image processing method, and storage medium
US20120007863A1 (en) Image processing apparatus and image processing method
JP2006214832A (en) Method of measuring marker arrangement, method of assuming position/attitude, device for measuring marker arrangement, device for assuming position/attitude
WO2019111339A1 (en) Learning device, inspection system, learning method, inspection method, and program
US9020215B2 (en) Systems and methods for detecting and visualizing correspondence corridors on two-dimensional and volumetric medical images
US8306354B2 (en) Image processing apparatus, method, and program
CN110910335A (en) Image processing method, image processing device and computer readable storage medium
CN115082373A (en) Method, device and equipment for testing medical image positioning line and storage medium
US8649633B2 (en) Image registration system with movable region indicating similarity of alignment
CN102421367B (en) Medical image display device and medical image display method
US10929990B2 (en) Registration apparatus, method, and program
US10319102B2 (en) Image processing apparatus, image processing system, image processing method, and storage medium
JP2016154701A (en) Image processing method, device and program
JP2006136462A (en) Medical image diagnosis support method and apparatus
JP2017225670A (en) Image processing apparatus and control method therefor

Legal Events

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