Python detect defects scratch

Hello, I have these two images and I need to detect the white scratch using python and opencv. I have tried computing a simple difference and using a mask but it didn’t detect the scratch. Could you please help? thanks

even without “the scratch”, your 2 images are not “the same”

About simple ways to detect scratch:

They are highly contextual. They depend on how you define scratch in visual and computable terms.

From the images you provided, the scratch is lighter, may be you can segment it with threshold.

An easier way is to look for scratches on the plain region.

You can use the reference image to align the test one. Then you look for scratches in ROIs, in designated areas where they are easier to detect.