Changeset 385 for trunk/src


Ignore:
Timestamp:
Mar 29, 2012, 4:50:42 PM (13 years ago)
Author:
sommeria
Message:

bug corrected in find_file_series

Location:
trunk/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/check_field_structure.m

    r382 r385  
    115115        else % DimName is detected in the current list of dimension names
    116116            if ~isequal(Data.DimValue(iprev),sizvar(idim))
    117                 Data.DimValue(iprev)
    118                 sizvar(idim)
    119117                if isequal(Data.DimValue(iprev),2)&& RangeTest(iprev)  % the dimension has been already detected as a range [min max]
    120118                    Data.DimValue(iprev)=sizvar(idim); %update with actual value
  • trunk/src/find_file_series.m

    r384 r385  
    6767    NomTypePref='';
    6868    RootFileNew=RootFile;
    69     if ~isempty(regexp(NomType,['^_']))
    70         NomTypePref='_';
    71         RootFileNew=[RootFileNew '_'];
    72     end
    73     r=regexp(NomType,['^' NomTypePref '(?<num1>\d+)'],'names');%look for a number at the beginning of NomTypeSt
     69%     if ~isempty(regexp(NomType,['^_']))
     70%         NomTypePref='_';
     71%         RootFileNew=[RootFileNew '_'];
     72%     end       RootPath='';
     73    r=regexp(NomType,'^(?<tiretnum>_?\d+)','names');%look for a number or _1 at the beginning of NomType
     74%     r=regexp(NomType,['^' NomTypePref '(?<num1>\d+)'],'names');%look for a number at the beginning of NomTypeSt
    7475    if ~isempty(r)
    75         NomTypePref=[NomTypePref r.num1];
     76        NomTypePref=r.tiretnum;
    7677        fileinput_end=regexprep(fileinput,['^' RootFileNew],'');
    7778        r=regexp(fileinput_end,'^(?<num1>\d+)','names');
     
    8586            j1_input=[];
    8687            j2_input=[];
     88        else
     89            NomTypePref='';
    8790        end
    8891    end
     
    154157    ref_j_list=zeros(1,nbpair);
    155158    if nbpair==0% no detected file
    156         RootPath='';
     159%         RootPath='';
    157160        RootFile='';
    158161    end
     
    223226    [tild,ifile_min]=min(ref_ij(ref_ij>0));
    224227    if isempty(ifile_min)
    225         RootPath='';
     228%         RootPath='';
    226229        RootFile='';
    227230        NomType='';
Note: See TracChangeset for help on using the changeset viewer.