This paper presents an enhanced approach to kidney segmentation using a modified CLAHE preprocessing method, aimed at improving image clarity and CNN performance on the KiTS19 dataset. To assess the impact of the modified CLAHE method, we conducted quality evaluations using the BRISQUE metric, comparing the original, standard CLAHE and modified CLAHE versions of the dataset. The BRISQUE score decreased from 28.8 in the original dataset to 21.1 with the modified CLAHE method, indicating a significant improvement in image quality. Furthermore, CNN segmentation accuracy rose from 0.951 with the original dataset to 0.996 with the modified CLAHE method, outperforming the accuracy achieved with standard CLAHE preprocessing (0.969). These results highlight the benefits of the modified CLAHE method in refining image quality and enhancing segmentation performance. This study highlights the value of adaptive preprocessing in medical imaging workflows and shows that CNN-based kidney segmentation accuracy may be greatly increased by altering conventional CLAHE. Our method provides insightful information on optimizing preprocessing for medical imaging applications, leading to more accurate and dependable segmentation results for better clinical diagnosis.