Changeset 985 for trunk/src/series/stereo_civ.m
 Timestamp:
 Jan 20, 2017, 5:17:25 PM (7 years ago)
 File:

 1 edited
Legend:
 Unmodified
 Added
 Removed

trunk/src/series/stereo_civ.m
r984 r985 92 92 end 93 93 [tild,i1_series,i2_series,j1_series,j2_series]=get_file_series(Param); 94 time=[]; 94 95 for iview=1:size(Param.InputTable,1) 95 96 XmlFileName=find_imadoc(Param.InputTable{iview,1},Param.InputTable{iview,2},Param.InputTable{iview,3},Param.InputTable{iview,5}); … … 135 136 i2_series_Civ1=i1_series{2};i2_series_Civ2=i1_series{2}; 136 137 if isempty(j1_series{1}) 138 FrameIndex_A_Civ1=i1_series_Civ1; 139 FrameIndex_B_Civ1=i2_series_Civ1; 137 140 j1_series_Civ1=ones(size(i1_series{1})); 138 141 j2_series_Civ1=ones(size(i1_series{2})); … … 140 143 j1_series_Civ1=j1_series{1}; 141 144 j2_series_Civ1=j1_series{2}; 145 FrameIndex_A_Civ1=j1_series_Civ1; 146 FrameIndex_B_Civ1=j2_series_Civ1; 142 147 end 143 148 j1_series_Civ2=j1_series_Civ1; 144 149 j2_series_Civ2=j2_series_Civ1; 145 NomTypeNc=NomType_A; 146 if isempty(j1_series_Civ1)147 FrameIndex_A_Civ1=i1_series_Civ1;148 FrameIndex_B_Civ1=i2_series_Civ1;149 j1_series_Civ1=ones(size(i1_series_Civ1));150 j2_series_Civ1=ones(size(i1_series_Civ1));151 else152 FrameIndex_A_Civ1=j1_series_Civ1;153 FrameIndex_B_Civ1=j2_series_Civ1;154 end150 151 % if isempty(j1_series_Civ1) 152 % FrameIndex_A_Civ1=i1_series_Civ1; 153 % FrameIndex_B_Civ1=i2_series_Civ1; 154 % j1_series_Civ1=ones(size(i1_series_Civ1)); 155 % j2_series_Civ1=ones(size(i1_series_Civ1)); 156 % else 157 % FrameIndex_A_Civ1=j1_series_Civ1; 158 % FrameIndex_B_Civ1=j2_series_Civ1; 159 % end 155 160 if isempty(PairCiv2) 156 161 FrameIndex_A_Civ2=FrameIndex_A_Civ1; … … 231 236 end 232 237 end 233 238 if ismember(FileType_A,{'mmreader','video','cine_phantom'}) 239 NomTypeNc='_1'; 240 else 241 NomTypeNc=NomType_A; 242 end 234 243 235 244 %% Output directory … … 244 253 245 254 %% get timing from input video 246 if isempty(time) && ~isempty(find(strcmp(FileType_A,{'mmreader','video','cine_phantom'})))% case of video input255 if isempty(time) && ismember(FileType_A,{'mmreader','video','cine_phantom'})% case of video input 247 256 time=zeros(FileInfo_A.NumberOfFrames+1,2); 248 257 time(:,2)=(0:1/FileInfo_A.FrameRate:(FileInfo_A.NumberOfFrames)/FileInfo_A.FrameRate)'; … … 281 290 Civ1Dir=OutputDir; 282 291 283 ncfile=fullfile_uvmat(RootPath_A,Civ1Dir,[RootFile_A,'_All'],'.nc',NomTypeNc,i2_series_Civ1(ifield),[],...284 j1_series_Civ1(ifield),j2_series_Civ1(ifield));285 286 287 ncfile2=fullfile_uvmat(RootPath_A,Civ1Dir, [RootFile_A,'_Light'],'.nc',NomTypeNc,i2_series_Civ1(ifield),[],...292 % ncfile=fullfile_uvmat(RootPath_A,Civ1Dir,[RootFile_A,'_All'],'.nc',NomTypeNc,i2_series_Civ1(ifield),[],... 293 % j1_series_Civ1(ifield),j2_series_Civ1(ifield)); 294 295 296 ncfile2=fullfile_uvmat(RootPath_A,Civ1Dir,RootFile_A,'.nc',NomTypeNc,i2_series_Civ1(ifield),[],... 288 297 j1_series_Civ1(ifield),j2_series_Civ1(ifield)); 289 298 … … 824 833 825 834 %% write result in a netcdf file if requested 826 if LSM ~= 1 % store all data827 if exist('ncfile','var')828 errormsg=struct2nc(ncfile,Data);829 if isempty(errormsg)830 disp([ncfile ' written'])831 else832 disp(errormsg)833 end834 end835 else835 % if LSM ~= 1 % store all data 836 % if exist('ncfile','var') 837 % errormsg=struct2nc(ncfile,Data); 838 % if isempty(errormsg) 839 % disp([ncfile ' written']) 840 % else 841 % disp(errormsg) 842 % end 843 % end 844 % else 836 845 % store only phys data 837 846 Data_light.ListVarName={'Xphys','Yphys','Zphys','Civ3_C','Xmid','Ymid','Uphys','Vphys','Error'}; … … 856 865 end 857 866 858 end867 % end 859 868 end 860 869 disp(['ellapsed time for the loop ' num2str(toc) ' s'])
Note: See TracChangeset
for help on using the changeset viewer.