Hyperiso 1.0.3
Modular flavour-physics calculations, Wilson coefficients and statistical inference
Loading...
Searching...
No Matches
main_multithread.cpp
Go to the documentation of this file.
1#include "HyperisoInterface.h"
2
3void ProcessFile(HyperisoInterface& instance, const std::string& lhaFile) {
4 MemoryManager* mm = instance.GetMemoryManager();
5 WilsonInterface* wi = instance.GetWilsonInterface();
6
7 mm->init(lhaFile, {0});
9 std::cout << "Processing file: " << lhaFile << std::endl;
11 wi->init_group(WGroup::B, CoefficientOrder::LO);
12
13 std::cout << "C7 in SM : " << wi->getMatchingCoefficient(WGroup::B, WilsonCoefficientList::C7, CoefficientOrder::LO) << std::endl;
14}
15
16int main() {
17 std::vector<std::string> lhaFiles = {"file1.slha", "file2.slha", "file3.slha"};
18
20
21 hyperiso.RunInParallel(
22 lhaFiles,
24 "SM",
25 {0},
26 4
27 );
28
29}
static HyperisoInterface & GetInstance()
WilsonInterface * GetWilsonInterface()
MemoryManager * GetMemoryManager()
void RunInParallel(const std::vector< std::string > &lhaFiles, std::function< void(HyperisoInterface &, const std::string &)> task, const std::string &model="SM", const std::vector< int > &models={0}, size_t maxThreads=std::thread::hardware_concurrency())
Singleton class responsible for initializing and managing memory, input files, and parameter blocks.
void init(const std::string &lhaFile, HyperisoConfig config)
Initializes the memory manager with the provided LHA file and configuration.
User-facing API to build and query Wilson coefficients at matching and hadronic scales.
void addWilsonGroup(WilsonBuildConfig config)
Adds one or more Wilson groups to an existing built interface.
scalar_t getMatchingCoefficient(WGroupId group, WCoefId coeff, QCDOrder order, ContributionType cont_type)
Returns the matching-scale coefficient at the requested QCD order.
void set_matching_scale(double mu_W)
Sets the matching scale (mu_W) in the global parameter system.
void ProcessFile(HyperisoInterface &instance, const std::string &lhaFile)
int main()