Changeset 1707 for branches/alma/src/Scantable.cpp
- Timestamp:
- 02/19/10 20:30:37 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/alma/src/Scantable.cpp
r1706 r1707 706 706 { 707 707 for (uInt i=0; i<table_.nrow(); ++i) { 708 Vector<Float> spcs = specCol_(i);709 708 Vector<uChar> flgs = flagsCol_(i); 709 srchChannelsToClip(i, uthres, dthres, clipoutside, unflag, flgs); 710 flagsCol_.put(i, flgs); 711 } 712 } 713 714 std::vector<bool> Scantable::getClipMask(int whichrow, const Float uthres, const Float dthres, bool clipoutside, bool unflag) 715 { 716 Vector<uChar> flags; 717 flagsCol_.get(uInt(whichrow), flags); 718 srchChannelsToClip(uInt(whichrow), uthres, dthres, clipoutside, unflag, flags); 719 Vector<Bool> bflag(flags.shape()); 720 convertArray(bflag, flags); 721 //bflag = !bflag; 722 723 std::vector<bool> mask; 724 bflag.tovector(mask); 725 return mask; 726 } 727 728 void Scantable::srchChannelsToClip(uInt whichrow, const Float uthres, const Float dthres, bool clipoutside, bool unflag, 729 Vector<uChar> flgs) 730 { 731 Vector<Float> spcs = specCol_(whichrow); 710 732 uInt nchannel = nchan(); 711 733 if (spcs.nelements() != nchannel) { … … 731 753 } 732 754 } 733 flagsCol_.put(i, flgs);734 }735 755 } 736 756
Note: See TracChangeset
for help on using the changeset viewer.