MAT files saved much larger then expected

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

MAT files saved much larger then expected

Mark popov
CONTENTS DELETED
The author has deleted this message.
Reply | Threaded
Open this post in threaded view
|

Re: MAT files saved much larger then expected

Mike Miller-4
On Thu, Apr 13, 2017 at 01:05:51 -0700, Mark popov wrote:

> Hi,
>
> I'm accustomed to Matlab, using it for around 12 years, and now started
> using Octave as well.
>
> I've noticed something strange - saving .mat files, might result with much
> higher size than expected.
> For example, saving a .mat file which contains a single struct of ~380
> cells, each one's size of ~1MB, results with an overall file size of 1GB
> (instead of just 380MB).
> The size of the RAM memory actually seems OK, only when writing to the
> hard-drive its size explodes.
> Furthermore, loading it takes considerable amount of time, and it's much
> more efficient to load the same data from distributed 400 different mat
> files.

Did you perhaps forget to include the -mat option? You may have assumed
that would be the default format, but it is not. See "help save".

  save file1.mat        ## file1.mat is Octave text format
  save -mat file2.mat   ## file2.mat is Matlab binary format

--
mike

_______________________________________________
Help-octave mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: MAT files saved much larger then expected

Mark popov
CONTENTS DELETED
The author has deleted this message.