sb_invert_uw.m
来自「StaMps最新测试版」· M 代码 · 共 66 行
M
66 行
function []=sb_invert_uw()%SB_INVERT_UW Invert unwrapped phase of short baseline ifgs%% Andy Hooper, September 2006%% ======================================================================% 07/2008 AH: Allow isolated images, not included in any interferogram% ======================================================================load psverpsname=['ps',num2str(psver)];phuwsbname=['phuw_sb',num2str(psver)];phuwsbresname=['phuw_sb_res',num2str(psver)];phuwname=['phuw',num2str(psver)];phuwsb=load(phuwsbname);ps=load(psname);unwrap_ifg_index=getparm('unwrap_ifg_index');if strcmpi(unwrap_ifg_index,'all') unwrap_ifg_index=[1:ps.n_ifg];endph_uw_sb=phuwsb.ph_uw(:,unwrap_ifg_index);clear phuwsbG=zeros(ps.n_ifg,ps.n_image);for i=1:ps.n_ifg G(i,ps.ifgday_ix(i,1))=-1; G(i,ps.ifgday_ix(i,2))=1;end%G=G(:,[1:ps.master_ix-1,ps.master_ix+1:end]); % take out master as refif sum(abs(G(:,ps.master_ix)))==0; error('Apparently none of the unwrapped interferograms include the original master image')else G(:,ps.master_ix)=0; % take out master as ref by setting to zeroendG2=G(unwrap_ifg_index,:);nzc_ix=sum(abs(G2))~=0; % index for non-zero columnsG2=G2(:,nzc_ix);if rank(G2)<size(G2,2) error('There are isolated images (cannot be inverted w.r.t. master)')endph_uw=zeros(ps.n_ps,ps.n_image,'single');%for i=1:ps.n_ps% ph_uw(i,:)=(G2\ph_uw_sb(i,:)')';%endph_uw(:,nzc_ix)=(G2\double(ph_uw_sb'))';ph_res=single(G*ph_uw')';%ph_uw=[ph_uw(:,1:ps.master_ix-1),zeros(ps.n_ps,1),ph_uw(:,ps.master_ix:end)];unwrap_ifg_index_sm=[1:ps.n_image]; % single master indexnzc_ix(ps.master_ix)=1;unwrap_ifg_index_sm=unwrap_ifg_index_sm(nzc_ix);save(phuwname,'ph_uw','unwrap_ifg_index_sm')save(phuwsbresname,'ph_res')
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?