G'MIC exercises

New exercise.

I have encountered more than one paper that requires calculations of distance within a neighbourhood. Does anyone (@Reptorian, @Iain, @David_Tschumperle?) have any recommendations on how to drive such algorithms in G’MIC? Well, starting with this example?

I am reading a paper that calculates the pixel weight as follows. Ln is the sum of distances between pixels along the path in the neighbourhood. In this case, red dot to yellow dot. It takes the min to the two routes of a corner. (I suppose all four corners would receive the same treatment for the kernel to be symmetrical… so min for 8 routes?) In Fig. 4, the min would be 0; i.e., the edge is too small for the kernel to detect.

image