[Insight-users] Gradient of Vector Image

Luis Ibanez luis . ibanez at kitware . com
Thu, 02 Oct 2003 16:28:47 -0400


Hi Bing,


   No, you cannot provide a vector image as
   input to the Gradient filter.  This filter
   is expecting a scalar image.

   You may want to double check on the math of
   what you would expect from this operation.
   The gradient of the gradient will not give
   you a Jacobian, but the Hessian matrix of
   the image.


   Assumming that the image is a function

             I = f(x,y,z)

   the Hessian matrix will have the second
   derivatives

        df/dxdx  df/dxdy   df/dxdz
        df/dydx  df/dydy   df/dydz
        df/dzdx  df/dxdy   df/dzdz


    You can get this matrix using the Recursive
    Gaussian filters.  Please look at the
    demo application:

      InsightApplications/Curve2DExtraction

    which computes the Hessian of the input
    image. Note that this applications uses
    2D images, but the concept is scalable
    in dimension.

    http://www . itk . org/HTML/Curve2DExtraction . htm



      Regards,


         Luis


--------------------------
Bing Jian wrote:
> Hi, Here is a question about gradient image.
> 
> Suppose I have a vector image which is obtained from
> the output of gradientfilter applied on a scalar 3D
> image. Now the dimension of vector is 3. Can I take
> this vector image as input to the gradientfilter again?
> My expected output image should be a 3d vector image.
> And here the dimension of the vector should be 3*3=9,
> as the Jacobian of the original gradient image.
> 
> Thanks in advance!
>