Changeset 1200 for trunk/src/series.m
- Timestamp:
- Mar 20, 2026, 4:42:36 PM (22 hours ago)
- File:
-
- 1 edited
-
trunk/src/series.m (modified) (41 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/series.m
r1199 r1200 165 165 RunModeList={'local';'background'}; % default choice of extensions (Matlab fct .m or compiled version .sh) 166 166 if isfield(SeriesData.ClusterParam, 'ExistenceTest') 167 oarcommand=SeriesData.ClusterParam.ExistenceTest; 168 s=system(oarcommand); % look for cluster system presence 167 ClusterExistenceTest=SeriesData.ClusterParam.ExistenceTest; 168 disp('look for cluster command available') 169 s=system(ClusterExistenceTest); % look for cluster system presence 169 170 if isequal(s,0)% cluster detected 170 171 RunModeList=[RunModeList;{'cluster'}]; … … 568 569 %------------------------------------------------------------------------ 569 570 CheckRelabel=get(handles.Relabel,'Value'); 570 check_input_file_series(handles,CheckRelabel) 571 572 %% enable field and veltype menus, in accordance with the current action 571 errormsg=check_input_file_series(handles,CheckRelabel); 572 if ~isempty(errormsg) 573 msgbox_uvmat('ERROR',errormsg);% no input files entered 574 set(handles.REFRESH,'BackgroundColor',[1 0 0])% set REFRESH back to red color 575 return 576 end 577 578 %% enable field and veltype menus, in accordance with the current action function 573 579 ActionInput_Callback([],[], handles) 574 580 575 581 %------------------------------------------------------------------------ 576 582 % --- check the input file series. 577 function check_input_file_series(handles,CheckRelabel)583 function errormsg=check_input_file_series(handles,CheckRelabel) 578 584 %------------------------------------------------------------------------ 579 585 InputTable=get(handles.InputTable,'Data');%read the table of input file series 580 586 set(handles.series,'Pointer','watch') % set the mouse pointer to 'watch' 581 587 set(handles.REFRESH,'BackgroundColor',[1 1 0])% set REFRESH button to yellow color (indicate activation) 582 set(handles.Relabel,'BackgroundColor',[0 1 0])583 588 drawnow 584 empty_line=false(size(InputTable,1),1); 589 errormsg='';%default 590 591 %% removes possible empty lines in the tables documenting the files index series 592 check_empty_line=false(size(InputTable,1),1); 585 593 for iline=1:size(InputTable,1) 586 empty_line(iline)= isempty(cell2mat(InputTable(iline,1:3)));%check the empty lines in the input table 587 end 588 if ~isempty(find(empty_line,1))%removes the empty lines in the table 589 InputTable(empty_line,:)=[]; % remove empty lines 594 check_empty_line(iline)= isempty(cell2mat(InputTable(iline,1:3)));%check the empty lines in the input table 595 end 596 empty_lines=find(check_empty_line);%line indices which are empty 597 if numel(empty_lines)==size(InputTable,1) 598 errormsg='input files needed';% no input files 599 return 600 end 601 if ~isempty(empty_lines) 602 InputTable(empty_lines,:)=[]; % remove empty lines 590 603 set(handles.InputTable,'Data',InputTable) 591 604 ListTable={'MinIndex_i','MaxIndex_i','MinIndex_j','MaxIndex_j','PairString','TimeTable'}; 592 605 for ilist=1:numel(ListTable) 593 606 Table=get(handles.(ListTable{ilist}),'Data'); 594 Table(empty_line ,:)=[]; % remove empty lines607 Table(empty_lines,:)=[]; % remove empty lines 595 608 set(handles.(ListTable{ilist}),'Data',Table); 596 609 end 597 610 set(handles.series,'UserData',[])%refresh the stored info 598 611 end 599 nbview=size(InputTable,1); 600 CheckRelabelQuest=false; 612 nbview=size(InputTable,1);% number of lines filled in the Input file table after this cleaning of empty lines 613 614 %% get info on each line of the input table 615 CheckRelabelQuest=true;% will ask for relabeling if relevant 601 616 for iview=1:nbview 602 RootPath=fullfile(InputTable{iview,1},InputTable{iview,2}); 603 Param.Relabel=false; 617 RootPath=fullfile(InputTable{iview,1},InputTable{iview,2});% path of the input file series 618 Param.Relabel=false;% no relabeling by default 604 619 MovieObject=[]; 605 620 Param.FileInfo=[]; 606 621 if ~exist(RootPath,'dir') 607 622 Param.i1_series=[]; 608 RootFile=''; 623 RootFile='';% input folder does not exist, will ask by browser 609 624 else 610 [XmlFileName,Rank]=find_imadoc(InputTable{iview,1},InputTable{iview,2}); 625 [XmlFileName,Rank]=find_imadoc(InputTable{iview,1},InputTable{iview,2});%look for ImaDoc file 611 626 if ~isempty(XmlFileName) 612 XmlData=read_imadoc(XmlFileName); 613 if Rank==0 && ~isempty(XmlData.FileSeries) 614 set(handles.Relabel,'Visible','on') 627 XmlData=read_imadoc(XmlFileName);%read the imadoc file through the local fct read_imadoc 628 if Rank==0 && ~isempty(XmlData.FileSeries)% file relabeling proposed in the xml file 629 set(handles.Relabel,'Visible','on')% make the relabel check box visible 615 630 answer='Yes'; 616 if ~CheckRelabel && ~CheckRelabelQuest% propose to relabel if not selected yet631 if ~CheckRelabel && CheckRelabelQuest% propose to relabel if not selected yet 617 632 answer=msgbox_uvmat('INPUT_Y-N','relabel the frame indices according to the xml info?'); 618 CheckRelabelQuest= true;633 CheckRelabelQuest=false;% will validate the answer for all lines 619 634 end 620 if strcmp(answer,'Yes') 621 set(handles.Relabel,'Value',1) 635 if strcmp(answer,'Yes')% relabel option activated 636 set(handles.Relabel,'Value',1)% activate the relabel option 637 CheckRelabel=true; 622 638 NomType='*'; 623 639 i1=1;i2=[];j1=1;j2=[]; … … 633 649 FirstFile=fullfile(InputTable{iview,1},InputTable{iview,2},XmlData.FileSeries.FileName{1}); 634 650 if ~exist(FirstFile,'file') 635 msgbox_uvmat('ERROR',[FirstFile ' does not exist']);651 errormsg=[FirstFile ' set by the xml file does not exist']; 636 652 return 637 653 end 638 [Param.FileInfo,VideoObject]=get_file_info(FirstFile);654 Param.FileInfo=get_file_info(FirstFile); 639 655 else 640 set(handles.Relabel,'Value',0) 656 set(handles.Relabel,'Value',0) % suppress the relabel option 641 657 end 642 658 end … … 647 663 %scan the input folder 648 664 InputTable{iview,3}=regexprep(InputTable{iview,3},'^/','');%suppress '/' at the beginning of the input name 649 i1=str2double(get(handles.num_first_i,'String')); 650 j1=str2double(get(handles.num_first_j,'String')); 651 j2=[];%default 652 % PairString=get(handles.PairString,'Data'); 653 % if numel(PairString)>=iview 654 % r=regexp(PairString{iview},'(?<num1>\d+)-(?<num2>\d+)' ,'names'); 655 % if ~isempty(r) 656 % j1=str2double(r.num1); 657 % j2=str2double(r.num2); 658 % end 659 % end 660 InputFile=[InputTable{iview,3} InputTable{iview,4} InputTable{iview,5}]; 661 %InputFile=fullfile_uvmat('','',InputTable{iview,3},InputTable{iview,5},InputTable{iview,4},i1,[],j1,j2); 665 InputFile=[InputTable{iview,3} InputTable{iview,4} InputTable{iview,5}]; 662 666 [RootPath,~,RootFile,Param.i1_series,Param.i2_series,Param.j1_series,Param.j2_series,~,Param.FileInfo,MovieObject]=... 663 667 find_file_series(fullfile(InputTable{iview,1},InputTable{iview,2}),InputFile); 664 668 end 665 669 666 % if no file is found on line #iv ew, open a browser670 % if no file is found on line #iview, open a browser 667 671 if ~Param.Relabel && isempty(RootFile)&& isempty(Param.i1_series) 668 672 fileinput=uigetfile_uvmat(['wrong input at line ' num2str(iview) ':pick a new input file'],RootPath); 669 673 if isempty(fileinput) 670 set(handles.REFRESH,'BackgroundColor',[1 0 0])% set REFRESH back to red color674 errormsg='no input file entered'; 671 675 return 672 676 else 673 display_file_name(handles,fileinput,iview)% update the table of input file series , thencall update_rootinfo677 display_file_name(handles,fileinput,iview)% update the table of input file series #iview, then will call update_rootinfo 674 678 end 675 679 else … … 678 682 end 679 683 680 %% update MinIndex_i and MaxIndex_i if the input table content has been reduced in line nbre684 %% suppress possible remaining data beyond nbview lines in MinIndex_i, MaxIndex_i ,MinIndex_j, MaxIndex_j,PairString,TimeTable 681 685 MinIndex_i_table=get(handles.MinIndex_i,'Data'); % retrieve the min indices in the table MinIndex 682 set(handles.MinIndex_i,'Data',MinIndex_i_table(1:nbview,:)); 686 set(handles.MinIndex_i,'Data',MinIndex_i_table(1:nbview)); % save only the nbviews values, remove possible values beyond 687 683 688 MinIndex_j_table=get(handles.MinIndex_j,'Data'); % retrieve the min indices in the table MinIndex 684 set(handles.MinIndex_j,'Data',MinIndex_j_table(1:nbview,:)); 685 MaxIndex_i_table=get(handles.MaxIndex_i,'Data'); % retrieve the min indices in the table MinIndex 686 687 set(handles.MaxIndex_i,'Data',MaxIndex_i_table(1:nbview,:)); 689 set(handles.MinIndex_j,'Data',MinIndex_j_table(1:nbview)); 690 691 MaxIndex_i_table=get(handles.MaxIndex_i,'Data'); % retrieve the max indices in the table MinIndex 692 set(handles.MaxIndex_i,'Data',MaxIndex_i_table(1:nbview)); 693 688 694 MaxIndex_j_table=get(handles.MaxIndex_j,'Data'); % retrieve the min indices in the table MinIndex 689 set(handles.MaxIndex_j,'Data',MaxIndex_j_table(1:nbview,:)); 695 set(handles.MaxIndex_j,'Data',MaxIndex_j_table(1:nbview)); 696 690 697 PairString=get(handles.PairString,'Data'); % retrieve the min indices in the table MinIndex 691 set(handles.PairString,'Data',PairString(1:nbview,:)); 698 set(handles.PairString,'Data',PairString(1:nbview)); 699 692 700 TimeTable=get(handles.TimeTable,'Data'); % retrieve the min indices in the table MinIndex 693 701 set(handles.TimeTable,'Data',TimeTable(1:nbview,:)); 694 702 695 696 703 set(handles.REFRESH,'BackgroundColor',[1 0 0])% set REFRESH button to red color (indicate activation finished) 697 704 set(handles.series,'Pointer','arrow') % set the mouse pointer to 'watch' 698 699 705 700 706 … … 750 756 XmlData=[]; 751 757 if ~isempty(XmlFileName) 752 XmlData=read_imadoc(XmlFileName); 758 XmlData=read_imadoc(XmlFileName);%read the imadoc file through the local fct read_imadoc 753 759 if isfield(XmlData,'FileSeries') && Rank==0 754 760 set(handles.Relabel,'Visible','on') … … 925 931 SeriesData.InputPath=InputPath; 926 932 end 927 928 929 933 set(handles.series,'UserData',SeriesData) 930 931 934 set(handles.InputTable,'BackgroundColor',[1 1 1]) 932 933 934 935 935 936 %% initiate input file series and refresh the current field view: … … 947 948 % --- get info from the xml file XmlFileName 948 949 function XmlData=read_imadoc(XmlFileName) 949 950 %------------------------------------------------------------------------ 950 951 [XmlData,errormsg]=imadoc2struct(XmlFileName); 951 952 if ~isempty(errormsg) … … 1011 1012 if isempty(i1_series) 1012 1013 MinIndex_j=1;MaxIndex_j=1;MinIndex_i=1;MaxIndex_i=1; 1013 elseif size(i1_series,2)==2 && min(min(i1_series(:,1,:)))==0 1014 elseif size(i1_series,2)==2 && min(min(i1_series(:,1,:)))==0 % file series with a single index i 1014 1015 MinIndex_j=1; % index j set to 1 by default 1015 1016 MaxIndex_j=1; … … 1026 1027 diff_i_max=diff(ref_i); 1027 1028 if ~isempty(diff_i_max) && isequal (diff_i_max,diff_i_max(1)*ones(size(diff_i_max))) 1028 set(handles.num_incr_i,'String',num2str(diff_i_max(1)))% detect an increment to disp aly by default1029 set(handles.num_incr_i,'String',num2str(diff_i_max(1)))% detect an increment to display by default 1029 1030 end 1030 1031 if ~isempty(diff_j_max) && isequal (diff_j_max,diff_j_max(1)*ones(size(diff_j_max))) … … 1078 1079 InputTable=get(handles.InputTable,'Data'); 1079 1080 [XmlFileName,Rank]=find_imadoc(InputTable{iview,1},InputTable{iview,2}); 1080 if isempty(XmlFileName) 1081 return 1082 else 1081 if ~isempty(XmlFileName) 1083 1082 Param.XmlData=read_imadoc(XmlFileName); 1084 end 1085 [nbfield,nbfield_j]=size(Param.XmlData.Time); 1086 nbfield=nbfield-1; %remove the possible index 0 1087 nbfield_j=nbfield_j-1; %remove the possible index 0 1088 % MaxIndex_i=get(handles.MaxIndex_i,'Data'); 1089 % MaxIndex_j=get(handles.MaxIndex_j,'Data'); 1090 % MaxIndex_i(1,:)=nbfield; 1091 % MaxIndex_j(1,:)=nbfield_j; 1092 % MinIndex_i(1,:)=1; 1093 % MinIndex_j(1,:)=1; 1094 MaxIndex_i=nbfield; 1095 MaxIndex_j=nbfield_j; 1096 MinIndex_i=1; 1097 MinIndex_j=1; 1098 1083 [nbfield,nbfield_j]=size(Param.XmlData.Time); 1084 nbfield=nbfield-1; %remove the possible index 0 1085 nbfield_j=nbfield_j-1; %remove the possible index 0 1086 MaxIndex_i=nbfield; 1087 MaxIndex_j=nbfield_j; 1088 MinIndex_i=1; 1089 MinIndex_j=1; 1090 end 1099 1091 1100 1092 first_i=str2double(get(handles.num_first_i,'String')); … … 1115 1107 1116 1108 %% determine the min and max times: case of Netcdf files will be treated later in FieldName_Callback 1117 if ~isempty(TimeName) 1109 if isempty(TimeName) 1110 TimeMin=NaN; TimeMax=NaN; TimeFirst=NaN; TimeLast=NaN; 1111 else 1118 1112 if size(Time)<[MaxIndex_i+1 MaxIndex_j+1] 1119 msgbox_uvmat('WARNING', ['incomplete time info in xml file']);1113 msgbox_uvmat('WARNING','incomplete time info in xml file'); 1120 1114 end 1121 1115 TimeMin=Time(MinIndex_i+1,MinIndex_j+1); … … 1143 1137 set(handles.MaxIndex_j,'Data',MaxIndex_j_table)%display the max indices in the table MaxIndex 1144 1138 1145 if isfield(Param .XmlData,'NbSlice') && ~isempty(Param.XmlData.NbSlice)1139 if isfield(Param,'XmlData') && isfield(Param.XmlData,'NbSlice') && ~isempty(Param.XmlData.NbSlice) 1146 1140 set(handles.num_NbSlice,'String',num2str(Param.XmlData.NbSlice)) 1147 1141 set(handles.num_NbSlice,'Visible','on') … … 1223 1217 SeriesData.j1_series{iview}=j1_series; 1224 1218 SeriesData.j2_series{iview}=j2_series; 1225 % SeriesData.FileType{iview}=FileInfo.FileType;1226 1219 SeriesData.FileInfo{iview}=Param.FileInfo; 1227 1220 SeriesData.Time{iview}=Time; … … 1882 1875 drawnow 1883 1876 end 1884 if get(handles.Replicate,'Value') 1877 if get(handles.Replicate,'Value')%resset the input file settings in case of replicated processing 1885 1878 set(handles.InputTable,'Data',Param.InputTable) 1886 1879 set(handles.OutputPath,'String',OutputPath) … … 2416 2409 %------------------------------------------------------------------------ 2417 2410 % --- read parameters from the GUI series 2418 %------------------------------------------------------------------------2419 2411 function Param=read_GUI_series(handles) 2420 2421 %% read raw parameters from the GUI series 2412 %------------------------------------------------------------------------ 2413 2414 % read raw parameters from the GUI series 2422 2415 Param=read_GUI(handles.series); 2423 2416 … … 2559 2552 set(handles.num_CPUTime,'String','') 2560 2553 2554 %------------------------------------------------------------------------ 2561 2555 % --- Executes on button press in ActionInput. 2562 2556 function ActionInput_Callback(hObject, eventdata, handles) 2557 %------------------------------------------------------------------------ 2563 2558 2564 2559 set(handles.ActionInput,'BackgroundColor',[1 1 0]) … … 3093 3088 end 3094 3089 3095 3090 %------------------------------------------------------------------------ 3096 3091 function [TimeValue,DtValue]=get_time(ref_i,ref_j,PairString,InputTable,FileInfo,TimeName,DtName) 3092 %------------------------------------------------------------------------ 3097 3093 [i1,i2,j1,j2] = get_file_index(ref_i,ref_j,PairString); 3098 3094 FileName=fullfile_uvmat(InputTable{1},InputTable{2},InputTable{3},InputTable{5},InputTable{4},i1,i2,j1,j2); … … 3182 3178 end 3183 3179 3184 3185 %%%%%%%%%%%%% 3180 %------------------------------------------------------------------------ 3186 3181 function [ind_remove]=find_pairs(dirpair,ind_i,last_i) 3182 %------------------------------------------------------------------------ 3187 3183 indsel=ind_i; 3188 3184 indiff=diff(ind_i); % test index increment to detect multiplets (several pairs with the same index ind_i) and holes in the series … … 3307 3303 %------------------------------------------------------------------------ 3308 3304 % --- Executes on button press in ViewObject. 3309 %------------------------------------------------------------------------3310 3305 function ViewObject_Callback(hObject, eventdata, handles) 3306 %------------------------------------------------------------------------ 3311 3307 3312 3308 UserData=get(handles.series,'UserData'); … … 3360 3356 %------------------------------------------------------------------------ 3361 3357 % --- Executed when CheckMask is activated 3362 %------------------------------------------------------------------------3363 3358 function CheckMask_Callback(hObject, eventdata, handles) 3359 %------------------------------------------------------------------------ 3364 3360 % SeriesData=get(handles.series,'UserData'); 3365 3361 … … 3484 3480 %------------------------------------------------------------------------ 3485 3481 % --- Executes when selected cell(s) is changed in MaskTable. 3486 %------------------------------------------------------------------------3487 3482 function MaskTable_CellSelectionCallback(hObject, eventdata, handles) 3488 3483 %------------------------------------------------------------------------ 3489 3484 if numel(eventdata.Indices)>=1 3490 3485 set(handles.ListMask,'Value',eventdata.Indices(1)) … … 3494 3489 function MenuHelp_Callback(hObject, eventdata, handles) 3495 3490 %------------------------------------------------------------------- 3496 3497 3498 % path_to_uvmat=which ('uvmat'); % check the path of uvmat 3499 % pathelp=fileparts(path_to_uvmat); 3500 % helpfile=fullfile(pathelp,'uvmat_doc','uvmat_doc.html'); 3501 % if isempty(dir(helpfile)), msgbox_uvmat('ERROR','Please put the help file uvmat_doc.html in the sub-directory /uvmat_doc of the UVMAT package') 3502 % else 3503 % addpath (fullfile(pathelp,'uvmat_doc')) 3504 % web([helpfile '#series']) 3505 % end 3491 web('https://legi.gricad-pages.univ-grenoble-alpes.fr/soft/uvmat-doc/help') 3506 3492 3507 3493 %------------------------------------------------------------------- … … 3580 3566 %------------------------------------------------------------------------ 3581 3567 % --- fct activated by the upper bar menu ExportConfig 3582 %------------------------------------------------------------------------3583 3568 function MenuDisplayConfig_Callback(hObject, eventdata, handles) 3584 3569 %------------------------------------------------------------------------ 3585 3570 global Param 3586 3571 Param=read_GUI_series(handles); 3587 3572 evalin('base','global Param')%make CurData global in the workspace 3588 disp lay('current series config :')3573 disp('current series config :') 3589 3574 evalin('base','Param') %display CurData in the workspace 3590 3575 commandwindow; % brings the Matlab command window to the front … … 3595 3580 %------------------------------------------------------------------------ 3596 3581 function MenuImportConfig_Callback(hObject, eventdata, handles) 3582 %------------------------------------------------------------------------ 3597 3583 3598 3584 %% use a browser to choose the xml file containing the processing config … … 3668 3654 3669 3655 %------------------------------------------------------------------------ 3670 % --- Executes when the GUI series is resized. 3671 %------------------------------------------------------------------------ 3656 % --- Executes when the GUI series is resized.- 3672 3657 function series_ResizeFcn(hObject, eventdata, handles) 3673 3674 %% input table 3658 %------------------------------------------------------------------------ 3659 3660 % input table 3675 3661 set(handles.InputTable,'Unit','pixel') 3676 3662 Pos=get(handles.InputTable,'Position'); … … 3713 3699 set(handles.PairString,'ColumnWidth',{Pos(3)-5}) 3714 3700 3715 %% MaskTable 3716 % % set(handles.MaskTable,'Unit','pixel') 3717 % % Pos=get(handles.MaskTable,'Position'); 3718 % % set(handles.MaskTable,'Unit','normalized') 3719 % % set(handles.MaskTable,'ColumnWidth',{Pos(3)-5}) 3720 3721 %------------------------------------------------------------------------ 3722 % --- Executes on button press in status. 3723 %------------------------------------------------------------------------ 3701 %------------------------------------------------------------------------ 3702 % --- Executes on button press in status.- 3724 3703 function status_Callback(hObject, eventdata, handles) 3725 3704 %------------------------------------------------------------------------ 3726 3705 if get(handles.status,'Value') 3727 3706 set(handles.status,'BackgroundColor',[1 1 0]) … … 3752 3731 end 3753 3732 3754 3755 3733 %------------------------------------------------------------------------ 3756 3734 % launched by selecting a file on the list 3757 %------------------------------------------------------------------------3758 3735 function view_file(hObject, eventdata) 3759 3736 %------------------------------------------------------------------------ 3760 3737 list=get(hObject,'String'); 3761 3738 index=get(hObject,'Value'); … … 3794 3771 end 3795 3772 3796 3797 3773 %------------------------------------------------------------------------ 3798 3774 % launched by refreshing the status figure 3799 %------------------------------------------------------------------------3800 3775 function refresh_GUI(hfig) 3801 3776 %------------------------------------------------------------------------ 3802 3777 htitlebox=findobj(hfig,'tag','titlebox'); 3803 3778 hlist=findobj(hfig,'tag','list'); … … 3858 3833 %------------------------------------------------------------------------ 3859 3834 % --- Executes on selection change in ActionExt. 3860 %------------------------------------------------------------------------3861 3835 function ActionExt_Callback(hObject, eventdata, handles) 3862 3836 %------------------------------------------------------------------------ 3863 3837 ActionExtList=get(handles.ActionExt,'String'); 3864 3838 ActionExt=ActionExtList{get(handles.ActionExt,'Value')}; … … 3912 3886 menu=menu(imin:imax); 3913 3887 3914 3915 % --- Executes on mouse motion over figure - except title and menu. 3916 % function series_WindowButtonMotionFcn(hObject, eventdata, handles) 3917 % set(hObject,'Pointer','arrow'); 3918 3919 3888 %------------------------------------------------------------------------ 3920 3889 % --- Executes on button press in SetPairs. 3921 3890 function SetPairs_Callback(hObject, eventdata, handles) 3922 3891 %------------------------------------------------------------------------ 3923 3892 %% delete previous occurrence of 'set_pairs' 3924 3893 hfig=findobj(allchild(0),'Tag','set_pairs'); … … 4006 3975 %------------------------------------------------------------------------ 4007 3976 function ListView_Callback(hObject,eventdata) 3977 %------------------------------------------------------------------------ 4008 3978 Mode_Callback(hObject,eventdata) 4009 3979 4010 3980 %------------------------------------------------------------------------ 4011 3981 function Mode_Callback(hObject,eventdata) 3982 %------------------------------------------------------------------------ 4012 3983 %% get input info 4013 3984 hseries=findobj(allchild(0),'tag','series'); % handles of the GUI series … … 4025 3996 4026 3997 %% enable j index visibility after the new choice 4027 4028 3998 if strcmp(mode,'series(Dj)') 4029 3999 status_j='on'; % default … … 4073 4043 set(hPairString,'Data',PairString) 4074 4044 4075 4076 4045 %------------------------------------------------------------------------ 4077 4046 function num_ref_i_Callback(hObject, eventdata) … … 4089 4058 delete(get(hObject,'parent')) 4090 4059 4091 4092 4060 %------------------------------------------------------------------------ 4093 4061 % --- Executes on button press in ClearLine. 4094 %------------------------------------------------------------------------4095 4062 function ClearLine_Callback(hObject, eventdata, handles) 4063 %------------------------------------------------------------------------ 4096 4064 InputTable=get(handles.InputTable,'Data'); 4097 4065 iline=str2double(get(handles.InputLine,'String')); … … 4102 4070 set(handles.REFRESH,'BackgroundColor',[1 0 1])% set REFRESH button to magenta color to indicate that input refr 4103 4071 4104 4072 %------------------------------------------------------------------------ 4105 4073 % --- Executes on button press in MonitorCluster. 4106 4074 function MonitorCluster_Callback(hObject, eventdata, handles) 4107 4075 %------------------------------------------------------------------------ 4108 4076 [rr,ss]=system('oarstat |grep N=UVmat');% check the list of jobs launched with uvmat 4109 4077 if isempty(ss) … … 4114 4082 end 4115 4083 4116 4084 %------------------------------------------------------------------------ 4117 4085 function OutputSubDir_Callback(hObject, eventdata, handles) 4086 %------------------------------------------------------------------------ 4118 4087 set(handles.OutputSubDir,'BackgroundColor',[1 1 1]) 4119 4088 … … 4124 4093 % --- Executes on button press in TestCPUTime. 4125 4094 function TestCPUTime_Callback(hObject, eventdata, handles) 4126 % hObject handle to TestCPUTime (see GCBO) 4127 % eventdata reserved - to be defined in a future version of MATLAB 4128 % handles structure with handles and user data (see GUIDATA) 4129 4130 4095 4096 %------------------------------------------------------------------------ 4131 4097 % --- Executes on button press in DiskQuota. 4132 4098 function DiskQuota_Callback(hObject, eventdata, handles) 4099 %------------------------------------------------------------------------ 4133 4100 SeriesData=get(handles.series,'UserData'); 4134 4101 system(SeriesData.DiskQuotaCmd) 4135 4102 4136 4103 %------------------------------------------------------------------------ 4137 4104 % --- Executes on button press in Replicate. 4138 4105 function Replicate_Callback(hObject, eventdata, handles) 4106 %------------------------------------------------------------------------ 4139 4107 if get(handles.Replicate,'Value') 4140 4108 InputTable=get(handles.InputTable,'Data'); … … 4159 4127 function Device_Callback(hObject, eventdata, handles) 4160 4128 4161 4129 %------------------------------------------------------------------------ 4162 4130 % --- Executes on button press in OutputPathBrowse. 4163 4131 function OutputPathBrowse_Callback(hObject, eventdata, handles) 4132 %------------------------------------------------------------------------ 4164 4133 CheckValue=get(handles.OutputPathBrowse,'Value'); 4165 4134 if CheckValue … … 4171 4140 end 4172 4141 4173 4142 %------------------------------------------------------------------------ 4174 4143 % --- Executes on button press in DeleteMask. 4175 4144 function DeleteMask_Callback(hObject, eventdata, handles) 4145 %------------------------------------------------------------------------ 4176 4146 set(handles.MaskTable,'Data',{}) 4177 4147 4178 4148 %------------------------------------------------------------------------ 4179 4149 % --- Executes on button press in Relabel. 4180 4150 function Relabel_Callback(hObject, eventdata, handles) 4151 %------------------------------------------------------------------------ 4181 4152 CheckRelabel=get(hObject,'Value'); 4182 4153 if CheckRelabel … … 4195 4166 end 4196 4167 end 4197 check_input_file_series(handles,CheckRelabel) 4198 ActionInput_Callback([],[], handles) 4199 4200 4168 check_input_file_series(handles,CheckRelabel)% check the min and max relabeled indices, or original ones if CheckRelabel=false 4169 ActionInput_Callback([],[], handles)% %% enable menus (field, vel type,...), in accordance with the current action function 4170 4171
Note: See TracChangeset
for help on using the changeset viewer.
