- Timestamp:
- 08/07/13 15:11:19 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/STSideBandSep.cpp
r2835 r2836 547 547 cout << "Grid parameter summary: " << endl; 548 548 cout << "- IF = " << sigIfno_ << endl; 549 cout << "- center = " << scenter << " )\n"549 cout << "- center = " << scenter << "\n" 550 550 << "- npix = (" << nx << ", " << ny << ")\n" 551 << "- cell = (" << scellx << ", " << scelly << endl;551 << "- cell = (" << scellx << ", " << scelly << ")" << endl; 552 552 #endif 553 553 gridder.grid(); … … 642 642 seltab_p->setSelection(sel2); 643 643 CountedPtr<Scantable> avetab_p; 644 vector<bool> mask;645 644 if (seltab_p->nrow() > 1) { 645 // STMath::average also merges FLAGTRA and FLAGROW 646 646 avetab_p = stm.average(vector< CountedPtr<Scantable> >(1, seltab_p), 647 647 vector<bool>(), "TINTSYS", "NONE"); … … 655 655 avetab_p = seltab_p; 656 656 } 657 // Check FLAGTRA and FLAGROW if there's any valid channel in the spectrum 658 if (avetab_p->getFlagRow(0) || avetab_p->isAllChannelsFlagged(0)) { 659 #ifdef KS_DEBUG 660 cout << "Table " << itab << " - All data are flagged. skipping the table." 661 << endl; 662 #endif 663 continue; 664 } 665 // Interpolate flagged channels of the spectrum. 666 Vector<Float> tmpSpec = avetab_p->getSpectrum(0); 667 vector<bool> mask = avetab_p->getMask(0); 668 mathutil::doZeroOrderInterpolation(tmpSpec, mask); 657 669 spec.reference(specMat.column(nspec)); 658 spec = avetab_p->getSpectrum(0);670 spec = tmpSpec; 659 671 tabIdvec.push_back((uInt) itab); 660 672 nspec++; 661 673 } // end of table loop 674 // Check the number of selected spectra and resize matrix. 662 675 if (nspec != nshift_){ 663 676 //shiftSpecmat.resize(nchan_, nspec, true); 677 specMat.resize(nchan_, nspec, true); 664 678 #ifdef KS_DEBUG 665 679 cout << "Could not find corresponding rows in some tables." … … 801 815 throw(AipsError("Internal error. The number of input shifts and spectrum differs.")); 802 816 817 #ifdef KS_DEBUG 803 818 float minval, maxval; 819 #endif 804 820 #ifdef KS_DEBUG 805 821 minMax(minval, maxval, specmat); … … 1208 1224 1209 1225 bool STSideBandSep::getLo1FromAsdm(const string asdmname, 1210 const double refval,1211 const double refpix,1212 const double increment,1213 const int nChan)1226 const double /*refval*/, 1227 const double /*refpix*/, 1228 const double /*increment*/, 1229 const int /*nChan*/) 1214 1230 { 1215 1231 // Check for relevant tables.
Note:
See TracChangeset
for help on using the changeset viewer.