added exception handling for string parameters. fixed bug in cv init parameter