adding directory util function and fixing bug in efficient version of model to svm data