qqp question1: How can we find the shortest m-connected path if the pixel values are given in matrix form? question2: How can I calculate the shortest path, if the path lengths are not summed but multiplied?