- Timestamp:
- 01/13/10 17:20:31 (15 years ago)
- Location:
- branches/alma/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/alma/src/STFiller.cpp
r1671 r1674 311 311 #endif 312 312 PKSrecord pksrec; 313 pksrec.srcType=-1; 313 314 int n = 0; 314 315 bool isGBTFITS = false ; … … 376 377 //*srcnCol = pksrec.srcName;//.before(rx2); 377 378 *srctCol = match; 379 if ( pksrec.srcType != -1 ) { 380 *srctCol = pksrec.srcType ; 381 } 378 382 RecordFieldPtr<uInt> beamCol(rec, "BEAMNO"); 379 383 *beamCol = pksrec.beamNo-beamOffset_-1; -
branches/alma/src/STMath.cpp
r1673 r1674 3412 3412 } 3413 3413 else { 3414 string onstr = "*_" ;3415 string offstr = "*_" ;3416 3417 if ( calmode == "ps" || calmode == "otf" ) {3418 onstr += "pson" ;3419 offstr += "psoff" ;3420 }3421 else if ( calmode == "wob" ) {3422 onstr += "wobon" ;3423 offstr += "woboff" ;3424 }3425 3426 3414 vector<bool> masks = s->getMask( 0 ) ; 3427 3415 3428 3416 // off scan 3429 3417 STSelector sel = STSelector() ; 3430 sel.setName( offstr ) ; 3418 string taql = "SELECT FROM $1 WHERE SRCTYPE == 0" ; 3419 sel.setTaQL( taql ) ; 3431 3420 s->setSelection( sel ) ; 3432 3421 // TODO 2010/01/08 TN … … 3475 3464 CountedPtr<Scantable> out = getScantable( s, true ) ; 3476 3465 insitu_ = insitu ; 3477 sel.setName( onstr ) ; 3466 taql = "SELECT FROM $1 WHERE SRCTYPE == 1" ; 3467 sel.setTaQL( taql ) ; 3478 3468 s->setSelection( sel ) ; 3479 3469 TableCopy::copyRows( out->table(), s->table() ) ; … … 3488 3478 out->setSpectrum( sp, i ) ; 3489 3479 } 3490 3491 // remove additional string from SRCNAME3492 ScalarColumn<String> srcnameCol ;3493 srcnameCol.attach( out->table(), "SRCNAME" ) ;3494 Vector<String> srcnames( srcnameCol.getColumn() ) ;3495 for ( uInt i = 0 ; i < srcnames.nelements() ; i++ ) {3496 srcnames[i] = srcnames[i].substr( 0, srcnames[i].find( onstr.substr(1,onstr.size()-1) ) ) ;3497 }3498 srcnameCol.putColumn( srcnames ) ;3499 3480 3500 3481 // flux unit
Note:
See TracChangeset
for help on using the changeset viewer.