Changeset 5954 for trunk/MagicSoft/Mars/mtemp/mifae
- Timestamp:
- 01/24/05 09:38:42 (20 years ago)
- Location:
- trunk/MagicSoft/Mars/mtemp/mifae
- Files:
-
- 1 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mtemp/mifae/Changelog
r5933 r5954 18 18 19 19 -*-*- END OF LINE -*-*- 20 21 2005/01/24 Eva Domingo 22 * programs/makeHillas.cc 23 programs/makehillas.datacard 24 programs/DISPstd.root, default DISP parameters values 25 - Add Disp computation 20 26 21 27 2005/01/21 Javier Rico -
trunk/MagicSoft/Mars/mtemp/mifae/programs/makeHillas.cc
r5934 r5954 5 5 #include "TString.h" 6 6 #include "TArrayS.h" 7 #include "TFile.h" 8 #include "TH1.h" 9 #include "TH2.h" 10 #include "TProfile.h" 7 11 8 12 #include "MArray.h" … … 66 70 #include "MRanForestCalc.h" 67 71 #include "MRanForestFill.h" 72 #include "MPointingPos.h" 73 #include "MPointingPosCalc.h" 74 #include "MImageParDisp.h" 75 #include "MDispParameters.h" 76 #include "MDispCalc.h" 77 #include "MHDisp.h" 78 #include "MFillH.h" 68 79 69 80 #include "TApplication.h" … … 110 121 Int_t sext = 0; 111 122 TString rffilename; 123 TString dispfilename; 112 124 113 125 const TString defaultcard="makehillas.datacard"; … … 411 423 MIslands isl3; 412 424 MTopology topology; 425 // disp 426 // (read in optimum Disp parameter values) 427 TFile inparam(dispfilename); 428 MDispParameters dispin; 429 dispin.Read("MDispParameters"); 430 inparam.Close(); 431 TArrayD dispPar; 432 dispPar = dispin.GetParameters(); 433 cout << "Optimum parameter values taken for calculating Disp : " << endl; 434 for (Int_t i=0; i<dispPar.GetSize(); i++) 435 { 436 cout << dispPar[i] << ", "; 437 } 438 cout << endl; 439 // Disp results container 440 MImageParDisp imagepardisp; 441 // Disp histograms 442 MHDisp hdisp; 443 hdisp.SetName("MHDispAsym"); 444 hdisp.SetSelectedPos(4); 445 MFillH filldisp("MHDispAsym[MHDisp]", ""); 413 446 414 447 isl.SetName("MIslands"); … … 440 473 plist5.AddToList(&topology); 441 474 plist5.AddToList(&ranforest); 475 plist5.AddToList(&dispin); 476 plist5.AddToList(&imagepardisp); 477 plist5.AddToList(&hdisp); 442 478 443 479 // cuts … … 478 514 MTopologyCalc topcalc; 479 515 516 MPointingPosCalc pointingposcalc; 517 MDispCalc dispcalc; 518 480 519 MContinue applycut(&cut); 481 520 applycut.SetInverted(kTRUE); … … 495 534 write.AddContainer("MIslands" , "Parameters"); 496 535 write.AddContainer("MReportDrive" , "Parameters"); 497 write.AddContainer("MTopology", "Parameters"); 498 write.AddContainer("MHadronness", "Parameters"); 499 536 write.AddContainer("MTopology" , "Parameters"); 537 write.AddContainer("MPointingPos" , "Parameters"); 538 if(rffilename.Length()) 539 write.AddContainer("MHadronness", "Parameters"); 540 if(dispfilename.Length()) 541 write.AddContainer("MImageParDisp" , "Parameters"); 500 542 if (islflag == 2) 501 543 write.AddContainer("MIslands2" , "Parameters"); … … 542 584 if(rffilename.Length()) 543 585 tlist5.AddToList(&hadrcalc); 586 tlist5.AddToList(&pointingposcalc); 587 if(dispfilename.Length()) 588 { 589 tlist5.AddToList(&dispcalc); 590 tlist5.AddToList(&filldisp); 591 } 544 592 tlist5.AddToList(&write); 545 593 if(display) … … 551 599 tlist5.AddToList(disphillas); 552 600 } 553 554 601 555 602 // Create and setup the eventloop … … 564 611 return; 565 612 613 if(dispfilename.Length()) 614 { 615 hdisp.GetHistSize()->Write(); 616 hdisp.GetHistcosZA()->Write(); 617 hdisp.GetSkymapXY()->Write(); 618 hdisp.GetHistMinPar()->Write(); 619 hdisp.GetHistDuDv()->Write(); 620 hdisp.GetHistMinParSize()->Write(); 621 hdisp.GetHistDuSize()->Write(); 622 hdisp.GetHistDvSize()->Write(); 623 hdisp.GetEvCorrAssign()->Write(); 624 } 625 566 626 tlist5.PrintStatistics(); 567 627 delete extractor; … … 688 748 } 689 749 750 // disp file name 751 if(strcmp(word.Data(),"DISP")==0) 752 { 753 if(dispfilename.Length()) 754 cout << "readDataCards Warning: overriding disp file name" << endl; 755 ifun >> dispfilename; 756 } 757 690 758 // cleaning level 691 759 if(strcmp(word.Data(),"EXTRACTOR")==0) … … 752 820 if(rffilename.Length()) 753 821 cout << "Random Forest will be read from " << rffilename << endl; 822 if(dispfilename.Length()) 823 cout << "Disp parameters will be read from " << dispfilename << endl; 754 824 if (islflag == 1 || islflag == 2) 755 825 cout << "Island calcultation..." << "using algorithm #" << kalgorithm <<endl; -
trunk/MagicSoft/Mars/mtemp/mifae/programs/makehillas.datacard
r5933 r5954 67 67 RANFOREST RFstd.root 68 68 69 // Add the following word if you want to apply DISP method analysis, 70 // followed by the name of the file where the MDispParameters container 71 // with the optimal values of the DISP parameters is stored 72 DISP DISPstd.root 73 69 74 //Island calculations 70 75 // 0 same as 1 1:normal algorithm
Note:
See TracChangeset
for help on using the changeset viewer.