analyzePixelIVF.m 768 B

1234567891011121314151617181920212223242526272829303132
  1. %reset random generator
  2. rng shuffle
  3. %add nrrd processing capability
  4. addpath('nrrd_read_write_rensonnet')
  5. [cax,cm]=loadTime(path,patientID);
  6. %segmFile=fullfile(path,patientID,sprintf('%s_Segmentation.txt',patientID));
  7. %v0=loadPixels(segm,patientID);
  8. [filepath,name,suffix]=fileparts(segmFile);
  9. if suffix=='nrrd'
  10. v0=extractPixelsFromNrrd(segmFile);
  11. end
  12. if suffix=='txt'
  13. v0=dlmread(segmFile);
  14. end
  15. data=loadSPECTdata(path,patientID,cm);
  16. sigma2=str2num(sigma2);
  17. na=7;
  18. fcenters=extractCenters(data,v0,sigma2,na);
  19. %this will write out fitPar
  20. [globalPar, cPars] = fitCentersPixelIVF(path, patientID, cax, cm, fcenters,sigma2);
  21. %[globalPar, cPars, xa, U]=fitFromClusters(path,cax, cm, data, nclass,realizationId);
  22. disp('DynamicPixelAnalysis done');
  23. %writeData