Skip to content

Commit

Permalink
Root6 fixes for PWGDQ (#375)
Browse files Browse the repository at this point in the history
* Root6 fixes

* just cust the cocktail pointer
  • Loading branch information
gconesab authored Jun 12, 2020
1 parent 1c51e69 commit 98c7745
Show file tree
Hide file tree
Showing 8 changed files with 22 additions and 18 deletions.
5 changes: 2 additions & 3 deletions MC/CustomGenerators/PWGDQ/Hijing_Jpsiee001.C
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
AliGenerator *
GeneratorCustom()
{

TString simulation = gSystem->Getenv("CONFIG_SIMULATION");

AliGenCocktail *ctl = GeneratorCocktail("Hijing_Jpsiee001");

AliGenCocktail *ctl = (AliGenCocktail*) GeneratorCocktail("Hijing_Jpsiee001");
if(!simulation.Contains("Embed")){
AliGenerator *hij = GeneratorHijing();
ctl->AddGenerator(hij, "Hijing", 1.);
Expand Down
4 changes: 2 additions & 2 deletions MC/CustomGenerators/PWGDQ/Hijing_Jpsiee002.C
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ GeneratorCustom(TString ptParamPrompt="UserParam_PbPb5TeV_0010")
{
TString simulation = gSystem->Getenv("CONFIG_SIMULATION");

AliGenCocktail *ctl = GeneratorCocktail("Hijing_Jpsiee002");

AliGenCocktail *ctl = (AliGenCocktail*) GeneratorCocktail("Hijing_Jpsiee002");
if(!simulation.Contains("Embed")){
AliGenerator *hij = GeneratorHijing();
ctl->AddGenerator(hij, "Hijing", 1.);
Expand Down
4 changes: 3 additions & 1 deletion MC/CustomGenerators/PWGDQ/Hijing_JpsieeXeXe.C
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
AliGenerator *
GeneratorCustom()
{
AliGenCocktail *cocktail = GeneratorCocktail("Hijing_JpsieeXeXe");
AliGenCocktail *cocktail = (AliGenCocktail*) GeneratorCocktail("Hijing_JpsieeXeXe");

AliGenerator *hij = GeneratorHijing();
cocktail->AddGenerator(hij, "Hijing", 1.);
if (uidConfig % 10 < 7) {
Expand All @@ -16,5 +17,6 @@ GeneratorCustom()
TFile *file = new TFile("typeHF_5.proc", "recreate");
file->Close();
}

return cocktail;
}
2 changes: 1 addition & 1 deletion MC/CustomGenerators/PWGDQ/Hijing_LMee001.C
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ GeneratorCustom(TString opt = "")
gSystem->Load("libEvtGenExternal");
gSystem->Load("libTEvtGen");

AliGenCocktail* ctl = (AliGenCocktail*) GeneratorCocktail("Hijing_LMee001");
AliGenCocktail *ctl = (AliGenCocktail*) GeneratorCocktail("Hijing_LMee001");

// Background events: HIJING (only if non-embedded)
TString simulation = gSystem->Getenv("CONFIG_SIMULATION");
Expand Down
3 changes: 1 addition & 2 deletions MC/CustomGenerators/PWGDQ/Hijing_LMee002.C
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
AliGenerator *
GeneratorCustom(TString opt = "")
{

AliGenCocktail* ctl = (AliGenCocktail*) GeneratorCocktail("Hijing_LMee002");
AliGenCocktail *ctl = (AliGenCocktail*) GeneratorCocktail("Hijing_LMee002");

// Background events: HIJING (only if non-embedded)
TString simulation = gSystem->Getenv("CONFIG_SIMULATION");
Expand Down
3 changes: 1 addition & 2 deletions MC/CustomGenerators/PWGDQ/Hijing_LMee003.C
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
AliGenerator *
GeneratorCustom(TString opt = "")
{

AliGenCocktail *ctl = (AliGenCocktail*)GeneratorCocktail("Hijing_LMee003");
AliGenCocktail *ctl = (AliGenCocktail*) GeneratorCocktail("Hijing_LMee003");

// Background events: HIJING (only if non-embedded)
TString simulation = gSystem->Getenv("CONFIG_SIMULATION");
Expand Down
4 changes: 2 additions & 2 deletions MC/CustomGenerators/PWGDQ/Hijing_Starlight.C
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
AliGenerator *
GeneratorCustom()
{
AliGenCocktail* cocktail = GeneratorCocktail("Hijing_Starlight");
AliGenCocktail *cocktail = (AliGenCocktail*) GeneratorCocktail("Hijing_Starlight");

AliGenerator* starlight = GeneratorStarlight();
if (processConfig == TString("kTwoGammaToElMedium")) {
AliGenStarLight *genStarLight = (AliGenStarLight*) starlight;
Expand Down
15 changes: 10 additions & 5 deletions MC/GeneratorConfig.C
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@
#include "AliDecayer.h"
#endif

#if !defined(__CINT__) || defined(__MAKECINT__)
R__ADD_INCLUDE_PATH($ALIDPG_ROOT)
#include "MC/CustomGenerators/PWGDQ/GenJPsiParaSet.C"
#endif


enum EGenerator_t {
kGeneratorDefault,
// Pythia6
Expand Down Expand Up @@ -1596,13 +1602,12 @@ Generator_Jpsiee(const Char_t *params, Float_t jpsifrac, Float_t lowfrac, Float_
AliGenParam* jpsi = NULL;
if(stringParams.Contains("UserParam")){
// use private parametrization for y / pT instead of AliGenMUONlib
#if defined(__CINT__)
// for root5
gROOT->LoadMacro("$ALIDPG_ROOT/MC/CustomGenerators/PWGDQ/GenJPsiParaSet.C++");
#if !(defined(__CLING__))
jpsi = GenJPsiParaSet(stringParams);
#else
Printf("ERROR: This option is not yet available for ROOT6 ... abort");
return NULL;
#endif

jpsi = GenJPsiParaSet(stringParams);
}
else jpsi = new AliGenParam(1, AliGenMUONlib::kJpsi, params, "Jpsi");
jpsi->SetPtRange(0., 1000.);
Expand Down

0 comments on commit 98c7745

Please sign in to comment.