After 15 minutes of posing for group photo after group photo, it looks like you’ve finally snapped the perfect one. Grandma is smiling, your nephew is sitting still, and even the dog is looking at the camera for once. Then, you find yourself in the corner: The shutter managed to capture the exact moment you blinked. Time to resume the positions.

With a new tool from Adobe, this scenario could become less common. Instead of retaking a picture every time someone closes their eyes, this feature would let you salvage the “ruined” photograph with a few clicks in Photoshop, Gizmodo reports.

The latest update of Photoshop Elements allows users to select the “Open Closed Eyes” option, choose which face in the photo they want to correct, and provide several additional photos of the subject with their eyes open. The software uses artificial intelligence to analyze each picture and determine which pair of peepers best matches the colors and lighting from the primary photograph. It then automatically pastes those eyes over the lids and blends them to make the addition look seamless.

Photoshop Elements (a simplified version of Adobe’s original image editor) offers many features that use AI algorithms to improve picture quality. Elements can automatically generate backgrounds when you move objects in a photo, suggest the best effects, and turn frowns into smiles. It even remembers the look you prefer and suggests personalized tone corrections. All of those capabilities and the new “Open Closed Eyes” tool are available today to customers who purchase Photoshop Elements 2018 for $100 (or upgrade their existing license for $80).

[h/t Gizmodo]