I believe the photo is encoded in the digital passport contents and the computer will check your face in the camera to see it matches. No human involved. Many countries have automatic passport gates now using this method.
If they already have your picture the agent will usually know who you are before you have even handed over your passport. The tech has gotten eerily good.