comp.lang.idl-pvwave archive - RDF feed
type: channel
description: Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado
items: Re: why is amoeba not working ??

Re: why is amoeba not working ??
type: item
description: "trex" <Terry.Suer@gmail.com> wrote in message news:1184722537.753989.104610@d30g2000prg.googlegroups.com.. . > I am trying to do a image subtraction minimization using amoeba. > When I try running the code below I get this error. Any ideas? AMOEBA requires that the supplied function return a *scalar* value, whereas your FUNC is returning an array the same size as the two images. You might insert a TOTAL() into the last line of FUNC so that it returns a scalar, e.g. res = total( abs(s - xyshift( (i*q[2]), q[0], q[1])) ) though I think I would instead prefer to maximize the correlation coefficient of the two images. --Wayne > > REPLICATE: Expression must be a scalar in this context: <DOUBLE > Array[201, 151]>. > % Execution halted at: AMOEBA 161 /opt/rsi/idl/lib/ > amoeba.pro > % $MAIN$ 28 /home/idl/func.pro > > > > FUNCTION FUNC,q > > i=mrdfits('/home/imcen.fits',/silent) > s=mrdfits('/home/spcen.fits',/silent) > res = s-xyshift((i*q[2]),q[0],q[1]) > > return,res > END
date: 2007-07-18T08:36:10-00:00