The correct way is to compute the DICE score per image and then find the mean, median and STD across all test images. It is good practice to report all three metrics to provide a clear intuition to the reader.
For more details, please refer to this answer.
You probably don't require the use of artificial intelligence for your task, it seems quite 'easy' to do, check out openCV library, it probably has a function that does the job without AI (here is one for example).
The use of IA network may get you a more accurate result tho, so I would do it using classic image segmentation (U-Net is one of the most common ...
In this tutorial they use the following to resize the image and mask.
Is it applicable to your use-case?
input_image = tf.image.resize(datapoint['image'], (128, 128))
input_mask = tf.image.resize(datapoint['segmentation_mask'], (128, 128))