Apollo3zehn / PureHDF

A pure .NET library that makes reading and writing of HDF5 files (groups, datasets, attributes, ...) very easy.
MIT License
47 stars 16 forks source link

Is posible if can read from buffer? #57

Closed chuongmep closed 5 months ago

chuongmep commented 5 months ago

Hi, whether do we have any way can allow read hdf from buffer memory ? Example :

H5File.OpenRead(byte[] buffer)
Apollo3zehn commented 5 months ago

You can wrap the buffer into a memory stream and then read from it:

var data = new byte[] { xxx };
using var stream = new MemoryStream(data);
using var h5File = H5File.Open(stream);
chuongmep commented 5 months ago

thank you, look nice,.