当前位置: 首页>>代码示例>>C++>>正文


C++ AliSimulation::ConvertRaw2SDigits方法代码示例

本文整理汇总了C++中AliSimulation::ConvertRaw2SDigits方法的典型用法代码示例。如果您正苦于以下问题:C++ AliSimulation::ConvertRaw2SDigits方法的具体用法?C++ AliSimulation::ConvertRaw2SDigits怎么用?C++ AliSimulation::ConvertRaw2SDigits使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在AliSimulation的用法示例。


在下文中一共展示了AliSimulation::ConvertRaw2SDigits方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: makeSDigit

void makeSDigit(Int_t run=117048,
                const char *fname="/alice/data/2010/LHC10b/000117048/raw/10000117048041.30.root")
{
  AliSimulation sim;
  //AliLog::SetGlobalDebugLevel(1);
  AliLog::SetModuleDebugLevel("STEER",1);
  AliCDBManager *cdbm = AliCDBManager::Instance();
  cdbm->SetRun(run);
  cdbm->SetDefaultStorage("local://$ALIROOT_OCDB_ROOT/OCDB");     
  //cdbm->SetDefaultStorage("raw://");     
  cdbm->SetSpecificStorage("GRP/GRP/Data",Form("local://%s","$ALICE_ROOT/test/rawmerge"));  
  sim.SetMakeSDigits("ITS TPC");
  sim.SetNumberOfEvents(10000);
  sim.ConvertRaw2SDigits(fname);
  return;
}
开发者ID:alisw,项目名称:AliRoot,代码行数:16,代码来源:makeSDigit.C

示例2: sim

void sim(Int_t embrun) 
{
  AliSimulation sim;
  if (embrun == 4) {
    AliCDBManager *cdbm = AliCDBManager::Instance();
    cdbm->SetRun(atoi(gSystem->Getenv("DC_RUN")));
    cdbm->SetDefaultStorage("local://$ALICE_ROOT/OCDB");     
    cdbm->SetSpecificStorage("GRP/GRP/Data",Form("local://%s",gSystem->pwd()));
    sim.SetMakeSDigits("ITS TPC TRD TOF VZERO");  

    sim.ConvertRaw2SDigits("raw.root","AliESDs.root");
    return;
  }
  
  if (embrun == 2) {
    sim.SetRunGeneration(kFALSE);
    sim.SetMakeSDigits("");
    sim.SetMakeDigitsFromHits("");
  }
  else {
    sim.SetRunGeneration(kTRUE);
    sim.SetMakeSDigits("ITS TPC TRD TOF VZERO");
  }
  sim.SetRunSimulation(kTRUE);
  sim.SetMakeDigits("ITS TPC TRD TOF VZERO");
  sim.SetWriteRawData("ITS TPC TRD TOF VZERO","raw.root",kTRUE);
  if (embrun == 1)
    sim.MergeWith("../BackgroundSDigits/galice.root",1);

  sim.SetDefaultStorage("local://$ALICE_ROOT/OCDB");
  sim.SetSpecificStorage("GRP/GRP/Data",
			       Form("local://%s",gSystem->pwd()));
  sim.SetRunQA(":") ; 
  AliQA::SetQARefStorage("local://$ALICE_ROOT/OCDB") ;
  
  for (Int_t det = 0 ; det < AliQA::kNDET ; det++) {
    sim.SetQACycles(det, 1) ;
  }

//   sim.SetDefaultStorage("alien://Folder=/alice/simulation/2008/v4-15-Release/Full/");
//   sim.SetRunHLT("");
//   sim.SetQA(kFALSE);

  sim.Run(1);
}
开发者ID:ktf,项目名称:AliRoot,代码行数:45,代码来源:sim.C

示例3: sim


//.........这里部分代码省略.........
		if (trgname){
			AliCDBEntry *grp_ctp = cdbm->Get("GRP/CTP/Config",run);
			AliTriggerConfiguration *trg_conf = (AliTriggerConfiguration *)grp_ctp->GetObject();
			trg_conf->Print();
			TObjArray trg_masks = trg_conf->GetClasses(); // Reference!!!
			std::vector<unsigned char> triggerconfs;
			for(Int_t iobj = 0; iobj < trg_masks.GetEntriesFast(); iobj++){
				AliTriggerClass *trg_class = (AliTriggerClass*)trg_masks.UncheckedAt(iobj);
				AliTriggerCluster *trg_clust = (AliTriggerCluster *)trg_class->GetCluster();
				//				printf("%s %s \n",trg_class->GetName(),trgname);
				if(TString(trg_class->GetName()).Contains(trgname)){
					printf("We will embed into events containing this trigger name(mask): %s(%d)\n",trg_class->GetName(),trg_class->GetMask());
					char triggerbuf[256];
					sprintf(triggerbuf, "?Trigger=%d", trg_class->GetMask());
					sfname += triggerbuf;
					//					triggerconfs.push_back(trg_class->GetMask());
				}
			}
			
			//			Int_t itrg = 0;
			//			printf("Number of Trigger Clusters including MUON: %d\n", (Int_t)triggerconfs.size());
			//    for(std::vector<unsigned char>::iterator it = triggerconfs.begin(); it < triggerconfs.end(); it++)
			//      printf("Trigger Mask %d for MUON: %d\n", itrg++, *it);
			//    filestring += "?EventType=7";
			//    char triggerbuf[256];
			//    Int_t triggerval = 0;
			//    for(std::vector<unsigned char>::iterator it = triggerconfs.begin(); it < triggerconfs.end(); it++)
			//      triggerval += *it;
			//    sprintf(triggerbuf, "?Trigger=%d", triggerval);
			//    filestring += triggerbuf; // This line does the trigger selection. It has to be uncommented if one wants to apply trigger selection
		}
		printf("Filename: %s\n", sfname.Data());
		
		Int_t iSelEvents = simulator.ConvertRaw2SDigits(sfname.Data(),esdname,nev,nskip);
		gSystem->Setenv("DC_NEVENTS",Form("%d",iSelEvents));
		gSystem->Exec("echo $DC_NEVENTS > selev.log");
		//			gSystem->Exec("echo ${DC_NEVENTS} > ${DC_NEVENTS}_${DC_NEVENTS}_0_${DC_NEVENTS}.stat"); // done in simrun.C
		gSystem->Exec("echo in sim.C $DC_NEVENTS");
		return;
	}
	
	// Signal: pure signal
	if (!(strcmp(embrun,"kSignal"))){
		
		if (!gSystem->Getenv("DC_NEVENTS")) {
			printf("DC_NEVENTS is not set and is needed at this step!!!");
			return;
		}
		
		AliCDBManager *cdbm = AliCDBManager::Instance();
		cdbm->SetDefaultStorage("alien://Folder=/alice/data/2011/OCDB");
		cdbm->SetRun(run);
		
		AliGRPManager grpM;
		grpM.ReadGRPEntry();
		grpM.SetMagField();
		printf("Field is locked now. It cannot be changed in Config.C\n");
		
		simulator.SetRunGeneration(kFALSE);
		simulator.SetMakeSDigits("");
		simulator.SetMakeDigitsFromHits("");
	}
	// MERGED: Simulate signal and merge with background
	if (!(strcmp(embrun,"kMerged"))){
		simulator.SetRunGeneration(kTRUE);
		simulator.SetMakeSDigits("MUON ITS");
开发者ID:JanFSchulte,项目名称:monalisa,代码行数:67,代码来源:sim.C


注:本文中的AliSimulation::ConvertRaw2SDigits方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。