Delete variables after use: hopefully fixes memory issue.