BICEP2/Keck Array. IV. Optical Characterization and Performance of the BICEP2 and Keck Array Experiments