Multiplexed photoinjector optimization for high-repetition-rate free-electron lasers