Commit 0b74b0ca authored by Lukas Cejka's avatar Lukas Cejka
Browse files

Fixed mistake where integer division was used for certain format declarations....

Fixed mistake where integer division was used for certain format declarations. Added commented-out helpful prints to identify errors.
parent b2f675d3
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -251,6 +251,13 @@ void ChunkedEllpack< Real, Device, Index >::setCompressedRowLengths( ConstCompre
      this->rowPointers.computePrefixSum();
   }
   
//   std::cout << "\ngetRowLength after first if: " << std::endl;
//   for( IndexType i = 0; i < rowLengths.getSize(); i++ )
//   {
//       std::cout << getRowLength( i ) << std::endl;
//   }
//   std::cout << "\n";

   if( std::is_same< Device, Devices::Cuda >::value )
   {
      ChunkedEllpack< RealType, Devices::Host, IndexType > hostMatrix;
@@ -274,6 +281,7 @@ void ChunkedEllpack< Real, Device, Index >::setCompressedRowLengths( ConstCompre
      elementsToAllocation = hostMatrix.values.getSize();
   }
   this->maxRowLength = rowLengths.max();
//   std::cout << "\nrowLengths.max() = " << rowLengths.max() << std::endl;
   Sparse< Real, Device, Index >::allocateMatrixElements( elementsToAllocation );
}