dsp.MatFileReader HDF5 library encountered an error

3 views (last 30 days)
Hi all, I am getting this error with MatFileReader which I don't know how to fix. The function below simply reads a mat file with dsp.MatFileReader.
S.A = randn(1000,1);
S.B = randn(1000,1);
save('sampleS.mat','S','-v7.3');
clear S;
filename = 'sampleS.mat';
VariableName = 'S';
SamplesPerFrame = 50;
mfr = dsp.MatFileReader;
mfr.Filename = filename;
mfr.VariableName = VariableName;
mfr.SamplesPerFrame = SamplesPerFrame;
while ~isDone(mfr)
x= mfr();
d = x.A;
end
Error using dsp.MatFileReader/setupObject (line 195)
The HDF5 library encountered an error and produced the following stack trace information:
H5D__open_name not a dataset
Error in dsp.MatFileReader/setupImpl (line 212)
setupObject(obj,varargin);
Error in matlab.system.mixin.FiniteSource/isDone
Error in untitled (line 17)
while ~isDone(mfr)

Answers (0)

Products


Release

R2021b

Community Treasure Hunt

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

Start Hunting!