28 std::vector<const GeometricDet*> theCompsPosNeg;
30 double theRmin = (**begin).rho();
31 double theRmax = theRmin;
32 for(vector<const GeometricDet*>::const_iterator it=
begin;
34 if((**it).phi() >= 0) theCompsPosNeg.emplace_back(*it);
35 theRmin =
std::min( theRmin, (**it).rho());
36 theRmax =
std::max( theRmax, (**it).rho());
38 for(vector<const GeometricDet*>::const_iterator it=
begin;
40 if((**it).phi() < 0) theCompsPosNeg.emplace_back(*it);
46 double radius_split = 100.;
47 std::vector<const GeometricDet*> theCompsInnerOuter;
48 unsigned int num_inner = 0;
49 for(vector<const GeometricDet*>::const_iterator it=theCompsPosNeg.begin();
50 it!=theCompsPosNeg.end();it++){
51 if((**it).rho() <= radius_split) {
52 theCompsInnerOuter.emplace_back(*it);
57 for(vector<const GeometricDet*>::const_iterator it=theCompsPosNeg.begin();
58 it!=theCompsPosNeg.end();it++){
59 if((**it).rho() > radius_split) theCompsInnerOuter.emplace_back(*it);
64 std::rotate(theCompsInnerOuter.begin()+num_inner,theCompsInnerOuter.begin()+num_inner+1,theCompsInnerOuter.end());
65 std::copy(theCompsInnerOuter.begin(), theCompsInnerOuter.end(),
begin);
static bool PhiSort(const GeometricDet *Panel1, const GeometricDet *Panel2)
def rotate(angle, cx=0, cy=0)