Read the data and only keep pics without NAs
1. Adjust the gray scale seach.
2. Changed every keypoints' "last" and "next" points based on our labels.
3. Re-defined the local.gray function. Fixed the points at the edge of pics.
Corrected the method to compute covariance matrix.
Use the whole d.train1 for alignment.(slow)
searching meahod in the test set