cleaning pig scripts