# Contrast-Invariant Edge Detection: A Methodological Advance in Medical Image Analysis
## 4 Experimental Results and Analysis
### The Contrast-Invariant Robustness of the CIED  
In addition to visual and quantitative evaluations, we also evaluated the contrast-invariant robustness of CIED. To verify the contrast-invariant of CIED, we linearly scaled the contrast of the image to different degrees, and then we used CIED for these images separately. Figure 7 shows the visual effect of the CIED at different contrasts from 10% to 100%. Rows 1, 3 of Figure 7 are medical images at different contrasts and Rows 2, 4 of Figure 7 are CIED edge detection results at different contrasts. In addition, Figure 7 shows the recall and F1-score at various contrast levels. From Rows 1 and 3 of Figure 7, it can be observed that when the contrast is only 10%, the image is barely visible. As the contrast gradually increases, the image becomes clearer and clearer. From Rows 2, 4 of Figure 7, it can be observed that CIED can identify edges clearly even when the contrast of the image is only 10%. With the gradual increase in contrast, CIED's edge detection visualization has been relatively stable and able to extract complete and clear edges. From the result of Figure 7, the recall of CIED is always high, almost always above 0.7. This indicates that CIED can extract the edges effectively in different contrasts. Especially in the case of low contrast, for example, in the contrast of only 10%, its edge detection results of recall can also reach 0.746. Due to the low contrast instead of reducing part of the noise interference, the performance of the F1-score reaches 0.558.  
Figure 6: The results of edge images in terms of accuracy, precision, recall, and F1-score. (**a**) The accuracy result. (**b**) The recall result. (**c**) The precision result. (**d**) The F1-score result.  
In addition, we also recorded detailed evaluation metrics for CIED at different contrast levels from 10% to 100%. Table 1 shows the specific evaluation metrics results for CIED at different contrast levels. We can observe that the CIED is able to maintain a high recall at any contrast. The CIED mainly utilizes the three MSB planes' information of the image to determine edges. When performing linear contrast transformation, the brightness distribution and color perception of the image change. Due to the change in contrast, regions in the image that originally had similar brightness may have new edges appear as the brightness difference increases, or regions that originally belonged to edges may have their edges weakened or even disappear as the brightness difference decreases. From the perspective of pixel values, their distribution is readjusted according to the contrast transformation rules, and the pixel distribution of each bit plane also changes accordingly. In addition, the edge and texture information of the image is also affected. Originally distinct edges may become indistinct, and the clarity and distinguishability of textures also change depending on the contrast. Even when the contrast changes significantly, CIED can still capture the key edge information in the image relatively accurately. This phenomenon further illustrates that the CIED is robust in the sense that it is contrast-invariant, and in the case of low contrast it also performs well.  
Figure 7: The demonstration of detected edge images using proposed CIED at different contrast levels.