I think that you are not probably reading this right now, but this might help someone. I had the same problem with my Redmi Note 9 Pro, and clearing cache or anything else did not work, but when I deleted the photos that had broken thumbnails, and recovered them from the thrash bin in the gallery, they returned to normal. Sorry for my bad english, I am from Finland