Changeset 2596 for branches/hpc34/external-alma/atnf/PKSIO
- Timestamp:
- 07/11/12 17:22:53 (12 years ago)
- Location:
- branches/hpc34/external-alma/atnf/PKSIO
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/hpc34/external-alma/atnf/PKSIO/NRODataset.cc
r2590 r2596 58 58 NRODataset::NRODataset( string name ) 59 59 { 60 LogIO os( LogOrigin( "NRODataset", "NRODataset()", WHERE ) ) ;61 62 60 // memory allocation 63 61 initialize() ; … … 243 241 NRODataRecord *NRODataset::getRecord( int i ) 244 242 { 245 LogIO os( LogOrigin( "NRODataset", "getRecord()", WHERE ) ) ;246 247 243 // DEBUG 248 244 //cout << "NRODataset::getRecord() Start " << i << endl ; 249 245 // 250 246 if ( i < 0 || i >= rowNum_ ) { 247 LogIO os( LogOrigin( "NRODataset", "getRecord()", WHERE ) ) ; 251 248 //cerr << "NRODataset::getRecord() data index out of range." << endl ; 252 249 os << LogIO::SEVERE << "data index " << i << " out of range. return NULL." << LogIO::POST ; … … 267 264 } 268 265 else { 266 LogIO os( LogOrigin( "NRODataset", "getRecord()", WHERE ) ) ; 269 267 //cerr << "NRODataset::getRecord() error while reading data " << i << endl ; 270 268 os << LogIO::SEVERE << "error while reading data " << i << ". return NULL." << LogIO::POST ; … … 278 276 int NRODataset::fillRecord( int i ) 279 277 { 280 LogIO os( LogOrigin( "NRODataset", "fillRecord()", WHERE ) ) ;281 282 278 int status = 0 ; 283 279 … … 295 291 if ( (int)fread( record_, 1, SCAN_HEADER_SIZE, fp_ ) != SCAN_HEADER_SIZE ) { 296 292 //cerr << "Failed to read scan header: " << i << endl ; 293 LogIO os( LogOrigin( "NRODataset", "fillRecord()", WHERE ) ) ; 297 294 os << LogIO::SEVERE << "Failed to read scan header for " << i << "th row." << LogIO::POST ; 298 295 return -1 ; … … 300 297 if ( (int)fread( record_->LDATA, 1, dataLen_, fp_ ) != dataLen_ ) { 301 298 //cerr << "Failed to read spectral data: " << i << endl ; 299 LogIO os( LogOrigin( "NRODataset", "fillRecord()", WHERE ) ) ; 302 300 os << LogIO::SEVERE << "Failed to read spectral data for " << i << "th row." << LogIO::POST ; 303 301 return -1 ; … … 354 352 vector<double> NRODataset::getSpectrum( int i ) 355 353 { 356 LogIO os( LogOrigin( "NRODataset", "getSpectrum", WHERE ) ) ;357 358 354 // DEBUG 359 355 //cout << "NRODataset::getSpectrum() start process (" << i << ")" << endl ; … … 413 409 if ( ( ivalue < 0 ) || ( ivalue > 4096 ) ) { 414 410 //cerr << "NRODataset::getSpectrum() ispec[" << i << "] is out of range" << endl ; 411 LogIO os( LogOrigin( "NRODataset", "getSpectrum", WHERE ) ) ; 415 412 os << LogIO::SEVERE << "ispec[" << i << "] is out of range" << LogIO::EXCEPTION ; 416 413 delete ispec ; -
branches/hpc34/external-alma/atnf/PKSIO/NROReader.cc
r2590 r2596 300 300 Vector<Double> NROReader::getSourceDirection() 301 301 { 302 LogIO os( LogOrigin( "NROReader", "getSourceDirection()", WHERE ) ) ;303 304 302 if ( msrcdir_.nelements() == 2 ) 305 303 return msrcdir_ ; … … 323 321 //<< srcra << "," << srcdec << ") B1950 to (" 324 322 //<< v( 0 ) << ","<< v( 1 ) << ") J2000" << endl ; 323 //LogIO os( LogOrigin( "NROReader", "getSourceDirection()", WHERE ) ) ; 325 324 //os << LogIO::NORMAL << "SRCDIRECTION convert from (" 326 325 // << srcra << "," << srcdec << ") B1950 to (" … … 337 336 Vector<Double> NROReader::getDirection( int i ) 338 337 { 339 LogIO os( LogOrigin( "NROReader", "getDirection()", WHERE ) ) ;340 341 338 Vector<Double> v( 2 ) ; 342 339 NRODataRecord *record = dataset_->getRecord( i ) ;
Note:
See TracChangeset
for help on using the changeset viewer.