Pion production in hyperon and KoKo channels in π−p interactions and multipion photoproduction