fullRO_beamCalc.m 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  1. function fullRO_beamCalc(Geometry)
  2. % this function will ask for an OptGoal file, and an exit folder, and will
  3. % then create a beamlet set for each of the scenarios specified in the
  4. % OptGoals.
  5. % It will also append the path to the OptGoal file
  6. % choose the OptGoal file
  7. [Obj_file,Obj_path,indx] = uigetfile([Geometry.patient_dir '\matlab_files\*.mat'], 'Select OptGoal file' );
  8. if Obj_file == 0
  9. disp('no file selected, aborting')
  10. return
  11. end
  12. path2goal = [Obj_path, Obj_file];
  13. load(path2goal);
  14. % choose the folder for new beamlets
  15. beamlet_dir = uigetdir([Geometry.patient_dir ], 'Make and select new beamlet folder' );
  16. if beamlet_dir == 0
  17. disp('no file selected, aborting')
  18. return
  19. end
  20. OptGoals.fullRO_beamlet_dir = beamlet_dir;
  21. %% start the modified beamlet calc
  22. % num_batches = helicalDosecalcSetup7_fullRO(Geometry.patient_dir, OptGoals, beamlet_dir)
  23. % num_batches = helicalDosecalcSetup7(Geometry.patient_dir)
  24. % num_batches = helicalDosecalcSetup8(Geometry.patient_dir)
  25. helicalDosecalcSetup7_fullRO(Geometry.patient_dir, OptGoals, beamlet_dir)
  26. % save the appended optGoal file
  27. save(path2goal, 'OptGoals');
  28. end