python: align ps1 and ps2