problem in reading hdf5 file into c#

Dear developers.

I am a newbie in the hdf5 world, but I'm really interested in learning how to work with it.

I'm trying to read a .h5 file into C#.
I have downloaded the HDF5DotNet reference and the required dlls in order to run my Visual Studio application.
I bumped into some difficulties while reading the file, which for the majority of you would be just a simple routine.

I attached a screenshot with the code and the result printed on screen.

As you can see I get a strange result for the variable "Wrap" which should give me the value of the correspondent variable Ls in .h5
Ls is a scalar number with a value of 0.01
The actual value I want to get out is somehow hidden into it, but I was not able to access it.

  [cid:image001.png@01D1707D.ACC37A90]

Does some of you know where I get it wrong?

Thank you so much for your help.
Looking forward to hearing from you.

Best regards.
Mirco Carciani

[cid:image001.png@01CFF911.F33F83E0]

Mirco Carciani
PSDC/TSI
Lyviksvägen 3
771 80, Ludvika, Dalarna, SWEDEN
Phone:
Mobile: +46 72 55 18 469
email: mirco.carciani@se.abb.com

Mirco,

Output Ls[0], not Wrap. When you write Wrap you're just getting the data type. If you write Ls, you'll probably get something similar.

Scott

···

From: Hdf-forum [mailto:hdf-forum-bounces@lists.hdfgroup.org] On Behalf Of Mirco Carciani
Sent: Friday, February 26, 2016 4:13 AM
To: hdf-forum@lists.hdfgroup.org
Cc: Prerna Bihani
Subject: [Hdf-forum] problem in reading hdf5 file into c#

Dear developers.

I am a newbie in the hdf5 world, but I'm really interested in learning how to work with it.

I'm trying to read a .h5 file into C#.
I have downloaded the HDF5DotNet reference and the required dlls in order to run my Visual Studio application.
I bumped into some difficulties while reading the file, which for the majority of you would be just a simple routine.

I attached a screenshot with the code and the result printed on screen.

As you can see I get a strange result for the variable "Wrap" which should give me the value of the correspondent variable Ls in .h5
Ls is a scalar number with a value of 0.01
The actual value I want to get out is somehow hidden into it, but I was not able to access it.

  [cid:image001.png@01D17077.817F7C90]

Does some of you know where I get it wrong?

Thank you so much for your help.
Looking forward to hearing from you.

Best regards.
Mirco Carciani

[cid:image001.png@01CFF911.F33F83E0]

Mirco Carciani
PSDC/TSI
Lyviksvägen 3
771 80, Ludvika, Dalarna, SWEDEN
Phone:
Mobile: +46 72 55 18 469
email: mirco.carciani@se.abb.com<mailto:mirco.carciani@se.abb.com>

Hi Mirco,

You might want to use HDF.PInvoke instead of HDF5DotNet. The latter is not being updated anymore, the former one is brand new and closer to the native c-API.
Have a look at GitHub - HDFGroup/HDF.PInvoke: Raw HDF5 Power for .NET and NuGet Gallery | HDF.PInvoke 1.10.6.1

Best regards,
Detlef

···

---

Detlef Sanchen
Senior Software Engineer

WITec GmbH
Lise-Meitner-Str. 6, 89081 Ulm, Germany
Phone: +49 (0)731 140 70-0, Fax: +49 (0)731 140 70-200
Email: Detlef.Sanchen@WITec.de<mailto:Detlef.Sanchen@WITec.de>, web: www.WITec.de<http://www.witec.de/&gt;

Join us on Facebook: Redirecting...<Facebook;

WITec Wissenschaftliche Instrumente und Technologie GmbH; Geschäftsführer: Dr.Olaf Hollricher, Dr.Joachim Koenen, Dr.Klaus Weishaupt; Amtsgericht Ulm HRB 3507

From: Hdf-forum [mailto:hdf-forum-bounces@lists.hdfgroup.org] On Behalf Of Mirco Carciani
Sent: Freitag, 26. Februar 2016 10:13
To: hdf-forum@lists.hdfgroup.org
Cc: Prerna Bihani <prerna.bihani@se.abb.com>
Subject: [Hdf-forum] problem in reading hdf5 file into c#

Dear developers.

I am a newbie in the hdf5 world, but I'm really interested in learning how to work with it.

I'm trying to read a .h5 file into C#.
I have downloaded the HDF5DotNet reference and the required dlls in order to run my Visual Studio application.
I bumped into some difficulties while reading the file, which for the majority of you would be just a simple routine.

I attached a screenshot with the code and the result printed on screen.

As you can see I get a strange result for the variable "Wrap" which should give me the value of the correspondent variable Ls in .h5
Ls is a scalar number with a value of 0.01
The actual value I want to get out is somehow hidden into it, but I was not able to access it.

  [cid:image001.png@01D170B4.7E901110]

Does some of you know where I get it wrong?

Thank you so much for your help.
Looking forward to hearing from you.

Best regards.
Mirco Carciani

[cid:image001.png@01CFF911.F33F83E0]

Mirco Carciani
PSDC/TSI
Lyviksvägen 3
771 80, Ludvika, Dalarna, SWEDEN
Phone:
Mobile: +46 72 55 18 469
email: mirco.carciani@se.abb.com<mailto:mirco.carciani@se.abb.com>