It’s still under research why sperm whales sleep this way. Recent studies show sperm whales sleep with half their brain. The other half stays alert making sure the blowhole is at the surface in order for the whale to breath. They nap this away for 12 to 13 minutes making it a rare sight to spot. Judging from the photo I think a whale stays on guard while the rest nap.