MappedByteBuffer buf = new FileInputStream(f).getChannel().map(FileChannel.MapMode.READ_ONLY, start,
Math.min(f.length() - start, size));
if (loadNow) {
buf.load();
}
addData(buf.asDoubleBuffer());
}
}
public static void writeMatrix(File f, Matrix m) throws IOException {
Preconditions.checkArgument(f.canWrite(), "Can't write to output file");