90 likes | 111 Views
Use new detector description in Reconstruction. You Zhengyun School of Physics , PKU 2005.7.13. Outline. XML-ROOT based detector description in Reco.;. How to use it for sub-detector Reco;. Test result in MUC;. Summery;. XML file (same as simu). Read. XML-ROOT Converter.
E N D
Use new detector description in Reconstruction You Zhengyun School of Physics , PKU 2005.7.13
Outline XML-ROOT based detector description in Reco.; How to use it for sub-detector Reco; Test result in MUC; Summery;
XML file (same as simu) Read XML-ROOT Converter IMucGeomSvc MUC ROOT Volume Ptr :: :: Fill Gap geom data Strip geom data Construct MucGeoGeneral Fill :: ROOT Geometry :: Gap geom data Gap ROOT Volume Ptr MucGeoGap Fill :: :: Strip ROOT Volume Ptr Strip geom data MucGeoStrip Connect New Initialization Comparison of Initialization (MUC) Alignment data (Database, ASCII) Old Initialization
Comparison of Function Realization Old: Functions wrote by ourselves 1. Coordinate translation : define by ourselves, using CLHEP 2. Boundary judgment: only simple shapes, box, ball… 3. … New: Functions offered by ROOT 1. Coordinate translation: easily realized to any level 2. Boundary judgment: easily realized for all shapes 3. Material of a volume 4. Many other functions offered by ROOT… Because the new detector description is based on ROOT, a complete geometry system, ROOT helps us to realize these functions.
How to use it Data: the same xml files as used in simulation Mdc.gdml, Tof.gdml, Emc.gdml, Muc.gdml ROOTGeo: A new package added : DetectorDescription----Identifier |--ROOTGeo ---- SubDetectorROOTGeo.cxx .h |-- MdcROOTGeo.cxx .h |-- T ofROOTGeo.cxx .h |-- EmcROOTGeo.cxx .h |-- MucROOTGeo.cxx .h ***GeomSvc: In requirement add : use ROOTGeo ROOTGeo-* DetectorDescription In source file : void InitFromXML() { m_MucROOTGeo = new MucROOTGeo(); m_MucROOTGeo->InitFromGdml(“Muc.gdml”, “Muc”); }
How to realize functions Two choices : 1. Keep old member variables, but fill them from ROOTGeo, No changes to member functions. m_StripDX = m_MucROOTGeo->GetStrip(part, seg, gap, strip)->GetShape()->GetDX(); …… Data from XML, functions still those by ourselves. 2. Delete old member variables, rewrite all functions. Coordinate translation to global : m_MucROOTGeo->GetStrip(part, seg, gap, strip)->GetMatrix(2); // two levels up Boundary judgment : m_MucROOTGeo->GetStrip(part, seg, gap, strip)->GetShape()->Contains( *point ); Get Material of a volume : m_MucROOTGeo->GetStrip(part, seg, gap, strip)->GetVolume()->GetMaterial(); No data in member variables, all functions from ROOTGeo.
Test in Muc Two geometry initialization method: Initialize from ASCII data, Initialize from XML; Get completely identical reconstruction output;
Summery Same XML files keeps geometry consistency in Simu. and Reco.; Geometry initialized automatically by GdmlToROOT; ROOT based geometry offer many functions; A compact geometry class, all from a pointer; Makes our work easier;