A method for processing injury images for forensic identification
By performing verticality verification and size calculation on the injury images of forensic identification, the problem in the existing technology of being unable to accurately determine the size of the wound in the image is solved, and the accuracy and timeliness of forensic identification are improved.
Patent Information
- Application Number
- CN202010916628.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-09-03
- Publication Date
- 2024-09-03
- Estimated Expiration
- 2040-09-03
AI Technical Summary
In the existing forensic identification process, when the captured images are used for identification, the specific size of the wound in the image cannot be accurately judged due to different shooting distances, which affects the accurate identification of the injury.
An injury image processing method used for forensic identification is used to obtain the image to be identified, verify whether it is a vertical shot, perform scalar and parameter calculations, and calculate the size information of the wound, including identifying color segments, calculating physical dimensions, and drawing wound and calculate its length or area.
It achieves accurate calculation of wound size information in images to be identified, improves the timeliness and accuracy of forensic identification, and enhances case handling efficiency.
Smart Images

Figure CN112053349B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of image recognition, and in particular to an injury image processing method for forensic identification. Background Art
[0002] Forensic identification is an important part of the technical work in the judicial process. It is the examination and identification of living bodies, corpses and biological evidence related to human bodies by using knowledge of medicine, biology, anthropology, physics, chemistry, etc., so as to obtain conclusive opinions such as the cause of death, degree of injury, type of murder weapon, blood type analysis, and fact confirmation.
[0003] In the current forensic clinical identification process, the police officers handling the case need to send the materials to be identified to the identification institute for identification, or ask the forensic doctor to go to the scene for identification. However, the timeliness of the above methods is poor, which will affect the efficiency of case handling and add extra burden to the police officers handling the case and the public.
[0004] Therefore, the police can take photos of the identification materials on the spot, and the forensic doctor can use the images to identify the case, which can enhance the timeliness of forensic identification and improve the efficiency of case handling. However, when using the images for forensic identification, due to the different shooting distances, the forensic doctor cannot accurately determine the specific size of the wound in the image during the identification process, which is not conducive to the accurate identification of the injury.
[0005] Therefore, in order to facilitate forensic doctors to use captured images for identification, the present invention discloses a method for processing injury images for forensic identification, which can effectively process the captured images in advance and calculate the size information of the wound in the image to be identified, which is conducive to the subsequent identification work. Summary of the invention
[0006] In view of the above-mentioned deficiencies in the prior art, the present invention actually solves the problem of calculating the size information of the wound in the image to be identified.
[0007] The present invention adopts the following technical solution:
[0008] A method for processing injury images for forensic identification, comprising:
[0009] S1, obtaining the image to be identified;
[0010] S2, verifying the image to be identified to determine whether the image to be identified is a vertically shot image, if so, executing step S3, otherwise, returning to executing step S1;
[0011] S3, performing scalar and parameter calculation on the image to be identified;
[0012] S4. Calculate the size of the wound in the image to be identified based on the parameter calculation results.
[0013] Preferably, the image to be identified includes a ruler attached to the surface to be identified, and the ruler includes a plurality of color segments arranged along the length direction of the ruler; in step S2, if the ratio of the length to the width of the color segment is within a preset threshold range, the image to be identified is judged to be a vertically shot image.
[0014] Preferably, the image to be identified includes a ruler attached to the surface to be identified, and the ruler includes a plurality of color segments arranged along the length direction of the ruler; in step S3, the number of pixels occupied by the color segments in the image to be identified and the coordinates of the minimum circumscribed rectangle corresponding to the color segments are identified as scalars, and the physical size represented by a single pixel in the color segment area in the image to be identified is calculated based on the actual size of the color segments, and the physical size is used as a parameter.
[0015] Preferably, when the wound is a linear plane wound, step S4 comprises:
[0016] S4001, receiving wound calibration data input by a staff member;
[0017] S4002, drawing the wound on the black image based on the wound calibration data, using a white 1px line during drawing;
[0018] S4003. Calculate the sum of the physical lengths of all white pixels in the black image based on the parameter calculation results, and use it as the length of the linear plane wound.
[0019] Preferably, when the wound is a regional plane wound, step S4 comprises:
[0020] S4011. Receive wound calibration data input by staff;
[0021] S4012, drawing the wound on the black image based on the wound calibration data, using a white 1px line during drawing;
[0022] S4013. Calculate the sum of the physical areas of all white pixels in the black image based on the parameter calculation results, and use it as the area of the regional plane wound.
[0023] Preferably, when the wound is a linear curved wound and / or a regional curved wound, step S3 further includes: calculating the average coordinates and depth ratio of the color segments as scalars, and calculating the standard depth as a parameter based on the average coordinates and depth ratio of the color segments.
[0024] Preferably, when the wound is a linear curved wound, step S4 comprises:
[0025] S4021. Receive wound calibration data input by a staff member;
[0026] S4022, drawing the wound on the black image based on the wound calibration data, using a white 1px line during drawing;
[0027] S4023, normalizing the white area in the black image using the standard depth;
[0028] S4024. Calculate the sum of the physical lengths of all white pixels in the normalized black image based on the parameter calculation result, and use it as the length of the linear surface wound.
[0029] Preferably, when the wound is a regional curved wound, step S4 comprises:
[0030] S4031. Receive wound calibration data input by a staff member;
[0031] S4032, drawing the wound on the black image based on the wound calibration data, using a white 1px line during drawing;
[0032] S4033, normalizing the white area in the black image using the standard depth;
[0033] S4034. Calculate the sum of the physical areas of all white pixels in the normalized black image based on the parameter calculation result, and use it as the area of the regional surface wound.
[0034] Preferably, when the target to be identified in the image to be identified is a part of a symmetrical structure and part of the target to be identified is missing, the injury image processing method for forensic identification further includes:
[0035] S501, taking an image of a symmetrical target corresponding to the target to be identified as a comparison image;
[0036] S502, extracting y, cr, br channel images using YUV color space for the identification image and the comparison image;
[0037] S503, reducing noise and smoothing the image of the cr channel by Gaussian filtering;
[0038] S504, using OTSU algorithm to calculate the cr channel image threshold;
[0039] S505, binarizing the image to be identified and the image to be compared respectively according to the image threshold value;
[0040] S506: Calculate the physical area corresponding to the area difference of the binary image using the parameter calculation result, and use it as the area of the missing part.
[0041] In summary, the present invention discloses a method for processing injury images for forensic identification, including: S1, obtaining an image to be identified; S2, verifying the image to be identified, determining whether the image to be identified is a vertically shot image, if so, executing step S3, otherwise, returning to executing step S1; S3, performing scalar and parameter calculations on the image to be identified; S4, calculating the size of the wound in the image to be identified based on the parameter calculation results. The present invention can effectively process the captured image in advance, calculate the size information of the wound in the image to be identified, and is conducive to the subsequent identification work. BRIEF DESCRIPTION OF THE DRAWINGS
[0042] In order to make the purpose, technical solutions and advantages of the present invention more clear, the present application will be further described in detail below with reference to the accompanying drawings, in which:
[0043] Figure 1 A flowchart of a specific implementation of a method for processing injury images for forensic identification disclosed in the present invention;
[0044] Figure 2 is a schematic diagram of a ruler in the present invention;
[0045] Figure 3 It is a schematic diagram of the principle of binocular ranging in the present invention. DETAILED DESCRIPTION
[0046] The present application will be further described in detail below in conjunction with the accompanying drawings.
[0047] like Figure 1 As shown, the present invention discloses a method for processing injury images for forensic identification, comprising:
[0048] S1, obtaining the image to be identified;
[0049] S2, verifying the image to be identified to determine whether the image to be identified is a vertically shot image, if so, executing step S3, otherwise, returning to executing step S1;
[0050] S3, performing scalar and parameter calculation on the image to be identified;
[0051] S4. Calculate the size of the wound in the image to be identified based on the parameter calculation results.
[0052] Compared with the prior art, the present invention can effectively process the captured images in advance and calculate the size information of the wound in the image to be identified, which is beneficial to the subsequent identification work.
[0053] In a specific implementation, the image to be identified includes a ruler attached to the surface to be identified, and the ruler includes a plurality of color segments (such as Figure 2In step S2, if the ratio of the length to the width of the color segment is within a preset threshold range, the image to be identified is determined to be a vertically shot image.
[0054] In the present invention, the image to be identified can be photographed through an external device on the PC or a mobile phone. In order to ensure the smooth progress of subsequent identification, the staff is required to shoot vertically toward the area to be identified during the shooting process. In the present invention, after shooting an image, it is necessary to first detect the image to determine whether it is a vertically shot image. If not, the image needs to be re-shot. After actual testing, the recognition accuracy of the color segment of the ruler is more than 2 times higher than the scale recognition. Therefore, the present invention uses the color segment as a calculation parameter.
[0055] For images not shot vertically, the color segments in the final image will be morphologically distorted, which directly results in the distortion of the length-to-width ratio of the color segment. Therefore, in the present invention, after a large number of tests, the threshold range of the ratio of the length and width of the color segment is determined. For the image to be identified, if the ratio of the length and width of the color segment is within the preset threshold range, the image to be identified is judged to be a vertically shot image. If the ratio of the length and width of the color segment is not within the preset threshold range or the color segment image cannot be identified, it needs to be re-shot. The threshold range of the mobile phone terminal is set to: [2.1, 2.4], and the threshold range of the PC terminal is set to: [1.75, 2.1].
[0056] In the actual verification process, the image to be identified will include multiple color segments. The color segment closest to the camera is selected as the verification object (the color segment containing the most pixels can be used as the color segment closest to the camera). This is because the closer to the camera, the smaller the impact of distortion is relative to farther places, which is conducive to improving the accuracy of the verification results.
[0057] In a specific implementation, the image to be identified includes a ruler attached to the surface to be identified, and the ruler includes a plurality of color segments arranged along the length direction of the ruler; in step S3, the number of pixels occupied by the color segments in the image to be identified and the coordinates of the minimum circumscribed rectangle corresponding to the color segments are identified as scalars, and the physical size represented by a single pixel in the color segment area in the image to be identified is calculated based on the actual size of the color segments, and the physical size is used as a parameter.
[0058] In this way, the physical size corresponding to each pixel in the image to be identified can be calculated, which is convenient for the subsequent calculation of the real size of the wound in the image to be identified.
[0059] In a specific implementation, when the wound is a linear plane wound, step S4 includes:
[0060] S4001, receiving wound calibration data input by a staff member;
[0061] S4002, drawing the wound on the black image based on the wound calibration data, using a white 1px line during drawing;
[0062] S4003. Calculate the sum of the physical lengths of all white pixels in the black image based on the parameter calculation results, and use it as the length of the linear plane wound.
[0063] In the present invention, whether the wound is a plane or a curved surface is determined by the staff inputting instructions through the interactive interface.
[0064] In a specific implementation, when the wound is a regional plane wound, step S4 includes:
[0065] S4011. Receive wound calibration data input by staff;
[0066] S4012, drawing the wound on the black image based on the wound calibration data, using a white 1px line during drawing;
[0067] S4013. Calculate the sum of the physical areas of all white pixels in the black image based on the parameter calculation results, and use it as the area of the regional plane wound.
[0068] In the present invention, after the staff takes the image, they need to calibrate the image. Specifically, the wound can be drawn using a mouse or a touch screen. If the pattern drawn is a non-closed pattern, it is considered to be a linear wound, and a wound pattern identical to the non-closed pattern is drawn using a 1px white line in the black image; if the pattern drawn is a closed pattern, it is considered to be a regional wound, and a wound pattern identical to the closed pattern is drawn using a 1px white line in the black image, and the closed pattern is filled with white.
[0069] In specific implementation, when the wound is a linear curved wound and / or a regional curved wound, step S3 also includes: calculating the average coordinates and depth ratio of the color segment as a scalar, and calculating the standard depth as a parameter based on the average coordinates and depth ratio of the color segment.
[0070] If the image to be identified is shot on a PC, the PC can directly obtain the depth value (depth ratio) of each pixel using an external device. If the image to be identified is shot on a mobile phone, the depth restoration algorithm can be used to obtain the depth value of each pixel. The specific method is as follows:
[0071] (1) Polar correction
[0072] Since the phone is not completely fixed during the shooting process, the imaging is not in an ideal state, so the images directly used for calculations have a great impact on the accuracy. Therefore, after the phone obtains two images A and B (the camera is controlled by an Android script here, and two images are automatically taken out after shooting once), it is necessary to use mature RANSAC and SIFT algorithms for feature matching (this algorithm is often used in image stitching, restoration, and matching technology), and obtain the rotation matrix and translation matrix between the two images based on the matching results, and then perform the corresponding perspective transformation on image B, so that image B and image A are in the same reference dimension in the imaging, that is, to achieve the purpose of epipolar correction.
[0073] (2) Parallax calculation
[0074] After the image is rectified, the normalized cross correlation (NCC) stereo reconstruction algorithm is used to calculate the disparity of the image.
[0075] After the image epipolar correction, the corresponding points of the two images are on the same horizontal line (i.e., the epipolar line). At this time, the coordinate difference of the corresponding points in each image on the epipolar line is the parallax.
[0076] The principle of the normalized cross correlation (NCC) algorithm: For the two corrected images A and B, NCC creates an n*n window to be matched for a pixel in image A, and constructs an n*n matching window for each pixel on the epipolar line of image B corresponding to A. For each epipolar line, the matching window of A is used to calculate the correlation with all matching windows of B, and the one with the highest correlation is regarded as the optimal matching result. The formula is:
[0077]
[0078] x is the pixel coordinate in the matching window, u1 and u2 are the pixel to be matched and the matching pixel respectively.
[0079] (3) Calculation depth
[0080] After getting the parallax d i,j Finally, the binocular ranging principle is used to calculate the depth ratio (because the configuration parameters of the camera cannot be obtained, the specific value cannot be calculated, and the ratio can only be calculated by calculating the formula to bypass the corresponding parameters)
[0081] The principle of binocular ranging is as follows Figure 3 shown.
[0082] The corresponding derivation is as follows:
[0083]
[0084]
[0085] f·x·xr=f·x·xl-f·b·xl
[0086] f·x·Δx=f·b·xl
[0087] x·Δx=b·xl
[0088]
[0089]
[0090]
[0091] Where f is the focal length of the camera, b is the center distance between the left and right cameras, x is the x-coordinate value of any point p, xl is the left disparity of point p, xr is the right disparity of point p, Δx is the disparity, the coordinates of p are expressed as (x, y, z), z is the distance from point p to the camera (i.e., depth), x, y are the horizontal and vertical coordinates of the plane where p is located (the plane is parallel to the plane formed by the left and right cameras and the vertical normal).
[0092] It is known that Δx=xr-xl, and f and b are fixed values.
[0093] Therefore, for corresponding points p1(x1,z1) and p2(x2,z2),
[0094] By deduction, we can get the depth ratio of each pixel without f and b. The first pixel of each image is set to 1, and the depth ratios of other pixels are calculated with reference to the first pixel. Finally, the depth ratio of the entire image is obtained.
[0095] In a specific implementation, when the wound is a linear curved wound, step S4 includes:
[0096] S4021. Receive wound calibration data input by a staff member;
[0097] S4022, drawing the wound on the black image based on the wound calibration data, using a white 1px line during drawing;
[0098] S4023, normalizing the white area in the black image using the standard depth;
[0099] S4024. Calculate the sum of the physical lengths of all white pixels in the normalized black image based on the parameter calculation result, and use it as the length of the linear surface wound.
[0100] In a specific implementation, when the wound is a regional curved wound, step S4 includes:
[0101] S4031. Receive wound calibration data input by a staff member;
[0102] S4032, drawing the wound on the black image based on the wound calibration data, using a white 1px line during drawing;
[0103] S4033, normalizing the white area in the black image using the standard depth;
[0104] S4034. Calculate the sum of the physical areas of all white pixels in the normalized black image based on the parameter calculation result, and use it as the area of the regional surface wound.
[0105] In a specific implementation, when the target to be identified in the image to be identified is part of a symmetrical structure and part of the target to be identified is missing, the injury image processing method for forensic identification further includes:
[0106] S501, taking an image of a symmetrical target corresponding to the target to be identified as a comparison image;
[0107] S502, extracting y, cr, br channel images using YUV color space for the identification image and the comparison image;
[0108] S503, reducing noise and smoothing the image of the cr channel by Gaussian filtering;
[0109] S504, using OTSU algorithm to calculate the cr channel image threshold;
[0110] S505, binarizing the image to be identified and the image to be compared respectively according to the image threshold value;
[0111] S506: Calculate the physical area corresponding to the area difference of the binary image using the parameter calculation result, and use it as the area of the missing part.
[0112] In the process of forensic identification, it may happen that part of the identification target is missing, such as missing fingers on the left hand. In this case, an image of the entire palm of the right hand can be taken as a comparison image (the shooting angle and shooting area of the comparison image must be consistent with the shooting angle and shooting area of the image to be identified). Then, the method disclosed in the present invention can be used to calculate the size of the missing part, so that the staff can use the calculated results to restore and model the missing part.
[0113] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application and are not limiting. Although the present application has been described by referring to the preferred embodiments of the present application, those skilled in the art should understand that various changes can be made in form and details without departing from the spirit and scope of the present application as defined in the appended claims.
Claims
1. A method for processing injury images for forensic identification, characterized in that: include: S1, obtaining the image to be identified; S2, verifying the image to be identified to determine whether the image to be identified is a vertically shot image, if so, executing step S3, otherwise, returning to executing step S1; S3, performing scalar and parameter calculation on the image to be identified; The image to be identified includes a ruler attached to the surface to be identified, and the ruler includes a plurality of color segments arranged along the length direction of the ruler; in step S3, the number of pixels occupied by the color segments in the image to be identified and the coordinates of the minimum circumscribed rectangle corresponding to the color segments are identified as scalars, and the physical size represented by a single pixel in the color segment area in the image to be identified is calculated based on the actual size of the color segments, and the physical size is used as a parameter; S4, calculating the size of the wound in the image to be identified based on the parameter calculation result; wherein, by receiving the wound calibration data input by the staff, drawing the wound on the black image based on the wound calibration data, using white 1px lines when drawing, and then calculating the size of the wound in the image to be identified; When the wound is a linear curved wound and / or a regional curved wound, step S3 further includes: calculating the average coordinates and depth ratio of the color segments as scalars, and calculating the standard depth as a parameter based on the average coordinates and depth ratio of the color segments; If the image to be identified is taken by a mobile phone, the depth restoration algorithm is used to obtain the depth value of each pixel. The specific method is as follows: (1) Epipolar correction: After the mobile phone acquires two images A and B, it performs feature matching. Based on the matching results, it obtains the rotation matrix and translation matrix between the two images. Then, it performs the corresponding perspective transformation on image B so that image B and image A are in the same reference dimension during imaging. (2) Disparity calculation: After the image is rectified, the normalized cross-correlation stereo reconstruction algorithm is used to calculate the disparity of the image. For the two rectified images A and B, the normalized cross-correlation stereo reconstruction algorithm creates an n*n window to be matched for a pixel of image A, and constructs an n*n matching window for each pixel on the epipolar line of image B corresponding to image A. For each epipolar line, the matching window of image A is used to calculate the correlation with all matching windows of image B. The one with the highest correlation is regarded as the optimal matching result. The correlation calculation formula is: x is the pixel coordinate in the matching window, u1 and u2 are the pixel to be matched and the matching pixel respectively; (3) Calculate depth: After obtaining the disparity d i,j Finally, the binocular ranging principle is used to calculate the depth ratio.
2. The injury image processing method for forensic identification according to claim 1, characterized in that: In step S2, if the ratio of the length to the width of the color segment is within a preset threshold range, the image to be identified is determined to be a vertically shot image.
3. The injury image processing method for forensic identification according to claim 1, characterized in that: When the wound is a linear plane wound, step S4 includes: S4001, receiving wound calibration data input by a staff member; S4002, drawing the wound on the black image based on the wound calibration data, using a white 1px line during drawing; S4003. Calculate the sum of the physical lengths of all white pixels in the black image based on the parameter calculation results, and use it as the length of the linear plane wound.
4. The injury image processing method for forensic identification according to claim 1, characterized in that: When the wound is a regional plane wound, step S4 includes: S4011. Receive wound calibration data input by staff; S4012, drawing the wound on the black image based on the wound calibration data, using a white 1px line during drawing; S4013. Calculate the sum of the physical areas of all white pixels in the black image based on the parameter calculation results, and use it as the area of the regional plane wound.
5. The injury image processing method for forensic identification according to claim 1, characterized in that: When the wound is a linear curved wound, step S4 includes: S4021. Receive wound calibration data input by a staff member; S4022, drawing the wound on the black image based on the wound calibration data, using a white 1px line during drawing; S4023, normalizing the white area in the black image using the standard depth; S4024. Calculate the sum of the physical lengths of all white pixels in the normalized black image based on the parameter calculation result, and use it as the length of the linear surface wound.
6. The injury image processing method for forensic identification according to claim 1, characterized in that: When the wound is a regional curved wound, step S4 includes: S4031. Receive wound calibration data input by a staff member; S4032, drawing the wound on the black image based on the wound calibration data, using a white 1px line during drawing; S4033, normalizing the white area in the black image using the standard depth; S4034. Calculate the sum of the physical areas of all white pixels in the normalized black image based on the parameter calculation result, and use it as the area of the regional surface wound.
7. The injury image processing method for forensic identification according to claim 1, characterized in that: When the target to be identified in the image to be identified is part of a symmetrical structure and part of the target to be identified is missing, the injury image processing method for forensic identification further includes: S501, taking an image of a symmetrical target corresponding to the target to be identified as a comparison image; S502, extracting y, cr, br channel images using YUV color space for the identification image and the comparison image; S503, reducing noise and smoothing the image of the cr channel by Gaussian filtering; S504, using OTSU algorithm to calculate the cr channel image threshold; S505, binarizing the image to be identified and the image to be compared respectively according to the image threshold value; S506: Calculate the physical area corresponding to the area difference of the binary image using the parameter calculation result, and use it as the area of the missing part.
