  Engineering vector spatial modes of photons is an important approach for
manipulating high-dimension photonic states in various quantum optical
experiments. In this work, we demonstrate generation of heralded single photons
with well-defined vector spatial modes by using a self-locking polarizing
interferometer comprising a spatial light modulator. Specifically, it is shown
that, by carefully tailoring and compensating spatial and temporal amplitudes
of manipulated photons, one can exactly convert ultrafast single photons into
desired spin-orbit states with extremely high purity. This compact and robust
device provides a versatile way for not only generation, but also manipulation
and characterization of arbitrary photonic spin-orbit states.
