OK, so it is basically just a decorator which calls color.rgb2gray and passes the converted image to the function? Johannes Schönberger Am 16.10.2012 um 20:42 schrieb Stéfan van der Walt <stefan@sun.ac.za>:
On Tue, Oct 16, 2012 at 7:13 AM, Schönberger Johannes <hannesschoenberger@gmail.com> wrote:
Sorry, but I do not understand what this decorator does. Could you provide a short example?
@each_channel def some_gray_level_filter(): return gray_image
image = data.something() gray_image = color.rgb2gray(image)
some_gray_level_filter(gray_image) some_gray_level_filter(image) <-- this works too
--
On Tue, Oct 16, 2012 at 1:54 PM, Schönberger Johannes <hannesschoenberger@gmail.com> wrote:
OK, so it is basically just a decorator which calls color.rgb2gray and passes the converted image to the function?
No, it is a function that passes each layer through the filter, and then assembles the results back into a color image.
participants (2)
-
Schönberger Johannes
-
Stéfan van der Walt