PF-MT-by-Vaswani

所属分类:人工智能/神经网络/深度学习
开发工具:matlab
文件大小:100KB
下载次数:52
上传日期:2011-08-29 11:46:46
上 传 者smileindark
说明:  Iowa大学的Vaswani使用水平集和粒子滤波的方法跟踪目标轮廓,对变形物体有很好的跟踪效果。
(University of Iowa Vaswani using the particle filter and the level set method to track the target profile, the deformation of the object have a good tracking results.)

文件列表:
PF-MT by Vaswani\affinetfm.m (1890, 2006-02-12)
PF-MT by Vaswani\affinetfm_geom.m (2821, 2006-03-10)
PF-MT by Vaswani\changeknots.m (1984, 2006-02-08)
PF-MT by Vaswani\coxdeboor3.m (751, 2005-06-27)
PF-MT by Vaswani\DefFreq.m (3233, 2006-04-21)
PF-MT by Vaswani\DefFreq0.m (2589, 2006-04-21)
PF-MT by Vaswani\DefFreq2.m (3909, 2007-10-09)
PF-MT by Vaswani\define_lset.m (1024, 2007-10-24)
PF-MT by Vaswani\define_lset_only.m (1032, 2007-10-24)
PF-MT by Vaswani\DefPSD.m (4436, 2006-07-03)
PF-MT by Vaswani\detectbndry.m (1511, 2006-03-13)
PF-MT by Vaswani\detectchangetopo.m (816, 2006-02-06)
PF-MT by Vaswani\detectknotschange.m (266, 2006-02-03)
PF-MT by Vaswani\detectknotsclose.m (308, 2005-09-11)
PF-MT by Vaswani\detectknotsfar.m (221, 2005-09-10)
PF-MT by Vaswani\detectneedchange.m (2586, 2005-12-16)
PF-MT by Vaswani\discretesample.m (486, 2005-06-24)
PF-MT by Vaswani\dispall.m (1040, 2006-03-29)
PF-MT by Vaswani\dispcontours.m (563, 2006-03-12)
PF-MT by Vaswani\displayknots.m (433, 2005-07-01)
PF-MT by Vaswani\extend.m (651, 2005-06-09)
PF-MT by Vaswani\extend2.m (357, 2005-06-22)
PF-MT by Vaswani\extend_initialize.m (16782, 2006-02-07)
PF-MT by Vaswani\FastMarching.m (29719, 2005-06-09)
PF-MT by Vaswani\findedge.m (790, 2006-03-14)
PF-MT by Vaswani\findedge0.m (814, 2006-03-13)
PF-MT by Vaswani\find_knot_indices.m (639, 2005-11-07)
PF-MT by Vaswani\Find_Narrow_band.m (9861, 2007-10-21)
PF-MT by Vaswani\Find_Narrow_band_old.m (9553, 2007-10-21)
PF-MT by Vaswani\ftest.m (1173, 2006-04-20)
PF-MT by Vaswani\gendata.m (3266, 2005-10-29)
PF-MT by Vaswani\gendata_2obj.m (3795, 2006-04-21)
PF-MT by Vaswani\gendata_2obj_geom.m (2908, 2007-10-20)
PF-MT by Vaswani\gendata_2obj_geom2.m (2918, 2006-02-12)
PF-MT by Vaswani\geom_learn.m (804, 2006-02-10)
PF-MT by Vaswani\getclosest.m (238, 2005-06-15)
PF-MT by Vaswani\getcontour.m (1115, 2005-12-13)
PF-MT by Vaswani\getcontour_geom.m (1203, 2006-02-12)
PF-MT by Vaswani\getlevset.m (158, 2005-06-24)
PF-MT by Vaswani\getsequence.m (706, 2005-12-15)
... ...

%Code written by Namrata Vaswani. A small part of the code (a little bit of the level set part) is taken from code written by Yogesh Rathi %Please cite %Namrata Vaswani, Yogesh Rathi, Anthony Yezzi, Allen Tannenbaum, PF-MT with an Interpolation Effective Basis for Tracking Local Contour Deformations, Accepted to IEEE Trans. Image Processing, 2008 %when using this code % A shorter version of this work appeared in %Namrata Vaswani, Anthony Yezzi, Yogesh Rathi, Allen Tannenbaum, Time-varying Finite Dimensional Basis for Tracking Contour Deformations, IEEE Conf. on Decision and Control (CDC), 2006. - Unzip utils.zip netlab.zip and DeformPFMT.zip - Add utils and netlab into MATLAB path runsims - generates simulated data and then first runs deform PF-MT and then runs affine PF-MT and compares results. - to run on real data, comment out the data generation part. - this is deform PF-MT with Radial-Angle Parameterization - To just run Deform PF-MT with Radial-Angle Parameterization (earlier called it Geometric Basis) - T = 20, gendata_2obj_geom, mcpf2_geom - I recommend using this one first - since it is much easier to handle. - To run Deform PF-MT with with Arclength Parameterization (earlier called it Parametric Basis) - T = 20, gendata_2obj, mcpf2 IMPORTANT THINGS - u0,v0, u2 need to be specified - I am not learning the intensities but forcing a certain pre-decided intensity. - Also, I am assuming a 3 region model with intensities u0, u2 and v0. Two types of object objecttype = 1 means u0 is intensity inside object, u2,v0 are intensities outside object objecttype = 2 means u0, u2 are two intensities inside object, v0 is intensity outside object In the simulated sequence, objectclass=1 segments the grey object. objectclass=2 segments the white object. - If set M=2 can track both object contours simultaneously. - initialize.m is the code used to approximately initialize the contour in the first frame. ****************************************************************************************** IMPORTANT FILES (RADIAL-ANGLE PARAMETERIZATION - also called GEOMETRIC BASIS) setparamssim_geom: setting of most parameters. Some others get set in mcpf2_geom (beginning) or in mcevidencesample5 gendata_2obj_geom: generates the simulated sequences as described in the paper. mcpf2_geom: runs the PF. Calls - setparamssim_geom: sets parameters. Replace by appropriate setparamssim for your sequence (either by learning or by tweeking) - mcsamplet1_geom: initializes the PF at t=1. Calls a script called initialize - initialize: reads in a circle image (for simulated data) or asks the user to enter an approximate contour for the first frame in the sequence(modify this for your application) PF LOOP: for each t calls: - mcsystemsample2_geom: generates samples from the system model and performs the GD iterations (number of gradient descent iterations is set as impsampiters). - mcevidencesample5 : weighting and resampling steps. The current weighting is by a combination of region based (Chan-Vese) and edge based (Condensation) likelihoods. - displaying routines learn_geom: learning the system model parameters. Need to write a similar code for affine parameter learning also. ****************************************************************************************** IMPORTANT FILES (ARCLENGTH PARAMETERIZATION also called PARAMETRIC BASIS) gendata_2obj: Generates the 2 object sequences mcpf2: Main PF file setparamssim: Called both in gendata_2obj and in mcpf2 - sets all parameters mcsystemsample2: a) Generates prediction particles using the "system model" for the state [C,Cvel_basis,knotloc_moved] Cvel_basis = K-dim velocity at the K control points corresponding the K knot locations knotloc_moved b) the code inside "if impsample" runs impsampiters iterations of gradient descent to minimize the Chan-Vese energy functional - the code in get_velocity_chanvese to get the velocity - the code needs to be modified/corrected a bit... For now impsampiters set to 0, but try setting it to 2 or 3 - helps lock the contour onto the object better than with just K-dim prediction. Also, in mcsystemsample2.m - may need to remove the deformindx part of the code or set deformindx = [] mcevidencesample5: a) Weights each particle by observation likelihood. observation likelihood = likelihood of contour C given current image b) "resamples" particles to eliminate low weight particles detectneedchange Detects the need to change knot locations (increase or decrease K) changeknots Re-allocates Knew knotlocations to the contour mcsamplet1 initialization: reads in a binary circle image as initial contour - adds noise to it to generate n=15 different contour particles, also allocates knots to each contour and also generates n=15 velocity particles. initialize reads in the binary circle image - change this file to read in your first contour. PARAMETERS OF INTEREST - MAY NEED TO CHANGE THEM a,signoise, v0, u0, u2, n, deformindx set M=1 sig2obsedge, dmax, rho In mcevidencesample5, change the - "if object1" part of the code - weight given to edgewt term in logw = edgewt + ... In mcpf2.m, change signoise, n initialize.m ****************************************************************************************** 10/20/07: Replaced xc = round(mean(nar_x)); yc = round(mean(nar_y)); by if ~isempty(nar_x) xc = round(mean(nar_x)); yc = round(mean(nar_y)); else xc = inf; yc = inf; disp('empty nar_x, nar_y in Find_Narrow_band') end ****************************************************************************************** THINGS TO MODIFY: 1,3 below are MOST IMPORTANT (I plan to get to these now, if I get it done will send them to you) 1. get_basis_fns_theta: WORST PIECE OF CODE, VERY SLOW. Can be made much faster by using MATLAB's spline function or interp1q. Make it even faster if generate the interpolation functions once and keep using them until K changes. 2. Changing K has not been implemented for arclength parameterization. Has been done for radial angle, see mcpf2.m 3. u0: Simple and efficient way to set: use the mean intensity inside the most likely contour or compute a weighted mean of intensities inside all contours. Similarly for v0. 4. Learning code: learn_geom.m - still working on it. 5. Change any of the above or other parameters: setparamssim_geom, mcpf2_geom (beginning) or mcevidencesample5 6. Current GD iter step does GD only for Chan-Vese energy, not for the edge based (Condensation) term. Correct thing to do: also include GD to minimize Condensation energy. If C_{obs} is the observed contour obtained by searching along the normals, then move a "few" iterations towards C_{obs}. IGNORE EVERYTHING BELOW IF YOU WANT TO WRITE CODE FOR ANGLE BASED INTERPOLATION: has been done I think file to change: mcsystemsample2.m OLDER VERSION - CHANGING K and DETECTING NEED TO CHANGE K IN sYSTEMsAMPLE.M - TRACKS ONE OF 2 OBJECTS DEPENDING ON OBSERVATION MODEL pf: Main PF file setparamssim: Called both in gendata_2obj and in mcpf - sets all parameters systemsample2: Generates evidencesample5: gendata_2obj uses systemsample.m to generate sample contours

近期下载者

相关文件


收藏者