Changeset 114


Ignore:
Timestamp:
Mar 18, 2010, 3:51:13 PM (9 years ago)
Author:
tjniskan
Message:
  • Still trying to optimize EPI-reading...

M aedes_readfid.m
M aedes_revision.m

Files:
2 edited

Legend:

Unmodified
Added
Removed
  • aedes_readfid.m

    r113 r114  
    894894    switch procpar.seqcon(2:3)
    895895      case {'cc','sc'}
    896         kspace = zeros(hdr.FileHeader.np/2,...
     896        kspace = complex(zeros(hdr.FileHeader.np/2,...
    897897          hdr.FileHeader.ntraces,...
    898           hdr.FileHeader.nblocks,Dat.precision);
     898          hdr.FileHeader.nblocks,Dat.precision));
    899899      otherwise
    900         kspace = zeros(hdr.FileHeader.np/2,...
     900        kspace = complex(zeros(hdr.FileHeader.np/2,...
    901901          hdr.FileHeader.nblocks,...
    902           hdr.FileHeader.ntraces,Dat.precision);
     902          hdr.FileHeader.ntraces,Dat.precision));
    903903    end
    904904  else
    905     kspace = zeros(hdr.FileHeader.np/2,...
     905    kspace = complex(zeros(hdr.FileHeader.np/2,...
    906906      hdr.FileHeader.ntraces,...
    907       hdr.FileHeader.nblocks,Dat.precision);
     907      hdr.FileHeader.nblocks,Dat.precision));
    908908  end
    909909else
    910910  %kspace = [];
    911    kspace = zeros(hdr.FileHeader.np/2*hdr.FileHeader.ntraces,...
    912      hdr.FileHeader.nblocks,Dat.precision);
     911   kspace = complex(zeros(hdr.FileHeader.np/2*hdr.FileHeader.ntraces,...
     912     hdr.FileHeader.nblocks,Dat.precision));
    913913end
    914914
     
    10611061  d=dir(fopen(file_fid));
    10621062  file_sz = d.bytes/1024/1024; % File size in MB
    1063   if file_sz<500
     1063  if file_sz<250
    10641064    nBlocks = 1;
    10651065  else
    1066     nBlocks = ceil(file_sz/500); % Read data in 500 MB blocks
     1066    nBlocks = ceil(file_sz/250); % Read data in 300 MB blocks
    10671067  end
    10681068 
     
    11191119  nVals = (nbheaders*28)/prec;
    11201120 
    1121   count = 1;
    1122   nbh = floor(nbheaders/nBlocks);
     1121  nbh = floor(hdr.FileHeader.nblocks/nBlocks);
    11231122  szh = nVals+hdr.FileHeader.np*hdr.FileHeader.ntraces;
    11241123  for ii=1:nBlocks
     
    11341133   
    11351134    if ii==nBlocks
    1136       inds = ((nBlocks-1)*nbh+1):size(kspace,2);
     1135      inds = ((ii-1)*nbh+1):size(kspace,2);
    11371136    else
    1138       inds = ((nBlocks-1)*nbh+1):nBlocks*nbh;
     1137      inds = ((ii-1)*nbh+1):ii*nbh;
    11391138    end
    11401139   
     
    13291328    data = zeros(procpar.nv,procpar.np/2,procpar.ns,nVols+1,'single');
    13301329    kssz=size(kspace);
    1331     blksz = 500; % Process EPI data in 500 volume blocks
     1330    blksz = 750; % Process EPI data in 750 volume blocks
    13321331    nBlocks = ceil((size(kspace,3)/nRcv)/blksz);
    13331332    lnum = length(num2str(nBlocks));
  • aedes_revision.m

    r113 r114  
    9393% bash-script every time it is called so that this file "aedes_revision.m" is
    9494% always in the list of committed files. DO NOT EDIT THE NEXT LINE!!!
    95 % - SVN Hook -
     95% - Svn Hook -
Note: See TracChangeset for help on using the changeset viewer.

Powered by Trac 1.0.9.Copyright © Juha-Pekka Niskanen 2008