Similarity Learning on  Graph (SLOG) matlab codes