MatFileRW is not abandoned, but we recommend migrating to HebiRobotics/MFL
MatFileRW will continue to accept bug reports and PRs. However, we recommend starting new projects with HebiRobotics/MFL because it:
- has every testcase from MatFileRW and more
- has a cleaner and more modern codebase
- supports concurrent compression and decompression
- is designed for interoperability with native-Java matrix manipulation
- has optional EJML integration
Besides the effort to learn the new API, there are no downsides and quite a few upsides. Migrating a project is a big job, so we will continue to accept bug reports and PR's for MatFileRW to support those who don't choose to migrate.
MatFileRW is a library which allows reading and writing MAT files. Have a look at MatIOTest.java to see each part in use.
As far as compatibility, the TL;DR is that it will work with any MAT-File with default settings. The dirty details are that this library works with v6
and v7
, but not v4
or v7.3
.
- v4 is the default format before R8
- v6 is the default format from R8 to R13
- v7 is the default format from R14 to present (every R20XXX release)
- MATLAB does not export to v7.3 by default.
- The Mathworks website has more details.
Since JMatIO wasn't updated for a while, lots of people made forks. One of the most prominent was Jason Lokerson's, hosted on GitHub as codemercenary/JMatIO. It included several improvements, but all the packages were renamed to ca.mjdsystems.jmatio
. Starting with 2.0.0, all of the improvements from MatFileRW and ca.mjdsystems.jmatio
have been merged into the com.jmatio
packages.
If you are a user of the ca.mjdsystems
packages, you should download com.diffplug.matsim:matfilerw:2.0.0.TRANSITION
from mavenCentral. This contains the ca.mjdsystems.jmatio
packages unchanged, but marked as deprecated. After you have removed all dependencies on the ca.mjdsystems.jmatio
packages, you will be able to use the regular 2.0.0
version, and its descendants.
This project is forked from the JMatIO project originally maintained on SourceForge, and now maintained on GitHub. The name was changed to ensure that we don't infringe the original project's license, but we did not change the package names, so this project is binary compatible with the original JMatIO. We are very thankful to Wojciech Gradkowski for creating JMatIO, but this fork is in no way associated with or endorsed by any authors of the original project.
We have fixed some bugs and added some features (see the changelog), and we will maintain this library into the future. We're happy to accept pull requests too!
People whose commits are included in this project
- Original JMatIO project credit to Wojciech Gradkowski
- Thanks to Tim Ryan for finding and fixing a multidimensional indexing bug.
- MLSparse improvements credit to Sina Samangooei
- Reading from streams credit to Jonathan Hare
- MCOS and Simulink MAT-File parsing by Matthew Dawson
- Further MCOS fixes thanks to Piotr Smolinski
- int32 writing by Gabriel Shubiner
- ZLIP EOF Exception fix by David Williams
- Integration work by Jason Lokerson
- Multidimensional array indexing by Mikael Grev
- AbstractIterator taken from Google's Guava
Tools used by this project