Difference: DaVinciTutorial0p5 (32 vs. 33)

Revision 332014-06-18 - NathanaelFarley

Line: 1 to 1
 
META TOPICPARENT name="DaVinciTutorial"

DaVinci Tutorial 0.5

Line: 43 to 43
  We now need to configure the job in the main options file. In this case it is as simple as writing some options for the "DaVinci Configurable".
Changed:
<
<
Remember from the tutorial that this object is not the same as the Ganga GPI object called "DaVinci". You need to add these lines to your options file, not paste them into the command line, they are used to stter the actual Gaudi, not define some parameter of the ganga job.
>
>
Remember from the tutorial that this object is not the same as the Ganga GPI object called "DaVinci". You need to add these lines to your options file, not paste them into the command line, they are used to steer the actual Gaudi, not define some parameter of the ganga job.
  %SYNTAX{ syntax="python"}%DaVinci().HistogramFile = "DVHistos.root" # Histogram file DaVinci().EvtMax = 1000 # Number of events
Line: 53 to 53
 %ENDSYNTAX%

Hint: if you have closed the file accidentally you can reopen with:

Changed:
<
<
!emacs $t.application.optsfile[0].name &
>
>
<!-- SyntaxHighlightingPlugin -->
!emacs $t.application.optsfile[0].name &
<!-- end SyntaxHighlightingPlugin -->
 

Data

Then we need some data.

Changed:
<
<
  • We will attach the data this time directly to the job object, instead of writing it into an options file. This is Muuuuch more flexible and almost always works first time.
>
>
  • We will attach the data this time directly to the job object, instead of writing it into an options file. This is much more flexible and almost always works first time.
 
Changed:
<
<
  • If you have a very good connection, you can open the feicim browser in ganga.
    <!-- SyntaxHighlightingPlugin -->
data = browseBK()
<!-- end SyntaxHighlightingPlugin -->
>
>
  • If you have a very good connection, you can open the feicim browser in ganga.
    <!-- SyntaxHighlightingPlugin -->
data = browseBK()
<!-- end SyntaxHighlightingPlugin -->
 
    • Navigate to a data sample of 2012 data -> reco 14 -> stripping 20 -> Dimuon stream.
    • Double click on it, and "save". Check:
      <!-- SyntaxHighlightingPlugin -->
for i in data.files: print i
<!-- end SyntaxHighlightingPlugin -->
Changed:
<
<
  • If you do not have a very good connection,, you can use "BKQuery" inside Ganga to get the data.
>
>
  • If you do not have a very good connection,, you can use "BKQuery" inside Ganga to get the data.
 
    • Try to get the bookkeeping path from the Bookkeeping webpage,
    • the path will appear on the top between the big "+" and "<-Go", just copy it (and remove things like "( Full stream )"),
    • then get the data in Ganga, like
      <!-- SyntaxHighlightingPlugin -->
data=BKQuery('/LHCb/Collision12/Beam4000GeV-VeloClosed-MagUp/Real Data/Reco14/Stripping20/90000000/DIMUON.DST', dqflag=['OK']).getDataset()
<!-- end SyntaxHighlightingPlugin -->
Changed:
<
<
  • This will be a set of LFNs that you can pass to the job:
    <!-- SyntaxHighlightingPlugin -->
t.inputdata = data
<!-- end SyntaxHighlightingPlugin -->
>
>
  • This will be a set of LFNs that you can pass to the job:
    <!-- SyntaxHighlightingPlugin -->
t.inputdata = data[0:10] # only access the first 10 elements for speed as this is a tutorial
<!-- end SyntaxHighlightingPlugin -->
 Remember, datasets can be stored in:
  • '.py' Files, using the lhcb_bkk interface outside of Ganga. This is not really recommended.
  • '.py' Files by using the 'export' feature inside Ganga. This is not really recommended.
  • The ganga jobs themselves, as LHCbDatasets. This works well, until you delete the jobs, and means you would have to give your jobs clever names.
  • The templates, as LHCbDatasets. This also works well,
  • The ganga box, the recommended and flexible way. Here you can give datasets different names, and even add "BKQuery" objects box.add(j.inputdata, "R14S20 DIMUON") ... any ganga object can be stored in your box.
Deleted:
<
<
OK, so there's like 3615 files in that BKQuery... and annoyingly at least one of them is missing any replicas, so you can probably just run on the first 10 ...
<!-- SyntaxHighlightingPlugin -->
t.inputdata = data[0:10]
<!-- end SyntaxHighlightingPlugin -->
 

Database tags

 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright & 2008-2019 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback