request/suggestion re: high level libraries and debugging

It occurs to me that the h5dump program does a lot of stuff that would be really useful to have in library code. As an example, I was running into a problem today that I suspected was due to a type definition that was in use incorrectly. I was ultimately able to confirm my suspicion by reading code, but during that search I thought it'd be really handy to have a function that I could use to dump out the structure of the data type to some output stream or other.

h5dump already does what I was interested in, but it's not library code and would be difficult to integrate into my program to look at the definition of a type that's only defined in memory.

Anyway, I thought it'd be super useful to have some of this code in h5dump moved into a high level library for debugging (or other) purposes.

Same goes for h5diff :wink: It'd be nice to be able to 'call' h5diff on two
files or two groups (optionally recusively) or two datasets, types or
attributes from within my application. I suspect similar arguments could
be made for most of the 'tools' codes.

Mark

···

On Thu, 2012-07-26 at 11:19 -0700, John K wrote:

It occurs to me that the h5dump program does a lot of stuff that would
be really useful to have in library code. As an example, I was running
into a problem today that I suspected was due to a type definition that
was in use incorrectly. I was ultimately able to confirm my suspicion
by reading code, but during that search I thought it'd be really handy
to have a function that I could use to dump out the structure of the
data type to some output stream or other.

h5dump already does what I was interested in, but it's not library code
and would be difficult to integrate into my program to look at the
definition of a type that's only defined in memory.

Anyway, I thought it'd be super useful to have some of this code in
h5dump moved into a high level library for debugging (or other) purposes.

_______________________________________________
Hdf-forum is for HDF software users discussion.
Hdf-forum@hdfgroup.org
http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org

--
Mark C. Miller, Lawrence Livermore National Laboratory
<<<<<<<<<<<<<<<<!!LLNL BUSINESS ONLY!!>>>>>>>>>>>>>>>>
miller86@llnl.gov urgent: miller86@pager.llnl.gov
T:8-6 (925)-423-5901 M/W/Th:7-12,2-7 (530)-753-8511

Would you be interested in XML or JSON snippets rather than clunky BNF?

G.

···

-----Original Message-----
From: hdf-forum-bounces@hdfgroup.org [mailto:hdf-forum-bounces@hdfgroup.org]
On Behalf Of John K
Sent: Thursday, July 26, 2012 1:20 PM
To: HDF Users Discussion List
Subject: [Hdf-forum] request/suggestion re: high level libraries and
debugging

It occurs to me that the h5dump program does a lot of stuff that would be
really useful to have in library code. As an example, I was running into a
problem today that I suspected was due to a type definition that was in use
incorrectly. I was ultimately able to confirm my suspicion by reading code,
but during that search I thought it'd be really handy to have a function
that I could use to dump out the structure of the data type to some output
stream or other.

h5dump already does what I was interested in, but it's not library code and
would be difficult to integrate into my program to look at the definition of
a type that's only defined in memory.

Anyway, I thought it'd be super useful to have some of this code in h5dump
moved into a high level library for debugging (or other) purposes.

_______________________________________________
Hdf-forum is for HDF software users discussion.
Hdf-forum@hdfgroup.org
http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org

John,

Do you think this High-Level function H5LTdtype_to_text would help? See http://www.hdfgroup.org/HDF5/doc/HL/RM_H5LT.html#H5LTdtype_to_text ?

Elena

···

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Elena Pourmal The HDF Group http://hdfgroup.org
1800 So. Oak St., Suite 203, Champaign IL 61820
217.531.6112
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

On Jul 26, 2012, at 1:19 PM, John K wrote:

It occurs to me that the h5dump program does a lot of stuff that would be really useful to have in library code. As an example, I was running into a problem today that I suspected was due to a type definition that was in use incorrectly. I was ultimately able to confirm my suspicion by reading code, but during that search I thought it'd be really handy to have a function that I could use to dump out the structure of the data type to some output stream or other.

h5dump already does what I was interested in, but it's not library code and would be difficult to integrate into my program to look at the definition of a type that's only defined in memory.

Anyway, I thought it'd be super useful to have some of this code in h5dump moved into a high level library for debugging (or other) purposes.

_______________________________________________
Hdf-forum is for HDF software users discussion.
Hdf-forum@hdfgroup.org
http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org

I don't think the default output of h5dump is really BNF... That said, for the aforementioned purposes of providing debugging output I think the default output format of h5dump is far more useful than XML. I presume JSON would also fall into the "less useful" category, though I didn't really know what it was until a minute ago.

I'm more interested in something that I can read, rather than something that a machine can read, and XML has so much additional overhead that I find it difficult to process visually. The current default output of h5dump is much better in that regard.

···

On 07/26/2012 01:28 PM, Gerd Heber wrote:

Would you be interested in XML or JSON snippets rather than clunky BNF?

G.

-----Original Message-----
From: hdf-forum-bounces@hdfgroup.org [mailto:hdf-forum-bounces@hdfgroup.org]
On Behalf Of John K
Sent: Thursday, July 26, 2012 1:20 PM
To: HDF Users Discussion List
Subject: [Hdf-forum] request/suggestion re: high level libraries and
debugging

It occurs to me that the h5dump program does a lot of stuff that would be
really useful to have in library code. As an example, I was running into a
problem today that I suspected was due to a type definition that was in use
incorrectly. I was ultimately able to confirm my suspicion by reading code,
but during that search I thought it'd be really handy to have a function
that I could use to dump out the structure of the data type to some output
stream or other.

h5dump already does what I was interested in, but it's not library code and
would be difficult to integrate into my program to look at the definition of
a type that's only defined in memory.

Anyway, I thought it'd be super useful to have some of this code in h5dump
moved into a high level library for debugging (or other) purposes.

_______________________________________________
Hdf-forum is for HDF software users discussion.
Hdf-forum@hdfgroup.org
http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org

_______________________________________________
Hdf-forum is for HDF software users discussion.
Hdf-forum@hdfgroup.org
http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org

Yeah, actually. I was unaware of that particular call. That said, that function is obviously limited to data types and operates on buffers, rather than on streams. At least for the debugging use case, having the output go to a stream would be more useful, IMO, thereby eliminating the overhead of having to allocate and free a temporary buffer.

For now I'll try to remember that function exists should the need come up again.

···

On 07/26/2012 02:05 PM, Elena Pourmal wrote:

John,

Do you think this High-Level function H5LTdtype_to_text would help? See http://www.hdfgroup.org/HDF5/doc/HL/RM_H5LT.html#H5LTdtype_to_text ?

Elena
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Elena Pourmal The HDF Group http://hdfgroup.org
1800 So. Oak St., Suite 203, Champaign IL 61820
217.531.6112
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

On Jul 26, 2012, at 1:19 PM, John K wrote:

It occurs to me that the h5dump program does a lot of stuff that would be really useful to have in library code. As an example, I was running into a problem today that I suspected was due to a type definition that was in use incorrectly. I was ultimately able to confirm my suspicion by reading code, but during that search I thought it'd be really handy to have a function that I could use to dump out the structure of the data type to some output stream or other.

h5dump already does what I was interested in, but it's not library code and would be difficult to integrate into my program to look at the definition of a type that's only defined in memory.

Anyway, I thought it'd be super useful to have some of this code in h5dump moved into a high level library for debugging (or other) purposes.

_______________________________________________
Hdf-forum is for HDF software users discussion.
Hdf-forum@hdfgroup.org <mailto:Hdf-forum@hdfgroup.org>
http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org

_______________________________________________
Hdf-forum is for HDF software users discussion.
Hdf-forum@hdfgroup.org
http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org