QMC related scripts