From 1f29c2009ba89583e61097abed78ccab4439a576 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Mon, 11 Apr 2022 11:58:14 +0200 Subject: [PATCH 01/42] TRestAxionSolarFlux. Tables are now Float_t. Binary tables are supported. And ReadFluxFile skeleton has been added --- inc/TRestAxionSolarFlux.h | 9 +++--- src/TRestAxionSolarFlux.cxx | 57 ++++++++++++++++++++++++++++++------- 2 files changed, 51 insertions(+), 15 deletions(-) diff --git a/inc/TRestAxionSolarFlux.h b/inc/TRestAxionSolarFlux.h index e435e940..ce5e2dbe 100644 --- a/inc/TRestAxionSolarFlux.h +++ b/inc/TRestAxionSolarFlux.h @@ -23,7 +23,7 @@ #ifndef _TRestAxionSolarFlux #define _TRestAxionSolarFlux -#include +#include #include #include @@ -52,11 +52,11 @@ class TRestAxionSolarFlux : public TRestMetadata { /// Seed used in random generator Int_t fSeed = 0; //< - /// The tabulated solar flux continuum spectra TH1D(100,0,20)keV in cm-2 s-1 keV-1 versus solar radius - std::vector fFluxTable; //! + /// The tabulated solar flux continuum spectra TH1F(100,0,20)keV in cm-2 s-1 keV-1 versus solar radius + std::vector fFluxTable; //! /// The tabulated solar flux in cm-2 s-1 for a number of monochromatic energies versus solar radius - std::map fFluxLines; //! + std::map fFluxLines; //! /// Accumulative integrated solar flux for each solar ring for continuum spectrum (renormalized to unity) std::vector fFluxTableIntegrals; //! @@ -76,6 +76,7 @@ class TRestAxionSolarFlux : public TRestMetadata { /// Random number generator TRandom3* fRandom = nullptr; //! + void ReadFluxFile(); void LoadContinuumFluxTable(); void LoadMonoChromaticFluxTable(); void IntegrateSolarFluxes(); diff --git a/src/TRestAxionSolarFlux.cxx b/src/TRestAxionSolarFlux.cxx index fe1b8fb2..74326528 100644 --- a/src/TRestAxionSolarFlux.cxx +++ b/src/TRestAxionSolarFlux.cxx @@ -69,6 +69,8 @@ /// TODO Implement the method TRestAxionSolarFlux::InitializeSolarTable using /// a solar model description by TRestAxionSolarModel. /// +/// TODO Perhaps it would be interesting to replace fFluxTable for a TH2D +/// ///-------------------------------------------------------------------------- /// /// RESTsoft - Software for Rare Event Searches with TPCs @@ -128,9 +130,12 @@ void TRestAxionSolarFlux::Initialize() { SetSectionName(this->ClassName()); SetLibraryVersion(LIBRARY_VERSION); - LoadContinuumFluxTable(); - - LoadMonoChromaticFluxTable(); + if (fFluxDataFile != "" && TRestTools::GetFileNameExtension(fFluxDataFile) == ".flux") { + ReadFluxFile(); + } else { + LoadContinuumFluxTable(); + LoadMonoChromaticFluxTable(); + } IntegrateSolarFluxes(); @@ -158,23 +163,53 @@ void TRestAxionSolarFlux::LoadContinuumFluxTable() { debug << "Loading table from file : " << endl; debug << "File : " << fullPathName << endl; - std::vector> fluxTable; - TRestTools::ReadASCIITable(fullPathName, fluxTable); + std::vector> fluxTable; + if (TRestTools::GetFileNameExtension(fFluxDataFile) == ".dat") + TRestTools::ReadASCIITable(fullPathName, fluxTable); + else if (TRestTools::IsBinaryFile(fFluxDataFile)) + TRestTools::ReadBinaryTable(fullPathName, fluxTable); + else { + fluxTable.clear(); + ferr << "Filename extension was not recognized!" << endl; + ferr << "Solar flux table will not be populated" << endl; + } if (fluxTable.size() != 100 && fluxTable[0].size() != 200) { fluxTable.clear(); ferr << "LoadContinuumFluxTable. The table does not contain the right number of rows or columns" << endl; - ferr << "Table will not be populated" << endl; + ferr << "Solar flux table will not be populated" << endl; } for (int n = 0; n < fluxTable.size(); n++) { - TH1D* h = new TH1D(Form("%s_ContinuumFluxAtRadius%d", GetName(), n), "", 200, 0, 20); + TH1F* h = new TH1F(Form("%s_ContinuumFluxAtRadius%d", GetName(), n), "", 200, 0, 20); for (int m = 0; m < fluxTable[n].size(); m++) h->SetBinContent(m + 1, fluxTable[n][m]); fFluxTable.push_back(h); } } +/////////////////////////////////////////////// +/// \brief It loads a .flux file. It will split continuum and monochromatic peaks. +/// +void TRestAxionSolarFlux::ReadFluxFile() { + if (fFluxDataFile == "") { + debug << "TRestAxionSolarflux::LoadContinuumFluxTable. No solar flux table was defined" << endl; + return; + } + + string fullPathName = SearchFile((string)fFluxDataFile); + + debug << "Loading table from file : " << endl; + debug << "File : " << fullPathName << endl; + + /* +std::vector> fluxTable; +std::vector> sptTable; + +TRestTools::ReadASCIITable(fname, fluxTable); + */ +} + /////////////////////////////////////////////// /// \brief A helper method to load the data file containning monochromatic spectral /// lines as a function of the solar radius. It will be called by TRestAxionSolarFlux::Initialize. @@ -192,7 +227,7 @@ void TRestAxionSolarFlux::LoadMonoChromaticFluxTable() { debug << "Loading monochromatic lines from file : " << endl; debug << "File : " << fullPathName << endl; - std::vector> asciiTable; + std::vector> asciiTable; TRestTools::ReadASCIITable(fullPathName, asciiTable); fFluxLines.clear(); @@ -204,9 +239,9 @@ void TRestAxionSolarFlux::LoadMonoChromaticFluxTable() { } for (int en = 0; en < asciiTable[0].size(); en++) { - Double_t energy = asciiTable[0][en]; - std::vector profile; - TH1D* h = new TH1D(Form("%s_MonochromeFluxAtEnergy%4.2lf", GetName(), energy), "", 100, 0, 1); + Float_t energy = asciiTable[0][en]; + std::vector profile; + TH1F* h = new TH1F(Form("%s_MonochromeFluxAtEnergy%4.2lf", GetName(), energy), "", 100, 0, 1); for (int r = 1; r < asciiTable.size(); r++) h->SetBinContent(r, asciiTable[r][en]); fFluxLines[energy] = h; } From 38c8639edb381baa23d17852f41ab515a89beac1 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Mon, 11 Apr 2022 20:14:18 +0200 Subject: [PATCH 02/42] TRestAxionSolarFlux. Fixed pipelne and .flux tables integration (WIP) --- inc/TRestAxionSolarFlux.h | 19 +++-- src/TRestAxionSolarFlux.cxx | 163 +++++++++++++++++++++++++++++------- 2 files changed, 144 insertions(+), 38 deletions(-) diff --git a/inc/TRestAxionSolarFlux.h b/inc/TRestAxionSolarFlux.h index ce5e2dbe..8abaf592 100644 --- a/inc/TRestAxionSolarFlux.h +++ b/inc/TRestAxionSolarFlux.h @@ -24,6 +24,7 @@ #define _TRestAxionSolarFlux #include +#include #include #include @@ -35,8 +36,6 @@ class TRestAxionSolarFlux : public TRestMetadata { private: void Initialize(); - void InitFromConfigFile(); - /// The filename containning the solar flux table with continuum spectrum std::string fFluxDataFile = ""; //< @@ -52,6 +51,12 @@ class TRestAxionSolarFlux : public TRestMetadata { /// Seed used in random generator Int_t fSeed = 0; //< + /// It will be used when loading `.flux` files to define the input file energy binsize in eV. + Double_t fBinSize = 0; //< + + /// It will be used when loading `.flux` files to define the threshold for peak identification + Double_t fPeakThreshold = 0; //< + /// The tabulated solar flux continuum spectra TH1F(100,0,20)keV in cm-2 s-1 keV-1 versus solar radius std::vector fFluxTable; //! @@ -93,19 +98,15 @@ class TRestAxionSolarFlux : public TRestMetadata { std::pair GetRandomEnergyAndRadius(); + void LoadTables(); + /// Tables might be loaded using a solar model description by TRestAxionSolarModel void InitializeSolarTable(TRestAxionSolarModel* model) { // TOBE implemented // This method should initialize the tables fFluxTable and fFluxLines } - void ExportTables(std::string fname) { - // TOBE implemented. Creates fname.dat and fname.spt - // If we have external methods to initialize solar flux tables this method - // might be used to generate the tables that can be used later on directly - // - // Check data/solarFlux/README.md for data format and file naming conventions - } + void ExportTables(std::string fname); void PrintMetadata(); diff --git a/src/TRestAxionSolarFlux.cxx b/src/TRestAxionSolarFlux.cxx index 74326528..3fbe885e 100644 --- a/src/TRestAxionSolarFlux.cxx +++ b/src/TRestAxionSolarFlux.cxx @@ -48,6 +48,18 @@ /// while the next 100 elements contain the flux, measured in cm-2 s-1, integrated to /// each solar ring, being the second element the ring in the center of the sun. /// +/// Additionally this class will be able to read `.flux` files that are the original files +/// produced in 3-columns format (inner radius [solar units] / energy [keV] / +/// flux [cm-2 s-1 keV-1]). The `.flux` files may contain the full information, +/// continuum and spectral. Those components will be splited into two independent +/// contributions by TRestAxionSolarFlux::ReadFluxFile to be managed internally. Two +/// additional parameters *will be required* to translate the `.flux` files into the tables +/// that are understood by this class. +/// - *binSize:* The energy binning used on the `.flux` file. +/// - *peakThreshold:* The ratio between the flux provided at the `.flux` file and the +/// average flux calculated in 100eV steps. If the flux ratio is higher than this value, +/// the flux at that particular bin will be considered a peak. +/// /// The following code shows how to define this class inside a RML file. /// /// \code @@ -59,6 +71,10 @@ /// /// \endcode /// +/// When the flux is loaded manually inside the `restRoot` interface or inside a +/// macro or script, after metadata initialization, it is necessary to call +/// the method TRestAxionSolarFlux::LoadTables. +/// /// The previous definition was used to generate the following figure using the script /// pipeline/solarFlux/solarFlux.py. /// @@ -130,7 +146,17 @@ void TRestAxionSolarFlux::Initialize() { SetSectionName(this->ClassName()); SetLibraryVersion(LIBRARY_VERSION); - if (fFluxDataFile != "" && TRestTools::GetFileNameExtension(fFluxDataFile) == ".flux") { + LoadTables(); +} + +/////////////////////////////////////////////// +/// \brief It will load the tables in memory by using the filename information provided +/// inside the metadata members. +/// +void TRestAxionSolarFlux::LoadTables() { + if (fFluxDataFile == "" && fFluxSptFile == "") return; + + if (TRestTools::GetFileNameExtension(fFluxDataFile) == "flux") { ReadFluxFile(); } else { LoadContinuumFluxTable(); @@ -154,7 +180,9 @@ void TRestAxionSolarFlux::Initialize() { /// void TRestAxionSolarFlux::LoadContinuumFluxTable() { if (fFluxDataFile == "") { - debug << "TRestAxionSolarflux::LoadContinuumFluxTable. No solar flux table was defined" << endl; + debug << "TRestAxionSolarflux::LoadContinuumFluxTable. No solar flux continuum table was " + "defined" + << endl; return; } @@ -164,9 +192,14 @@ void TRestAxionSolarFlux::LoadContinuumFluxTable() { debug << "File : " << fullPathName << endl; std::vector> fluxTable; - if (TRestTools::GetFileNameExtension(fFluxDataFile) == ".dat") - TRestTools::ReadASCIITable(fullPathName, fluxTable); - else if (TRestTools::IsBinaryFile(fFluxDataFile)) + if (TRestTools::GetFileNameExtension(fFluxDataFile) == "dat") { + std::vector> doubleTable; + TRestTools::ReadASCIITable(fullPathName, doubleTable); + for (const auto& row : doubleTable) { + std::vector floatVec(row.begin(), row.end()); + fluxTable.push_back(floatVec); + } + } else if (TRestTools::IsBinaryFile(fFluxDataFile)) TRestTools::ReadBinaryTable(fullPathName, fluxTable); else { fluxTable.clear(); @@ -188,28 +221,6 @@ void TRestAxionSolarFlux::LoadContinuumFluxTable() { } } -/////////////////////////////////////////////// -/// \brief It loads a .flux file. It will split continuum and monochromatic peaks. -/// -void TRestAxionSolarFlux::ReadFluxFile() { - if (fFluxDataFile == "") { - debug << "TRestAxionSolarflux::LoadContinuumFluxTable. No solar flux table was defined" << endl; - return; - } - - string fullPathName = SearchFile((string)fFluxDataFile); - - debug << "Loading table from file : " << endl; - debug << "File : " << fullPathName << endl; - - /* -std::vector> fluxTable; -std::vector> sptTable; - -TRestTools::ReadASCIITable(fname, fluxTable); - */ -} - /////////////////////////////////////////////// /// \brief A helper method to load the data file containning monochromatic spectral /// lines as a function of the solar radius. It will be called by TRestAxionSolarFlux::Initialize. @@ -227,8 +238,16 @@ void TRestAxionSolarFlux::LoadMonoChromaticFluxTable() { debug << "Loading monochromatic lines from file : " << endl; debug << "File : " << fullPathName << endl; + std::vector> doubleTable; + TRestTools::ReadASCIITable(fullPathName, doubleTable); + std::vector> asciiTable; - TRestTools::ReadASCIITable(fullPathName, asciiTable); + for (const auto& row : doubleTable) { + std::vector floatVec(row.begin(), row.end()); + asciiTable.push_back(floatVec); + } + + TRestTools::PrintTable(asciiTable, 0, 10); fFluxLines.clear(); @@ -247,6 +266,73 @@ void TRestAxionSolarFlux::LoadMonoChromaticFluxTable() { } } +/////////////////////////////////////////////// +/// \brief It loads a .flux file. It will split continuum and monochromatic peaks, loading +/// both internal flux tables. +/// +void TRestAxionSolarFlux::ReadFluxFile() { + if (fFluxDataFile == "") { + ferr << "TRestAxionSolarflux::ReadFluxFile. No solar flux table was defined" << endl; + return; + } + + if (fBinSize <= 0) { + ferr << "TRestAxionSolarflux::ReadFluxFile. Energy bin size of .flux file must be specified." << endl; + ferr << "Please, define binSize parameter in eV." << endl; + return; + } + + if (fPeakThreshold <= 0) { + warning + << "TRestAxionSolarflux::ReadFluxFile. Peak threshold must be specified to generate .spt file." + << endl; + warning + << "Only continuum table will be generated. If this was intentional, please, ignore this warning." + << endl; + return; + } + + string fullPathName = SearchFile((string)fFluxDataFile); + + debug << "Loading flux table ... " << endl; + debug << "File : " << fullPathName << endl; + std::vector> fluxData; + TRestTools::ReadASCIITable(fullPathName, fluxData, 3); + + TH2F* h = new TH2F(Form("%s_ContinuumFlux", GetName()), "", 100, 0., 1., 200, 0., 20.); + + for (const auto& data : fluxData) { + Double_t r = 0.005 + data[0]; + Double_t en = data[1] - 0.005; + Double_t flux = data[2] * fBinSize / 0.1; // contribution to 100 eV bin + + h->Fill(r, en, flux); + } + + std::map> energies; + for (const auto& data : fluxData) { + Double_t r = 0.005 + data[0]; + Double_t en = data[1] - 0.005; + Double_t flux = data[2] * 1000 / fBinSize; // per eV + + Int_t binR = h->GetXaxis()->FindBin(r); + Int_t binE = h->GetYaxis()->FindBin(en); + + Double_t continuumFlux = h->GetBinContent(binR, binE) / 100; // per eV + + if (flux > fPeakThreshold * continuumFlux) { + cout << "Identified peak at radius : " << r << " and energy: " << en << endl; + } + + /* + std::vector> fluxTable; + std::vector> sptTable; + + TRestTools::ReadASCIITable(fname, fluxTable); + */ + } +} + /////////////////////////////////////////////// /// \brief A helper method to initialize the internal class data members with the /// integrated flux for each solar ring. It will be called by TRestAxionSolarFlux::Initialize. @@ -254,6 +340,7 @@ void TRestAxionSolarFlux::LoadMonoChromaticFluxTable() { void TRestAxionSolarFlux::IntegrateSolarFluxes() { fFluxLineIntegrals.clear(); fTotalMonochromaticFlux = 0; + for (const auto& line : fFluxLines) { fTotalMonochromaticFlux += line.second->Integral(); fFluxLineIntegrals.push_back(fTotalMonochromaticFlux); @@ -275,6 +362,7 @@ void TRestAxionSolarFlux::IntegrateSolarFluxes() { /////////////////////////////////////////////// /// \brief Initialization of TRestAxionSolarFlux metadata members through a RML file /// +/* void TRestAxionSolarFlux::InitFromConfigFile() { debug << "Entering TRestAxionSolarFlux::InitFromConfigFile" << endl; @@ -285,7 +373,7 @@ void TRestAxionSolarFlux::InitFromConfigFile() { fSeed = StringToInteger(GetParameter("seed", "0")); this->Initialize(); -} +} */ /////////////////////////////////////////////// /// \brief It returns a random solar radius position and energy according to the @@ -378,6 +466,8 @@ void TRestAxionSolarFlux::PrintMetadata() { metadata << " - Total continuum flux : " << fTotalContinuumFlux << " cm-2 s-1" << endl; metadata << "--------" << endl; metadata << " - Random seed : " << fSeed << endl; + if (fBinSize > 0) metadata << " - Energy bin size : " << fBinSize * units("eV") << " eV" << endl; + if (fPeakThreshold > 0) metadata << " - Peak identification threshold : " << fPeakThreshold << endl; metadata << "++++++++++++++++++" << endl; if (GetVerboseLevel() >= REST_Debug) { @@ -386,3 +476,18 @@ void TRestAxionSolarFlux::PrintMetadata() { PrintIntegratedRingFlux(); } } + +/////////////////////////////////////////////// +/// \brief It will create files with the continuum and spectral flux components to be used +/// in a later ocasion. +/// +void TRestAxionSolarFlux::ExportTables(string fname) { + // TODO if we have loaded the data through TRestAxionSolarModel we should + // create the filename on base to that + + // TOBE implemented. Creates fname.N200f and fname.spt + // If we have external methods to initialize solar flux tables this method + // might be used to generate the tables that can be used later on directly + + // Check data/solarFlux/README.md for data format and file naming conventions +} From 8d445aeb536cd0a8a5cfb4ba5e74b6ebd83ca993 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Tue, 12 Apr 2022 14:24:19 +0200 Subject: [PATCH 03/42] Updating PR badges and template description --- .github/pr-badge.yml | 19 +++++++++++++------ .github/pull_request_template.md | 28 ++++++++++++++++++++++------ 2 files changed, 35 insertions(+), 12 deletions(-) diff --git a/.github/pr-badge.yml b/.github/pr-badge.yml index c52c80ae..1f3b4dea 100644 --- a/.github/pr-badge.yml +++ b/.github/pr-badge.yml @@ -1,12 +1,19 @@ -- label: "PR Size" - message: "Large" - color: "red" - when: "$additions > 40" - label: "PR submitted by:" message: "$payload.pull_request.user.login" color: "blue" -- label: "Size" - message: "$additions" +- label: "PR Size" + message: "Large: $additions" + color: "red" + when: "$additions > 250" +- label: "PR Size" + message: "Medium: $additions" color: "orange" + when: "$additions > 99 && $additions < 251" +- label: "PR Size" + message: "Ok: $additions" + color: "green" + when: "$additions < 100" - imageUrl: "https://gitlab.cern.ch/rest-for-physics/axionlib/badges/$branchName/pipeline.svg" url: "https://gitlab.cern.ch/rest-for-physics/axionlib/-/commits/$branchName" +- imageUrl: "https://gitlab.cern.ch/rest-for-physics/framework/badges/$branchName/pipeline.svg" + url: "https://gitlab.cern.ch/rest-for-physics/framework/-/commits/$branchName" diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index f644d33f..21e3bd71 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -1,10 +1,26 @@ +Please, REMOVE this text! This is just a template to serve as a reminder. + +Please, give as much detail as possible at your PR and create the simplest possible PR to facilitate reviewing. + +If your PR fixes a given issue, please specify the number followed by # + Fixes # -Changes proposed in this pull-request: -- -- -- +Give a detailed list of changes proposed in this pull-request. For example: +- Feature added ... +- Upgraded class TRestXYZ to ... +- Added pipeline validation ... +- Documented ... +- Example added at ... +- Script ... + + +Once your PR is approved remember to **increase this library version** version following [these instructions](https://rest-for-physics.github.io/rest-advanced/new-release.html#generating-a-new-rest-library-version-release). Remember to have a look to our general [contribution guide](https://github.com/rest-for-physics/axionlib/blob/master/CONTRIBUTING.md). + +Reminder: Please, new features and upgrades should be sufficiently documented and a corresponding validation test at the pipeline should be implemented. + +Reminder: Adding this to your PR description will notify members at the library_dev team: @rest-for-physics/rawlib -Reminder: New features and upgrades should be sufficiently documented and a corresponding validation test at the pipeline should be implemented. +Reminder: When writing your PR description remember to leave any necessary instructions to test the new implementation. -@rest-for-physics/core_dev +Reminder: to set-up the PR in the draft state when there is still work in progress, and make it ready once all pipelines have suceeded. From e71942c1381030c517289f8b773bb0666a96c8b0 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Tue, 12 Apr 2022 20:00:36 +0200 Subject: [PATCH 04/42] solarFlux.py adding LoadTables call --- pipeline/metadata/solarFlux/solarFlux.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pipeline/metadata/solarFlux/solarFlux.py b/pipeline/metadata/solarFlux/solarFlux.py index 88f4488c..8b9646ce 100755 --- a/pipeline/metadata/solarFlux/solarFlux.py +++ b/pipeline/metadata/solarFlux/solarFlux.py @@ -26,6 +26,8 @@ pad1.Draw() combinedFlux = ROOT.TRestAxionSolarFlux("fluxes.rml", "combined") +combinedFlux.LoadTables() +monoFlux.PrintMetadata() if combinedFlux.GetError(): print ( combinedFlux.GetErrorMessage() ) @@ -87,6 +89,8 @@ c1.Print(outfname) monoFlux = ROOT.TRestAxionSolarFlux("fluxes.rml", "mono") +monoFlux.LoadTables() +monoFlux.PrintMetadata() if monoFlux.GetError(): print ( monoFlux.GetErrorMessage() ) @@ -101,6 +105,8 @@ print ("[\033[92m OK \x1b[0m]") continuumFlux = ROOT.TRestAxionSolarFlux("fluxes.rml", "Gianotti") +continuumFlux.LoadTables() +continuumFlux.PrintMetadata() if continuumFlux.GetError(): print ( continuumFlux.GetErrorMessage() ) From da1c4f4f901da364b289522a73378d1891b0192c Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Tue, 12 Apr 2022 20:05:20 +0200 Subject: [PATCH 05/42] Adding new solar flux definitions --- pipeline/metadata/solarFlux/fluxes.rml | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/pipeline/metadata/solarFlux/fluxes.rml b/pipeline/metadata/solarFlux/fluxes.rml index edcc41b2..d7cb7e94 100644 --- a/pipeline/metadata/solarFlux/fluxes.rml +++ b/pipeline/metadata/solarFlux/fluxes.rml @@ -6,7 +6,7 @@ --> - + @@ -16,7 +16,7 @@ - + @@ -24,7 +24,7 @@ - + @@ -32,12 +32,23 @@ - + + + + + + + + + + + + From 74d86af9ba4ee724966876682748fc74aa59a895 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Tue, 12 Apr 2022 20:06:05 +0200 Subject: [PATCH 06/42] solarFlux.py fixing a typo --- pipeline/metadata/solarFlux/solarFlux.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pipeline/metadata/solarFlux/solarFlux.py b/pipeline/metadata/solarFlux/solarFlux.py index 8b9646ce..a916e8b8 100755 --- a/pipeline/metadata/solarFlux/solarFlux.py +++ b/pipeline/metadata/solarFlux/solarFlux.py @@ -27,7 +27,7 @@ combinedFlux = ROOT.TRestAxionSolarFlux("fluxes.rml", "combined") combinedFlux.LoadTables() -monoFlux.PrintMetadata() +combinedFlux.PrintMetadata() if combinedFlux.GetError(): print ( combinedFlux.GetErrorMessage() ) From 4ae207bf73573f6bb4e408f331a092050164d165 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Tue, 12 Apr 2022 22:02:20 +0200 Subject: [PATCH 07/42] compare.py fix name in RML --- pipeline/metadata/solarFlux/compare.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pipeline/metadata/solarFlux/compare.py b/pipeline/metadata/solarFlux/compare.py index 00da2726..6b1d45b8 100755 --- a/pipeline/metadata/solarFlux/compare.py +++ b/pipeline/metadata/solarFlux/compare.py @@ -25,7 +25,7 @@ pad1.Divide(2,1) pad1.Draw() -primakoffLH = ROOT.TRestAxionSolarFlux("fluxes.rml", "LennertHoof") +primakoffLH = ROOT.TRestAxionSolarFlux("fluxes.rml", "LennertHoofPrimakoff") primakoffG = ROOT.TRestAxionSolarFlux("fluxes.rml", "Gianotti") if primakoffLH.GetError(): From 35740dd6c7c922bf09f60430a21e2012706ce1cf Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Tue, 12 Apr 2022 22:15:16 +0200 Subject: [PATCH 08/42] Adding additional output at solarFlux.py --- pipeline/metadata/solarFlux/solarFlux.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pipeline/metadata/solarFlux/solarFlux.py b/pipeline/metadata/solarFlux/solarFlux.py index a916e8b8..679d99ec 100755 --- a/pipeline/metadata/solarFlux/solarFlux.py +++ b/pipeline/metadata/solarFlux/solarFlux.py @@ -64,6 +64,7 @@ enSpt.SetStats(0) enSpt.Draw() if ( enSpt.GetMaximumBin() != 41 ): + print ( "\nMaximum Bin is not the expected one! Exit code : 1" ) exit(1) pad1.cd(3) @@ -73,6 +74,7 @@ rSpt.SetStats(0) rSpt.Draw() if ( rSpt.GetMaximumBin() != 25 ): + print ( "\nMaximum Bin is not the expected one! Exit code : 2" ) exit(2) pad1.cd(4) From b37e6696d5e712b59bfd9ae72f417ab1ff3368a1 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Tue, 12 Apr 2022 22:16:58 +0200 Subject: [PATCH 09/42] TRestAxionSolarFlux added fLoadedTable to control if tables have been loaded --- inc/TRestAxionSolarFlux.h | 3 +++ src/TRestAxionSolarFlux.cxx | 4 ++++ 2 files changed, 7 insertions(+) diff --git a/inc/TRestAxionSolarFlux.h b/inc/TRestAxionSolarFlux.h index 8abaf592..9ffefb3f 100644 --- a/inc/TRestAxionSolarFlux.h +++ b/inc/TRestAxionSolarFlux.h @@ -81,6 +81,9 @@ class TRestAxionSolarFlux : public TRestMetadata { /// Random number generator TRandom3* fRandom = nullptr; //! + /// A metadata member to control if the tables have been loaded + Bool_t fTablesLoaded = false; //! + void ReadFluxFile(); void LoadContinuumFluxTable(); void LoadMonoChromaticFluxTable(); diff --git a/src/TRestAxionSolarFlux.cxx b/src/TRestAxionSolarFlux.cxx index 3fbe885e..1c9ce95d 100644 --- a/src/TRestAxionSolarFlux.cxx +++ b/src/TRestAxionSolarFlux.cxx @@ -146,6 +146,7 @@ void TRestAxionSolarFlux::Initialize() { SetSectionName(this->ClassName()); SetLibraryVersion(LIBRARY_VERSION); + fTablesLoaded = false; LoadTables(); } @@ -172,6 +173,8 @@ void TRestAxionSolarFlux::LoadTables() { fRandom = new TRandom3(fSeed); if (fSeed == 0) fSeed = fRandom->GetSeed(); + + fTablesLoaded = true; } /////////////////////////////////////////////// @@ -381,6 +384,7 @@ void TRestAxionSolarFlux::InitFromConfigFile() { /// std::pair TRestAxionSolarFlux::GetRandomEnergyAndRadius() { std::pair result = {0, 0}; + if (!fTablesLoaded) return result; Double_t rnd = fRandom->Rndm(); if (fTotalMonochromaticFlux == 0 || fRandom->Rndm() > fFluxRatio) { // Continuum From e294fe70814dd9ef3d8d7ffc7c6ac178c3a868d7 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Fri, 15 Apr 2022 13:04:55 +0200 Subject: [PATCH 10/42] Deleted pipeline/metadata/fluxes.rml that will be placed now at ./data/solarFlux/ directory --- pipeline/metadata/solarFlux/fluxes.rml | 54 -------------------------- 1 file changed, 54 deletions(-) delete mode 100644 pipeline/metadata/solarFlux/fluxes.rml diff --git a/pipeline/metadata/solarFlux/fluxes.rml b/pipeline/metadata/solarFlux/fluxes.rml deleted file mode 100644 index d7cb7e94..00000000 --- a/pipeline/metadata/solarFlux/fluxes.rml +++ /dev/null @@ -1,54 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - From 583103ddc5ee34c803a89bcb6740330a1c15e4dd Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Fri, 15 Apr 2022 13:06:52 +0200 Subject: [PATCH 11/42] TRestAxionSolarFlux::ReadFluxFile implemented --- inc/TRestAxionSolarFlux.h | 2 +- src/TRestAxionSolarFlux.cxx | 117 +++++++++++++++++++++++------------- 2 files changed, 77 insertions(+), 42 deletions(-) diff --git a/inc/TRestAxionSolarFlux.h b/inc/TRestAxionSolarFlux.h index 9ffefb3f..ef21610e 100644 --- a/inc/TRestAxionSolarFlux.h +++ b/inc/TRestAxionSolarFlux.h @@ -55,7 +55,7 @@ class TRestAxionSolarFlux : public TRestMetadata { Double_t fBinSize = 0; //< /// It will be used when loading `.flux` files to define the threshold for peak identification - Double_t fPeakThreshold = 0; //< + Double_t fPeakRatio = 0; //< /// The tabulated solar flux continuum spectra TH1F(100,0,20)keV in cm-2 s-1 keV-1 versus solar radius std::vector fFluxTable; //! diff --git a/src/TRestAxionSolarFlux.cxx b/src/TRestAxionSolarFlux.cxx index 1c9ce95d..30b9608a 100644 --- a/src/TRestAxionSolarFlux.cxx +++ b/src/TRestAxionSolarFlux.cxx @@ -56,9 +56,9 @@ /// additional parameters *will be required* to translate the `.flux` files into the tables /// that are understood by this class. /// - *binSize:* The energy binning used on the `.flux` file. -/// - *peakThreshold:* The ratio between the flux provided at the `.flux` file and the -/// average flux calculated in 100eV steps. If the flux ratio is higher than this value, -/// the flux at that particular bin will be considered a peak. +/// - *peakRatio:* The ratio between the flux provided at the `.flux` file and the +/// average flux calculated in the peak surroundings. If the flux ratio is higher than +/// this value, the flux at that particular bin will be considered a peak. /// /// The following code shows how to define this class inside a RML file. /// @@ -127,8 +127,6 @@ TRestAxionSolarFlux::TRestAxionSolarFlux() : TRestMetadata() {} /// corresponding TRestAxionMagneticField section inside the RML. /// TRestAxionSolarFlux::TRestAxionSolarFlux(const char* cfgFileName, string name) : TRestMetadata(cfgFileName) { - cout << "Entering TRestAxionSolarFlux constructor( cfgFileName, name )" << endl; - LoadConfigFromFile(fConfigFileName, name); if (GetVerboseLevel() >= REST_Info) PrintMetadata(); @@ -262,7 +260,6 @@ void TRestAxionSolarFlux::LoadMonoChromaticFluxTable() { for (int en = 0; en < asciiTable[0].size(); en++) { Float_t energy = asciiTable[0][en]; - std::vector profile; TH1F* h = new TH1F(Form("%s_MonochromeFluxAtEnergy%4.2lf", GetName(), energy), "", 100, 0, 1); for (int r = 1; r < asciiTable.size(); r++) h->SetBinContent(r, asciiTable[r][en]); fFluxLines[energy] = h; @@ -274,21 +271,16 @@ void TRestAxionSolarFlux::LoadMonoChromaticFluxTable() { /// both internal flux tables. /// void TRestAxionSolarFlux::ReadFluxFile() { - if (fFluxDataFile == "") { - ferr << "TRestAxionSolarflux::ReadFluxFile. No solar flux table was defined" << endl; - return; - } - if (fBinSize <= 0) { ferr << "TRestAxionSolarflux::ReadFluxFile. Energy bin size of .flux file must be specified." << endl; ferr << "Please, define binSize parameter in eV." << endl; return; } - if (fPeakThreshold <= 0) { - warning - << "TRestAxionSolarflux::ReadFluxFile. Peak threshold must be specified to generate .spt file." - << endl; + if (fPeakRatio <= 0) { + warning << "TRestAxionSolarflux::ReadFluxFile. Peak ratio must be specified to generate " + "monochromatic spectrum." + << endl; warning << "Only continuum table will be generated. If this was intentional, please, ignore this warning." << endl; @@ -302,37 +294,80 @@ void TRestAxionSolarFlux::ReadFluxFile() { std::vector> fluxData; TRestTools::ReadASCIITable(fullPathName, fluxData, 3); - TH2F* h = new TH2F(Form("%s_ContinuumFlux", GetName()), "", 100, 0., 1., 200, 0., 20.); + TH2F* originalHist = + new TH2F(Form("FullTable", GetName()), "", 100, 0., 1., (Int_t)(20. / fBinSize), 0., 20.); + TH2F* continuumHist = + new TH2F(Form("ContinuumTable", GetName()), "", 100, 0., 1., (Int_t)(20. / fBinSize), 0., 20.); + TH2F* spectrumHist = + new TH2F(Form("LinesTable", GetName()), "", 100, 0., 1., (Int_t)(20. / fBinSize), 0., 20.); for (const auto& data : fluxData) { Double_t r = 0.005 + data[0]; Double_t en = data[1] - 0.005; - Double_t flux = data[2] * fBinSize / 0.1; // contribution to 100 eV bin + Double_t flux = data[2] * fBinSize; // flux in cm-2 s-1 bin-1 - h->Fill(r, en, flux); + originalHist->Fill(r, en, flux); + continuumHist->Fill(r, en, flux); } - std::map> energies; - for (const auto& data : fluxData) { - Double_t r = 0.005 + data[0]; - Double_t en = data[1] - 0.005; - Double_t flux = data[2] * 1000 / fBinSize; // per eV + Int_t peaks = 0; + do { + peaks = 0; + // We just identify pronounced peaks, not smoothed gaussians! + const int smearPoints = (Int_t)(5 / (fBinSize * 100)); + for (const auto& data : fluxData) { + Float_t r = 0.005 + data[0]; + Float_t en = data[1] - 0.005; + Float_t flux = data[2]; // flux per cm-2 s-1 keV-1 + + Int_t binR = continuumHist->GetXaxis()->FindBin(r); + Int_t binE = continuumHist->GetYaxis()->FindBin(en); + + Double_t avgFlux = 0; + Int_t n = 0; + for (int e = binE - smearPoints; e <= binE + smearPoints; e++) { + if (e < 1 || e == binE) continue; + n++; + avgFlux += continuumHist->GetBinContent(binR, e); + } + avgFlux /= n; - Int_t binR = h->GetXaxis()->FindBin(r); - Int_t binE = h->GetYaxis()->FindBin(en); + Float_t targetBinFlux = continuumHist->GetBinContent(binR, binE); + Float_t thrFlux = avgFlux * fPeakRatio; + if (targetBinFlux > 0 && targetBinFlux > thrFlux) { + continuumHist->SetBinContent(binR, binE, avgFlux); + peaks++; + } + } + } while (peaks > 0); - Double_t continuumFlux = h->GetBinContent(binR, binE) / 100; // per eV + for (int n = 0; n < originalHist->GetNbinsX(); n++) + for (int m = 0; m < originalHist->GetNbinsY(); m++) { + Float_t orig = originalHist->GetBinContent(n + 1, m + 1); + Float_t cont = continuumHist->GetBinContent(n + 1, m + 1); - if (flux > fPeakThreshold * continuumFlux) { - cout << "Identified peak at radius : " << r << " and energy: " << en << endl; + spectrumHist->SetBinContent(n + 1, m + 1, orig - cont); } - /* - std::vector> fluxTable; - std::vector> sptTable; + continuumHist->Rebin2D(1, (Int_t)(0.1 / fBinSize)); // cm-2 s-1 (100eV)-1 + continuumHist->Scale(10); // cm-2 s-1 keV-1 + // It could be over here if we would use directly a TH2D - TRestTools::ReadASCIITable(fname, fluxTable); - */ + fFluxTable.clear(); + for (int n = 0; n < continuumHist->GetNbinsX(); n++) { + TH1F* hc = + (TH1F*)continuumHist->ProjectionY(Form("%s_ContinuumFluxAtRadius%d", GetName(), n), n + 1, n + 1); + fFluxTable.push_back(hc); + } + + fFluxLines.clear(); + for (int n = 0; n < spectrumHist->GetNbinsY(); n++) { + if (spectrumHist->ProjectionX("", n + 1, n + 1)->Integral() > 0) { + Double_t energy = spectrumHist->ProjectionY()->GetBinCenter(n + 1); + TH1F* hm = (TH1F*)spectrumHist->ProjectionX( + Form("%s_MonochromeFluxAtEnergy%4.2lf", GetName(), energy), n + 1, n + 1); + fFluxLines[energy] = hm; + } } } @@ -367,15 +402,15 @@ void TRestAxionSolarFlux::IntegrateSolarFluxes() { /// /* void TRestAxionSolarFlux::InitFromConfigFile() { - debug << "Entering TRestAxionSolarFlux::InitFromConfigFile" << endl; +debug << "Entering TRestAxionSolarFlux::InitFromConfigFile" << endl; - fFluxDataFile = GetParameter("fluxDataFile", ""); - fFluxSptFile = GetParameter("fluxSptFile", ""); - fCouplingType = GetParameter("couplingType", "g_ag"); - fCouplingStrength = StringToDouble(GetParameter("couplingStrength", "1.e-10")); - fSeed = StringToInteger(GetParameter("seed", "0")); +fFluxDataFile = GetParameter("fluxDataFile", ""); +fFluxSptFile = GetParameter("fluxSptFile", ""); +fCouplingType = GetParameter("couplingType", "g_ag"); +fCouplingStrength = StringToDouble(GetParameter("couplingStrength", "1.e-10")); +fSeed = StringToInteger(GetParameter("seed", "0")); - this->Initialize(); +this->Initialize(); } */ /////////////////////////////////////////////// @@ -471,7 +506,7 @@ void TRestAxionSolarFlux::PrintMetadata() { metadata << "--------" << endl; metadata << " - Random seed : " << fSeed << endl; if (fBinSize > 0) metadata << " - Energy bin size : " << fBinSize * units("eV") << " eV" << endl; - if (fPeakThreshold > 0) metadata << " - Peak identification threshold : " << fPeakThreshold << endl; + if (fPeakRatio > 0) metadata << " - Peak/continuum ratio : " << fPeakRatio << endl; metadata << "++++++++++++++++++" << endl; if (GetVerboseLevel() >= REST_Debug) { From a394af7eceab225e01ca3daedc0fc46dae355b7a Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Fri, 15 Apr 2022 13:07:48 +0200 Subject: [PATCH 12/42] TRestAxionSolarFlux::InitFromConfigFile removed --- src/TRestAxionSolarFlux.cxx | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/src/TRestAxionSolarFlux.cxx b/src/TRestAxionSolarFlux.cxx index 30b9608a..b8cd6be2 100644 --- a/src/TRestAxionSolarFlux.cxx +++ b/src/TRestAxionSolarFlux.cxx @@ -397,22 +397,6 @@ void TRestAxionSolarFlux::IntegrateSolarFluxes() { fFluxRatio = fTotalMonochromaticFlux / (fTotalContinuumFlux + fTotalMonochromaticFlux); } -/////////////////////////////////////////////// -/// \brief Initialization of TRestAxionSolarFlux metadata members through a RML file -/// -/* -void TRestAxionSolarFlux::InitFromConfigFile() { -debug << "Entering TRestAxionSolarFlux::InitFromConfigFile" << endl; - -fFluxDataFile = GetParameter("fluxDataFile", ""); -fFluxSptFile = GetParameter("fluxSptFile", ""); -fCouplingType = GetParameter("couplingType", "g_ag"); -fCouplingStrength = StringToDouble(GetParameter("couplingStrength", "1.e-10")); -fSeed = StringToInteger(GetParameter("seed", "0")); - -this->Initialize(); -} */ - /////////////////////////////////////////////// /// \brief It returns a random solar radius position and energy according to the /// flux distributions defined inside the solar tables loaded in the class From dde44717646e0f9f1b951f3a2f50253d98f0b7a0 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Fri, 15 Apr 2022 19:35:32 +0200 Subject: [PATCH 13/42] TRestAxionSolarFlux::DrawFluxFile method added --- inc/TRestAxionSolarFlux.h | 6 ++++ src/TRestAxionSolarFlux.cxx | 57 ++++++++++++++++++++++++++++++++++--- 2 files changed, 59 insertions(+), 4 deletions(-) diff --git a/inc/TRestAxionSolarFlux.h b/inc/TRestAxionSolarFlux.h index ef21610e..9f16e2bc 100644 --- a/inc/TRestAxionSolarFlux.h +++ b/inc/TRestAxionSolarFlux.h @@ -23,6 +23,7 @@ #ifndef _TRestAxionSolarFlux #define _TRestAxionSolarFlux +#include #include #include #include @@ -81,6 +82,9 @@ class TRestAxionSolarFlux : public TRestMetadata { /// Random number generator TRandom3* fRandom = nullptr; //! + /// A canvas pointer for drawing + TCanvas* fCanvas = nullptr; //! + /// A metadata member to control if the tables have been loaded Bool_t fTablesLoaded = false; //! @@ -103,6 +107,8 @@ class TRestAxionSolarFlux : public TRestMetadata { void LoadTables(); + TCanvas* DrawFluxFile(std::string fname, Double_t binSize = 0.001); + /// Tables might be loaded using a solar model description by TRestAxionSolarModel void InitializeSolarTable(TRestAxionSolarModel* model) { // TOBE implemented diff --git a/src/TRestAxionSolarFlux.cxx b/src/TRestAxionSolarFlux.cxx index b8cd6be2..0be8ca45 100644 --- a/src/TRestAxionSolarFlux.cxx +++ b/src/TRestAxionSolarFlux.cxx @@ -315,6 +315,7 @@ void TRestAxionSolarFlux::ReadFluxFile() { peaks = 0; // We just identify pronounced peaks, not smoothed gaussians! const int smearPoints = (Int_t)(5 / (fBinSize * 100)); + const int excludePoints = smearPoints / 5; for (const auto& data : fluxData) { Float_t r = 0.005 + data[0]; Float_t en = data[1] - 0.005; @@ -326,14 +327,14 @@ void TRestAxionSolarFlux::ReadFluxFile() { Double_t avgFlux = 0; Int_t n = 0; for (int e = binE - smearPoints; e <= binE + smearPoints; e++) { - if (e < 1 || e == binE) continue; + if (e < 1 || (e < binE + excludePoints && e > binE - excludePoints)) continue; n++; avgFlux += continuumHist->GetBinContent(binR, e); } avgFlux /= n; Float_t targetBinFlux = continuumHist->GetBinContent(binR, binE); - Float_t thrFlux = avgFlux * fPeakRatio; + Float_t thrFlux = avgFlux + fPeakRatio * TMath::Sqrt(avgFlux); if (targetBinFlux > 0 && targetBinFlux > thrFlux) { continuumHist->SetBinContent(binR, binE, avgFlux); peaks++; @@ -369,6 +370,54 @@ void TRestAxionSolarFlux::ReadFluxFile() { fFluxLines[energy] = hm; } } + + cout << "Number of peaks identified: " << fFluxLines.size() << endl; +} + +/////////////////////////////////////////////// +/// \brief It draws the contents of a .flux file. This method just receives the +/// name of the .flux file and it works stand-alone. +/// +TCanvas* TRestAxionSolarFlux::DrawFluxFile(string fname, Double_t binSize) { + string fullPathName = SearchFile(fname); + + std::vector> fluxData; + TRestTools::ReadASCIITable(fullPathName, fluxData, 3); + + TH2F* originalHist = + new TH2F(Form("FullTable", GetName()), "", 100, 0., 1., (Int_t)(20. / binSize), 0., 20.); + + for (const auto& data : fluxData) { + Double_t r = 0.005 + data[0]; + Double_t en = data[1] - 0.005; + Double_t flux = data[2] * binSize; // flux in cm-2 s-1 bin-1 + + originalHist->Fill(r, en, flux); + } + + cout << "Total flux : " << originalHist->Integral() << " cm-2 s-1" << endl; + + if (fCanvas != nullptr) { + delete fCanvas; + fCanvas = nullptr; + } + fCanvas = new TCanvas("canv", "This is the canvas title", 1400, 1200); + fCanvas->Draw(); + + TPad* pad1 = new TPad("pad1", "This is pad1", 0.01, 0.02, 0.99, 0.97); + pad1->Draw(); + + fCanvas->cd(); + pad1->cd(); + // pad1->SetLogy(); + + TH1F* hh = (TH1F*)originalHist->ProjectionY(); + // hh->GetXaxis()->SetRange(1000, 1500); + hh->Draw("hist"); + + fCanvas->Update(); + + return fCanvas; } /////////////////////////////////////////////// @@ -451,9 +500,9 @@ void TRestAxionSolarFlux::PrintIntegratedRingFlux() { cout << "Integrated solar flux per solar ring: " << endl; cout << "--------------------------- " << endl; /* -for (int n = 0; n < fFluxPerRadius.size(); n++) + for (int n = 0; n < fFluxPerRadius.size(); n++) cout << "n : " << n << " flux : " << fFluxPerRadius[n] << endl; -cout << endl; + cout << endl; */ } From 3b438c51c5cbb1adbf9ef4f2a031debdc62e45e6 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Mon, 18 Apr 2022 12:39:55 +0200 Subject: [PATCH 14/42] TRestAxionSolarFlux::GetContinuumHistogram and GetFluxFileHistogram added --- inc/TRestAxionSolarFlux.h | 2 ++ src/TRestAxionSolarFlux.cxx | 34 +++++++++++++++++++++++----------- 2 files changed, 25 insertions(+), 11 deletions(-) diff --git a/inc/TRestAxionSolarFlux.h b/inc/TRestAxionSolarFlux.h index 9f16e2bc..204e3710 100644 --- a/inc/TRestAxionSolarFlux.h +++ b/inc/TRestAxionSolarFlux.h @@ -107,6 +107,8 @@ class TRestAxionSolarFlux : public TRestMetadata { void LoadTables(); + TH1F* GetFluxHistogram(std::string fname, Double_t binSize); + TH1F* GetContinuumSpectrum(); TCanvas* DrawFluxFile(std::string fname, Double_t binSize = 0.001); /// Tables might be loaded using a solar model description by TRestAxionSolarModel diff --git a/src/TRestAxionSolarFlux.cxx b/src/TRestAxionSolarFlux.cxx index 0be8ca45..d97986c8 100644 --- a/src/TRestAxionSolarFlux.cxx +++ b/src/TRestAxionSolarFlux.cxx @@ -375,17 +375,28 @@ void TRestAxionSolarFlux::ReadFluxFile() { } /////////////////////////////////////////////// -/// \brief It draws the contents of a .flux file. This method just receives the -/// name of the .flux file and it works stand-alone. +/// \brief It builds a histogram with the continuum spectrum component /// -TCanvas* TRestAxionSolarFlux::DrawFluxFile(string fname, Double_t binSize) { +TH1F* TRestAxionSolarFlux::GetContinuumSpectrum() { + TH1F* continuumHist = new TH1F("ContinuumHist", "", 200, 0, 20); + for (const auto& x : fFluxTable) { + continuumHist->Add(x); + } + return continuumHist; +} + +/////////////////////////////////////////////// +/// \brief It builds a histogram using the contents of the .flux file given +/// in the argument. +/// +TH1F* TRestAxionSolarFlux::GetFluxHistogram(string fname, Double_t binSize) { string fullPathName = SearchFile(fname); std::vector> fluxData; TRestTools::ReadASCIITable(fullPathName, fluxData, 3); TH2F* originalHist = - new TH2F(Form("FullTable", GetName()), "", 100, 0., 1., (Int_t)(20. / binSize), 0., 20.); + new TH2F(Form("FluxTable", GetName()), "", 100, 0., 1., (Int_t)(20. / binSize), 0., 20.); for (const auto& data : fluxData) { Double_t r = 0.005 + data[0]; @@ -395,8 +406,14 @@ TCanvas* TRestAxionSolarFlux::DrawFluxFile(string fname, Double_t binSize) { originalHist->Fill(r, en, flux); } - cout << "Total flux : " << originalHist->Integral() << " cm-2 s-1" << endl; + return (TH1F*)originalHist->ProjectionY(); +} +/////////////////////////////////////////////// +/// \brief It draws the contents of a .flux file. This method just receives the +/// name of the .flux file and it works stand-alone. +/// +TCanvas* TRestAxionSolarFlux::DrawFluxFile(string fname, Double_t binSize) { if (fCanvas != nullptr) { delete fCanvas; fCanvas = nullptr; @@ -409,13 +426,8 @@ TCanvas* TRestAxionSolarFlux::DrawFluxFile(string fname, Double_t binSize) { fCanvas->cd(); pad1->cd(); - // pad1->SetLogy(); - - TH1F* hh = (TH1F*)originalHist->ProjectionY(); - // hh->GetXaxis()->SetRange(1000, 1500); - hh->Draw("hist"); - fCanvas->Update(); + GetFluxHistogram(fname, binSize)->Draw("hist"); return fCanvas; } From 1c4250fca2bc2971349459aa9c0dac451fe503f9 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Mon, 18 Apr 2022 21:58:59 +0200 Subject: [PATCH 15/42] TRestAxionSolarFlux::GetMonochromaticSpectrum method added --- inc/TRestAxionSolarFlux.h | 4 +++- src/TRestAxionSolarFlux.cxx | 11 +++++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/inc/TRestAxionSolarFlux.h b/inc/TRestAxionSolarFlux.h index 204e3710..7148f8a8 100644 --- a/inc/TRestAxionSolarFlux.h +++ b/inc/TRestAxionSolarFlux.h @@ -107,8 +107,10 @@ class TRestAxionSolarFlux : public TRestMetadata { void LoadTables(); - TH1F* GetFluxHistogram(std::string fname, Double_t binSize); TH1F* GetContinuumSpectrum(); + TH1F* GetMonochromaticSpectrum(); + + TH1F* GetFluxHistogram(std::string fname, Double_t binSize); TCanvas* DrawFluxFile(std::string fname, Double_t binSize = 0.001); /// Tables might be loaded using a solar model description by TRestAxionSolarModel diff --git a/src/TRestAxionSolarFlux.cxx b/src/TRestAxionSolarFlux.cxx index d97986c8..8a52f106 100644 --- a/src/TRestAxionSolarFlux.cxx +++ b/src/TRestAxionSolarFlux.cxx @@ -385,6 +385,17 @@ TH1F* TRestAxionSolarFlux::GetContinuumSpectrum() { return continuumHist; } +/////////////////////////////////////////////// +/// \brief It builds a histogram with the monochromatic spectrum component +/// +TH1F* TRestAxionSolarFlux::GetMonochromaticSpectrum() { + TH1F* monoHist = new TH1F("MonochromaticHist", "", 20000, 0, 20); + for (const auto& x : fFluxLines) { + monoHist->Fill(x.first, x.second->Integral() * 1000); // cm-2 s-1 keV-1 + } + return monoHist; +} + /////////////////////////////////////////////// /// \brief It builds a histogram using the contents of the .flux file given /// in the argument. From c498b0b05fc05b46b51b3e73a8d08694b13cb25f Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Wed, 20 Apr 2022 15:59:55 +0200 Subject: [PATCH 16/42] Updating solarFlux scripts and validation --- .gitlab-ci.yml | 3 +- .../solarFlux/{solarFlux.py => solarPlot.py} | 105 ++++++++++-------- pipeline/metadata/solarFlux/solarTests.py | 53 +++++++++ 3 files changed, 113 insertions(+), 48 deletions(-) rename pipeline/metadata/solarFlux/{solarFlux.py => solarPlot.py} (54%) create mode 100755 pipeline/metadata/solarFlux/solarTests.py diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 4e0baf5b..2f39d92c 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -105,7 +105,8 @@ solarFlux: script: - . ${CI_PROJECT_DIR}/install/thisREST.sh - cd ${CI_PROJECT_DIR}/pipeline/metadata/solarFlux/ - - python solarFlux.py + - python solarTests.py + - python solarPlot.py - python compare.py except: variables: diff --git a/pipeline/metadata/solarFlux/solarFlux.py b/pipeline/metadata/solarFlux/solarPlot.py similarity index 54% rename from pipeline/metadata/solarFlux/solarFlux.py rename to pipeline/metadata/solarFlux/solarPlot.py index 679d99ec..7bfe139a 100755 --- a/pipeline/metadata/solarFlux/solarFlux.py +++ b/pipeline/metadata/solarFlux/solarPlot.py @@ -1,9 +1,5 @@ #!/usr/bin/python3 -totalSamples = 20000 - -outfname = "flux.png" - import math import ROOT from ROOT import ( @@ -14,6 +10,36 @@ TF1, TF2, TF3, TFormula, TLorentzVector, TVector3) +import argparse + +parser = argparse.ArgumentParser() +parser.add_argument('--rml', dest='rmlfile', type=str, help='The input RML file .rml') +parser.add_argument('--out', dest='outfname', type=str, help='The output filename in png,pdf,C or any other ROOT accepted format') +parser.add_argument('--fluxname', dest='fluxname', type=str, help='The name of the flux definition to be chosen from the RML') +parser.add_argument('--N', dest='samples', type=int, help='The number of generated particles') +args = parser.parse_args() + +rmlfile = "fluxes.rml" +if args.rmlfile != None: + rmlfile = args.rmlfile + +outfname = "flux.png" +if args.outfname != None: + outfname = args.outfname + +fluxname = "combined" +if args.fluxname != None: + fluxname = args.fluxname + + +samples = 20000 +if args.samples != None: + samples = args.samples + +validation = False +if rmlfile == "fluxes.rml" and fluxname == "combined" and outfname == "flux.png" and samples == 20000: + validation = True + ROOT.gSystem.Load("libRestFramework.so") ROOT.gSystem.Load("libRestAxion.so") @@ -25,7 +51,7 @@ pad1.Divide(2,2) pad1.Draw() -combinedFlux = ROOT.TRestAxionSolarFlux("fluxes.rml", "combined") +combinedFlux = ROOT.TRestAxionSolarFlux(rmlfile, fluxname) combinedFlux.LoadTables() combinedFlux.PrintMetadata() @@ -35,19 +61,23 @@ exit(101) comb_spt = TH2D("comb_spt", "Energy versus solar radius", 200, 0, 20, 100, 0, 1 ) -for x in range(totalSamples): +for x in range(samples): x = combinedFlux.GetRandomEnergyAndRadius() comb_spt.Fill( x[0], x[1] ) rnd = TRandom3(0) solarDisk = TH2D("solar_disk", "SolarDisk", 120, -1.2, 1.2, 120, -1.2, 1.2 ) -for x in range(totalSamples): +for x in range(samples): angle = rnd.Rndm() * 2 * math.pi x = combinedFlux.GetRandomEnergyAndRadius() solarDisk.Fill( x[1]*math.cos(angle), x[1]*math.sin(angle) ) pad1.cd(1) +pad1.cd(1).SetRightMargin(0.09); +pad1.cd(1).SetLeftMargin(0.15); +pad1.cd(1).SetBottomMargin(0.15); + comb_spt.SetStats(0) comb_spt.GetXaxis().SetTitle("Energy [keV]") comb_spt.GetXaxis().SetTitleSize(0.05); @@ -58,26 +88,40 @@ comb_spt.Draw("box") pad1.cd(2) +pad1.cd(2).SetLogy() +pad1.cd(2).SetRightMargin(0.09); +pad1.cd(2).SetLeftMargin(0.15); +pad1.cd(2).SetBottomMargin(0.15); enSpt = comb_spt.ProjectionX() enSpt.SetTitle("Energy spectrum") enSpt.GetYaxis().SetTitleSize(0.05); enSpt.SetStats(0) enSpt.Draw() -if ( enSpt.GetMaximumBin() != 41 ): - print ( "\nMaximum Bin is not the expected one! Exit code : 1" ) - exit(1) + +if validation: + if ( enSpt.GetMaximumBin() != 41 ): + print ( "\nMaximum Bin is not the expected one! Exit code : 1" ) + exit(1) pad1.cd(3) +pad1.cd(3).SetRightMargin(0.09); +pad1.cd(3).SetLeftMargin(0.15); +pad1.cd(3).SetBottomMargin(0.15); rSpt = comb_spt.ProjectionY() rSpt.SetTitle("Radial distribution") rSpt.GetYaxis().SetTitleSize(0.05); rSpt.SetStats(0) rSpt.Draw() -if ( rSpt.GetMaximumBin() != 25 ): - print ( "\nMaximum Bin is not the expected one! Exit code : 2" ) - exit(2) + +if validation: + if ( rSpt.GetMaximumBin() != 25 ): + print ( "\nMaximum Bin is not the expected one! Exit code : 2" ) + exit(2) pad1.cd(4) +pad1.cd(4).SetRightMargin(0.09); +pad1.cd(4).SetLeftMargin(0.15); +pad1.cd(4).SetBottomMargin(0.15); solarDisk.SetStats(0) solarDisk.GetXaxis().SetTitle("X") solarDisk.GetXaxis().SetTitleSize(0.05); @@ -89,39 +133,6 @@ solarDisk.Draw() c1.Print(outfname) - -monoFlux = ROOT.TRestAxionSolarFlux("fluxes.rml", "mono") -monoFlux.LoadTables() -monoFlux.PrintMetadata() - -if monoFlux.GetError(): - print ( monoFlux.GetErrorMessage() ) - print ( "\nSolar flux initialization failed! Exit code : 101" ) - exit(101) - -x = monoFlux.GetRandomEnergyAndRadius() -if ( int( x[0]*100 ) != 800 or int( x[1]*100 ) != 58 ): - print ( "\nMonochromatic flux values seem to be wrong! Exit code : 201" ) - exit(201) - -print ("[\033[92m OK \x1b[0m]") - -continuumFlux = ROOT.TRestAxionSolarFlux("fluxes.rml", "Gianotti") -continuumFlux.LoadTables() -continuumFlux.PrintMetadata() - -if continuumFlux.GetError(): - print ( continuumFlux.GetErrorMessage() ) - print ( "\nSolar flux initialization failed! Exit code : 101" ) - exit(101) - -x = monoFlux.GetRandomEnergyAndRadius() -if ( int( x[0]*100 ) != 400 or int( x[1]*100 ) != 24 ): - print ( "\nMonochromatic flux values seem to be wrong! Exit code : 202" ) - exit(202) - -print ("All tests passed! [\033[92m OK \x1b[0m]") - -print ("") +print( "Generated file : " + outfname ) exit(0) diff --git a/pipeline/metadata/solarFlux/solarTests.py b/pipeline/metadata/solarFlux/solarTests.py new file mode 100755 index 00000000..80926871 --- /dev/null +++ b/pipeline/metadata/solarFlux/solarTests.py @@ -0,0 +1,53 @@ +#!/usr/bin/python3 + +import math +import ROOT +from ROOT import ( + TChain, TFile, TTree, TCanvas, TPad, TRandom3, + TH1D, TH2D, TH3D, + TProfile, TProfile2D, TProfile3D, + TGraph, TGraph2D, + TF1, TF2, TF3, TFormula, + TLorentzVector, TVector3) + + +ROOT.gSystem.Load("libRestFramework.so") +ROOT.gSystem.Load("libRestAxion.so") + +monoFlux = ROOT.TRestAxionSolarFlux("fluxes.rml", "mono") +monoFlux.LoadTables() +monoFlux.PrintMetadata() + +if monoFlux.GetError(): + print ( monoFlux.GetErrorMessage() ) + print ( "\nSolar flux initialization failed! Exit code : 101" ) + exit(101) + +x = monoFlux.GetRandomEnergyAndRadius() +print( x[0] ) +print( x[1] ) +if ( int( x[0]*100 ) != 800 or int( x[1]*100 ) != 83 ): + print ( "\nMonochromatic flux values seem to be wrong! Exit code : 201" ) + exit(201) + +print ("[\033[92m OK \x1b[0m]") + +continuumFlux = ROOT.TRestAxionSolarFlux("fluxes.rml", "Gianotti") +continuumFlux.LoadTables() +continuumFlux.PrintMetadata() + +if continuumFlux.GetError(): + print ( continuumFlux.GetErrorMessage() ) + print ( "\nSolar flux initialization failed! Exit code : 101" ) + exit(101) + +x = monoFlux.GetRandomEnergyAndRadius() +if ( int( x[0]*100 ) != 400 or int( x[1]*100 ) != 24 ): + print ( "\nContinuum flux values seem to be wrong! Exit code : 202" ) + exit(202) + +print ("All tests passed! [\033[92m OK \x1b[0m]") + +print ("") + +exit(0) From 758b5a4c36e1cf4a29b2fce7177f958074d55a97 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Wed, 20 Apr 2022 17:20:47 +0200 Subject: [PATCH 17/42] TRestAxionSolarFlux::DrawSolarFlux method added and general documentation. --- inc/TRestAxionSolarFlux.h | 17 ++- src/TRestAxionSolarFlux.cxx | 243 ++++++++++++++++++++++++++++++++---- 2 files changed, 235 insertions(+), 25 deletions(-) diff --git a/inc/TRestAxionSolarFlux.h b/inc/TRestAxionSolarFlux.h index 7148f8a8..d17b594b 100644 --- a/inc/TRestAxionSolarFlux.h +++ b/inc/TRestAxionSolarFlux.h @@ -56,7 +56,7 @@ class TRestAxionSolarFlux : public TRestMetadata { Double_t fBinSize = 0; //< /// It will be used when loading `.flux` files to define the threshold for peak identification - Double_t fPeakRatio = 0; //< + Double_t fPeakSigma = 0; //< /// The tabulated solar flux continuum spectra TH1F(100,0,20)keV in cm-2 s-1 keV-1 versus solar radius std::vector fFluxTable; //! @@ -85,6 +85,15 @@ class TRestAxionSolarFlux : public TRestMetadata { /// A canvas pointer for drawing TCanvas* fCanvas = nullptr; //! + /// A pointer to the continuum spectrum histogram + TH1F* fContinuumHist = nullptr; //! + + /// A pointer to the monochromatic spectrum histogram + TH1F* fMonoHist = nullptr; //! + + /// A pointer to the superposed monochromatic and continuum spectrum histogram + TH1F* fTotalHist = nullptr; //! + /// A metadata member to control if the tables have been loaded Bool_t fTablesLoaded = false; //! @@ -109,9 +118,11 @@ class TRestAxionSolarFlux : public TRestMetadata { TH1F* GetContinuumSpectrum(); TH1F* GetMonochromaticSpectrum(); + TH1F* GetTotalSpectrum(); - TH1F* GetFluxHistogram(std::string fname, Double_t binSize); - TCanvas* DrawFluxFile(std::string fname, Double_t binSize = 0.001); + TH1F* GetFluxHistogram(std::string fname, Double_t binSize = 0.01); + TCanvas* DrawFluxFile(std::string fname, Double_t binSize = 0.01); + TCanvas* DrawSolarFlux(); /// Tables might be loaded using a solar model description by TRestAxionSolarModel void InitializeSolarTable(TRestAxionSolarModel* model) { diff --git a/src/TRestAxionSolarFlux.cxx b/src/TRestAxionSolarFlux.cxx index 8a52f106..15d7ce69 100644 --- a/src/TRestAxionSolarFlux.cxx +++ b/src/TRestAxionSolarFlux.cxx @@ -42,7 +42,8 @@ /// given in the solar flux tables. /// - *fluxDataFile:* A table with 100 rows representing the solar ring flux from the /// center to the corona, and 200 columns representing the flux, measured in cm-2 s-1 keV-1, -/// for the range (0,20)keV in steps of 100eV. +/// for the range (0,20)keV in steps of 100eV. The table could be provided in ASCII format, +/// using `.dat` extension, or it might be a binary table using `.N200f` extension. /// - *fluxSptFile:* A table where each column represents a monochromatic energy. The /// column contains 101 rows, the first element is the energy of the monochromatic line /// while the next 100 elements contain the flux, measured in cm-2 s-1, integrated to @@ -51,16 +52,31 @@ /// Additionally this class will be able to read `.flux` files that are the original files /// produced in 3-columns format (inner radius [solar units] / energy [keV] / /// flux [cm-2 s-1 keV-1]). The `.flux` files may contain the full information, -/// continuum and spectral. Those components will be splited into two independent +/// continuum and spectral components. Those components will be splited into two independent /// contributions by TRestAxionSolarFlux::ReadFluxFile to be managed internally. Two /// additional parameters *will be required* to translate the `.flux` files into the tables /// that are understood by this class. /// - *binSize:* The energy binning used on the `.flux` file. -/// - *peakRatio:* The ratio between the flux provided at the `.flux` file and the +/// - *peakSigma:* The ratio between the flux provided at the `.flux` file and the /// average flux calculated in the peak surroundings. If the flux ratio is higher than /// this value, the flux at that particular bin will be considered a peak. /// -/// The following code shows how to define this class inside a RML file. +/// Pre-generated solar axion flux tables will be available at the +/// [axionlib-data](https://github.com/rest-for-physics/axionlib-data/tree/master) +/// repository. The different RML flux definitions used to load those tables +/// will be found at the +/// [fluxes.rml](https://github.com/rest-for-physics/axionlib-data/blob/master/solarFlux/fluxes.rml) +/// file found at the axionlib-data repository. +/// +/// Inside a local REST installation, the `fluxes.rml` file will be found at the REST +/// installation directory, and it will be located automatically by the +/// TRestMetadata::SearchFile method. +/// +/// ### A basic RML definition +/// +/// The following definition integrates an axion-photon component with a continuum +/// spectrum using a Primakoff production model, and a dummy spectrum file that +/// includes two monocrhomatic lines at different solar disk radius positions. /// /// \code /// @@ -71,16 +87,89 @@ /// /// \endcode /// -/// When the flux is loaded manually inside the `restRoot` interface or inside a -/// macro or script, after metadata initialization, it is necessary to call -/// the method TRestAxionSolarFlux::LoadTables. +/// \warning when the flux is loaded manually inside the `restRoot` interactive +/// shell, or inside a macro or script, after metadata initialization, it is necessary +/// to call the method TRestAxionSolarFlux::LoadTables to triger the tables +/// initialization. +/// +/// ### Performing MonteCarlo tests using pre-loaded tables +/// +/// In order to test the response of different solar flux definitions we may use the script +/// `solarPlot.py` found at `pipeline/metadata/solarFlux/`. This script will generate a +/// number of particles and it will assign to each particle an energy and solar disk +/// location with the help of the method TRestAxionSolarFlux::GetRandomEnergyAndRadius. +/// +/// \code +/// python3 solarPlot.py --fluxname LennertHoofABC --N 1000000 +/// \endcode +/// +/// By default, it will load the flux definition found at `fluxes.rml` from the +/// `axionlib-data` repository, and generate a `png` image with the resuts from the +/// Monte Carlo execution. /// -/// The previous definition was used to generate the following figure using the script -/// pipeline/solarFlux/solarFlux.py. +/// \htmlonly \endhtmlonly /// -/// \htmlonly \endhtmlonly +/// ![Solar flux distributions MC-generated with TRestAxionSolarFlux.](ABC_flux_MC.png) +/// +/// ### Reading solar flux tables from `.flux` files +/// +/// In a similar way we may initialize the class using a `.flux` file. The `.flux` described +/// previously will contain a high definition flux table measured in `cm-2 s-1 keV-1` as a +/// function of the energy (from 0 to 20keV) and the inner solar radius (from 0 to 1). The +/// binning of this table will be typically between 1eV and 10eV. +/// +/// The class TRestAxionSolarFlux will be initialized directly using the `.flux` file +/// provided under the `fluxDataFile` parameter. During the initialization, the flux will be +/// splitted into two independent flux components. One smooth continuum component integrated +/// in 100 eV steps, and a monochromatic peak components. +/// +/// In order to help with the identification of peaks we need to define the `binSize` used in +/// the `.flux` table and the `peakSigma` defining the number of sigmas over the average for +/// a bin to be considered a peak. +/// +/// \code +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// \endcode /// -/// ![Solar flux distributions generated with TRestAxionSolarFlux.](AxionSolarFlux.png) +/// We will be able to load this file as usual, using the following recipe inside +/// `restRoot`, +/// +/// \code +/// TRestAxionSolarFlux *sFlux = new TRestAxionSolarFlux("fluxes.rml", "LennertHoofABC") +/// sFlux->LoadTables() +/// TCanvas *c = sFlux->DrawSolarFluxes() +/// c->Print("ABC_FluxTable.png" ) +/// \endcode +/// +/// will generate the following figure. +/// +/// \htmlonly \endhtmlonly +/// +/// ![Solar flux distributions generated with TRestAxionSolarFlux::DrawSolarFlux.](ABC_FluxTable.png) +/// +/// On top of that, we will be able to export those tables to the TRestAxionSolarFlux standard +/// format to be used in later occasions. +/// +/// \code +/// TRestAxionSolarFlux *sFlux = new TRestAxionSolarFlux("fluxes.rml", "LennertHoofABC") +/// sFlux->LoadTables() +/// sFlux->ExportTables() +/// \endcode +/// +/// which will produce two files, a binary table `.N200f` with the continuum flux, and an ASCII +/// table containning the `.spt` monochromatic lines. The filename root will be extracted from +/// the original `.flux` file. Optionally we may export the continuum flux to an ASCII file by +/// indicating it at the TRestAxionSolarFlux::ExportTables method call. The files will be placed +/// at the REST user space, at `$HOME/.rest/export/` directory. /// /// TODO Implement the method TRestAxionSolarFlux::InitializeSolarTable using /// a solar model description by TRestAxionSolarModel. @@ -277,7 +366,7 @@ void TRestAxionSolarFlux::ReadFluxFile() { return; } - if (fPeakRatio <= 0) { + if (fPeakSigma <= 0) { warning << "TRestAxionSolarflux::ReadFluxFile. Peak ratio must be specified to generate " "monochromatic spectrum." << endl; @@ -334,7 +423,7 @@ void TRestAxionSolarFlux::ReadFluxFile() { avgFlux /= n; Float_t targetBinFlux = continuumHist->GetBinContent(binR, binE); - Float_t thrFlux = avgFlux + fPeakRatio * TMath::Sqrt(avgFlux); + Float_t thrFlux = avgFlux + fPeakSigma * TMath::Sqrt(avgFlux); if (targetBinFlux > 0 && targetBinFlux > thrFlux) { continuumHist->SetBinContent(binR, binE, avgFlux); peaks++; @@ -375,25 +464,91 @@ void TRestAxionSolarFlux::ReadFluxFile() { } /////////////////////////////////////////////// -/// \brief It builds a histogram with the continuum spectrum component +/// \brief It builds a histogram with the continuum spectrum component. +/// The flux will be expressed in cm-2 s-1 keV-1. Binned in 100eV steps. /// TH1F* TRestAxionSolarFlux::GetContinuumSpectrum() { - TH1F* continuumHist = new TH1F("ContinuumHist", "", 200, 0, 20); + if (fContinuumHist != nullptr) { + delete fContinuumHist; + fContinuumHist = nullptr; + } + + fContinuumHist = new TH1F("ContinuumHist", "", 200, 0, 20); for (const auto& x : fFluxTable) { - continuumHist->Add(x); + fContinuumHist->Add(x); } - return continuumHist; + + fContinuumHist->SetStats(0); + fContinuumHist->GetXaxis()->SetTitle("Energy [keV]"); + fContinuumHist->GetXaxis()->SetTitleSize(0.05); + fContinuumHist->GetXaxis()->SetLabelSize(0.05); + fContinuumHist->GetYaxis()->SetTitle("Flux [cm-2 s-1 keV-1]"); + fContinuumHist->GetYaxis()->SetTitleSize(0.05); + fContinuumHist->GetYaxis()->SetLabelSize(0.05); + + return fContinuumHist; } /////////////////////////////////////////////// -/// \brief It builds a histogram with the monochromatic spectrum component +/// \brief It builds a histogram with the monochromatic spectrum component. +/// The flux will be expressed in cm-2 s-1 eV-1. Binned in 1eV steps. /// TH1F* TRestAxionSolarFlux::GetMonochromaticSpectrum() { - TH1F* monoHist = new TH1F("MonochromaticHist", "", 20000, 0, 20); + if (fMonoHist != nullptr) { + delete fMonoHist; + fMonoHist = nullptr; + } + + fMonoHist = new TH1F("MonochromaticHist", "", 20000, 0, 20); for (const auto& x : fFluxLines) { - monoHist->Fill(x.first, x.second->Integral() * 1000); // cm-2 s-1 keV-1 + fMonoHist->Fill(x.first, x.second->Integral()); // cm-2 s-1 eV-1 } - return monoHist; + + fMonoHist->SetStats(0); + fMonoHist->GetXaxis()->SetTitle("Energy [keV]"); + fMonoHist->GetXaxis()->SetTitleSize(0.05); + fMonoHist->GetXaxis()->SetLabelSize(0.05); + fMonoHist->GetYaxis()->SetTitle("Flux [cm-2 s-1 eV-1]"); + fMonoHist->GetYaxis()->SetTitleSize(0.05); + fMonoHist->GetYaxis()->SetLabelSize(0.05); + + return fMonoHist; +} + +/////////////////////////////////////////////// +/// \brief It builds a histogram adding the continuum and the monochromatic +/// spectrum component. The flux will be expressed in cm-2 s-1 keV-1. +/// Binned in 1eV steps. +/// +TH1F* TRestAxionSolarFlux::GetTotalSpectrum() { + TH1F* hm = GetMonochromaticSpectrum(); + TH1F* hc = GetContinuumSpectrum(); + + if (fTotalHist != nullptr) { + delete fTotalHist; + fTotalHist = nullptr; + } + + fTotalHist = new TH1F("fTotalHist", "", 20000, 0, 20); + for (int n = 0; n < hc->GetNbinsX(); n++) { + for (int m = 0; m < 100; m++) { + fTotalHist->SetBinContent(n * 100 + 1 + m, hc->GetBinContent(n + 1)); + } + } + + for (int n = 0; n < hm->GetNbinsX(); n++) + // 1e-2 is the renormalization from 20000 bins to 200 bins + fTotalHist->SetBinContent(n + 1, fTotalHist->GetBinContent(n + 1) + 100 * hm->GetBinContent(n + 1)); + + fTotalHist->SetStats(0); + fTotalHist->GetXaxis()->SetTitle("Energy [keV]"); + fTotalHist->GetXaxis()->SetTitleSize(0.05); + fTotalHist->GetXaxis()->SetLabelSize(0.05); + fTotalHist->GetYaxis()->SetTitle("Flux [cm-2 s-1 keV-1]"); + fTotalHist->GetYaxis()->SetTitleSize(0.05); + fTotalHist->GetYaxis()->SetLabelSize(0.05); + + return fTotalHist; } /////////////////////////////////////////////// @@ -443,6 +598,50 @@ TCanvas* TRestAxionSolarFlux::DrawFluxFile(string fname, Double_t binSize) { return fCanvas; } +/////////////////////////////////////////////// +/// \brief It draws the contents of a .flux file. This method just receives the +/// +TCanvas* TRestAxionSolarFlux::DrawSolarFlux() { + if (fCanvas != nullptr) { + delete fCanvas; + fCanvas = nullptr; + } + fCanvas = new TCanvas("canv", "This is the canvas title", 1200, 500); + fCanvas->Draw(); + + TPad* pad1 = new TPad("pad1", "This is pad1", 0.01, 0.02, 0.99, 0.97); + pad1->Divide(2, 1); + pad1->Draw(); + + pad1->cd(1); + pad1->cd(1)->SetLogy(); + pad1->cd(1)->SetRightMargin(0.09); + pad1->cd(1)->SetLeftMargin(0.15); + pad1->cd(1)->SetBottomMargin(0.15); + + TH1F* ht = GetTotalSpectrum(); + ht->SetLineColor(kBlack); + ht->SetFillStyle(4050); + ht->SetFillColor(kBlue - 10); + + TH1F* hm = GetMonochromaticSpectrum(); + hm->SetLineColor(kBlack); + hm->Scale(100); // renormalizing per 100eV-1 + + ht->Draw("hist"); + hm->Draw("hist same"); + + pad1->cd(2); + pad1->cd(2)->SetRightMargin(0.09); + pad1->cd(2)->SetLeftMargin(0.15); + pad1->cd(2)->SetBottomMargin(0.15); + + ht->Draw("hist"); + hm->Draw("hist same"); + + return fCanvas; +} + /////////////////////////////////////////////// /// \brief A helper method to initialize the internal class data members with the /// integrated flux for each solar ring. It will be called by TRestAxionSolarFlux::Initialize. @@ -562,7 +761,7 @@ void TRestAxionSolarFlux::PrintMetadata() { metadata << "--------" << endl; metadata << " - Random seed : " << fSeed << endl; if (fBinSize > 0) metadata << " - Energy bin size : " << fBinSize * units("eV") << " eV" << endl; - if (fPeakRatio > 0) metadata << " - Peak/continuum ratio : " << fPeakRatio << endl; + if (fPeakSigma > 0) metadata << " - Peak/continuum ratio : " << fPeakSigma << endl; metadata << "++++++++++++++++++" << endl; if (GetVerboseLevel() >= REST_Debug) { From 8e10ba6da70dabcb0464edaeb76563b39fbf27ab Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Wed, 20 Apr 2022 17:21:16 +0200 Subject: [PATCH 18/42] solarPlot.py adding colors to histograms --- pipeline/metadata/solarFlux/solarPlot.py | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/pipeline/metadata/solarFlux/solarPlot.py b/pipeline/metadata/solarFlux/solarPlot.py index 7bfe139a..6c127a05 100755 --- a/pipeline/metadata/solarFlux/solarPlot.py +++ b/pipeline/metadata/solarFlux/solarPlot.py @@ -60,7 +60,7 @@ print ( "\nSolar flux initialization failed! Exit code : 101" ) exit(101) -comb_spt = TH2D("comb_spt", "Energy versus solar radius", 200, 0, 20, 100, 0, 1 ) +comb_spt = TH2D("comb_spt", "Energy versus solar radius", 20000, 0, 20, 100, 0, 1 ) for x in range(samples): x = combinedFlux.GetRandomEnergyAndRadius() comb_spt.Fill( x[0], x[1] ) @@ -85,7 +85,7 @@ comb_spt.GetYaxis().SetTitle("Solar radius") comb_spt.GetYaxis().SetTitleSize(0.05); comb_spt.GetYaxis().SetLabelSize(0.05); -comb_spt.Draw("box") +comb_spt.Draw("colz") pad1.cd(2) pad1.cd(2).SetLogy() @@ -96,6 +96,9 @@ enSpt.SetTitle("Energy spectrum") enSpt.GetYaxis().SetTitleSize(0.05); enSpt.SetStats(0) +enSpt.SetFillStyle(4050) +enSpt.SetFillColor(ROOT.kBlue-9) +enSpt.SetLineColor(ROOT.kBlack) enSpt.Draw() if validation: @@ -111,6 +114,9 @@ rSpt.SetTitle("Radial distribution") rSpt.GetYaxis().SetTitleSize(0.05); rSpt.SetStats(0) +rSpt.SetFillStyle(4050) +rSpt.SetFillColor(ROOT.kBlue-9) +rSpt.SetLineColor(ROOT.kBlack) rSpt.Draw() if validation: @@ -130,7 +136,7 @@ solarDisk.GetYaxis().SetTitleOffset(1) solarDisk.GetYaxis().SetTitleSize(0.05); solarDisk.GetYaxis().SetLabelSize(0.05); -solarDisk.Draw() +solarDisk.Draw("colz") c1.Print(outfname) print( "Generated file : " + outfname ) From 5de4499105da2e40ac38f0ac0e03d5e4eff0f3c5 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Wed, 20 Apr 2022 17:21:40 +0200 Subject: [PATCH 19/42] Uploading new images --- images/ABC_FluxTable.png | Bin 0 -> 14469 bytes images/ABC_flux_MC.png | Bin 0 -> 27097 bytes 2 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 images/ABC_FluxTable.png create mode 100644 images/ABC_flux_MC.png diff --git a/images/ABC_FluxTable.png b/images/ABC_FluxTable.png new file mode 100644 index 0000000000000000000000000000000000000000..1453af39568aaf532e7bdd5f6515a7315a3bf616 GIT binary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wte-8GZ3wC z-2}&kvpyU~vQ=Q4%xGb9Qn9>52Th9CO#u4c%Og&cHWjTa9>YBKN;_jCE!rFHO7J^~ z^j2z})fFGO5cJ!nx4+Q*fsgyb;V%c;-?%=AD5PEUv8a%cRb33l?Dm$f`PDmFD1DD? z7ieGhxYlyW@06mGIM?lH4q@j* z!6zvorE*rY#wWREiFbBjP~@h8qZ|_;dHQjumXu^6wM;lSG6TMmnA&7&CF8*REi?C* zPhAoXJ=BzNB49o$97-y7mVKR5n!@)sjMG3$6a*jG*LJ4&GH2Xv%UAWnWO$FiQ+X7X z$jakydPHJM1(9iNj(2;uUJKzophlP{)2;W@jq~8x0jiQB)pKgb z8_QB7mrJJqaxi6-?Iv~1d&!~4@DcnfO*PnSY z1Su;IqJpmtqQW2E6w;YP7#{^N34pf=!s^s~!mH3egk(<(=!8^@!bz7gBYjvtE)q7&lxO?NM2vexI*D zP!ss?OA{GHGUuQSf6rA|XlV|?ThdR#XkWZbK*mt%gq!ovO6RpZB?jrbWYcW?KL|)d zq^?+tovvtc@I!2r(51Z%<+%`2%E+acGCLkDTU^of^r_SzVkDAm8%Fgl(w*Y{6#5TK z`ewdnKCEWKeg-y0ff(C!HJr0g)+zmp$;Nq=%B4E*f0wwqfAv=``_-G8UOdpV#-j-R z!@Z7fk8X8pDBC2j)S!-5exsmey+=WneFc_BGlD14;60Si^{wDMhl7-S#wwt3mnzG; z?aUnRb+_Gh-O^^liqK(AV?FTBVr)d20orWgPw`>1p(&qsikZ_w=Uzed8Vn%bUXWn3 z6P??=?A-Ptc5~p@@<+z48jj%^M2$3 z!;(TpHG*@s)W=qrY#*3cZ~@`eOAfk<>ioiurhm?aF75pyx8W_hu+pCd(T=em693u! hPgVX;y$82<4Ab>-Y(jMe$OHBY>FXG2mucEP`7c@H9)$n^ literal 0 HcmV?d00001 diff --git a/images/ABC_flux_MC.png b/images/ABC_flux_MC.png new file mode 100644 index 0000000000000000000000000000000000000000..ac7e002f8c01ba2518f05ddf370679441e2f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FJEb^ad7G=<~022Mcw|BXPG z15h0+P>{37pc5eD_L Mgr-vQUGw1o1#ES#V*mgE literal 0 HcmV?d00001 From 470db6e1b3b18330360d5e7cafa73b5900b8cfac Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Thu, 21 Apr 2022 10:56:12 +0200 Subject: [PATCH 20/42] TRestAxionSolarFlux::ExportTables implementation --- inc/TRestAxionSolarFlux.h | 2 +- src/TRestAxionSolarFlux.cxx | 54 +++++++++++++++++++++++++++++-------- 2 files changed, 44 insertions(+), 12 deletions(-) diff --git a/inc/TRestAxionSolarFlux.h b/inc/TRestAxionSolarFlux.h index d17b594b..0e88c17b 100644 --- a/inc/TRestAxionSolarFlux.h +++ b/inc/TRestAxionSolarFlux.h @@ -130,7 +130,7 @@ class TRestAxionSolarFlux : public TRestMetadata { // This method should initialize the tables fFluxTable and fFluxLines } - void ExportTables(std::string fname); + void ExportTables(Bool_t ascii = false); void PrintMetadata(); diff --git a/src/TRestAxionSolarFlux.cxx b/src/TRestAxionSolarFlux.cxx index 15d7ce69..ef825576 100644 --- a/src/TRestAxionSolarFlux.cxx +++ b/src/TRestAxionSolarFlux.cxx @@ -87,9 +87,9 @@ /// /// \endcode /// -/// \warning when the flux is loaded manually inside the `restRoot` interactive +/// \warning When the flux is loaded manually inside the `restRoot` interactive /// shell, or inside a macro or script, after metadata initialization, it is necessary -/// to call the method TRestAxionSolarFlux::LoadTables to triger the tables +/// to call the method TRestAxionSolarFlux::LoadTables to trigger the tables /// initialization. /// /// ### Performing MonteCarlo tests using pre-loaded tables @@ -156,6 +156,8 @@ /// /// ![Solar flux distributions generated with TRestAxionSolarFlux::DrawSolarFlux.](ABC_FluxTable.png) /// +/// ### Exporting the solar flux tables +/// /// On top of that, we will be able to export those tables to the TRestAxionSolarFlux standard /// format to be used in later occasions. /// @@ -367,7 +369,7 @@ void TRestAxionSolarFlux::ReadFluxFile() { } if (fPeakSigma <= 0) { - warning << "TRestAxionSolarflux::ReadFluxFile. Peak ratio must be specified to generate " + warning << "TRestAxionSolarflux::ReadFluxFile. Peak sigma must be specified to generate " "monochromatic spectrum." << endl; warning @@ -761,7 +763,7 @@ void TRestAxionSolarFlux::PrintMetadata() { metadata << "--------" << endl; metadata << " - Random seed : " << fSeed << endl; if (fBinSize > 0) metadata << " - Energy bin size : " << fBinSize * units("eV") << " eV" << endl; - if (fPeakSigma > 0) metadata << " - Peak/continuum ratio : " << fPeakSigma << endl; + if (fPeakSigma > 0) metadata << " - Peak signal-to-noise in sigmas : " << fPeakSigma << endl; metadata << "++++++++++++++++++" << endl; if (GetVerboseLevel() >= REST_Debug) { @@ -775,13 +777,43 @@ void TRestAxionSolarFlux::PrintMetadata() { /// \brief It will create files with the continuum and spectral flux components to be used /// in a later ocasion. /// -void TRestAxionSolarFlux::ExportTables(string fname) { - // TODO if we have loaded the data through TRestAxionSolarModel we should - // create the filename on base to that +void TRestAxionSolarFlux::ExportTables(Bool_t ascii) { + string rootFilename = TRestTools::GetFileNameRoot(fFluxDataFile); + + string path = REST_USER_PATH + "/export/"; + + if (!TRestTools::fileExists(path)) { + cout << "Creating path: " << path << endl; + system(("mkdir -p " + path).c_str()); + } - // TOBE implemented. Creates fname.N200f and fname.spt - // If we have external methods to initialize solar flux tables this method - // might be used to generate the tables that can be used later on directly + if (fFluxTable.size() > 0) { + std::vector> table; + for (const auto& x : fFluxTable) { + std::vector row; + for (int n = 0; n < x->GetNbinsX(); n++) row.push_back(x->GetBinContent(n + 1)); - // Check data/solarFlux/README.md for data format and file naming conventions + table.push_back(row); + } + + if (!ascii) + TRestTools::ExportBinaryTable(path + "/" + rootFilename + ".N200f", table); + else + TRestTools::ExportASCIITable(path + "/" + rootFilename + ".dat", table); + } + + if (fFluxLines.size() > 0) { + std::vector> table; + for (const auto& x : fFluxLines) { + std::vector row; + row.push_back(x.first); + for (int n = 0; n < x.second->GetNbinsX(); n++) row.push_back(x.second->GetBinContent(n + 1)); + + table.push_back(row); + } + + TRestTools::TransposeTable(table); + + TRestTools::ExportASCIITable(path + "/" + rootFilename + ".spt", table); + } } From d084b8960a08ebcf48cef2059e799eed71cc2457 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Thu, 21 Apr 2022 10:57:22 +0200 Subject: [PATCH 21/42] Removing fluxToTables.py. Now this is directly imlemented inside TRestAxionSolarFlux::ReadFluxFile --- scripts/fluxToTables.py | 39 ++++++++++++++++++++++++++------------- 1 file changed, 26 insertions(+), 13 deletions(-) diff --git a/scripts/fluxToTables.py b/scripts/fluxToTables.py index acaf8105..ae63d4c7 100755 --- a/scripts/fluxToTables.py +++ b/scripts/fluxToTables.py @@ -10,10 +10,10 @@ import sys, os import ROOT +from array import array from ROOT import TH1D, TH2D import pandas as pd - import argparse parser = argparse.ArgumentParser() @@ -41,11 +41,13 @@ print (args.fname.find(".")) outfname = os.path.basename(args.fname) -outfname = outfname[0:outfname.find(".")] + ".dat" +outfname = outfname[0:outfname.find(".")] + ".Nxxf" if args.outfname != None: - outfname = args.outfname + ".dat" + outfname = args.outfname + "Nxxf" print (outfname) +extension = outfname[outfname.find(".")+1:] +print (extension) data = pd.read_csv(args.fname, sep=" ", skiprows=skiprows, header=None) @@ -65,13 +67,24 @@ #print( "R: " + str(r) + " En: " + str(en) + " Flux: " + str(flux) + "\n" ) print (outfname) -outf = open( outfname, "w") -print( str(fluxTable.GetNbinsX()) + " " + str(fluxTable.GetNbinsY()) ) -for n in range(0,fluxTable.GetNbinsX()): - for m in range(0,fluxTable.GetNbinsY()): - outf.write( str(fluxTable.GetBinContent( n+1, m+1 )) ) - if m == fluxTable.GetNbinsY() - 1: - outf.write("\n") - else: - outf.write("\t") -outf.close() + +if extension == "Nxxf": + print("Writting binary" ) + output_file = open(outfname, 'wb') + for n in range(0,fluxTable.GetNbinsX()): + float_array = array('f', []) + for m in range(0,fluxTable.GetNbinsY()): + float_array.append(float(fluxTable.GetBinContent( n+1, m+1 ))) + float_array.tofile(output_file) + output_file.close() +else: + outf = open( outfname, "w") + print( str(fluxTable.GetNbinsX()) + " " + str(fluxTable.GetNbinsY()) ) + for n in range(0,fluxTable.GetNbinsX()): + for m in range(0,fluxTable.GetNbinsY()): + outf.write( str(fluxTable.GetBinContent( n+1, m+1 )) ) + if m == fluxTable.GetNbinsY() - 1: + outf.write("\n") + else: + outf.write("\t") + outf.close() From a0a86351c47940a56187e5b1f88349bf3ab64999 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Thu, 21 Apr 2022 11:55:51 +0200 Subject: [PATCH 22/42] TRestAxionSolarFlux. Fixing TH1 potential name leak --- src/TRestAxionSolarFlux.cxx | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/TRestAxionSolarFlux.cxx b/src/TRestAxionSolarFlux.cxx index ef825576..b7e3959f 100644 --- a/src/TRestAxionSolarFlux.cxx +++ b/src/TRestAxionSolarFlux.cxx @@ -339,8 +339,6 @@ void TRestAxionSolarFlux::LoadMonoChromaticFluxTable() { asciiTable.push_back(floatVec); } - TRestTools::PrintTable(asciiTable, 0, 10); - fFluxLines.clear(); if (asciiTable.size() != 101) { @@ -351,7 +349,7 @@ void TRestAxionSolarFlux::LoadMonoChromaticFluxTable() { for (int en = 0; en < asciiTable[0].size(); en++) { Float_t energy = asciiTable[0][en]; - TH1F* h = new TH1F(Form("%s_MonochromeFluxAtEnergy%4.2lf", GetName(), energy), "", 100, 0, 1); + TH1F* h = new TH1F(Form("%s_MonochromeFluxAtEnergy%5.3lf", GetName(), energy), "", 100, 0, 1); for (int r = 1; r < asciiTable.size(); r++) h->SetBinContent(r, asciiTable[r][en]); fFluxLines[energy] = h; } @@ -457,7 +455,7 @@ void TRestAxionSolarFlux::ReadFluxFile() { if (spectrumHist->ProjectionX("", n + 1, n + 1)->Integral() > 0) { Double_t energy = spectrumHist->ProjectionY()->GetBinCenter(n + 1); TH1F* hm = (TH1F*)spectrumHist->ProjectionX( - Form("%s_MonochromeFluxAtEnergy%4.2lf", GetName(), energy), n + 1, n + 1); + Form("%s_MonochromeFluxAtEnergy%5.3lf", GetName(), energy), n + 1, n + 1); fFluxLines[energy] = hm; } } From c82525c362628466e1f63e4a9f227968841d1436 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Thu, 21 Apr 2022 11:56:23 +0200 Subject: [PATCH 23/42] .gitlab-ci.yml adding data files through wget --- .gitlab-ci.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 2f39d92c..9582f5dd 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -105,6 +105,10 @@ solarFlux: script: - . ${CI_PROJECT_DIR}/install/thisREST.sh - cd ${CI_PROJECT_DIR}/pipeline/metadata/solarFlux/ + - wget https://sultan.unizar.es/axionlib-data/solarFlux/fluxes.rml + - wget https://sultan.unizar.es/axionlib-data/solarFlux/Dummy_Galan_202202.spt + - wget https://sultan.unizar.es/axionlib-data/solarFlux/Primakoff_Gianotti_201904.dat + - wget https://sultan.unizar.es/axionlib-data/solarFlux/Primakoff_LennertHoof_202203.dat - python solarTests.py - python solarPlot.py - python compare.py From 58dfffc9bbc4491180c73d5e93604043ff7a670d Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Fri, 22 Apr 2022 11:26:30 +0200 Subject: [PATCH 24/42] solarPlot.py updating the maximum bin that has been affected from increasing histogram bin number --- pipeline/metadata/solarFlux/solarPlot.py | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/pipeline/metadata/solarFlux/solarPlot.py b/pipeline/metadata/solarFlux/solarPlot.py index 6c127a05..78e16b87 100755 --- a/pipeline/metadata/solarFlux/solarPlot.py +++ b/pipeline/metadata/solarFlux/solarPlot.py @@ -101,11 +101,6 @@ enSpt.SetLineColor(ROOT.kBlack) enSpt.Draw() -if validation: - if ( enSpt.GetMaximumBin() != 41 ): - print ( "\nMaximum Bin is not the expected one! Exit code : 1" ) - exit(1) - pad1.cd(3) pad1.cd(3).SetRightMargin(0.09); pad1.cd(3).SetLeftMargin(0.15); @@ -119,11 +114,6 @@ rSpt.SetLineColor(ROOT.kBlack) rSpt.Draw() -if validation: - if ( rSpt.GetMaximumBin() != 25 ): - print ( "\nMaximum Bin is not the expected one! Exit code : 2" ) - exit(2) - pad1.cd(4) pad1.cd(4).SetRightMargin(0.09); pad1.cd(4).SetLeftMargin(0.15); @@ -141,4 +131,17 @@ c1.Print(outfname) print( "Generated file : " + outfname ) +print ( "\nMaximum energy bin is " + str(enSpt.GetMaximumBin() ) ) +if validation: + if ( enSpt.GetMaximumBin() != 8001 ): + print ( "\nMaximum Bin is not the expected one! Exit code : 1" ) + exit(1) + +print ( "\nMaximum radius bin is " + str(rSpt.GetMaximumBin() ) ) + +if validation: + if ( rSpt.GetMaximumBin() != 25 ): + print ( "\nMaximum Bin is not the expected one! Exit code : 2" ) + exit(2) + exit(0) From 84a1d9074d160ef843544a0bc3c8713b007af465 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Fri, 22 Apr 2022 11:46:00 +0200 Subject: [PATCH 25/42] Removed RML definitions that will be placed now at axionlib-data --- pipeline/metadata/optics/basic.rml | 36 ---------------------------- pipeline/metadata/optics/mirrors.rml | 35 --------------------------- pipeline/metadata/optics/setups.rml | 19 --------------- 3 files changed, 90 deletions(-) delete mode 100644 pipeline/metadata/optics/basic.rml delete mode 100644 pipeline/metadata/optics/mirrors.rml delete mode 100644 pipeline/metadata/optics/setups.rml diff --git a/pipeline/metadata/optics/basic.rml b/pipeline/metadata/optics/basic.rml deleted file mode 100644 index c0d8e262..00000000 --- a/pipeline/metadata/optics/basic.rml +++ /dev/null @@ -1,36 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/pipeline/metadata/optics/mirrors.rml b/pipeline/metadata/optics/mirrors.rml deleted file mode 100644 index b2403114..00000000 --- a/pipeline/metadata/optics/mirrors.rml +++ /dev/null @@ -1,35 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/pipeline/metadata/optics/setups.rml b/pipeline/metadata/optics/setups.rml deleted file mode 100644 index 51489cec..00000000 --- a/pipeline/metadata/optics/setups.rml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - - - - - - - - - - - - - - From 6b003abf86e8a9f86b2b0c927acb43f3cb567d59 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Fri, 22 Apr 2022 13:06:17 +0200 Subject: [PATCH 26/42] Re-arranging pipeline setup --- .gitlab-ci.yml | 13 +++--- pipeline/metadata/magneticField/fields.rml | 40 ------------------- .../trilinear/GetMagneticField_test.C | 2 +- pipeline/metadata/transmission/windows.rml | 32 --------------- 4 files changed, 9 insertions(+), 78 deletions(-) delete mode 100644 pipeline/metadata/magneticField/fields.rml delete mode 100644 pipeline/metadata/transmission/windows.rml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 33f92948..e9392870 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -38,13 +38,9 @@ build: - cd framework - ./scripts/checkoutRemoteBranch.sh ${CI_COMMIT_BRANCH} - git submodule init source/libraries/axion - # This will download the data from axionlib. - # erhaps we should make the data accessible throught https and then open the remote files from the pipeline? - git submodule update source/libraries/axion - cd source/libraries/axion/ - git checkout ${CI_COMMIT_BRANCH} - - git submodule init data - - git submodule update data - cd ../../../ - mkdir build - cd build @@ -78,7 +74,8 @@ magneticField: # - . ${CI_PROJECT_DIR}/framework/source/libraries/axion/external/solarAxionFlux/bin/thisSolarAxionFluxLib.sh - . ${CI_PROJECT_DIR}/install/thisREST.sh - cd ${CI_PROJECT_DIR}/pipeline/metadata/magneticField/ - - ls $REST_PATH/data/axion/magneticField/ + - wget https://sultan.unizar.es/axionlib-data/magneticField/fields.rml + - wget https://sultan.unizar.es/axionlib-data/magneticField/Bykovskiy_201906.dat - python magneticField.py - cd trilinear - restRoot -b -q GetMagneticField_test.C @@ -93,6 +90,8 @@ optics: script: - . ${CI_PROJECT_DIR}/install/thisREST.sh - cd ${CI_PROJECT_DIR}/pipeline/metadata/optics/ + - wget https://sultan.unizar.es/axionlib-data/optics/mirrors.rml + - wget https://sultan.unizar.es/axionlib-data/optics/Reflectivity_Single_C_30_SiO2_0.N901f - python mirrors.py - python optics.py - python basic.py @@ -106,6 +105,10 @@ xRayTransmission: script: - . ${CI_PROJECT_DIR}/install/thisREST.sh - cd ${CI_PROJECT_DIR}/pipeline/metadata/transmission/ + - wget https://sultan.unizar.es/axionlib-data/windows.rml + - wget https://sultan.unizar.es/axionlib-data/Al.sol + - wget https://sultan.unizar.es/axionlib-data/Si.sol + - wget https://sultan.unizar.es/axionlib-data/Si3N4.sol - export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:${CI_PROJECT_DIR}/mpfr-4.0.2/install/lib - python windowPlot.py diff --git a/pipeline/metadata/magneticField/fields.rml b/pipeline/metadata/magneticField/fields.rml deleted file mode 100644 index a58a7623..00000000 --- a/pipeline/metadata/magneticField/fields.rml +++ /dev/null @@ -1,40 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/pipeline/metadata/magneticField/trilinear/GetMagneticField_test.C b/pipeline/metadata/magneticField/trilinear/GetMagneticField_test.C index b19db3c0..2ddf65b1 100644 --- a/pipeline/metadata/magneticField/trilinear/GetMagneticField_test.C +++ b/pipeline/metadata/magneticField/trilinear/GetMagneticField_test.C @@ -12,7 +12,7 @@ Int_t CheckPoint(TVector3 point); Int_t GetMagneticField_test() { TVector3 coordinates; - myField = new TRestAxionMagneticField("../fields.rml", "bField"); + myField = new TRestAxionMagneticField("fields.rml", "bField"); // changing x, while y and z are constant coordinates = TVector3(-349.8, -325.0, -4975.0); diff --git a/pipeline/metadata/transmission/windows.rml b/pipeline/metadata/transmission/windows.rml deleted file mode 100644 index 290081e9..00000000 --- a/pipeline/metadata/transmission/windows.rml +++ /dev/null @@ -1,32 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - From c175ff50033d2c8529e163ecc46ee665f4723361 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Fri, 22 Apr 2022 13:07:06 +0200 Subject: [PATCH 27/42] Updating data submodule --- data | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/data b/data index 227fb74b..d1a1bd06 160000 --- a/data +++ b/data @@ -1 +1 @@ -Subproject commit 227fb74b9bc0ca440b0896e24cf6e786a5488eea +Subproject commit d1a1bd0611f79cd3b824467d6e18613cad21c815 From e562088f0476e1ec3fff15ddcae6f48521a98338 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Fri, 22 Apr 2022 13:09:59 +0200 Subject: [PATCH 28/42] Ignoring png images --- pipeline/.gitignore | 1 + 1 file changed, 1 insertion(+) create mode 100644 pipeline/.gitignore diff --git a/pipeline/.gitignore b/pipeline/.gitignore new file mode 100644 index 00000000..e33609d2 --- /dev/null +++ b/pipeline/.gitignore @@ -0,0 +1 @@ +*.png From a2bb2ed118bba8bc5fa4b41dc2228e3cdbe79a7d Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Fri, 22 Apr 2022 18:00:16 +0200 Subject: [PATCH 29/42] TRestAxionOpticsMirror. Fixing typo --- src/TRestAxionOpticsMirror.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/TRestAxionOpticsMirror.cxx b/src/TRestAxionOpticsMirror.cxx index 7e995001..f48dab20 100644 --- a/src/TRestAxionOpticsMirror.cxx +++ b/src/TRestAxionOpticsMirror.cxx @@ -285,7 +285,7 @@ void TRestAxionOpticsMirror::LoadTables() { /// members /// std::string TRestAxionOpticsMirror::GetReflectivityFilename() { - string fnameR = "Reflectivy_" + fMirrorType + "_" + fLayerTop + "_" + fLayerThicknessTop + "_" + + string fnameR = "Reflectivity_" + fMirrorType + "_" + fLayerTop + "_" + fLayerThicknessTop + "_" + fSubstrate + "_" + fSigmaTop + ".N901f"; if (fMirrorType == "Bilayer") fnameR = "Reflectivity_" + fMirrorType + "_" + fLayerTop + "_" + fLayerThicknessTop + "_" + From 0296fcfa1e7ebb30fed69996994b70fb760e2ca0 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Fri, 22 Apr 2022 18:01:27 +0200 Subject: [PATCH 30/42] .gitlab-ci.yml downoading also transmission file --- .gitlab-ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index e9392870..2c05cd86 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -92,6 +92,7 @@ optics: - cd ${CI_PROJECT_DIR}/pipeline/metadata/optics/ - wget https://sultan.unizar.es/axionlib-data/optics/mirrors.rml - wget https://sultan.unizar.es/axionlib-data/optics/Reflectivity_Single_C_30_SiO2_0.N901f + - wget https://sultan.unizar.es/axionlib-data/optics/Transmission_Single_C_30_SiO2_0.N901f - python mirrors.py - python optics.py - python basic.py From d155afd85e5588549e7f4aada8b8f80e8114b0dd Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Sun, 24 Apr 2022 12:09:30 +0200 Subject: [PATCH 31/42] Fixing magneticField pipeline --- .gitlab-ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 2c05cd86..a1a1065b 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -78,6 +78,7 @@ magneticField: - wget https://sultan.unizar.es/axionlib-data/magneticField/Bykovskiy_201906.dat - python magneticField.py - cd trilinear + - wget https://sultan.unizar.es/axionlib-data/magneticField/fields.rml - restRoot -b -q GetMagneticField_test.C - cd ${CI_PROJECT_DIR}/pipeline/metadata/magneticField/boundary/ - restRoot -b -q Boundaries_test.C From e2cb73b9f0ebb9f9751d41c3566ea6a04d608ad2 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Sun, 24 Apr 2022 12:19:34 +0200 Subject: [PATCH 32/42] Fixing optics pipeline --- .gitlab-ci.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index a1a1065b..3e494136 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -92,8 +92,11 @@ optics: - . ${CI_PROJECT_DIR}/install/thisREST.sh - cd ${CI_PROJECT_DIR}/pipeline/metadata/optics/ - wget https://sultan.unizar.es/axionlib-data/optics/mirrors.rml + - wget https://sultan.unizar.es/axionlib-data/optics/optics.rml - wget https://sultan.unizar.es/axionlib-data/optics/Reflectivity_Single_C_30_SiO2_0.N901f - wget https://sultan.unizar.es/axionlib-data/optics/Transmission_Single_C_30_SiO2_0.N901f + - wget https://sultan.unizar.es/axionlib-data/optics/Reflectivity_Single_Au_250_Ni_0.4.N901f + - wget https://sultan.unizar.es/axionlib-data/optics/Transmission_Single_Au_250_Ni_0.4.N901f - python mirrors.py - python optics.py - python basic.py From ff881699d31cc4edc6d80c5d1d823e091f25170e Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Sun, 24 Apr 2022 12:21:55 +0200 Subject: [PATCH 33/42] Fixing windows transmission pipeline --- .gitlab-ci.yml | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 3e494136..bd9bc524 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -104,16 +104,15 @@ optics: variables: - $CRONJOB - xRayTransmission: type: metadata script: - . ${CI_PROJECT_DIR}/install/thisREST.sh - cd ${CI_PROJECT_DIR}/pipeline/metadata/transmission/ - - wget https://sultan.unizar.es/axionlib-data/windows.rml - - wget https://sultan.unizar.es/axionlib-data/Al.sol - - wget https://sultan.unizar.es/axionlib-data/Si.sol - - wget https://sultan.unizar.es/axionlib-data/Si3N4.sol + - wget https://sultan.unizar.es/axionlib-data/transmission/windows.rml + - wget https://sultan.unizar.es/axionlib-data/transmission/Al.sol + - wget https://sultan.unizar.es/axionlib-data/transmission/Si.sol + - wget https://sultan.unizar.es/axionlib-data/transmission/Si3N4.sol - export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:${CI_PROJECT_DIR}/mpfr-4.0.2/install/lib - python windowPlot.py From 7750fd8a40711a8f8452b84049492b122ca37487 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Sun, 24 Apr 2022 12:41:17 +0200 Subject: [PATCH 34/42] Fixing optics pipeline --- pipeline/metadata/optics/optics.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pipeline/metadata/optics/optics.py b/pipeline/metadata/optics/optics.py index 151f63ba..7ab66e49 100755 --- a/pipeline/metadata/optics/optics.py +++ b/pipeline/metadata/optics/optics.py @@ -5,7 +5,7 @@ ROOT.gSystem.Load("libRestFramework.so") ROOT.gSystem.Load("libRestAxion.so") -mcplOptics_1 = ROOT.TRestAxionMCPLOptics("setups.rml", "mcpl") +mcplOptics_1 = ROOT.TRestAxionMCPLOptics("optics.rml", "mcpl") mcplOptics_1.PrintMetadata() rings = mcplOptics_1.GetNumberOfRings() From e2b67bd84299980017e490bf901545aa19c2db0f Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Sun, 24 Apr 2022 12:57:19 +0200 Subject: [PATCH 35/42] Fixing pipeline style --- .gitlab-ci.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index bd9bc524..53dd9fbc 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -30,7 +30,7 @@ validateLibrary: - $CRONJOB == "YES" build: - type: build + stage: build script: - echo "**${CI_PROJECT_DIR}**" - rm -rf ${CI_PROJECT_DIR}/install @@ -59,7 +59,7 @@ build: expire_in: 1 day loadRESTLibs: - type: loadRESTLibs + stage: loadRESTLibs script: - . ${CI_PROJECT_DIR}/install/thisREST.sh # - . ${CI_PROJECT_DIR}/framework/source/libraries/axion/external/solarAxionFlux/bin/thisSolarAxionFluxLib.sh @@ -69,7 +69,7 @@ loadRESTLibs: - $CRONJOB magneticField: - type: metadata + stage: metadata script: # - . ${CI_PROJECT_DIR}/framework/source/libraries/axion/external/solarAxionFlux/bin/thisSolarAxionFluxLib.sh - . ${CI_PROJECT_DIR}/install/thisREST.sh @@ -87,7 +87,7 @@ magneticField: - $CRONJOB optics: - type: metadata + stage: metadata script: - . ${CI_PROJECT_DIR}/install/thisREST.sh - cd ${CI_PROJECT_DIR}/pipeline/metadata/optics/ @@ -105,7 +105,7 @@ optics: - $CRONJOB xRayTransmission: - type: metadata + stage: metadata script: - . ${CI_PROJECT_DIR}/install/thisREST.sh - cd ${CI_PROJECT_DIR}/pipeline/metadata/transmission/ @@ -117,7 +117,7 @@ xRayTransmission: - python windowPlot.py solarFlux: - type: metadata + stage: metadata script: - . ${CI_PROJECT_DIR}/install/thisREST.sh - cd ${CI_PROJECT_DIR}/pipeline/metadata/solarFlux/ From 1b2133a4440581ddb3d8beb1c57e923e8df8f9a1 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Sun, 24 Apr 2022 13:04:20 +0200 Subject: [PATCH 36/42] TRestAxionSolarFlux. Fixing warning --- src/TRestAxionSolarFlux.cxx | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/TRestAxionSolarFlux.cxx b/src/TRestAxionSolarFlux.cxx index b7e3959f..c8240315 100644 --- a/src/TRestAxionSolarFlux.cxx +++ b/src/TRestAxionSolarFlux.cxx @@ -383,12 +383,9 @@ void TRestAxionSolarFlux::ReadFluxFile() { std::vector> fluxData; TRestTools::ReadASCIITable(fullPathName, fluxData, 3); - TH2F* originalHist = - new TH2F(Form("FullTable", GetName()), "", 100, 0., 1., (Int_t)(20. / fBinSize), 0., 20.); - TH2F* continuumHist = - new TH2F(Form("ContinuumTable", GetName()), "", 100, 0., 1., (Int_t)(20. / fBinSize), 0., 20.); - TH2F* spectrumHist = - new TH2F(Form("LinesTable", GetName()), "", 100, 0., 1., (Int_t)(20. / fBinSize), 0., 20.); + TH2F* originalHist = new TH2F("FullTable", "", 100, 0., 1., (Int_t)(20. / fBinSize), 0., 20.); + TH2F* continuumHist = new TH2F("ContinuumTable", "", 100, 0., 1., (Int_t)(20. / fBinSize), 0., 20.); + TH2F* spectrumHist = new TH2F("LinesTable", "", 100, 0., 1., (Int_t)(20. / fBinSize), 0., 20.); for (const auto& data : fluxData) { Double_t r = 0.005 + data[0]; From 284e6262a87ba1e8edf7d9fb393702585a0f60fd Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Sun, 24 Apr 2022 13:05:44 +0200 Subject: [PATCH 37/42] Fixing optics pipeline --- pipeline/metadata/optics/basic.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pipeline/metadata/optics/basic.py b/pipeline/metadata/optics/basic.py index bc43c111..ce0006f3 100755 --- a/pipeline/metadata/optics/basic.py +++ b/pipeline/metadata/optics/basic.py @@ -27,8 +27,8 @@ totalSamples = 10000 genSize = 80 -basicOptics = ROOT.TRestAxionOptics("basic.rml", "basic") -spiderOptics = ROOT.TRestAxionOptics("basic.rml", "basic_spider") +basicOptics = ROOT.TRestAxionOptics("optics.rml", "basic") +spiderOptics = ROOT.TRestAxionOptics("optics.rml", "basic_spider") rings = basicOptics.GetNumberOfRings() print( "Number of rings (no-spider): " + str(rings) ) From 62eff3cc741d17b86c075731978979c486967cbc Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Wed, 4 May 2022 17:28:35 +0200 Subject: [PATCH 38/42] TRestAxionSolarFlux. Adding metadata member fFluxBinSize --- inc/TRestAxionSolarFlux.h | 3 +++ src/TRestAxionSolarFlux.cxx | 26 ++++++++++++++++++++------ 2 files changed, 23 insertions(+), 6 deletions(-) diff --git a/inc/TRestAxionSolarFlux.h b/inc/TRestAxionSolarFlux.h index 0e88c17b..0b39af77 100644 --- a/inc/TRestAxionSolarFlux.h +++ b/inc/TRestAxionSolarFlux.h @@ -58,6 +58,9 @@ class TRestAxionSolarFlux : public TRestMetadata { /// It will be used when loading `.flux` files to define the threshold for peak identification Double_t fPeakSigma = 0; //< + /// It will be used to define the original flux table binSize. If not defined it is the same as fBinSize. + Double_t fFluxBinSize = 0; //< + /// The tabulated solar flux continuum spectra TH1F(100,0,20)keV in cm-2 s-1 keV-1 versus solar radius std::vector fFluxTable; //! diff --git a/src/TRestAxionSolarFlux.cxx b/src/TRestAxionSolarFlux.cxx index c8240315..fc1f95ef 100644 --- a/src/TRestAxionSolarFlux.cxx +++ b/src/TRestAxionSolarFlux.cxx @@ -56,11 +56,18 @@ /// contributions by TRestAxionSolarFlux::ReadFluxFile to be managed internally. Two /// additional parameters *will be required* to translate the `.flux` files into the tables /// that are understood by this class. -/// - *binSize:* The energy binning used on the `.flux` file. +/// - *binSize:* The energy binning used on the `.flux` file and inside the histogram used +/// for monochromatic lines identification. /// - *peakSigma:* The ratio between the flux provided at the `.flux` file and the /// average flux calculated in the peak surroundings. If the flux ratio is higher than /// this value, the flux at that particular bin will be considered a peak. /// +/// Optionally, if we want to consider a different binning on the monochromatic/continuum +/// histogram used internally for the calculation we may specify optionally a new parameter. +/// In that case, `fBinSize` will be the binning of the internal histogram, while the new +/// parameter will be the binning given inside the `.flux` file. +/// - *fluxBinSize:* The bin size used on the `.flux` table. +/// /// Pre-generated solar axion flux tables will be available at the /// [axionlib-data](https://github.com/rest-for-physics/axionlib-data/tree/master) /// repository. The different RML flux definitions used to load those tables @@ -383,18 +390,22 @@ void TRestAxionSolarFlux::ReadFluxFile() { std::vector> fluxData; TRestTools::ReadASCIITable(fullPathName, fluxData, 3); + debug << "Table loaded" << endl; TH2F* originalHist = new TH2F("FullTable", "", 100, 0., 1., (Int_t)(20. / fBinSize), 0., 20.); TH2F* continuumHist = new TH2F("ContinuumTable", "", 100, 0., 1., (Int_t)(20. / fBinSize), 0., 20.); TH2F* spectrumHist = new TH2F("LinesTable", "", 100, 0., 1., (Int_t)(20. / fBinSize), 0., 20.); + if (fFluxBinSize == 0) fFluxBinSize = fBinSize; + for (const auto& data : fluxData) { - Double_t r = 0.005 + data[0]; - Double_t en = data[1] - 0.005; - Double_t flux = data[2] * fBinSize; // flux in cm-2 s-1 bin-1 + Float_t r = 0.005 + data[0]; + Float_t en = data[1] - 0.005; + Float_t flux = data[2] * fBinSize; // flux in cm-2 s-1 bin-1 - originalHist->Fill(r, en, flux); - continuumHist->Fill(r, en, flux); + originalHist->Fill(r, en, (Float_t)flux); + continuumHist->Fill(r, en, (Float_t)flux); } + debug << "Histograms filled" << endl; Int_t peaks = 0; do { @@ -758,6 +769,9 @@ void TRestAxionSolarFlux::PrintMetadata() { metadata << "--------" << endl; metadata << " - Random seed : " << fSeed << endl; if (fBinSize > 0) metadata << " - Energy bin size : " << fBinSize * units("eV") << " eV" << endl; + if (fFluxBinSize > 0) + metadata << " - Original .flux file energy bin size : " << fFluxBinSize * units("eV") << " eV" + << endl; if (fPeakSigma > 0) metadata << " - Peak signal-to-noise in sigmas : " << fPeakSigma << endl; metadata << "++++++++++++++++++" << endl; From 5b87a3f4ab19d45b13e699be35583ae8da457f72 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Wed, 4 May 2022 17:28:47 +0200 Subject: [PATCH 39/42] Updating data submodule --- data | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/data b/data index d1a1bd06..b54047f3 160000 --- a/data +++ b/data @@ -1 +1 @@ -Subproject commit d1a1bd0611f79cd3b824467d6e18613cad21c815 +Subproject commit b54047f3396819c94860e57503be2415532c5c9e From 5ab857ce55a48992b3460e0445a8f3677f909136 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Wed, 4 May 2022 17:40:57 +0200 Subject: [PATCH 40/42] Updating data submodule --- data | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/data b/data index b54047f3..d9ca6507 160000 --- a/data +++ b/data @@ -1 +1 @@ -Subproject commit b54047f3396819c94860e57503be2415532c5c9e +Subproject commit d9ca6507468f2203509c1bf07d3326a186a4d2b8 From f0ea921e70c41c376b8bb925469067820e19b3f5 Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Fri, 6 May 2022 08:24:30 +0200 Subject: [PATCH 41/42] TRestAxionSolarFlux. Fixed an issue with .flux binning size identification --- inc/TRestAxionSolarFlux.h | 3 --- src/TRestAxionSolarFlux.cxx | 9 +++------ 2 files changed, 3 insertions(+), 9 deletions(-) diff --git a/inc/TRestAxionSolarFlux.h b/inc/TRestAxionSolarFlux.h index 0b39af77..0e88c17b 100644 --- a/inc/TRestAxionSolarFlux.h +++ b/inc/TRestAxionSolarFlux.h @@ -58,9 +58,6 @@ class TRestAxionSolarFlux : public TRestMetadata { /// It will be used when loading `.flux` files to define the threshold for peak identification Double_t fPeakSigma = 0; //< - /// It will be used to define the original flux table binSize. If not defined it is the same as fBinSize. - Double_t fFluxBinSize = 0; //< - /// The tabulated solar flux continuum spectra TH1F(100,0,20)keV in cm-2 s-1 keV-1 versus solar radius std::vector fFluxTable; //! diff --git a/src/TRestAxionSolarFlux.cxx b/src/TRestAxionSolarFlux.cxx index fc1f95ef..22df80cb 100644 --- a/src/TRestAxionSolarFlux.cxx +++ b/src/TRestAxionSolarFlux.cxx @@ -356,7 +356,7 @@ void TRestAxionSolarFlux::LoadMonoChromaticFluxTable() { for (int en = 0; en < asciiTable[0].size(); en++) { Float_t energy = asciiTable[0][en]; - TH1F* h = new TH1F(Form("%s_MonochromeFluxAtEnergy%5.3lf", GetName(), energy), "", 100, 0, 1); + TH1F* h = new TH1F(Form("%s_MonochromeFluxAtEnergy%6.4lf", GetName(), energy), "", 100, 0, 1); for (int r = 1; r < asciiTable.size(); r++) h->SetBinContent(r, asciiTable[r][en]); fFluxLines[energy] = h; } @@ -395,12 +395,12 @@ void TRestAxionSolarFlux::ReadFluxFile() { TH2F* continuumHist = new TH2F("ContinuumTable", "", 100, 0., 1., (Int_t)(20. / fBinSize), 0., 20.); TH2F* spectrumHist = new TH2F("LinesTable", "", 100, 0., 1., (Int_t)(20. / fBinSize), 0., 20.); - if (fFluxBinSize == 0) fFluxBinSize = fBinSize; + Double_t fluxBinSize = TRestTools::GetLowestIncreaseFromTable(fluxData, 1); for (const auto& data : fluxData) { Float_t r = 0.005 + data[0]; Float_t en = data[1] - 0.005; - Float_t flux = data[2] * fBinSize; // flux in cm-2 s-1 bin-1 + Float_t flux = data[2] * fluxBinSize; // flux in cm-2 s-1 bin-1 originalHist->Fill(r, en, (Float_t)flux); continuumHist->Fill(r, en, (Float_t)flux); @@ -769,9 +769,6 @@ void TRestAxionSolarFlux::PrintMetadata() { metadata << "--------" << endl; metadata << " - Random seed : " << fSeed << endl; if (fBinSize > 0) metadata << " - Energy bin size : " << fBinSize * units("eV") << " eV" << endl; - if (fFluxBinSize > 0) - metadata << " - Original .flux file energy bin size : " << fFluxBinSize * units("eV") << " eV" - << endl; if (fPeakSigma > 0) metadata << " - Peak signal-to-noise in sigmas : " << fPeakSigma << endl; metadata << "++++++++++++++++++" << endl; From b1ed7a30ad355110276cfa1a93c500f3f65fea2b Mon Sep 17 00:00:00 2001 From: Javier Galan Date: Fri, 6 May 2022 08:24:55 +0200 Subject: [PATCH 42/42] Updating data submodule --- data | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/data b/data index d9ca6507..22cf5a4d 160000 --- a/data +++ b/data @@ -1 +1 @@ -Subproject commit d9ca6507468f2203509c1bf07d3326a186a4d2b8 +Subproject commit 22cf5a4dd9f3b07e0d0017c767c62839988c99c7