Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
cbmroot
Manage
Activity
Members
Labels
Plan
Wiki
Redmine
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Computing
cbmroot
Commits
e262c966
Commit
e262c966
authored
3 years ago
by
Alexandru Bercuci
Browse files
Options
Downloads
Patches
Plain Diff
add radiator identification based on geo file
parent
a4a08463
No related branches found
No related tags found
1 merge request
!565
Fix TRD-2D geometry and simulation for mCBM
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
core/detectors/trd/CbmTrdGeoHandler.cxx
+14
-0
14 additions, 0 deletions
core/detectors/trd/CbmTrdGeoHandler.cxx
core/detectors/trd/CbmTrdGeoHandler.h
+6
-1
6 additions, 1 deletion
core/detectors/trd/CbmTrdGeoHandler.h
with
20 additions
and
1 deletion
core/detectors/trd/CbmTrdGeoHandler.cxx
+
14
−
0
View file @
e262c966
...
...
@@ -39,6 +39,7 @@ CbmTrdGeoHandler::CbmTrdGeoHandler()
,
fLayerId
(
0
)
,
fModuleId
(
0
)
,
fModuleType
(
0
)
,
fRadiatorType
(
-
1
)
,
fRotation
(
0
)
,
fStation
(
0
)
,
fLayer
(
0
)
...
...
@@ -159,6 +160,12 @@ Int_t CbmTrdGeoHandler::GetModuleType(const TString& path)
return
fModuleType
;
}
Int_t
CbmTrdGeoHandler
::
GetRadiatorType
(
const
TString
&
path
)
{
if
(
fGeoPathHash
!=
path
.
Hash
())
{
NavigateTo
(
path
);
}
return
fRadiatorType
;
}
Int_t
CbmTrdGeoHandler
::
GetStation
(
const
TString
&
path
)
{
if
(
fGeoPathHash
!=
path
.
Hash
())
{
NavigateTo
(
path
);
}
...
...
@@ -221,6 +228,13 @@ void CbmTrdGeoHandler::NavigateTo(const TString& path)
// In TGeoManager numbering starts with 1, so we have to subtract 1.
fModuleCopy
=
((
modulecopyNr
/
1000000
)
%
100
);
// from module copy number
fRotation
=
((
modulecopyNr
/
100000
)
%
10
);
// from module copy number
fRadiatorType
=
-
1
;
for
(
int
i
=
0
;
i
<
modulenode
->
GetNdaughters
();
i
++
)
{
TString
nDaughter
(
modulenode
->
GetDaughter
(
i
)
->
GetName
());
if
(
!
nDaughter
.
BeginsWith
(
"radiator"
)
&&
!
nDaughter
.
BeginsWith
(
"Radiator"
))
continue
;
fRadiatorType
=
0
;
// TODO define radiator (+ entrance window) types according to the naming convention
}
}
else
// 2013 and earlier
{
...
...
This diff is collapsed.
Click to expand it.
core/detectors/trd/CbmTrdGeoHandler.h
+
6
−
1
View file @
e262c966
...
...
@@ -82,6 +82,10 @@ public:
Double_t
GetY
(
const
TString
&
path
);
Double_t
GetZ
(
const
TString
&
path
);
Int_t
GetModuleType
(
const
TString
&
path
);
/** \brief Navigate to node and return the radiator type build in the geometry based on the naming convention.
* @return radiator type ID or -1 if the radiator is not installed
*/
Int_t
GetRadiatorType
(
const
TString
&
path
);
// for backward compatibility
Int_t
GetStation
(
const
TString
&
path
);
...
...
@@ -101,6 +105,7 @@ private:
Int_t
fLayerId
;
//!
Int_t
fModuleId
;
//!
Int_t
fModuleType
;
//!
Int_t
fRadiatorType
;
//! radiator + chamber entrance window type
Int_t
fRotation
;
//! rotation angle 0,1,2,3
// for backward compatibility
...
...
@@ -111,7 +116,7 @@ private:
CbmTrdGeoHandler
(
const
CbmTrdGeoHandler
&
);
CbmTrdGeoHandler
operator
=
(
const
CbmTrdGeoHandler
&
);
ClassDef
(
CbmTrdGeoHandler
,
4
)
ClassDef
(
CbmTrdGeoHandler
,
5
)
};
#endif //CBMTRDGEOHANDLER_H
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment