Changeset 2479


Ignore:
Timestamp:
04/24/12 11:14:39 (13 years ago)
Author:
Takeshi Nakazato
Message:

New Development: No

JIRA Issue: No

Ready for Test: Yes

Interface Changes: No

What Interface Changed: Please list interface changes

Test Programs: List test programs

Put in Release Notes: Yes/No

Module(s): Module Names change impacts.

Description: Describe your changes here...

bug fixes in STMath::new_average

  • proper handling of scan average
  • proper handling of multi-beam data


File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/STMath.cpp

    r2477 r2479  
    33253325
    33263326    // reset SCANNO and IFNO/FREQ_ID: IF is reset by the result of sortation
    3327     os << "All scan number is set to 0" << LogIO::POST ;
    33283327    //os << "All IF number is set to IF group index" << LogIO::POST ;
    33293328    insize = newin.size() ;
     3329    // reset SCANNO only when avmode != "SCAN"
     3330    if ( avmode != "SCAN" ) {
     3331      os << "All scan number is set to 0" << LogIO::POST ;
     3332      for ( uInt itable = 0 ; itable < insize ; itable++ ) {
     3333        uInt nrow = newin[itable]->nrow() ;
     3334        Table &tmpt = newin[itable]->table() ;
     3335        scannoCol.attach( tmpt, "SCANNO" ) ;
     3336        for ( uInt irow = 0 ; irow < nrow ; irow++ )
     3337          scannoCol.put( irow, 0 ) ;
     3338      }
     3339    }
    33303340    for ( uInt itable = 0 ; itable < insize ; itable++ ) {
    33313341      uInt rows = newin[itable]->nrow() ;
    33323342      Table &tmpt = newin[itable]->table() ;
    33333343      freqIDCol.attach( tmpt, "FREQ_ID" ) ;
    3334       scannoCol.attach( tmpt, "SCANNO" ) ;
    33353344      ifnoCol.attach( tmpt, "IFNO" ) ;
    33363345      for ( uInt irow=0 ; irow < rows ; irow++ ) {
    3337         scannoCol.put( irow, 0 ) ;
    33383346        uInt freqID = freqIDCol( irow ) ;
    33393347        vector<uInt>::iterator iter = find( freqid[newtableids[itable]].begin(), freqid[newtableids[itable]].end(), freqID ) ;
     
    36173625//     dirColOut.attach( out->table(), "DIRECTION" ) ;
    36183626    Table &tab = tmpout->table() ;
    3619     Block<String> cols(1);
     3627//     Block<String> cols(1);
     3628//     cols[0] = String("POLNO") ;
     3629    Block<String> cols(3);
    36203630    cols[0] = String("POLNO") ;
     3631    cols[1] = String("SCANNO") ;
     3632    cols[2] = String("BEAMNO") ;
    36213633    TableIterator iter( tab, cols ) ;
    36223634    vector< vector<uInt> > sizes( freqgrp.size() ) ;
Note: See TracChangeset for help on using the changeset viewer.