How to perform the cross validation?

Have you looked into this post?