Hi all, I'm currently trying to use Spark Kmean|| to cluster keypoints descriptor extracted using OpenCV. OpenCV extract and store descriptors insinde Mat object. I convert Mat object into Array[Array[Double]] with the following code :
(0 until descriptors.rows).map { i => val row = new Array[Float](descriptors.cols) descriptors.get(i,0,row) row.map(_.toDouble) } This works but really slow down the code. Is there another alternatives ? Cheers,