Fixed ShapeRec, threshold issue and directory issue.