Source
1459
1459
Int chunksize=imagestore->getShape()[3]/chanchunks;
1460
1460
Int rem=imagestore->getShape()[3] % chanchunks;
1461
1461
///Avoid an extra chunk with 1 channel as it cause bumps in linear interpolation
1462
1462
///See CAS-12625
1463
1463
while(rem==1){
1464
1464
chanchunks +=1;
1465
1465
chunksize=imagestore->getShape()[3]/chanchunks;
1466
1466
rem=imagestore->getShape()[3] % chanchunks;
1467
1467
}
1468
1468
1469
-
Bool extra1chan=False;
1469
+
1470
1470
if( rem>0 )
1471
1471
{
1472
1472
// os << LogIO::WARN << "chanchunks ["+String::toString(chanchunks)+"] is not a divisor of nchan ["+String::toString(imagestore->getShape()[3])+"].";
1473
1473
// os << "Therefore, "+String::toString(imagestore->getShape()[3] % chanchunks)+" channel(s) at the end of the cube will be treated as an extra chunk." << LogIO::POST ;
1474
1474
1475
1475
if( rem < chunksize ) extrachunks=1;
1476
1476
else
1477
1477
{
1478
1478
extrachunks=rem/chunksize;
1479
1479
if( rem % chunksize > 0 ) extrachunks += 1;