/search.css" rel="stylesheet" type="text/css"/> /search.js">
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

In This Package:

Public Member Functions | Public Attributes | Static Public Attributes
gen::PoolPmts Class Reference

List of all members.

Public Member Functions

def __init__
 column with 3 pmts
def pmtid
def nearOutFinShort
 Near Site npath and support defination ####################.
def nearOutFinCorner
def nearOutFinLong
def nearOutFinBott1
def nearOutFinBott2
def nearOutFoutShort
def nearOutFoutCorner
def nearOutFoutLong
def nearInFinShort
def nearInFinCorner
def nearInFinLong1
def nearInFinLong2
def nearInFinBott
def farOutFinLong
 Far Site npath and support defination ####################.
def farOutFinCorner
def farOutFinBott1
def farOutFinBott2
def farOutFoutLong
def farOutFoutCorner
def farInFinLong1
def farInFinLong2
def farInFinCorner
def farInFinBott1
def farInFinBott2
def fillNearInShort
 Write PMT ID one by one on each wall ##################.
def fillNearInCorner
def fillNearInLong
def fillNearInBot
def fillNearOutFinShort
 Outer face in #######.
def fillNearOutFinCorner
def fillNearOutFinLong
def fillNearOutFinBot
def fillNearOutFoutShort
 Out face out#########.
def fillNearOutFoutCorner
def fillNearOutFoutLong
def fillFarInLong
 Far Site Pool ######### Inner face in #######.
def fillFarInCorner
def fillFarInBot
def fillFarOutFinLong
 Outer face in ########.
def fillFarOutFinCorner
def fillFarOutFinBot
def fillFarOutFoutLong
 Outer face out ####.
def fillFarOutFoutCorner
def write

Public Attributes

 site
 siteid
 poolcount
 wallcount

Static Public Attributes

string lvname = "/dd/Geometry/PMT/lvPmtHemiFrame"
list siteids = [0x01,0x02,0x04]
list poolnums = [(5<<1)|1, (6<<1)|1, 6<<1]
list poolcounts = ['InnFin','OutFin','OutFout']
list wallcounts = [9, 9, 8]
list nearInFin = [8,8,24,8,8,8,24,8,20]
list nearOutFin = [8,8,16,8,8,8,16,8,29]
list nearOutFout = [4,8,12,8,4,8,12,8]
list farInFin = [24,8,24,8,24,8,24,8,32]
list farOutFin = [16,8,16,8,16,8,16,8,32]
list farOutFout = [16,8,16,8,16,8,16,8]
string npath = ''
string support = ''
int c4 = 4
int c3 = 3
 column with 4 pmts

Detailed Description

Definition at line 47 of file gen.py.


Constructor & Destructor Documentation

def gen::PoolPmts::__init__ (   self,
  site,
  siteid,
  poolcount,
  wallcount 
)

column with 3 pmts

Definition at line 65 of file gen.py.

00066                                                       :
00067         self.site = site
00068         self.siteid = siteid
00069         self.poolcount = poolcount
00070         self.wallcount = wallcount
00071         pass


Member Function Documentation

def gen::PoolPmts::pmtid (   self,
  site,
  pooln,
  iid,
  iwall 
)

Definition at line 73 of file gen.py.

00074                                         :
00075         # shift up pooln by only 15 since it was shifted one bit already
00076         inward = 0
00077         if pooln == 11 or pooln == 13:
00078             inward = 1
00079         return (site<<24)|(pooln&0xffe)<<15|inward<<12|(iwall<<8)|iid

def gen::PoolPmts::nearOutFinShort (   self,
  data 
)

Near Site npath and support defination ####################.

Definition at line 83 of file gen.py.

00084                                   :
00085         PoolPmts.npath="pvNearOutPTE/pvNearOutPTEFinSide/pvNearShortPanelOutFinSide:%(tmp1)d/pvNearShortPanelOutFinQuad/pvNearShortPanelOutFinUnitPmt/pvShortPanelOutFinPmt:%(tmp2)d/pvVetoPmtOutFIn4:%(tmp3)d/pvVetoPmtUnit"%data
00086         PoolPmts.support="/dd/Structure/Pool/%(site)s-ows"%data
00087         return
00088 
    
def gen::PoolPmts::nearOutFinCorner (   self,
  data 
)

Definition at line 90 of file gen.py.

00091                                    :
00092         PoolPmts.npath="pvNearOutPTE/pvNearOutPTEFinSide/pvNearCornerPanelOutFinSide:%(tmp1)d/pvNearCornerPanelOutFinQuad:%(tmp2)d/pvFarCornerPanelOutFinUnitPmt/pvCornerPanelOutFinPmt:%(tmp3)d/pvVetoPmtOutFIn4:%(tmp4)d/pvVetoPmtUnit"%data
00093         PoolPmts.support="/dd/Structure/Pool/%(site)s-ows"%data
00094         return
00095 
        
def gen::PoolPmts::nearOutFinLong (   self,
  data 
)

Definition at line 97 of file gen.py.

00098                                  :
00099         PoolPmts.npath="pvNearOutPTE/pvNearOutPTEFinSide/pvNearLongPanelOutFinSide:%(tmp1)d/pvNearLongPanelOutFinQuad/pvFarLongPanelOutFinUnitPmt/pvLongPanelOutFinPmt:%(tmp2)d/pvVetoPmtOutFIn4:%(tmp3)d/pvVetoPmtUnit"%data
00100         PoolPmts.support="/dd/Structure/Pool/%(site)s-ows"%data
00101         return

def gen::PoolPmts::nearOutFinBott1 (   self,
  data 
)

Definition at line 103 of file gen.py.

00104                                   :
00105         PoolPmts.npath="pvNearOutPTE/pvNearOutPTEBott/pvNearOutBott/pvVetoPmtNearOutBott:%(tmp1)d/pvVetoPmtNearOutBottHalf%(tmp2)d:%(tmp3)d/pvVetoPmtOutBot:%(tmp4)d/pvVetoPmtUnit"%data
00106         PoolPmts.support="/dd/Structure/Pool/%(site)s-ows"%data
00107         return

def gen::PoolPmts::nearOutFinBott2 (   self,
  data 
)

Definition at line 109 of file gen.py.

00110                                   :
00111         PoolPmts.npath="pvNearOutPTE/pvNearOutPTEBott/pvNearOutBott/pvVetoPmtNearOutBott:%(tmp1)d/pvVetoPmtOutBot:%(tmp2)d/pvVetoPmtUnit"%data
00112         PoolPmts.support="/dd/Structure/Pool/%(site)s-ows"%data
00113         return

def gen::PoolPmts::nearOutFoutShort (   self,
  data 
)

Definition at line 115 of file gen.py.

00116                                    :
00117         PoolPmts.npath="pvNearOutPTE/pvNearOutPTEFoutSide/pvNearShortPanelOutFoutSide:%(tmp1)d/pvNearShortPanelOutFoutQuad/pvNearShortPanelOutFoutUnitPmt/pvShortPanelOutFoutPmt/pvVetoPmtIn4:%(tmp2)d/pvVetoPmtUnit"%data
00118         PoolPmts.support="/dd/Structure/Pool/%(site)s-ows"%data
00119         return

def gen::PoolPmts::nearOutFoutCorner (   self,
  data 
)

Definition at line 121 of file gen.py.

00122                                     :
00123         PoolPmts.npath="pvNearOutPTE/pvNearOutPTEFoutSide/pvNearCornerPanelOutFoutSide:%(tmp1)d/pvNearCornerPanelOutFoutQuad:%(tmp2)d/pvFarCornerPanelOutFoutUnitPmt/pvCornerPanelOutFoutPmt:%(tmp3)d/pvVetoPmtIn4:%(tmp4)d/pvVetoPmtUnit"%data
00124         PoolPmts.support="/dd/Structure/Pool/%(site)s-ows"%data
00125         return
00126 

def gen::PoolPmts::nearOutFoutLong (   self,
  data 
)

Definition at line 128 of file gen.py.

00129                                   :
00130         PoolPmts.npath="pvNearOutPTE/pvNearOutPTEFoutSide/pvNearLongPanelOutFoutSide:%(tmp1)d/pvNearLongPanelOutFoutQuad/pvNearLongPanelOutFoutUnitPmt/pvNearLongPanelOutFoutPmt:%(tmp2)d/pvVetoPmtIn4:%(tmp3)d/pvVetoPmtUnit"%data
00131         PoolPmts.support="/dd/Structure/Pool/%(site)s-ows"%data
00132         return

def gen::PoolPmts::nearInFinShort (   self,
  data 
)

Definition at line 134 of file gen.py.

00135                                  :
00136         PoolPmts.npath="pvNearInPTE/pvNearInPTEFinSide/pvNearShortPanelInFinSide:%(tmp1)d/pvNearShortPanelInFinQuad/pvNearShortPanelInFinUnitPmt/pvShortPanelInFinPmt:%(tmp2)d/pvVetoPmtIn4:%(tmp3)d/pvVetoPmtUnit"%data
00137         PoolPmts.support="/dd/Structure/Pool/%(site)s-iws"%data
00138         return

def gen::PoolPmts::nearInFinCorner (   self,
  data 
)

Definition at line 140 of file gen.py.

00141                                   :
00142         PoolPmts.npath="pvNearInPTE/pvNearInPTEFinSide/pvNearCornerPanelInFinSide:%(tmp1)d/pvNearCornerPanelInFinQuad:%(tmp2)d/pvFarCornerPanelInFinUnitPmt/pvCornerPanelInFinPmt:%(tmp3)d/pvVetoPmtIn4:%(tmp4)d/pvVetoPmtUnit"%data
00143         PoolPmts.support="/dd/Structure/Pool/%(site)s-iws"%data
00144         return

def gen::PoolPmts::nearInFinLong1 (   self,
  data 
)

Definition at line 146 of file gen.py.

00147                                  :
00148         PoolPmts.npath="pvNearInPTE/pvNearInPTEFinSide/pvNearLongPanelInFinSide:%(tmp1)d/pvNearLongPanelInFinQuad/pvFarLongPanelInFinUnitPmt/pvLongPanelInFinPmt:%(tmp2)d/pvVetoPmtIn4:%(tmp3)d/pvVetoPmtUnit"%data
00149         PoolPmts.support="/dd/Structure/Pool/%(site)s-iws"%data
00150         return

def gen::PoolPmts::nearInFinLong2 (   self,
  data 
)

Definition at line 152 of file gen.py.

00153                                  :
00154         PoolPmts.npath="pvNearInPTE/pvNearInPTEFinSide/pvNearLongPanelInFinSide:%(tmp1)d/pvNearLongPanelInFinQuad/pvFarLongPanelInFinUnitPmt/pvLongPanelInFinPmt:%(tmp2)d/pvVetoPmtFIn3:%(tmp3)d/pvVetoPmtUnit"%data
00155         PoolPmts.support="/dd/Structure/Pool/%(site)s-iws"%data
00156         return

def gen::PoolPmts::nearInFinBott (   self,
  data 
)

Definition at line 158 of file gen.py.

00159                                 :
00160         PoolPmts.npath="pvNearInPTE/pvNearInPTEBott/pvNearInBott/pvVetoPmtNearInBott:%(tmp1)d/pvVetoPmtNearInBottHalf%(tmp2)d:%(tmp3)d/pvVetoPmtInBot:%(tmp4)d/pvVetoPmtUnit"%data
00161         PoolPmts.support="/dd/Structure/Pool/%(site)s-iws"%data
00162         return

def gen::PoolPmts::farOutFinLong (   self,
  data 
)

Far Site npath and support defination ####################.

Definition at line 166 of file gen.py.

00167                                 :
00168         PoolPmts.npath="pvFarOutPTE/pvFarOutPTEFinSide/pvLongPanelOutFinSide:%(tmp1)d/pvFarLongPanelOutFinQuad/pvFarLongPanelOutFinUnitPmt/pvLongPanelOutFinPmt:%(tmp2)d/pvVetoPmtOutFIn4:%(tmp3)d/pvVetoPmtUnit"%data
00169         PoolPmts.support="/dd/Structure/Pool/%(site)s-ows"%data
00170         return

def gen::PoolPmts::farOutFinCorner (   self,
  data 
)

Definition at line 172 of file gen.py.

00173                                   :
00174         PoolPmts.npath="pvFarOutPTE/pvFarOutPTEFinSide/pvCornerPanelOutFinSide:%(tmp1)d/pvFarCornerPanelOutFinQuad/pvFarCornerPanelOutFinUnitPmt/pvCornerPanelOutFinPmt:%(tmp2)d/pvVetoPmtOutFIn4:%(tmp3)d/pvVetoPmtUnit"%data
00175         PoolPmts.support="/dd/Structure/Pool/%(site)s-ows"%data
00176         return
        
def gen::PoolPmts::farOutFinBott1 (   self,
  data 
)

Definition at line 178 of file gen.py.

00179                                  :
00180         PoolPmts.npath="pvFarOutPTE/pvFarOutPTEBott/pvFarOutBott/pvVetoPmtFarOutBott:%(tmp1)d/pvVetoPmtOutBotF:%(tmp2)d/pvVetoPmtUnit"%data
00181         PoolPmts.support="/dd/Structure/Pool/%(site)s-ows"%data
00182         return

def gen::PoolPmts::farOutFinBott2 (   self,
  data 
)

Definition at line 184 of file gen.py.

00185                                  :
00186         PoolPmts.npath="pvFarOutPTE/pvFarOutPTEBott/pvFarOutBott/pvVetoPmtFarOutBott:%(tmp1)d/pvVetoPmtOutBotF:%(tmp2)d/pvVetoPmtUnit"%data
00187         PoolPmts.support="/dd/Structure/Pool/%(site)s-ows"%data
00188         return

def gen::PoolPmts::farOutFoutLong (   self,
  data 
)

Definition at line 190 of file gen.py.

00191                                  :
00192         PoolPmts.npath="pvFarOutPTE/pvFarOutPTEFoutSide/pvFarLongPanelOutFoutSide:%(tmp1)d/pvFarLongPanelOutFoutQuad/pvFarLongPanelOutFoutUnitPmt/pvFarLongPanelOutFoutPmt:%(tmp2)d/pvVetoPmtIn4:%(tmp3)d/pvVetoPmtUnit"%data
00193         PoolPmts.support="/dd/Structure/Pool/%(site)s-ows"%data
00194         return

def gen::PoolPmts::farOutFoutCorner (   self,
  data 
)

Definition at line 196 of file gen.py.

00197                                    :
00198         PoolPmts.npath="pvFarOutPTE/pvFarOutPTEFoutSide/pvFarCornerPanelOutFoutSide:%(tmp1)d/pvFarCornerPanelOutFoutQuad/pvFarCornerPanelOutFoutUnitPmt/pvCornerPanelOutFoutPmt:%(tmp2)d/pvVetoPmtIn4:%(tmp3)d/pvVetoPmtUnit"%data
00199         PoolPmts.support="/dd/Structure/Pool/%(site)s-ows"%data
00200         return

def gen::PoolPmts::farInFinLong1 (   self,
  data 
)

Definition at line 202 of file gen.py.

00203                                 :
00204         PoolPmts.npath="pvFarInPTE/pvFarInPTEFinSide/pvLongPanelInFinSide:%(tmp1)d/pvFarLongPanelInFinQuad/pvFarLongPanelInFinUnitPmt/pvLongPanelInFinPmt:%(tmp2)d/pvVetoPmtIn4:%(tmp3)d/pvVetoPmtUnit"%data
00205         PoolPmts.support="/dd/Structure/Pool/%(site)s-iws"%data
00206         return

def gen::PoolPmts::farInFinLong2 (   self,
  data 
)

Definition at line 208 of file gen.py.

00209                                 :
00210         PoolPmts.npath="pvFarInPTE/pvFarInPTEFinSide/pvLongPanelInFinSide:%(tmp1)d/pvFarLongPanelInFinQuad/pvFarLongPanelInFinUnitPmt/pvLongPanelInFinPmt:%(tmp2)d/pvVetoPmtFIn3:%(tmp3)d/pvVetoPmtUnit"%data
00211         PoolPmts.support="/dd/Structure/Pool/%(site)s-iws"%data
00212         return

def gen::PoolPmts::farInFinCorner (   self,
  data 
)

Definition at line 214 of file gen.py.

00215                                  :
00216         PoolPmts.npath="pvFarInPTE/pvFarInPTEFinSide/pvCornerPanelInFinSide:%(tmp1)d/pvFarCornerPanelInFinQuad/pvFarCornerPanelInFinUnitPmt/pvCornerPanelInFinPmt:%(tmp2)d/pvVetoPmtIn4:%(tmp3)d/pvVetoPmtUnit"%data
00217         PoolPmts.support="/dd/Structure/Pool/%(site)s-iws"%data
00218         return

def gen::PoolPmts::farInFinBott1 (   self,
  data 
)

Definition at line 220 of file gen.py.

00221                                 :
00222         PoolPmts.npath="pvFarInPTE/pvFarInPTEBott/pvFarInBott/pvVetoPmtFarInBott:%(tmp1)d/pvVetoPmtInBotF:%(tmp2)d/pvVetoPmtUnit"%data
00223         PoolPmts.support="/dd/Structure/Pool/%(site)s-iws"%data
00224         return

def gen::PoolPmts::farInFinBott2 (   self,
  data 
)

Definition at line 226 of file gen.py.

00227                                 :
00228         PoolPmts.npath="pvFarInPTE/pvFarInPTEBott/pvFarInBott/pvVetoPmtFarInBott:%(tmp1)d/pvVetoPmtInBotF:%(tmp2)d/pvVetoPmtUnit"%data
00229         PoolPmts.support="/dd/Structure/Pool/%(site)s-iws"%data
00230         return
    
def gen::PoolPmts::fillNearInShort (   self,
  iid,
  data 
)

Write PMT ID one by one on each wall ##################.

Near Site Pool ######### Inner Face in ##########

Definition at line 235 of file gen.py.

00236                                       :
00237         if iid<=4:
00238             data['tmp2']=1
00239             data['tmp3']=iid
00240         elif iid<=8 and iid>=5:
00241             data['tmp2']=2
00242             data['tmp3']=iid-PoolPmts.c4
00243         else:
00244             print 'iid=%d',iid
00245             print "find error 1"
00246             sys.exit(1)
00247         self.nearInFinShort(data)
00248         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00249         

def gen::PoolPmts::fillNearInCorner (   self,
  iid,
  data 
)

Definition at line 250 of file gen.py.

00251                                        :
00252         if iid<=4:
00253             data['tmp3']=1
00254             data['tmp4']=iid
00255         elif iid<=8 and iid>=5:
00256             data['tmp3']=2
00257             data['tmp4']=iid-PoolPmts.c4
00258         else:
00259             print "find error 2"
00260             sys.exit(1)
00261         self.nearInFinCorner(data)
00262         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0

def gen::PoolPmts::fillNearInLong (   self,
  iid,
  data 
)

Definition at line 263 of file gen.py.

00264                                      :
00265         if iid<=3:
00266             data['tmp2']=1
00267             data['tmp3']=iid
00268             self.nearInFinLong2(data)
00269         elif iid<=7 and iid>=4:
00270             data['tmp2']=2
00271             data['tmp3']=iid-PoolPmts.c3
00272             self.nearInFinLong1(data)
00273         elif iid>=8 and iid<=10:
00274             data['tmp2']=3
00275             data['tmp3']=iid-PoolPmts.c4-PoolPmts.c3
00276             self.nearInFinLong2(data)
00277         elif iid<=14 and iid>=11:
00278             data['tmp2']=4
00279             data['tmp3']=iid-PoolPmts.c4-2*PoolPmts.c3
00280             self.nearInFinLong1(data)
00281         elif iid>=15 and iid<=17:
00282             data['tmp2']=5
00283             data['tmp3']=iid-2*PoolPmts.c4-2*PoolPmts.c3
00284             self.nearInFinLong2(data)
00285         elif iid<=21 and iid>=18:
00286             data['tmp2']=6
00287             data['tmp3']=iid-2*PoolPmts.c4-3*PoolPmts.c3
00288             self.nearInFinLong1(data)
00289         elif iid>=22 and iid<=24:
00290             data['tmp2']=7
00291             data['tmp3']=iid-3*PoolPmts.c4-3*PoolPmts.c3
00292             self.nearInFinLong2(data)
00293         else:
00294             print "find error 3"
00295             sys.exit(1)
00296         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00297             

def gen::PoolPmts::fillNearInBot (   self,
  iid,
  data 
)

Definition at line 298 of file gen.py.

00299                                     :
00300         if iid<=5:
00301             data['tmp1']=data['tmp2']=data['tmp3']=1
00302             data['tmp4']=iid;
00303         elif 6<=iid<=10:
00304             data['tmp1']=data['tmp2']=2
00305             data['tmp3']=1
00306             data['tmp4']=iid;
00307         elif 11<=iid<=15:
00308             data['tmp1']=data['tmp2']=1
00309             data['tmp3']=2
00310             data['tmp4']=iid-10;
00311         elif 16<=iid<=20:
00312             data['tmp1']=data['tmp2']=data['tmp3']=2
00313             data['tmp4']=iid-10;
00314         else:
00315             print "find error 4"
00316             sys.exit(1)
00317         self.nearInFinBott(data)
00318         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00319         return

def gen::PoolPmts::fillNearOutFinShort (   self,
  iid,
  data 
)

Outer face in #######.

Definition at line 322 of file gen.py.

00323                                           :
00324         if iid<=4:
00325             data['tmp2']=1
00326             data['tmp3']=iid
00327         elif iid<=8 and iid>=5:
00328             data['tmp2']=2
00329             data['tmp3']=iid-PoolPmts.c4
00330         else:
00331             print 'iid=%d',iid
00332             print "find error 5"
00333             sys.exit(1)
00334         self.nearOutFinShort(data)
00335         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00336         return
    
def gen::PoolPmts::fillNearOutFinCorner (   self,
  iid,
  data 
)

Definition at line 337 of file gen.py.

00338                                            :
00339         if iid<=4:
00340             data['tmp3']=1
00341             data['tmp4']=iid
00342         elif iid<=8 and iid>=5:
00343             data['tmp3']=2
00344             data['tmp4']=iid-PoolPmts.c4
00345         else:
00346             print 'iid=%d',iid
00347             print "find error 6"
00348             sys.exit(1)
00349         self.nearOutFinCorner(data)
00350         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00351         return

def gen::PoolPmts::fillNearOutFinLong (   self,
  iid,
  data 
)

Definition at line 352 of file gen.py.

00353                                          :
00354         if iid<=4:
00355             data['tmp2']=1
00356             data['tmp3']=iid
00357         elif iid<=8 and iid>=5:
00358             data['tmp2']=2
00359             data['tmp3']=iid-PoolPmts.c4
00360         elif iid<=12 and iid>=9:
00361             data['tmp2']=3
00362             data['tmp3']=iid-2*PoolPmts.c4
00363         elif iid<=16 and iid>=13:
00364             data['tmp2']=4
00365             data['tmp3']=iid-3*PoolPmts.c4
00366         else:
00367             print 'iid=%d',iid
00368             print "find error 7"
00369             sys.exit(1)
00370         self.nearOutFinLong(data)
00371         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00372         return
00373 
   
def gen::PoolPmts::fillNearOutFinBot (   self,
  iid,
  data 
)

Definition at line 374 of file gen.py.

00375                                         :
00376         if iid<=24:
00377             if iid<=6:
00378                 data['tmp1']=data['tmp2']=data['tmp3']=1
00379                 data['tmp4']=iid;
00380             elif 7<=iid<=12:
00381                 data['tmp1']=data['tmp2']=2
00382                 data['tmp3']=1
00383                 data['tmp4']=iid;
00384             elif 13<=iid<=18:
00385                 data['tmp1']=data['tmp2']=1
00386                 data['tmp3']=2
00387                 data['tmp4']=iid-12;
00388             elif 19<=iid<=24:
00389                 data['tmp1']=data['tmp2']=data['tmp3']=2
00390                 data['tmp4']=iid-12;
00391             else:
00392                 print "find error 4"
00393                 sys.exit(1)
00394             self.nearOutFinBott1(data)
00395                 
00396         elif iid<=29 and iid>=25:
00397             data['tmp1']=3
00398             data['tmp2']=iid-12
00399             self.nearOutFinBott2(data)
00400         else:
00401             print 'iid=%d',iid
00402             print "find error 8"
00403             sys.exit(1)
00404             data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00405         return
    
def gen::PoolPmts::fillNearOutFoutShort (   self,
  iid,
  data 
)

Out face out#########.

Definition at line 408 of file gen.py.

00409                                            :
00410         if iid<=4:
00411             data['tmp2']=iid
00412         else:
00413             print 'iid=%d',iid
00414             print "find error 9"
00415             sys.exit(1)
00416         self.nearOutFoutShort(data)
00417         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00418         return

def gen::PoolPmts::fillNearOutFoutCorner (   self,
  iid,
  data 
)

Definition at line 419 of file gen.py.

00420                                             :
00421         if iid<=4:
00422             data['tmp3']=1
00423             data['tmp4']=iid
00424         elif iid<=8 and iid>=5:
00425             data['tmp3']=2
00426             data['tmp4']=iid-PoolPmts.c4
00427         else:
00428             print 'iid=%d',iid
00429             print "find error 10"
00430             sys.exit(1)
00431         self.nearOutFoutCorner(data)
00432         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00433         return
00434 

def gen::PoolPmts::fillNearOutFoutLong (   self,
  iid,
  data 
)

Definition at line 435 of file gen.py.

00436                                           :
00437         if iid<=4:
00438             data['tmp2']=1
00439             data['tmp3']=iid
00440         elif iid<=8 and iid>=5:
00441             data['tmp2']=2
00442             data['tmp3']=iid-PoolPmts.c4
00443         elif iid<=12 and iid>=9:
00444             data['tmp2']=3
00445             data['tmp3']=iid-2*PoolPmts.c4
00446         else:
00447             print 'iid=%d',iid
00448             print "find error 11"
00449             sys.exit(1)
00450         self.nearOutFoutLong(data)
00451         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00452         return
    
def gen::PoolPmts::fillFarInLong (   self,
  iid,
  data 
)

Far Site Pool ######### Inner face in #######.

Definition at line 455 of file gen.py.

00456                                     :
00457         if iid<=3:
00458             data['tmp2']=1
00459             data['tmp3']=iid
00460             self.farInFinLong2(data)
00461         elif iid<=7 and iid>=4:
00462             data['tmp2']=2
00463             data['tmp3']=iid-PoolPmts.c3
00464             self.farInFinLong1(data)
00465         elif iid>=8 and iid<=10:
00466             data['tmp2']=3
00467             data['tmp3']=iid-PoolPmts.c4-PoolPmts.c3
00468             self.farInFinLong2(data)
00469         elif iid<=14 and iid>=11:
00470             data['tmp2']=4
00471             data['tmp3']=iid-PoolPmts.c4-2*PoolPmts.c3
00472             self.farInFinLong1(data)
00473         elif iid>=15 and iid<=17:
00474             data['tmp2']=5
00475             data['tmp3']=iid-2*PoolPmts.c4-2*PoolPmts.c3
00476             self.farInFinLong2(data)
00477         elif iid<=21 and iid>=18:
00478             data['tmp2']=6
00479             data['tmp3']=iid-2*PoolPmts.c4-3*PoolPmts.c3
00480             self.farInFinLong1(data)
00481         elif iid>=22 and iid<=24:
00482             data['tmp2']=7
00483             data['tmp3']=iid-3*PoolPmts.c4-3*PoolPmts.c3
00484             self.farInFinLong2(data)
00485         else:
00486             print "find error 12"
00487             sys.exit(1)
00488         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00489         return

def gen::PoolPmts::fillFarInCorner (   self,
  iid,
  data 
)

Definition at line 490 of file gen.py.

00491                                       :
00492         if iid<=4:
00493             data['tmp2']=1
00494             data['tmp3']=iid
00495         elif iid<=8 and iid>=5:
00496             data['tmp2']=2
00497             data['tmp3']=iid-PoolPmts.c4
00498         else:
00499             print 'iid=%d',iid
00500             print "find error 13"
00501             sys.exit(1)
00502         self.farInFinCorner(data)
00503         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00504         return

def gen::PoolPmts::fillFarInBot (   self,
  iid,
  data 
)

Definition at line 505 of file gen.py.

00506                                    :
00507         if iid<=28:
00508             if iid<=7:
00509                 data['tmp1']=1
00510                 data['tmp2']=iid
00511             elif iid>=8 and iid<=14:
00512                 data['tmp1']=2
00513                 data['tmp2']=iid-7
00514             elif iid>=15 and iid<=21:
00515                 data['tmp1']=3
00516                 data['tmp2']=iid-2*7
00517             elif iid>=22 and iid<=28:
00518                 data['tmp1']=4
00519                 data['tmp2']=iid-3*7
00520             self.farInFinBott1(data)
00521         elif iid<=32 and iid>=29:
00522             data['tmp1']=5
00523             data['tmp2']=iid-21
00524             self.farInFinBott2(data)
00525         else:
00526             print 'iid=%d',iid
00527             print "find error 14"
00528             sys.exit(1)
00529         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00530         return

def gen::PoolPmts::fillFarOutFinLong (   self,
  iid,
  data 
)

Outer face in ########.

Definition at line 532 of file gen.py.

00533                                         :
00534         if iid<=4:
00535             data['tmp2']=1
00536             data['tmp3']=iid
00537         elif iid<=8 and iid>=5:
00538             data['tmp2']=2
00539             data['tmp3']=iid-PoolPmts.c4
00540         elif iid<=12 and iid>=9:
00541             data['tmp2']=3
00542             data['tmp3']=iid-2*PoolPmts.c4
00543         elif iid<=16 and iid>=13:
00544             data['tmp2']=4
00545             data['tmp3']=iid-3*PoolPmts.c4
00546         else:
00547             print 'iid=%d',iid
00548             print "find error 15"
00549             sys.exit(1)
00550         self.farOutFinLong(data)
00551         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00552         return

def gen::PoolPmts::fillFarOutFinCorner (   self,
  iid,
  data 
)

Definition at line 553 of file gen.py.

00554                                           :
00555         if iid<=4:
00556             data['tmp2']=1
00557             data['tmp3']=iid
00558         elif iid<=8 and iid>=5:
00559             data['tmp2']=2
00560             data['tmp3']=iid-PoolPmts.c4
00561         else:
00562             print 'iid=%d',iid
00563             print "find error 16"
00564             sys.exit(1)
00565         self.farOutFinCorner(data)
00566         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00567         return
00568 

def gen::PoolPmts::fillFarOutFinBot (   self,
  iid,
  data 
)

Definition at line 569 of file gen.py.

00570                                        :
00571         if iid<=28:
00572             if iid<=7:
00573                 data['tmp1']=1
00574                 data['tmp2']=iid
00575             elif iid>=8 and iid<=14:
00576                 data['tmp1']=2
00577                 data['tmp2']=iid-7
00578             elif iid>=15 and iid<=21:
00579                 data['tmp1']=3
00580                 data['tmp2']=iid-2*7
00581             elif iid>=22 and iid<=28:
00582                 data['tmp1']=4
00583                 data['tmp2']=iid-3*7
00584             self.farOutFinBott1(data)
00585             
00586         elif iid<=32 and iid>=29:
00587             data['tmp1']=5
00588             data['tmp2']=iid-21
00589             self.farOutFinBott2(data)
00590 
00591         else:
00592             print 'iid=%d',iid
00593             print "find error 17"
00594             sys.exit(1)
00595         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00596         return

def gen::PoolPmts::fillFarOutFoutLong (   self,
  iid,
  data 
)

Outer face out ####.

Definition at line 599 of file gen.py.

00600                                          :
00601         if iid<=4:
00602             data['tmp2']=1
00603             data['tmp3']=iid
00604         elif iid<=8 and iid>=5:
00605             data['tmp2']=2
00606             data['tmp3']=iid-PoolPmts.c4
00607         elif iid<=12 and iid>=9:
00608             data['tmp2']=3
00609             data['tmp3']=iid-2*PoolPmts.c4
00610         elif iid<=16 and iid>=13:
00611             data['tmp2']=4
00612             data['tmp3']=iid-3*PoolPmts.c4
00613         else:
00614             print 'iid=%d',iid
00615             print "find error 18"
00616             sys.exit(1)
00617         self.farOutFoutLong(data)
00618         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00619         return

def gen::PoolPmts::fillFarOutFoutCorner (   self,
  iid,
  data 
)

Definition at line 620 of file gen.py.

00621                                            :
00622         if iid<=4:
00623             data['tmp2']=1
00624             data['tmp3']=iid
00625         elif iid<=8 and iid>=5:
00626             data['tmp2']=2
00627             data['tmp3']=iid-PoolPmts.c4
00628         else:
00629             print 'iid=%d',iid
00630             print "find error 19"
00631             sys.exit(1)
00632         self.farOutFoutCorner(data)
00633         data['tmp1']=data['tmp2']=data['tmp3']=data['tmp4']=0
00634         return
00635 
    
def gen::PoolPmts::write (   self,
  outdir 
)

Definition at line 636 of file gen.py.

00637                           :
00638         from XmlDetDescGen.util import XmlFile, Comment
00639         from XmlDetDescGen.structure import DetElem,UserParameter
00640 
00641         for poolp, pooln, walln in zip(PoolPmts.poolcounts,PoolPmts.poolnums,PoolPmts.wallcounts):
00642 
00643             pmts = []
00644 
00645 
00646             for iwall in range(0,walln): #max wallcount=9
00647                 
00648                 iwall += 1
00649 
00650                 if (site=='db') | (site=='la'):
00651                     if poolp==PoolPmts.poolcounts[0]:
00652                         ipmt =  PoolPmts.nearInFin[iwall-1]
00653                     elif poolp==PoolPmts.poolcounts[1]:
00654                         ipmt =  PoolPmts.nearOutFin[iwall-1]
00655                     elif poolp==PoolPmts.poolcounts[2]:
00656                         ipmt =  PoolPmts.nearOutFout[iwall-1]
00657                     else:
00658                         print "error found in near pool,exit"
00659                         sys.exit(1)
00660                     
00661                 elif site=='far':
00662                     if poolp==PoolPmts.poolcounts[0]:
00663                         ipmt =  PoolPmts.farInFin[iwall-1]
00664                     elif poolp==PoolPmts.poolcounts[1]:
00665                         ipmt =  PoolPmts.farOutFin[iwall-1]
00666                     elif poolp==PoolPmts.poolcounts[2]:
00667                         ipmt =  PoolPmts.farOutFout[iwall-1]
00668                     else:
00669                         print "error found in far pool,exit"
00670                         sys.exit(1)
00671 
00672                 #print "Number of PMT in this wall is %d"%ipmt
00673 
00674 
00675                 for iid in range(0,ipmt): #pmt number in that wall
00676                     iid += 1
00677                 
00678                     pmtid = self.pmtid(siteid,pooln,iid,iwall)
00679 
00680                     ####tmp1,2,3,4 are paramphy index numbers for different walls
00681                     tmp1=tmp2=tmp3=tmp4=0
00682                     
00683                     data = { 'site':site,'siteid':siteid,'poolpv':poolp,'poolnum':pooln,'wallnum':iwall,
00684                              'idnum':iid,'pmtid':pmtid,'tmp1':tmp1,'tmp2':tmp2,'tmp3':tmp3,'tmp4':tmp4 }
00685                     
00686                     if (site=='db') | (site=='la'):
00687                         if poolp==PoolPmts.poolcounts[0]:
00688                             if iwall==1:
00689                                 data['tmp1']=1
00690                                 self.fillNearInShort(iid,data)
00691 
00692                             elif iwall==2:
00693                                 data['tmp1']=data['tmp2']=1
00694                                 self.fillNearInCorner(iid,data)
00695                                 
00696                             elif iwall==3:
00697                                 data['tmp1']=1
00698                                 self.fillNearInLong(iid,data)
00699 
00700                             elif iwall==4:
00701                                 data['tmp1']=1
00702                                 data['tmp2']=2
00703                                 self.fillNearInCorner(iid,data)
00704 
00705                             elif iwall==5:
00706                                 data['tmp1']=2
00707                                 self.fillNearInShort(iid,data)
00708 
00709                             elif iwall==6:
00710                                 data['tmp1']=2
00711                                 data['tmp2']=1
00712                                 self.fillNearInCorner(iid,data)
00713 
00714                             elif iwall==7:
00715                                 data['tmp1']=2
00716                                 self.fillNearInLong(iid,data)
00717                                 
00718                             elif iwall==8:
00719                                 data['tmp1']=2
00720                                 data['tmp2']=2
00721                                 self.fillNearInCorner(iid,data)
00722                             elif iwall==9:
00723                                 self.fillNearInBot(iid,data)
00724                             else:
00725                                 print "error find in Near Inn face-in"
00726                                 sys.exit(1)
00727 
00728                         elif poolp==PoolPmts.poolcounts[1]:
00729                             if iwall==1:
00730                                 data['tmp1']=1
00731                                 self.fillNearOutFinShort(iid,data)
00732 
00733                             elif iwall==2:
00734                                 data['tmp1']=data['tmp2']=1
00735                                 self.fillNearOutFinCorner(iid,data)
00736                                 
00737                             elif iwall==3:
00738                                 data['tmp1']=1
00739                                 self.fillNearOutFinLong(iid,data)
00740 
00741                             elif iwall==4:
00742                                 data['tmp1']=1
00743                                 data['tmp2']=2
00744                                 self.fillNearOutFinCorner(iid,data)
00745 
00746                             elif iwall==5:
00747                                 data['tmp1']=2
00748                                 self.fillNearOutFinShort(iid,data)
00749 
00750                             elif iwall==6:
00751                                 data['tmp1']=2
00752                                 data['tmp2']=1
00753                                 self.fillNearOutFinCorner(iid,data)
00754 
00755                             elif iwall==7:
00756                                 data['tmp1']=2
00757                                 self.fillNearOutFinLong(iid,data)
00758                                 
00759                             elif iwall==8:
00760                                 data['tmp1']=2
00761                                 data['tmp2']=2
00762                                 self.fillNearOutFinCorner(iid,data)
00763                                 
00764                             elif iwall==9:
00765                                 self.fillNearOutFinBot(iid,data)
00766 
00767                             else:
00768                                 print "error find in Near Out face-in"
00769                                 sys.exit(1)
00770                             
00771                         elif poolp==PoolPmts.poolcounts[2]:
00772                             if iwall==1:
00773                                 data['tmp1']=1
00774                                 self.fillNearOutFoutShort(iid,data)
00775 
00776                             elif iwall==2:
00777                                 data['tmp1']=data['tmp2']=1
00778                                 self.fillNearOutFoutCorner(iid,data)
00779                                 
00780                             elif iwall==3:
00781                                 data['tmp1']=1
00782                                 self.fillNearOutFoutLong(iid,data)
00783 
00784                             elif iwall==4:
00785                                 data['tmp1']=1
00786                                 data['tmp2']=2
00787                                 self.fillNearOutFoutCorner(iid,data)
00788 
00789                             elif iwall==5:
00790                                 data['tmp1']=2
00791                                 self.fillNearOutFoutShort(iid,data)
00792 
00793                             elif iwall==6:
00794                                 data['tmp1']=2
00795                                 data['tmp2']=1
00796                                 self.fillNearOutFoutCorner(iid,data)
00797 
00798                             elif iwall==7:
00799                                 data['tmp1']=2
00800                                 self.fillNearOutFoutLong(iid,data)
00801                                 
00802                             elif iwall==8:
00803                                 data['tmp1']=2
00804                                 data['tmp2']=2
00805                                 self.fillNearOutFoutCorner(iid,data)
00806                             else:
00807                                 print "error find in Near Out face-out"
00808                                 sys.exit(1)
00809 
00810                             
00811                     elif site=='far':
00812                         if poolp==PoolPmts.poolcounts[0]:
00813                             if iwall==1:
00814                                 data['tmp1']=1
00815                                 self.fillFarInLong(iid,data)
00816 
00817                             elif iwall==2:
00818                                 data['tmp1']=1
00819                                 self.fillFarInCorner(iid,data)
00820                                 
00821                             elif iwall==3:
00822                                 data['tmp1']=2
00823                                 self.fillFarInLong(iid,data)
00824 
00825                             elif iwall==4:
00826                                 data['tmp1']=2
00827                                 self.fillFarInCorner(iid,data)
00828 
00829                             elif iwall==5:
00830                                 data['tmp1']=3
00831                                 self.fillFarInLong(iid,data)
00832 
00833                             elif iwall==6:
00834                                 data['tmp1']=3
00835                                 self.fillFarInCorner(iid,data)
00836 
00837                             elif iwall==7:
00838                                 data['tmp1']=4
00839                                 self.fillFarInLong(iid,data)
00840                                 
00841                             elif iwall==8:
00842                                 data['tmp1']=4
00843                                 self.fillFarInCorner(iid,data)
00844 
00845                             elif iwall==9:
00846                                 self.fillFarInBot(iid,data)
00847 
00848                             else:
00849                                 print "error find in Far Inn face-in"
00850                                 sys.exit(1)
00851 
00852                             
00853                         elif poolp==PoolPmts.poolcounts[1]:
00854                             if iwall==1:
00855                                 data['tmp1']=1
00856                                 self.fillFarOutFinLong(iid,data)
00857 
00858                             elif iwall==2:
00859                                 data['tmp1']=1
00860                                 self.fillFarOutFinCorner(iid,data)
00861                                 
00862                             elif iwall==3:
00863                                 data['tmp1']=2
00864                                 self.fillFarOutFinLong(iid,data)
00865 
00866                             elif iwall==4:
00867                                 data['tmp1']=2
00868                                 self.fillFarOutFinCorner(iid,data)
00869 
00870                             elif iwall==5:
00871                                 data['tmp1']=3
00872                                 self.fillFarOutFinLong(iid,data)
00873 
00874                             elif iwall==6:
00875                                 data['tmp1']=3
00876                                 self.fillFarOutFinCorner(iid,data)
00877 
00878                             elif iwall==7:
00879                                 data['tmp1']=4
00880                                 self.fillFarOutFinLong(iid,data)
00881                                 
00882                             elif iwall==8:
00883                                 data['tmp1']=4
00884                                 self.fillFarOutFinCorner(iid,data)
00885 
00886                             elif iwall==9:
00887                                 self.fillFarOutFinBot(iid,data)
00888 
00889                             else:
00890                                 print "error find in Far Out face-in"
00891                                 sys.exit(1)
00892 
00893                         elif poolp==PoolPmts.poolcounts[2]:
00894                             if iwall==1:
00895                                 data['tmp1']=1
00896                                 self.fillFarOutFoutLong(iid,data)
00897 
00898                             elif iwall==2:
00899                                 data['tmp1']=1
00900                                 self.fillFarOutFoutCorner(iid,data)
00901                                 
00902                             elif iwall==3:
00903                                 data['tmp1']=2
00904                                 self.fillFarOutFoutLong(iid,data)
00905 
00906                             elif iwall==4:
00907                                 data['tmp1']=2
00908                                 self.fillFarOutFoutCorner(iid,data)
00909 
00910                             elif iwall==5:
00911                                 data['tmp1']=3
00912                                 self.fillFarOutFoutLong(iid,data)
00913 
00914                             elif iwall==6:
00915                                 data['tmp1']=3
00916                                 self.fillFarOutFoutCorner(iid,data)
00917 
00918                             elif iwall==7:
00919                                 data['tmp1']=4
00920                                 self.fillFarOutFoutLong(iid,data)
00921                                 
00922                             elif iwall==8:
00923                                 data['tmp1']=4
00924                                 self.fillFarOutFoutCorner(iid,data)
00925                             else:
00926                                 print "error find in Far Out face-out"
00927                                 sys.exit(1)
00928 
00929                         else:
00930                             print "error found in far pool,exit"
00931                             sys.exit(1)
00932 
00933                     de = DetElem('%(site)s-%(poolpv)s-wall%(wallnum)d-id%(idnum)d'%data,
00934                                  self.lvname, PoolPmts.npath, PoolPmts.support)
00935                     
00936                     de.refs = [UserParameter("PmtID","int",['0x%x'%pmtid],desc="Packed PMT ID")]
00937                     
00938                     pmts.append(de)
00939                     continue
00940                 continue
00941 
00942             file = XmlFile()
00943             file.objects = pmts
00944             file.write(outdir+"/%s%s.xml"%(self.site,poolp))
00945             continue
00946 
#---------------------------------------------------------------

Member Data Documentation

string gen::PoolPmts::lvname = "/dd/Geometry/PMT/lvPmtHemiFrame" [static]

Definition at line 49 of file gen.py.

list gen::PoolPmts::siteids = [0x01,0x02,0x04] [static]

Definition at line 50 of file gen.py.

list gen::PoolPmts::poolnums = [(5<<1)|1, (6<<1)|1, 6<<1] [static]

Definition at line 51 of file gen.py.

list gen::PoolPmts::poolcounts = ['InnFin','OutFin','OutFout'] [static]

Definition at line 52 of file gen.py.

list gen::PoolPmts::wallcounts = [9, 9, 8] [static]

Definition at line 53 of file gen.py.

list gen::PoolPmts::nearInFin = [8,8,24,8,8,8,24,8,20] [static]

Definition at line 54 of file gen.py.

list gen::PoolPmts::nearOutFin = [8,8,16,8,8,8,16,8,29] [static]

Definition at line 55 of file gen.py.

list gen::PoolPmts::nearOutFout = [4,8,12,8,4,8,12,8] [static]

Definition at line 56 of file gen.py.

list gen::PoolPmts::farInFin = [24,8,24,8,24,8,24,8,32] [static]

Definition at line 57 of file gen.py.

list gen::PoolPmts::farOutFin = [16,8,16,8,16,8,16,8,32] [static]

Definition at line 58 of file gen.py.

list gen::PoolPmts::farOutFout = [16,8,16,8,16,8,16,8] [static]

Definition at line 59 of file gen.py.

string gen::PoolPmts::npath = '' [static]

Definition at line 60 of file gen.py.

string gen::PoolPmts::support = '' [static]

Definition at line 61 of file gen.py.

int gen::PoolPmts::c4 = 4 [static]

Definition at line 62 of file gen.py.

int gen::PoolPmts::c3 = 3 [static]

column with 4 pmts

Definition at line 63 of file gen.py.

Definition at line 65 of file gen.py.

Definition at line 65 of file gen.py.

Definition at line 65 of file gen.py.

Definition at line 65 of file gen.py.


The documentation for this class was generated from the following file:
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

Generated on Fri May 16 2014 09:56:07 for XmlDetDesc by doxygen 1.7.4