Skip to content

Conversation

@jgalan
Copy link
Member

@jgalan jgalan commented May 24, 2023

jgalan Medium: 165

TRestMetadata::GetDataMemberValues minor fix on TVector2,3 output component

Before this PR (for the case of TVector2,3), the following output was generated when invoking GetMetadataMember.

root [7] run0->GetMetadataMember("axionGen::fEnergyRange[0]")
(std::string) "(0.05"
root [8] run0->GetMetadataMember("axionGen::fEnergyRange[1]")
(std::string) "10)"

After this PR, parenthesis are removed from the output.

root [7] run0->GetMetadataMember("axionGen::fEnergyRange[0]")
(std::string) "0.05"
root [8] run0->GetMetadataMember("axionGen::fEnergyRange[1]")
(std::string) "10"

Added also:

  • REST_Generate_DataSets macro that will allow to export several datasets from a given list of dataset names.
  • Added new filter condition equalsTo that allows to evaluate numerically if a datamember is equal to the filter. If it is not equal, then the run will be rejected and thus not included in the dataset.
  • Added method TRestDataSet::Define that allows to create a new column using the values of relevant quantities.
  • Added method TRestDataSet::Import( std::vector <std::string> fNames ) allowing to combine datasets into one single instance. If saved to disk the metadata member fMergedDataSet will be true in order to identify that it is a non-pure original dataset.

For the moment metadata filter conditions do not support units. See issue: #429

@jgalan jgalan changed the title Jgalan minor fix on TVector2,3 output component TRestMetadata::GetDataMemberValues minor fix on TVector2,3 output component May 24, 2023
@jgalan jgalan changed the title TRestMetadata::GetDataMemberValues minor fix on TVector2,3 output component TRestMetadata May 24, 2023
@jgalan jgalan changed the title TRestMetadata Fix on TRestMetadata and TRestDataSet add-ons May 24, 2023
@jgalan jgalan marked this pull request as ready for review May 25, 2023 08:00
@jgalan
Copy link
Member Author

jgalan commented May 26, 2023

I am going a need an Import method that allows me to combine different datasets to be loaded in TRestComponent. Thus, I have implemented a new Import method allowing to receive several ROOT files as argument. There will be a datamember fMergedDataSet that keeps track if this method was used to initialize the dataset.

I also added a new TRestDataSet::Define method that allows to generate a new column using/replacing the values of relevant quantities.

Any feedback about their implementation? @juanangp

@jgalan jgalan merged commit c33746a into master May 26, 2023
@jgalan jgalan deleted the jgalan_minor_fix branch May 26, 2023 09:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants