Previous | Next --- Slide 37 of 63
Back to Lecture Thumbnails
martigp

This is a bit of a semantics question, but why does the compute.at generated double loop iterate over +2 on the y and x coordinate. Surely it would only have to do so on the y coordinate for the second inner loop to work correctly.

awu

@martigp Just speculating here, but perhaps that has to do with the fact that we need +/-1 entries for computation in both x and y? In blurx(x,y) we take x-1 & x+1, while in out(x,y) we take y-1 & y+1.

evs

@martigp Since were moving along in groups of three the pixels at the border will still need the two other pixels to perform the blur.

apappu

It's interesting to me that from a client perspective Halide allows a range of specifications for those who understand/have an idea of what a more efficient implementation may be and those who don't, since the programmer can specify details of the blur at varying levels of granularity

Please log in to leave a comment.