The image is taken from this link.
Here Alice is using random bases to encode 0 or 1. After the process is completed, Bob has similarly polarized photons as Alice. These polarization can be any of the $\lvert 0 \rangle , \lvert 1 \rangle, \lvert + \rangle$ or $\lvert - \rangle$. However, how would Bob know what Alice meant for which two of these bases? Meaning, Alice might choose ${\lvert 0 \rangle, \lvert + \rangle}$ to encode a 0 and ${\lvert 1 \rangle, \lvert - \rangle}$ to encode a 1 or vice versa. How do they determine which polarization encodes which bits?