H5.close prevents saving complex data to files with '-v7.3'

I regularly write and read data to files using HDF5 library routines, and to be safe, I always call H5.close when I'm done writing or reading the data. However, I recently noticed that after calling H5.close, I can no longer use the save command to write complex data in the '-v7.3' format. Even if I try H5.open again, it still doesn't work. This seems like a bug to me.
For example:
>> test = sqrt(-1);
>> save('temp1.mat', 'test', '-v7.3')
>> clear test
>> load('temp1.mat') % Works fine.
>> H5.close
>> save('temp2.mat', 'test', '-v7.3') % Does not work.
Error using save
Can't write file [...]\temp2.mat.
>> H5.open
>> save('temp2.mat', 'test', '-v7.3') % Still doesn't work.
Error using save
Can't write file [...]\temp2.mat.

4 Comments

I reproduced this behavior on R2013a and Win7.
For the record, I'm using R2014b on Win7. I can also reproduce this on R2011b.
Hi Patrick, Can you please verify that you see this behavior in R2014b? I'm trying to determine if it is directly related to your other inquiry on H5L.visit behavior in R2015a. Thank you, Ellen
Hello Ellen, I can verify this does not work on 2014b or 2015a. I had originally seen it on 2014b, and when I tested it now on 2015a, it crashed Matlab.

Sign in to comment.

Answers (0)

Categories

Products

Asked:

on 4 Jun 2015

Commented:

on 10 Aug 2015

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!