-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Binary I/O #83
Binary I/O #83
Conversation
…der, added instantiations
…der, added instantiations
# Conflicts: # src/CMakeLists.txt # src/generate_explicit_instantiations.py # src/sparsebase/sparse_reader.cc # src/sparsebase/sparse_reader.h
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The names of the Read
and Write
Functions in sparse_file_format
should be more clear.
Also, I recommend merging this PR with #82 (i.e., closing that one and moving its PR comments here) since the code for the latter is already merged here.
As suggested by @AmroAlJundi, all the changes from the pull request #82 are also here due to a necessary merge. So that pull request is closed and all the features discussed there are part of this request. |
SBFF (SparseBase File Format) (naming is open for debate)
This pull request adds a custom binary format for input and output of
Format
objects.Goals
This format is designed with the following goals in mind:
Specifications
Overview
The general structure of the file format is shown in the figure below.
As can be seen from the figure there are 3 entities in each file:
File Header
The file header is a JSON object encoded in ASCII and padded with space characters to be exactly 1KB in length. The object contains the following fields:
Array Header
Array headers are identical file headers in structure (JSON object encoded in ASCII and padded). However they contain different fields:
Array
The actual data of the arrays are written directly to the disk. Depending on the OS this is done in two ways: