ComputingTutorials: Difference between revisions
(→dCache) |
|||
Line 62: | Line 62: | ||
==Code, art and fcl== | ==Code, art and fcl== | ||
The main program that is used for simulation, reconstruction and analysis is Mu2e Offline. This is an art-based framework in which the data passes through a series of modules to perform a variety of tasks. Sometimes you will need to | The main program that is used for simulation, reconstruction and analysis is Mu2e Offline. This is an art-based framework in which the data passes through a series of modules to perform a variety of tasks. Sometimes you will need to build the full Mu2e Offline framework (e.g. if you are a developer) but in other cases you might only need a partial build or use an already existing build. | ||
Tutorial: | Tutorial: | ||
* The [[CodeArtFclTutorial]] | * The [[CodeArtFclTutorial]] | ||
** [[CodeRecipe]] runs you through setting up the environment, checking out a full or Satellite release and building Mu2e Offline; | ** [[CodeRecipe]] runs you through setting up the environment, checking out a full or Satellite release and building Mu2e Offline; | ||
** [[SatelliteRelease]] has more information on Satellite releases; and, | ** [[SatelliteRelease]] has more information on Satellite releases; and, |
Revision as of 21:13, 18 June 2019
Introduction
This page is intended for physicists who are just starting to work in the mu2e computing environment. The following is a broad overview of the major components, their terminology, and how you might use them. Following each into paragraph, here are links into more specific tutorials and the rest of the mu2e documentation which is more terse and is intended as a reference once you get through the introductory material.
You probably don't have to work through this entire page and you can stop and any point, please talk to you adviser or mentor to see what's appropriate. The material you are most likely need to use comes first, followed by more in-depth tutorials for people who will be spending years on mu2e and learn to do more complex work.
Prerequisites
In this tutorial we will assume you are familiar with the following topics
- the mu2e detector, the parts, what they do, and how they work
- the basic bash shell commands on a linux system
- c++ code concepts and syntax
- HEP offline concepts
Authentication
You login to the mu2e interactive machines with kerberos authentication. You will need a permanent ID called a kerberos "principal" which is looks like "your_username@FNAL.GOV". (You will have one username for all computing purposes at Fermilab.) You will have a password associated with your principal. You will use this principal and password to log into the various personal linux desktops located at Fermilab or to ssh into the collaboration interactive machines from your home institution. You typically re-enter your kerberos authentication every day.
The second identity you will need is the services principal, which looks like your_username@services.fnal.gov, or often just your_username, and also has a password (different from your kerberos password). You will need this identity to log into Fermilab email, the servicedesk web site and some other services based at the lab. You would typically only use this authentication at the point you log into the service.
The third identity you will need is a CILogin certificate. This "cert" is the basis of authentication to the mu2e documents database, the computing farms, and a few other services. You will use this cert in two ways. The first way is to load it into your browser, which then gives you access to web pages and web services. The second is by using your kerberos authentication to access a copy of your certificate maintained in a remote database. You get this certificate once and then renew it only once a year.
hypernews is an archived blog and email list - for access here, you will need both a hypernews password and your services password!
Finally, the mu2e internal web pages require a collaboration username and password, please ask your mu2e mentor.
Try:
- ComputingAccounts create your accounts and authentication if you are joining mu2e
Become familiar with these references:
Interactive logins
Collaborators can do interactive computing work in several places. Probably the best place to start is the collaboration's interactive linux machines at Fermilab. The disks that the user sees are located on specialized disk server hardware and the same disks are mounted by all the interactive machines. There are five quad-core machines named mu2egpvm01.fnal.gov through mu2egpvm05.fnal.gov. You will have an account and a home area here (the same home area is on all machines) and some disk space for data. We prefer using the bash shell for all purposes. Collaborators can also compile and run mu2e code on their linux desktops or laptops.
Try:
- LoginTutorial checking your access
Become familiar with these references:
Ntuple
The data from the detector, and the reconstructed data, is stored in files in art format. Accessing this data generally requires compiling code and learning a special configuration language, so we will save that for a later tutorial. To simplify, and speed up access to the data, we often run a program to copy a small part of the data in the art file into a convenient format call a root ntuple (pronounced "en-tuple"). This format is easy to browser interactively and make histograms. The ntuple file may contain histograms that were already made, or a list of the tracks in each event along with interesting quantities, such as the number of hits on the track or its reconstructed momentum.
Tutorial:
- NtupleTutorial is the tutorial for this section and will guide you through making plots with one of the Mu2e-specific ntuples that are available.
Other useful pages:
- ROOT is a very useful resource. In particular: getting started and code reference
- Overview of existing mu2e ntuples
Geometry Browser
It is often useful to look at the detector as it is implemented in the simulation either to debug (e.g. double-check the geometry is as you expect) or to get images for presentations.
Tutorial:
Related references:
Code, art and fcl
The main program that is used for simulation, reconstruction and analysis is Mu2e Offline. This is an art-based framework in which the data passes through a series of modules to perform a variety of tasks. Sometimes you will need to build the full Mu2e Offline framework (e.g. if you are a developer) but in other cases you might only need a partial build or use an already existing build.
Tutorial:
- The CodeArtFclTutorial
- CodeRecipe runs you through setting up the environment, checking out a full or Satellite release and building Mu2e Offline;
- SatelliteRelease has more information on Satellite releases; and,
- ReleaseList gives the list of releases that are available on cvmfs.
Event Display
Not only is it useful to look at the geometry but it is also useful to look at specific events in the simulation to see what is happening.
Tutorial:
- The EventDisplayTutorial is still to be written but...
- EventDisplays gives an overview of the current ways to display events.
Art Data Products
All objects (e.g. straw hits, calorimeter clusters) are stored in the art event as art data products. These are accessed and created in Offline modules.
Tutorial:
- The ArtDataProductTutorial is still to be written but...
- ReadProducts gives information on reading products; and,
- MakeProducts gives information on creating products.
Checkout and build code
If you need to write your own modules or edit code in Offline itself, then you will need your own build of Offline.
Tutorial:
- The CheckoutAndBuildCodeTutorial is still to be written but...
- CodeRecipe runs you through setting up the environment, checking out a full or Satellite release and building Mu2e Offline;
- SatelliteRelease has more information on Satellite releases; and,
- ReleaseList gives the list of releases that are available on cvmfs.
Modules
There are a few different types of art module that you will encounter. "Analyzers" can only analyze data products that are already in the event; "producers" can create new data products; and, "filters" make a decision as to whether an event passes or fails some criteria.
Tutorial:
- The ModulesTutorial is still to be written but...
- Modules discusses module names and labels; and
- FilterModules discusses filter modules.
Geometry and Config
For your study, you might need to edit part of the geometry or change the generated particle that is simulated. This is done with config files
Tutorial:
- The GeometryAndConfig tutorial is still to be written but...
- SimpleConfig describes the format of these files.
Staging and Mixing Concepts
For the simulation, we don't just run from protons-on-target (POT) all the way through to hits in the tracker and actually run it in stages. This allows us to re-run specific stages to test new geometries without having to run everything again; and it also allows us to generate large samples of specific processes (e.g. particles emitted after a muon is captured by a nucleus) with better efficiency before mixing them all together into a full microbunch event.
Tutorial:
- The StagingAndMixingTutorial is still to be written but...
Datasets and dCache
dCache is the tape system that we use to store our art files.
Tutorial:
- The dCacheTutorial is still to be written but...
- Dcache gives a good introduction
Grids
To run large jobs, we use the grid rather than run on a local machine.
Tutorial:
- The GridTutorial is still to be written but...
Git commits
Git is a version control system that allows us to coordinate many people developing software at the same time. It is widely used in the software development world so you will be able to find a lot of information online.
Tutorial:
- The GitTutorial is still to be written but...
- Git has some Mu2e specific information
Code standards
In order to ensure that our code is stable and doing what we expect, there are various tasks where we enforce standard ways of performing them.
Tutorial:
- The CodeStandardsTutorial is still to be written but...
- CodingStandards has a nice summary; and,
- RandomNumbers and RandomNumbersBasic describes the way you should generate random numbers in Offline.
References and resources
The best ways to get help can be found on the ComputingHelp page.
Random Links (scratch)
Sarah's google doc on clickable status and intro paragraphs
Rob's 10/26/17 talk on intro to computing plan
Rob's first geant run for new users
Summer 2016 SCD workshops (includes geometry tutorial)
July 2016 intro talks
Tutorials (scratch)
- Testing the ROOT display
- Testing the Geant4 based event display
- Notes on dynamic libraries
- The First Step: the art workbook
- Running G4 within art: The first examples.
- Mu2e maintained FAQs: C++ FAQ, Unix/Linux FAQ, ROOT FAQ, Geant4 Notes