Problems with CONVOL and 3D data [message #29260] |
Fri, 08 February 2002 04:45 |
Alberto Martinez
Messages: 1 Registered: February 2002
|
Junior Member |
|
|
I have a problem filtering 3D data wih convol. Here is the code that does'nt
work properly:
(I'm using IDL v5.4 under Windows 2000 Professional)
data = INTARR(40,40,40) ; My data example
kernel_1 = [1,2,1]
kernel_1 = REFORM(kernel_1,3,1,1) ; An array in X direction , 3D
kernel_2 = REFORM(kernel_1,1,3,1) ; The same in Y
kernel_3 = REFORM(kernel_1,1,1,3) ; In Z direction
result = CONVOL(data, kernel_1) ; No problems
result = CONVOL(data, kernel_2) ; No problems
result = CONVOL(data, kernel_3) ; No problems
; but if i don�t use integers:
result = CONVOL(FLOAT(data), FLOAT(kernel_2)) ;
> %CONVOL: Kernel's dimensions are incompatible with operand's
It seems that the filtering with "kernel_2" only works with data and kernel
in integers!
I can�t filter Other types others types of 3D data with simple vector in the
Y direction !
The others kernels works perfectly.
any suggestion, please? Is this a know bug or what?
Thanks.
Alberto.
|
|
|