Class ReaderTextCSVParallel


  • public class ReaderTextCSVParallel
    extends MatrixReader
    Parallel version of ReaderTextCSV.java. To summarize, we do two passes in order to compute row offsets and the actual read. We accordingly create count and read tasks and use fixed-size thread pools to execute these tasks. If the target matrix is dense, the inserts are done lock-free. In contrast to textcell parallel read, we also do lock-free inserts. If the matrix is sparse, because splits contain row partitioned lines and hence there is no danger of lost updates. Note, there is also no sorting of sparse rows required because data comes in sorted order per row.