Unless I'm making a mistake (somebody correct me if I'm wrong), that electromagnetic wave is identical to the wave of probability amplitude.
(The word "amplitude" is the key. Think of it as a complex number spinning around in a circle.)
The way you get a particle out of it is by being uncertain of it's frequency.
If its frequency is totally certain, then its position is totally uncertain, and it's just infinitely "spread out".
If its frequency has a distribution, like a gaussian distribution about a mean, that's equivalent to an infinite sum of probability amplitude waves of different frequencies and powers.
When they are added together, the only place they are "in sync" is one place, and either side of that, the power tapers off, because the waves all cancel out.
The location of where they are in sync moves at what's called "group velocity".
That's the wave packet, whose power represents the probability of a photon appearing there.