Changeset 905
- Timestamp:
- 03/17/06 17:00:16 (19 years ago)
- Location:
- trunk/src
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/STFiller.cpp
r901 r905 102 102 nPol_ += 2; // Convert Complex -> 2 Floats 103 103 } 104 105 104 if (header_) delete header_; 106 105 header_ = new STHeader(); … … 108 107 header_->npol = nPol_; 109 108 header_->nbeam = nBeam_; 109 110 if ( nPol_ == 1 ) header_->poltype = "stokes"; 111 else header_->poltype = "linear"; 110 112 111 113 Int status = reader_->getHeader(header_->observer, header_->project, -
trunk/src/STHeader.h
r901 r905 65 65 casa::String fluxunit; 66 66 casa::String epoch; 67 casa::String poltype; 67 68 void print() const ; 68 69 }; -
trunk/src/Scantable.cpp
r902 r905 298 298 table_.rwKeywordSet().define("FluxUnit", sdh.fluxunit); 299 299 table_.rwKeywordSet().define("Epoch", sdh.epoch); 300 table_.rwKeywordSet().define("POLTYPE", sdh.poltype); 300 301 } 301 302 … … 319 320 table_.keywordSet().get("FluxUnit", sdh.fluxunit); 320 321 table_.keywordSet().get("Epoch", sdh.epoch); 322 table_.keywordSet().get("POLTYPE", sdh.poltype); 321 323 return sdh; 322 324 } … … 596 598 const std::string& poltype ) const 597 599 { 600 String ptype = poltype; 601 if (poltype == "" ) ptype = getPolType(); 598 602 if ( whichrow < 0 || whichrow >= nrow() ) 599 603 throw(AipsError("Illegal row number.")); … … 602 606 uInt requestedpol = polCol_(whichrow); 603 607 String basetype = getPolType(); 604 if ( String(poltype) == basetype) {608 if ( ptype == basetype ) { 605 609 specCol_.get(whichrow, arr); 606 610 } else { … … 613 617 focusTable_.getEntry(frot, fang, ftan, mfocusidCol_(row)); 614 618 stpol->setPhaseCorrections(frot, fang, ftan); 615 arr = stpol->getSpectrum(requestedpol, p oltype);619 arr = stpol->getSpectrum(requestedpol, ptype); 616 620 delete stpol; 617 621 } catch (AipsError& e) { -
trunk/src/Scantable.h
r902 r905 251 251 std::vector<bool> getMask(int whichrow) const; 252 252 std::vector<float> getSpectrum(int whichrow, 253 const std::string& poltype = "linear") const;253 const std::string& poltype = "" ) const; 254 254 255 255 void setSpectrum(const std::vector<float>& spec, int whichrow); -
trunk/src/ScantableWrapper.h
r902 r905 64 64 65 65 std::vector<float> getSpectrum( int whichrow=0, 66 const std::string& poltype=" linear" ) const {66 const std::string& poltype="" ) const { 67 67 return table_->getSpectrum(whichrow, poltype); 68 68 } -
trunk/src/python_Scantable.cpp
r902 r905 69 69 .def("_setInstrument", &ScantableWrapper::setInstrument) 70 70 .def("_getspectrum", &ScantableWrapper::getSpectrum, 71 (arg("whichrow")=0, arg("poltype")=std::string(" linear")) )71 (arg("whichrow")=0, arg("poltype")=std::string("")) ) 72 72 .def("poltype", &ScantableWrapper::getPolType ) 73 73 .def("_getpollabel", &ScantableWrapper::getPolarizationLabel)
Note:
See TracChangeset
for help on using the changeset viewer.