using this script to run the pd process