Josephson junctions in InAs nanowires proximitized with an Al shell can host gate-tunable Andreev bound states. Depending on the bound state occupation, the fermion parity of the junction can be even or odd. Coherent control of Andreev bound states has recently been achieved within each parity sector, but it is impeded by incoherent parity switches due to excess quasiparticles in the superconducting environment. Here, we show that we can polarize the fermion parity dynamically using microwave pulses by embedding the junction in a superconducting LC resonator. We demonstrate polarization up to 94%±1% (89%±1%) for the even (odd) parity as verified by single shot parity readout. Finally, we apply this scheme to probe the flux-dependent transition spectrum of the even or odd parity sector selectively, without any postprocessing or heralding.