Teaching quality evaluation method based on head temperature variation
By preprocessing and image segmentation of visible light images, screening and transforming the head area to the infrared coordinate system, and counting the average gray value change, the problem of inaccurate head temperature change evaluation in the prior art is solved, and a more accurate teaching quality evaluation is achieved.
Patent Information
- Application Number
- CN202510266763.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-07
- Publication Date
- 2025-06-20
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
When evaluating teaching quality, it is difficult to accurately extract areas with large temperature changes in the human head, resulting in a decrease in the temperature change and affecting the accuracy of the evaluation.
By obtaining visible light images, preprocessing and image segmentation, the head area is filtered out, and transformed to an infrared coordinate system, and the average gray value change in the head area is counted to evaluate the teaching quality.
This method can effectively extract areas with large changes in the head temperature, improving the accuracy and reliability of teaching quality evaluation.
Smart Images

Figure CN120182998A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of data classification, and in particular, to a teaching quality evaluation method based on the change amount of head temperature. Background Art
[0002] In a teaching scenario, the same student studies different courses, and multiple students study the same course with different degrees of concentration. The temperature change of a student's head can reflect the student's concentration during learning, so as to evaluate the teaching quality.
[0003] An infrared image is an image formed by acquiring infrared radiation in a scene, and the infrared image can reflect the temperature change of an object. The prior art is to use an infrared camera to take pictures of students, count the gray values of the entire body of the students in the infrared image, and then convert the gray values into human body temperatures. However, since the temperature changes of different parts of the human body are different within the same time interval, calculating the average temperature of the entire human body will calculate the average value of the human body areas with large temperature changes and the human body areas with small temperature changes, thereby reducing the temperature change amplitude of one or several human body areas.
[0004] Therefore, a method is needed that can extract the human body area with large temperature changes and evaluate the teaching quality according to the human body area with large temperature changes. Summary of the Invention
[0005] To overcome the problems existing in the related art, the purpose of the present invention is to provide a teaching quality evaluation method based on the change amount of head temperature, which can extract the human body area with large temperature changes and evaluate the teaching quality according to the human body area with large temperature changes.
[0006] A teaching quality evaluation method based on the change amount of head temperature includes:
[0007] Obtain a visible light image, preprocess the visible light image to obtain a preprocessed visible light image;
[0008] Perform image segmentation on the preprocessed visible light image to obtain K segmentation regions;
[0009] Screen out the first head region from the K segmentation regions;
[0010] Transform the first head region from the visible light coordinate system to the infrared coordinate system to obtain a second head region;
[0011] At time T, count the average gray value of the second head region to obtain the average gray value at time T;
[0012] At time T + t, count the average gray value of the second head region to obtain the average gray value at time T + t;
[0013] Determine the head temperature change amount according to the average gray value change amount from the average gray value at time T to the average gray value at time T+t;
[0014] Evaluate the teaching quality according to the head temperature change amount.
[0015] In a preferred technical solution of the present invention, the image segmentation of the preprocessed visible light image to obtain K segmentation regions includes:
[0016] Perform image reconstruction on the preprocessed visible light image to obtain a reconstructed image;
[0017] Perform image segmentation on the reconstructed image to obtain K segmentation regions.
[0018] In a preferred technical solution of the present invention, the performing image reconstruction on the preprocessed visible light image to obtain a reconstructed image includes:
[0019] Perform upsampling on the preprocessed visible light image to obtain an upsampled image;
[0020] Perform downsampling on the preprocessed visible light image to obtain a downsampled image;
[0021] Perform adaptive low-pass filtering on the upsampled image to obtain a low-pass filtered image;
[0022] Perform adaptive high-pass filtering on the downsampled image to obtain a high-pass filtered image;
[0023] Add the low-pass filtered image and the high-pass filtered image to obtain a reconstructed image.
[0024] In a preferred technical solution of the present invention, the performing image segmentation on the reconstructed image to obtain K segmentation regions includes:
[0025] Calculate the light intensity distribution of the reconstructed image using the following formula:
[0026] H(i) = γ * A(i) * k(i) + B(i) * (1 - k(i));
[0027] Where, H(i) is the light intensity of the i-th pixel point of the reconstructed image, A(i) is the long-distance light intensity emitted by the distant light source to the i-th pixel point of the reconstructed image, B(i) is the short-distance light intensity emitted by the near light source to the i-th pixel point of the reconstructed image, γ is the attenuation factor, the value of the attenuation factor is negatively correlated with the distance between the distant light source and the i-th pixel point of the reconstructed image, and k(i) is the transmittance corresponding to the i-th pixel point of the reconstructed image;
[0028] Randomly select K seed points, and perform image segmentation on the basis of the light intensity distribution of the reconstructed image by using the region growing method to obtain K segmented regions.
[0029] In a preferred technical solution of the present invention, the adaptive low-pass filtering of the upsampled image to obtain a low-pass filtered image includes:
[0030] Input N test upsampled images into an adaptive low-pass filter to obtain N low-pass filtered output images;
[0031] According to the difference between each low-pass filtered output image and the corresponding test upsampled image, adjust the parameters of the adaptive low-pass filter until the parameters of the adaptive low-pass filter converge;
[0032] Input the upsampled image into the adaptive low-pass filter for adaptive low-pass filtering to obtain a low-pass filtered image.
[0033] In a preferred technical solution of the present invention, the screening of the first head region from the K segmented regions includes:
[0034] Select a pixel point as a test point in each segmented region;
[0035] Select a first focus and a second focus;
[0036] Construct an elliptic curve according to the first focus, the second focus and the test point;
[0037] Add the distance from the test point to the first focus and the distance from the test point to the second focus to obtain a test distance; add the error value to the test distance to obtain a distance threshold;
[0038] Calculate the sum of the distances from the edge points of each segmented region to the first focus and the second focus;
[0039] Count the number of edge points in each segmented region that meet the condition that the sum of the distances is less than or equal to the distance threshold to obtain K optimized edge point sets; each optimized edge point set includes multiple optimized edge points;
[0040] Select the optimized edge point set with the largest number of optimized edge points from the K optimized edge point sets to obtain a target edge point set;
[0041] Connect all the optimized edge points in the target edge point set end to end to obtain the first head region.
[0042] In a preferred technical solution of the present invention, the transformation of the first head region from the visible light coordinate system to the infrared coordinate system to obtain a second head region includes:
[0043] Transforming the first head region from the visible light pixel coordinate system to the visible light image coordinate system to obtain a third head region;
[0044] Transforming the third head region from the visible light image coordinate system to the visible light camera coordinate system to obtain a fourth head region;
[0045] Transforming the fourth head region from the visible light camera coordinate system to the world coordinate system to obtain a real head region;
[0046] Transforming the real head region to the infrared camera coordinate system to obtain a fifth head region;
[0047] Transforming the fifth head region to the infrared image coordinate system to obtain a sixth head region;
[0048] Transforming the sixth head region to the infrared pixel coordinate system to obtain a second head region.
[0049] In a preferred technical solution of the present invention, the determination of the head temperature change amount according to the average gray value change amount from the average gray value at time T to the average gray value at time T + t includes:
[0050] Subtracting the average gray value at time T from the average gray value at time T + t to obtain the average gray value change amount;
[0051] According to the following formula, calculating the head temperature change amount by means of non-linear transformation:
[0052]
[0053] where ΔT is the head temperature change amount, c is the first non-linear mapping parameter, d is the second non-linear mapping parameter, and ΔG is the average gray value change amount.
[0054] In a preferred technical solution of the present invention, the evaluation of the teaching quality according to the head temperature change amount includes:
[0055] If there is one course in the teaching scenario from time T to time T + t, then count the head temperature change amounts of all students in the teaching scenario from time T to time T + t;
[0056] Classify the teaching qualities of all students according to the head temperature change amounts of all students;
[0057] If there are multiple courses in the teaching scene from time T to time T+t, the head temperature change of a single student in the teaching scene from time T to time T+t is counted;
[0058] The teaching quality of individual students is classified according to the change in head temperature of the individual students.
[0059] In a preferred technical solution of the present invention, the preprocessing of the visible light image to obtain the preprocessed visible light image includes:
[0060] Performing guided filtering on the visible light image to obtain a filtered image;
[0061] Adaptive histogram equalization is performed on the filtered image to obtain a preprocessed visible light image.
[0062] The beneficial effects of the present invention are:
[0063] The teaching quality evaluation method based on the head temperature change provided by the present invention includes acquiring a visible light image, preprocessing the visible light image, and obtaining a preprocessed visible light image. The preprocessed visible light image is segmented to obtain K segmented areas. The visible light image has a high image resolution, and the preprocessing can remove the noise in the visible light image and improve the contrast of the visible light image. The preprocessed visible light image is segmented into K segmented areas by using an image segmentation algorithm, such as a head area, a shoulder area, an arm area, and a leg area. A first head area is screened out from the K segmented areas, and the first head area is located in a visible light coordinate system. Since the positions of the visible light camera and the infrared camera in the three-dimensional space are different, and the angles of the human body are also different, the first head area is transformed from the visible light coordinate system to the infrared coordinate system to obtain a second head area. The second head area can reflect the human head area in the infrared coordinate system, and the higher the temperature value of the human head area, the greater the average grayscale value of the second head area. The average grayscale value of the second head area is counted at time T to obtain the average grayscale value at time T. At time T+t, the average grayscale value of the second head area is counted to obtain the average grayscale value at time T+t. The difference between the average grayscale value at time T+t and the average grayscale value at time T is calculated, and the head temperature change is determined according to the average grayscale value change from the average grayscale value at time T to the average grayscale value at time T+t, and the teaching quality is evaluated according to the head temperature change. The present invention uses visible light images to accurately screen out the head area of the human body, and the average grayscale value of the second head area obtained based on the transformation of the first head area changes more obviously, thereby highlighting the head temperature change of the human body, thereby evaluating the teaching quality according to the second head area with a larger temperature change. BRIEF DESCRIPTION OF THE DRAWINGS
[0064] Figure 1It is a flowchart of the teaching quality evaluation method based on the head temperature change amount of the present invention;
[0065] Figure 2 It is a flowchart of image reconstruction for the preprocessed visible light image of the present invention;
[0066] Figure 3 It is a flowchart of screening out the first head region from K segmented regions of the present invention. Detailed implementation manners
[0067] The preferred embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. Although the preferred embodiments of the present invention are shown in the drawings, it should be understood that the present invention can be implemented in various forms and should not be limited by the embodiments set forth herein. On the contrary, these embodiments are provided to make the present invention more thorough and complete, and to fully convey the scope of the present invention to those skilled in the art.
[0068] Example 1
[0069] As Figure 1 shown, this embodiment provides a teaching quality evaluation method based on the head temperature change amount, including:
[0070] S1: Obtain a visible light image, preprocess the visible light image to obtain a preprocessed visible light image.
[0071] S2: Perform image segmentation on the preprocessed visible light image to obtain K segmented regions.
[0072] S3: Screen out the first head region from the K segmented regions.
[0073] S4: Transform the first head region from the visible light coordinate system to the infrared coordinate system to obtain a second head region.
[0074] S5: Statistically calculate the average gray value of the second head region at time T to obtain the average gray value at time T.
[0075] S6: Statistically calculate the average gray value of the second head region at time T + t to obtain the average gray value at time T + t.
[0076] S7: Determine the head temperature change amount according to the average gray value change amount from the average gray value at time T to the average gray value at time T + t.
[0077] S8: Evaluate the teaching quality according to the head temperature change amount.
[0078] The visible light camera and the infrared camera are both connected to the single-chip microcomputer by wires. In steps S1 - S6, data is collected by the visible light camera and the infrared camera and sent to the single-chip microcomputer. The single-chip microcomputer performs calculations based on the data collected by the visible light camera and the infrared camera to obtain the average gray value at time T and the average gray value at time T + t. The single-chip microcomputer sends the data to the server through the wireless communication module, and steps S7 - S8 are executed by the server.
[0079] Performing image segmentation on the preprocessed visible light image to obtain K segmentation regions, including:
[0080] S21: Performing image reconstruction on the preprocessed visible light image to obtain a reconstructed image.
[0081] S22: Performing image segmentation on the reconstructed image to obtain K segmentation regions.
[0082] By using the method of image reconstruction, the edge part and detail part in the preprocessed visible light image can be highlighted to obtain a reconstructed image. The reconstructed image includes multiple human body regions, such as the head region, shoulder region, arm region, and leg region. Performing image segmentation on the reconstructed image to obtain K segmentation regions, and then screening out the head region from the K segmentation regions.
[0083] As Figure 2 shown, performing image reconstruction on the preprocessed visible light image to obtain a reconstructed image, including:
[0084] S211: Performing upsampling on the preprocessed visible light image to obtain an upsampled image.
[0085] S212: Performing downsampling on the preprocessed visible light image to obtain a downsampled image.
[0086] S213: Performing adaptive low-pass filtering on the upsampled image to obtain a low-pass filtered image.
[0087] S214: Performing adaptive high-pass filtering on the downsampled image to obtain a high-pass filtered image.
[0088] S215: Adding the low-pass filtered image and the high-pass filtered image to obtain a reconstructed image.
[0089] Upsampling uses the interpolation method. Based on the pixel points of the preprocessed visible light image, appropriate interpolation algorithms are used to insert new pixel points between the pixel points. If the size of the preprocessed visible light image is weight*height, and the preprocessed visible light image is downsampled by a factor of s, then the size of the downsampled image obtained is (weight / s)*(height / s), where s is the greatest common divisor of weight and height. The preprocessed visible light image is in matrix form. The image area within an s*s window in the preprocessed visible light image is changed into a single pixel point, and the value of this pixel point is the average of the pixel values of all the pixel points within the s*s window.
[0090] The size of the upsampled image is larger than that of the preprocessed visible light image. Performing adaptive low-pass filtering on the upsampled image can better reflect the overall contour of the image and retain areas with less change in the human body, filtering out background interference with faster changes. The size of the downsampled image is smaller than that of the preprocessed visible light image. Performing adaptive high-pass filtering on the downsampled image can better highlight the edges and details of the image and retain areas with greater change in the human body. Adding the low-pass filtered image and the high-pass filtered image can better retain the edges and details of the human body while retaining the overall contour and internal areas of the human body, obtaining the reconstructed image.
[0091] Performing adaptive low-pass filtering on the upsampled image to obtain a low-pass filtered image includes:
[0092] S2131: Input N test upsampled images into the adaptive low-pass filter to obtain N low-pass filtered output images.
[0093] S2132: Adjust the parameters of the adaptive low-pass filter according to the difference between each low-pass filtered output image and the corresponding test upsampled image until the parameters of the adaptive low-pass filter converge.
[0094] S2133: Input the upsampled image into the adaptive low-pass filter for adaptive low-pass filtering to obtain a low-pass filtered image.
[0095] An adaptive low-pass filter can adaptively select the cut-off frequency of the filter according to the spectral characteristics of the signal, thereby more effectively removing high-frequency noise. The adaptive low-pass filter includes three working steps: (1) Noise estimation. A sliding window is used to select a continuous segment of the signal as a reference to estimate the power spectral density of the signal. (2) Adjusting the filter coefficients. According to the noise estimation result, the least mean square error algorithm is used to adjust the coefficients of the adaptive low-pass filter based on the error between the input and output of the adaptive low-pass filter to minimize the error. (3) Filtering operation. The upsampled image is input into the adaptive low-pass filter, and the cut-off frequency of the adaptive low-pass filter is adaptively adjusted according to the spectral characteristics of the input signal, thereby removing the high-frequency components in the upsampled image to obtain a low-pass filtered image.
[0096] Performing adaptive high-pass filtering on the downsampled image to obtain a high-pass filtered image, including:
[0097] S2141: Input N test downsampled images into the adaptive high-pass filter to obtain N high-pass filtered output images.
[0098] S2142: Adjust the parameters of the adaptive high-pass filter according to the difference between each high-pass filtered output image and the corresponding test downsampled image until the parameters of the adaptive high-pass filter converge.
[0099] S2143: Input the downsampled image into the adaptive high-pass filter for adaptive high-pass filtering to obtain a high-pass filtered image.
[0100] The teaching quality assessment method based on the head temperature change provided in this embodiment includes acquiring a visible light image, preprocessing the visible light image, and obtaining a preprocessed visible light image. The preprocessed visible light image is segmented to obtain K segmented areas. The visible light image has a high image resolution, and the preprocessing can remove the noise in the visible light image and improve the contrast of the visible light image. The preprocessed visible light image is segmented into K segmented areas by using an image segmentation algorithm, such as a head area, a shoulder area, an arm area, and a leg area. A first head area is screened out from the K segmented areas, and the first head area is located in a visible light coordinate system. Since the positions of the visible light camera and the infrared camera in the three-dimensional space are different, and the angles of the human body are also different, the first head area is transformed from the visible light coordinate system to the infrared coordinate system to obtain a second head area. The second head area can reflect the human head area in the infrared coordinate system. The higher the temperature value of the human head area, the greater the average grayscale value of the second head area. The average grayscale value of the second head area is counted at time T to obtain the average grayscale value at time T. At time T+t, the average grayscale value of the second head area is counted to obtain the average grayscale value at time T+t. The difference between the average grayscale value at time T+t and the average grayscale value at time T is calculated, and the head temperature change is determined according to the average grayscale value change from the average grayscale value at time T to the average grayscale value at time T+t, and the teaching quality is evaluated according to the head temperature change. The present invention uses visible light images to accurately screen out the head area of the human body, and the average grayscale value of the second head area obtained based on the transformation of the first head area changes more obviously, thereby highlighting the head temperature change of the human body, thereby evaluating the teaching quality according to the second head area with a larger temperature change.
[0101] Example 2
[0102] This embodiment provides a teaching quality assessment method based on the head temperature change. This embodiment only describes the differences from Embodiment 1. The reconstructed image is segmented to obtain K segmented regions, including:
[0103] The light intensity distribution of the reconstructed image is calculated using the following formula:
[0104] H(i)=γ*A(i)*k(i)+B(i)*(1-k(i));
[0105] Wherein, H(i) is the light intensity of the i-th pixel of the reconstructed image, A(i) is the long-distance light intensity emitted by the distant light source to the i-th pixel of the reconstructed image, B(i) is the short-distance light intensity emitted by the near light source to the i-th pixel of the reconstructed image, γ is the attenuation factor, and the value of the attenuation factor is negatively correlated with the distance between the distant light source and the i-th pixel of the reconstructed image, that is, the greater the distance between the distant light source and the i-th pixel of the reconstructed image, the smaller the value of the attenuation factor, and k(i) is the transmittance corresponding to the i-th pixel of the reconstructed image;
[0106] Randomly select K seed points, and perform image segmentation on the basis of the light intensity distribution of the reconstructed image by using the region growing method to obtain K segmentation regions.
[0107] The scene of the reconstructed image is students studying in a learning place, and the reconstructed image has a certain brightness. The distant light source and the near light source emit light respectively, and the light propagates towards the learning place. Since there is air in the learning place, reflection and transmission will occur when the light passes through the air. In this embodiment, it is taken as an example that the light emitted by the distant light source propagates to the human body only undergoes transmission, and there is attenuation in the transmission, and the light emitted by the near light source propagates to the human body only undergoes reflection.
[0108] Since the air distribution near the human body in the teaching scene is fixed and unchanged, this embodiment uses a fixed attenuation factor to calculate the influence of the distant light source on the light intensity distribution of the reconstructed image. Multiply the attenuation factor by the long-distance light intensity emitted by the distant light source to the i-th pixel and the transmittance k(i) corresponding to the i-th pixel of the reconstructed image to obtain the influence of the distant light source on the light intensity of the i-th pixel in the reconstructed image. Multiply the short-distance light intensity emitted by the near light source to the i-th pixel by the reflectivity 1-k(i) corresponding to the i-th pixel of the reconstructed image to obtain the influence of the near light source on the light intensity distribution of the reconstructed image. Add the light intensity generated by the distant light source and the light intensity generated by the near light source to obtain the light intensity of the i-th pixel of the reconstructed image.
[0109] Preferably, multiply γ*A(i)*k(i) by the first light intensity distribution weight α, and multiply B(i)*(1-k(i)) by the second light intensity distribution weight β, and the sum of the first light intensity distribution weight α and the second light intensity distribution weight β is 1. When the distant light source has a greater influence on the students in the teaching scene, for example, the brightness of the lamp on the ceiling of the classroom is greater, increase the first light intensity distribution weight and decrease the second light intensity distribution weight; when the near light source has a greater influence on the students in the teaching scene, for example, when the students are using the computer in the computer room and the brightness of the computer screen is greater, decrease the first light intensity distribution weight and increase the second light intensity distribution weight.
[0110] Such as Figure 3As shown, screening out the first head region from the K segmentation regions includes:
[0111] S31: Select a pixel point as a test point in each of the segmentation regions.
[0112] S32: Select a first focus and a second focus.
[0113] S33: Construct an elliptic curve based on the first focus, the second focus, and the test point.
[0114] S34: Add the distance from the test point to the first focus and the distance from the test point to the second focus to obtain a test distance; add the error value to the test distance to obtain a distance threshold.
[0115] S35: Calculate the sum of the distances from the edge points of each segmentation region to the first focus and the second focus.
[0116] S36: Count the number of edge points in each segmentation region that meet the condition that the sum of the distances is less than or equal to the distance threshold to obtain K optimized edge point sets; each optimized edge point set includes multiple optimized edge points.
[0117] S37: Screen out the optimized edge point set with the largest number of optimized edge points from the K optimized edge point sets to obtain a target edge point set.
[0118] S38: Connect all the optimized edge points in the target edge point set end to end to obtain the first head region.
[0119] The distance between the first focus and the second focus is equal to twice the focal length of the elliptic curve, and the focal length of the elliptic curve is r. The test point is a point on the elliptic curve, and the elliptic curve can be determined by combining the first focus, the second focus, and the test point. The distance from the test point to the first focus is r1, and the distance from the test point to the second focus is r2, and r1 + r2 is equal to the major axis of the elliptic curve. When the test distance is fixed, the smaller the error value, the smaller the distance threshold, the stricter the process of screening optimized edge points, and the closer the obtained first head region is to an ellipse.
[0120] The K optimized edge point sets correspond to K regions of the human body, and the optimized edge point set with the largest number of optimized edge points is used as the target edge point set. The target edge point set contains P optimized edge points. Connect the P optimized edge points end to end to obtain the first head region, and the contour of the first head region is an ellipse.
[0121] Combining the first focus, the second focus, and the test point, an elliptic curve can be accurately constructed. In this embodiment, the error value can also be adjusted as needed. If the requirement for the student's head to be elliptical is relatively strict, a smaller error value is adopted; if the requirement for the student's head to be elliptical is not strict, a larger error value is adopted.
[0122] Preprocessing the visible light image to obtain a preprocessed visible light image includes:
[0123] S12: Performing guided filtering on the visible light image to obtain a filtered image;
[0124] S13: Performing adaptive histogram equalization on the filtered image to obtain a preprocessed visible light image.
[0125] Before step S12, step S11 is also included: Obtaining a visible light image. The advantages of guided filtering include: (1) High computational efficiency. The time complexity of guided filtering is related to pixels and independent of the size of the mask window. (2) Strong ability to preserve edge details. Guided filtering can effectively avoid the common gradient inversion problem in bilateral filtering.
[0126] This embodiment combines the light propagation of a distant light source and a near light source to measure the light intensity of pixel points. For the light rays emitted by the distant light source, there will be transmission and attenuation; for the light rays emitted by the near light source, there will be reflection. A(i) is the long-distance light intensity emitted by the distant light source to the i-th pixel point, and γ*A(i)*k(i) represents the light intensity generated by the light rays emitted by the distant light source after attenuation and transmission, irradiating the student and generating at the i-th pixel point in the reconstructed image. B(i) is the short-distance light intensity emitted by the near light source to the i-th pixel point, and B(i)*(1 - k(i)) represents the light intensity generated by the light rays emitted by the near light source after reflection, irradiating the student and generating at the i-th pixel point in the reconstructed image. Randomly select K seed points, and perform image segmentation on the basis of the light intensity distribution of the reconstructed image using the region growing method to obtain K segmented regions. Since the reflectivity of different parts of the human body to light is different, for example, the head has hair and the reflectivity to light is different from that of the back of the hand not covered by clothing. Therefore, performing image segmentation on the reconstructed image based on the light intensity distribution can distinguish different human body parts.
[0127] Embodiment 3
[0128] This embodiment provides a teaching quality evaluation method based on the change amount of head temperature. This embodiment only describes the differences from Embodiment 1. Transforming the first head region from the visible light coordinate system to the infrared coordinate system to obtain a second head region includes:
[0129] S41: Transform the first head region from the visible light pixel coordinate system to the visible light image coordinate system to obtain a third head region.
[0130] S42: Transform the third head region from the visible light image coordinate system to the visible light camera coordinate system to obtain a fourth head region.
[0131] S43: Transform the fourth head region from the visible light camera coordinate system to the world coordinate system to obtain a true head region.
[0132] S44: Transform the true head region to the infrared camera coordinate system to obtain a fifth head region.
[0133] S45: Transform the fifth head region to the infrared image coordinate system to obtain a sixth head region.
[0134] S46: Transform the sixth head region to the infrared pixel coordinate system to obtain a second head region.
[0135] First, inversely transform the first head region to the visible light image coordinate system and the visible light camera coordinate system in sequence to obtain a fourth head region, and then inversely transform the fourth head region from the visible light camera coordinate system to the world coordinate system to obtain a true head region. Transform the true head region to the infrared camera coordinate system, the infrared image coordinate system, and the infrared pixel coordinate system in sequence to obtain a second head region, that is, the region of the student's head in the infrared pixel coordinate system.
[0136] Since the visible light camera and the infrared camera are set at different positions in the teaching scenario, that is, their three-dimensional coordinates are different, first use the method of multiple inverse transformations to find the true head region in the world coordinate system, and then use the method of multiple transformations to find the second head region of the true head region in the infrared pixel coordinate system.
[0137] The determination of the head temperature change amount according to the average gray value change amount from the average gray value at time T to the average gray value at time T + t includes:
[0138] Subtract the average gray value at time T from the average gray value at time T + t to obtain the average gray value change amount;
[0139] According to the following formula, use the method of non-linear transformation to calculate the head temperature change amount:
[0140]
[0141] Among them, ΔT is the head temperature change amount, c is the first non-linear mapping parameter, d is the second non-linear mapping parameter, and ΔG is the average gray value change amount.
[0142] The non - linear transformation of the present invention uses a sigmoid curve function to describe the non - linear relationship between the change in head temperature and the change in the average gray - scale value of the head region. The sigmoid curve is approximately linear in the middle section, i.e., the region where the change in the average gray - scale value is moderate, and is gentle at both ends. That is, the sigmoid curve changes relatively slowly in the regions where the change in the average gray - scale value is small and large, which can eliminate the influence on the change in head temperature when the outside disturbance causes a small change in the average gray - scale value.
[0143] When the average gray - scale value changes greatly, since the temperature of the human head is not too high and the change in head temperature is within a certain range, the change in the average gray - scale value from time T to time T + t is within a certain range.
[0144] Evaluating the teaching quality according to the change in head temperature includes:
[0145] S81: If there is one course in the teaching scenario from time T to time T + t, then count the change in head temperature of all students in the teaching scenario from time T to time T + t.
[0146] S82: Classify the teaching quality of all students according to the change in head temperature of all students.
[0147] S83: If there are multiple courses in the teaching scenario from time T to time T + t, then count the change in head temperature of a single student in the teaching scenario from time T to time T + t.
[0148] S84: Classify the teaching quality of a single student according to the change in head temperature of the single student.
[0149] As an example, for the same course, if the total number of students in the teaching scenario, such as in a classroom, is 40, and the change in head temperature of 35 students is greater than or equal to the first temperature change threshold, while the change in head temperature of the other 5 students is less than the first temperature change threshold, then the learning enthusiasm of these 5 students is poor, and the learning enthusiasm of the other 35 students is good. Therefore, it is determined that the teaching quality is good, and generally, the students' recognition of the teacher teaching this course is relatively high.
[0150] If from time T to time T + t, the course changes from course one to course two, and the change in head temperature of the first student is greater than or equal to the second temperature change threshold, then it is determined that the learning enthusiasm of this student is good, and therefore, it is determined that the teaching quality is good, and this student does not have the problem of partial subject; if the change in head temperature of the first student is less than the second temperature change threshold, then it is determined that the learning enthusiasm of this student is poor, and therefore, it is determined that the teaching quality is poor, and this student has the problem of partial subject.
[0151] In this embodiment, an S-shaped curve is used to convert the change in the average gray value with a time interval of t into the change in the head temperature, which can eliminate the excessively small change in the average gray value caused by external disturbances, improve the robustness of the algorithm, and prevent the average gray value from changing greatly, avoiding mapping the change in the average gray value to an excessively large change in the head temperature, thereby ensuring that the change in the head temperature is within a certain range.
[0152] Embodiment 4
[0153] In an embodiment of the present application, a computer device is further provided. The computer device may be a server. Among them, the computer device includes a processor, a memory, a network interface, and a database connected through a system bus. The processor of the computer design is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The network interface of the computer device is used to communicate with an external terminal through a network connection.
[0154] This embodiment further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, it implements the teaching quality evaluation method based on the change in the head temperature described in any one of Embodiments 1-3. It can be understood that the computer-readable storage medium in this embodiment can be a volatile readable storage medium or a non-volatile readable storage medium.
[0155] It should be noted that in this article, the terms "include", "comprise" or any other variant thereof are intended to cover non-exclusive inclusion, so that a process, device, article or method including a series of elements not only includes those elements, but also includes other elements not expressly listed, or further includes elements inherent to such process, device, article or method. Without further limitation, an element defined by the statement "including one..." does not exclude the existence of additional identical elements in the process, device, article or method including that element.
[0156] The above are only the preferred embodiments of the present application, and do not limit the patent scope of the present application. Any equivalent structure or equivalent process transformation made using the specification and drawings of the present application, or directly or indirectly applied in other related technical fields, shall be equally included in the patent protection scope of the present application.
Claims
1. A teaching quality evaluation method based on head temperature change, characterized in that: include: Acquire a visible light image, and preprocess the visible light image to obtain a preprocessed visible light image; Performing image segmentation on the preprocessed visible light image to obtain K segmented regions; Filter out a first head region from the K segmented regions; Transforming the first head region from a visible light coordinate system to an infrared coordinate system to obtain a second head region; At time T, the average grayscale value of the second head region is counted to obtain the average grayscale value at time T; At time T+t, the average grayscale value of the second head region is counted to obtain the average grayscale value at time T+t; Determine the head temperature change according to the average gray value change from the average gray value at time T to the average gray value at time T+t; The teaching quality is evaluated based on the head temperature change.
2. The teaching quality evaluation method based on head temperature variation according to claim 1, characterized in that: The performing image segmentation on the preprocessed visible light image to obtain K segmented regions includes: Reconstructing the preprocessed visible light image to obtain a reconstructed image; Perform image segmentation on the reconstructed image to obtain K segmentation regions.
3. The teaching quality evaluation method based on head temperature variation according to claim 2, characterized in that: The step of reconstructing the preprocessed visible light image to obtain a reconstructed image includes: Upsampling the preprocessed visible light image to obtain an upsampled image; Downsampling the preprocessed visible light image to obtain a downsampled image; Performing adaptive low-pass filtering on the upsampled image to obtain a low-pass filtered image; Performing adaptive high-pass filtering on the down-sampled image to obtain a high-pass filtered image; The low-pass filtered image and the high-pass filtered image are added together to obtain a reconstructed image.
4. The teaching quality evaluation method based on head temperature variation according to claim 2, characterized in that: The reconstructed image is segmented to obtain K segmented regions, including: The light intensity distribution of the reconstructed image is calculated using the following formula: H(i)=γ*A(i)*k(i)+B(i)*(1-k(i)); Wherein, H(i) is the light intensity of the i-th pixel point of the reconstructed image, A(i) is the long-distance light intensity emitted by the distant light source to the i-th pixel point of the reconstructed image, B(i) is the short-distance light intensity emitted by the near light source to the i-th pixel point of the reconstructed image, γ is the attenuation factor, and the value of the attenuation factor is negatively correlated with the distance between the distant light source and the i-th pixel point of the reconstructed image, and k(i) is the transmittance corresponding to the i-th pixel point of the reconstructed image; K seed points are randomly selected, and the image is segmented using a region growing method based on the light intensity distribution of the reconstructed image to obtain K segmented regions.
5. The teaching quality evaluation method based on head temperature variation according to claim 3, characterized in that: The step of performing adaptive low-pass filtering on the up-sampled image to obtain a low-pass filtered image comprises: Input N test upsampled images into an adaptive low-pass filter to obtain N low-pass filtered output images; According to the difference between each of the low-pass filtered output images and the corresponding test up-sampled image, adjusting the parameters of the adaptive low-pass filter until the parameters of the adaptive low-pass filter converge; The up-sampled image is input into the adaptive low-pass filter for adaptive low-pass filtering to obtain a low-pass filtered image.
6. The teaching quality evaluation method based on head temperature variation according to claim 1, characterized in that: The step of selecting the first head region from the K segmented regions includes: Selecting a pixel point in each segmented area as a test point; Select the first and second focus points; constructing an elliptic curve according to the first focus, the second focus and the test point; Adding the distance from the test point to the first focus and the distance from the test point to the second focus to obtain a test distance; adding the error value to the test distance to obtain a distance threshold; Calculating the sum of the distances from the edge points of each segmented area to the first focus and the second focus; Counting the number of edge points in each segmented area that meet the distance and are less than or equal to the distance threshold, to obtain K optimized edge point sets; each of the optimized edge point sets includes a plurality of optimized edge points; Filter out the optimized edge point set with the largest number of optimized edge points from the K optimized edge point sets to obtain a target edge point set; All the optimized edge points in the target edge point set are connected end to end to obtain a first head region.
7. The teaching quality evaluation method based on head temperature variation according to claim 1, characterized in that: The step of transforming the first head region from a visible light coordinate system to an infrared coordinate system to obtain a second head region includes: Transforming the first head region from a visible light pixel coordinate system to a visible light image coordinate system to obtain a third head region; transforming the third head region from the visible light image coordinate system to the visible light camera coordinate system to obtain a fourth head region; Transforming the fourth head region from the visible light camera coordinate system to the world coordinate system to obtain a real head region; Transforming the real head region into the infrared camera coordinate system to obtain a fifth head region; Transforming the fifth head region into an infrared image coordinate system to obtain a sixth head region; The sixth head region is transformed into an infrared pixel coordinate system to obtain a second head region.
8. The teaching quality evaluation method based on head temperature variation according to claim 1, characterized in that: The step of determining the head temperature change according to the average grayscale value change from the average grayscale value at time T to the average grayscale value at time T+t includes: Subtract the average gray value at time T from the average gray value at time T+t to get the average gray value change; According to the following formula, the head temperature change is calculated by nonlinear transformation: Wherein, ΔT is the head temperature change, c is the first nonlinear mapping parameter, d is the second nonlinear mapping parameter, and ΔG is the average gray value change.
9. The teaching quality evaluation method based on head temperature variation according to claim 1, characterized in that: The step of evaluating the teaching quality according to the head temperature change comprises: If there is only one course in the teaching scene from time T to time T+t, the head temperature changes of all students in the teaching scene from time T to time T+t are counted; classifying the teaching quality of all students according to the amount of change in head temperature of all students; If there are multiple courses in the teaching scene from time T to time T+t, the head temperature change of a single student in the teaching scene from time T to time T+t is counted; The teaching quality of individual students is classified according to the change in head temperature of the individual students.
10. The teaching quality evaluation method based on head temperature variation according to claim 1, characterized in that: The preprocessing of the visible light image to obtain a preprocessed visible light image includes: Performing guided filtering on the visible light image to obtain a filtered image; Adaptive histogram equalization is performed on the filtered image to obtain a preprocessed visible light image.