Commits
400 400 | for (auto itmin=localminfreq.begin(); itmin != localminfreq.end(); ++itmin){ |
401 401 | if(swingFreq < abs(*itmin -minFreq)) |
402 402 | swingFreq=abs(*itmin -minFreq); |
403 403 | if(swingFreq < abs(*itmax -maxFreq)) |
404 404 | swingFreq=abs(*itmax -maxFreq); |
405 405 | if(firstchanshift < abs(*itf-minfirstchan)) |
406 406 | firstchanshift=abs(*itf-minfirstchan); |
407 407 | itf++; |
408 408 | itmax++; |
409 409 | } |
410 - | swingpad=2*(Int(std::ceil((swingFreq+firstchanshift)/freqincr))+8); |
411 - | //cerr << "CPUID " << my_cpu_id <<" swingfreq " << (swingFreq/freqincr) << " firstchanshift " << (firstchanshift/freqincr) << " SWINGPAD " << swingpad << endl; |
410 + | Int extrapad=max(min(4, Int(imNChan/10)),1); |
411 + | swingpad=2*(Int(std::ceil((swingFreq+firstchanshift)/freqincr))+extrapad); |
412 + | cerr <<" swingfreq " << (swingFreq/freqincr) << " firstchanshift " << (firstchanshift/freqincr) << " SWINGPAD " << swingpad << endl; |
412 413 | //////////////// |
413 414 | return swingpad; |
414 415 | |
415 416 | } |
416 417 | |
417 418 | String BriggsCubeWeightor::makeScratchImagingWeightTable(CountedPtr<Table>& weightTable, const String& filetag){ |
418 419 | |
419 420 | //String wgtname=File::newUniqueName(".", "IMAGING_WEIGHT").absoluteName(); |
420 421 | String wgtname=Path("IMAGING_WEIGHT_"+filetag).absoluteName(); |
421 422 | //cerr << "NAME " << wgtname << endl; |