GithubHelp home page GithubHelp logo

jamesetsmith / mtxio Goto Github PK

View Code? Open in Web Editor NEW
0.0 2.0 0.0 119 KB

Matrix Market IO

License: Apache License 2.0

CMake 18.84% C 70.61% Python 0.44% C++ 9.73% Shell 0.39%
matrix-market openmp parallel sparse

mtxio's Introduction

Faster Parsing for Matrix Market

build

There are several great C++ projects (PIGO and fast_matrix_market) for reading matrix market files faster in serial and parallel. However, GraphBLAS is written in ANSI C and I wanted to try and write a matrix market reader (and eventually writer) in C so it could be used side-by-side with GraphBLAS. This is based heavily on the great C++ projects mentioned above and several of the utility functions are lifted almost verbatim from those projects.

โš ๏ธ This project is pre-alpha and is currently unstable. Currently only reading matrix market coordinate files with doubles is supported. Please understand there will be breaking changes.

TODOs

Features required to meet specification:

  • Object

    • matrix
    • vector
  • Format

    • coordinate
    • array
  • Fields

    • real
    • complex
    • integer
    • pattern (i.e. no values)
  • Symmetry

    • general
    • symmetric
    • skew-symmetric
    • hermitian
  • Feature: Add sanitizer checks to CI

  • Feature: handle inf, nan, etc

  • Feature: gracefully handle non-conformant/non-mtx files

  • Feature: add parallel write

  • Feature: Add proper CMake aliases (like mtxio::mtxio) to make it easier to integrate with other CMake projects

  • Feature: Clean up CMake default flags (maybe use CMake configurations?)

  • Performance: Improve parallel read performance, still slower than PIGO by 30-50%.

Prerequisites

  • C/C++ compiler
  • Python3 and SciPy (Optional, needed to make benchmarking data)

Build

[email protected]:jamesETsmith/mtxio.git
cd mtxio
export CPM_SOURCE_CACHE=$HOME/.cache/CPM # (optional)
cmake -B build
cmake --build build
ctest --test-dir build

Benchmarking

cd data && python generate_data.py # May take a while
cd ..
perf stat -- env OMP_NUM_THREADS=12 ./build/bench/pigo_read data/n_15_0.3.mtx
perf stat -- env OMP_NUM_THREADS=12 ./build/bench/mtxio_read data/n_15_0.3.mtx

mtxio's People

Contributors

jamesetsmith avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.