h5edit failed to open attribute

h5edit passed all checks during installation but i don't manage to modify my own h5 file:

h5edit -c "MODIFY /Output/Model/Fm {1.7};" myfile.h5

results in:

failed to open attribute /Output/Model/Fm
failed to get the definition of old attribute Fm

But i know from hdfview that Fm exists in /Output/Model/

I also can't DELETE /Output/Model.

I ran h5check without errors.

Has somebody an idea about this?

Thanks,

Thomas

Thomas,

Is it possible for you to give me a copy of your data file?
You can ftp to
"ftp://ftp.hdfgroup.uiuc.edu/pub/incoming/acheng/ "

If it is not available, can you send me the output of h5dump on the data file,
$ h5dump -p -H myfile.h5

Thanks.

-Albert Cheng
THG Staff

···

On Oct 22, 2013, at 9:47 AM, "Zander, Thomas" <thomas.zander@charite.de> wrote:

h5edit passed all checks during installation but i don't manage to modify my own h5 file:

h5edit -c "MODIFY /Output/Model/Fm {1.7};" myfile.h5

results in:

failed to open attribute /Output/Model/Fm
failed to get the definition of old attribute Fm

But i know from hdfview that Fm exists in /Output/Model/

I also can't DELETE /Output/Model.

I ran h5check without errors.

Has somebody an idea about this?

Thanks,

Thomas

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

Hi Albert,

thanks for your reply. I uploaded myfile.h5. In fact the command i used was meant as example.
More specific it is:
h5edit -c "MODIFY /Output/Model/HumanModel/Right/Leg/Mus/AdductorBrevisDistal1 Fm {0.111}; " myfile.h5
Hope the file is not too large (35MB).

Thanks,

Thomas

···

On 22.10.2013 19:46, Albert Cheng wrote:

Thomas,

Is it possible for you to give me a copy of your data file?
You can ftp to
"ftp://ftp.hdfgroup.uiuc.edu/pub/incoming/acheng/"

If it is not available, can you send me the output of h5dump on the data file,
$ h5dump -p -H myfile.h5

Thanks.

-Albert Cheng
THG Staff

On Oct 22, 2013, at 9:47 AM, Thomas Zander wrote
  

h5edit passed all checks during installation but i don't manage to modify my own h5 file:

h5edit -c "MODIFY /Output/Model/Fm {1.7};" myfile.h5

results in:

failed to open attribute /Output/Model/Fm
failed to get the definition of old attribute Fm

But i know from hdfview that Fm exists in /Output/Model/

I also can't DELETE /Output/Model.

I ran h5check without errors.

Has somebody an idea about this?

Thanks,

Thomas

Hi Barbara and Albert,

thanks for your helpful informations.
I managed to modify/write the desired values to my h5-file with a small c application. I took the output from h5diff and used H5Dwrite to overwrite the datasets.
Thanks a lot,

Thomas

···

On 23.10.2013 19:10, help@hdfgroup.org wrote:

Hi Thomas,

Could you write a small application that reads the dataset, and writes
out the correct values?

We have a "Learning the Basics" tutorial here,
    http://www.hdfgroup.org/HDF5/Tutor/introductory.html

The "Reading From and Writing To a Dataset" topic discusses how to
read and write to a dataset:

    http://www.hdfgroup.org/HDF5/Tutor/rdwt.html

We provide example programs in the tutorials, and they can also be found
on this page (including user-contributed Mathematica examples and wrappers):

     http://www.hdfgroup.org/HDF5/examples/intro.html

The HDF Group provides the C, Fortran, C++, and Java wrappers. If you need
help installing HDF5 or HDF-Java, I can help with that.

Python requires h5py. See this page for information on that:

     http://www.h5py.org/

-Barbara

====================
Barbara Jones
The HDF Helpdesk

The HDF Group
help@hdfgroup.org

(I Cc our help desk in case there is other information they can offer.)

At the moment, there are two tools, h5view and h5import, that may help your needs.
You can check to see if they may meet your needs.

Meanwhile, we are looking for funding to add more features to the h5edit tool.
If you know of any possible source, please let us know.

-Albert

On Oct 23, 2013, at 9:26 AM, Thomas Zander wrote:

Hi Albert,

oops, i know about the h5 format no longer than few days. I just wanted to change the 0.559344 to another value. Can't i use h5edit for this?

In fact this wish comes from another one: I want to have a h5 file which contains the difference of two other h5 files (the difference of all Fm values they contain). There are several hundred Fm values in the two h5 files as reported from h5diff. Their structures are identical. I wanted to use the output of the h5diff to create a script which changes the Fm values in a copy of one of the two h5 files with the help of h5edit. The h5 files are from another software which i can't modify.
Do you know another command line solution for this problem?

Thanks,

Thomas

On 23.10.2013 16:02, Albert Cheng wrote:

Hi Thomas,

I did an h5dump on the file.
I found /Output/Model/HumanModel/Right/Leg/Mus/AdductorBrevisDistal1/Fm as a dataset,
not as an attribute of a group or a dataset. H5edit currently edits attributes only.
It does not edit datasets yet.

Did you misunderstand what h5edit does or did I miss attribute "Fm"?

HDF5 "myfile.h5" {
GROUP "/Output/Model/HumanModel/Right/Leg/Mus/AdductorBrevisDistal1" {

    DATASET "Fm" {
       DATATYPE H5T_IEEE_F64LE
       DATASPACE SIMPLE { ( 1 ) / ( 1 ) }
       DATA {
       (0): 0.559344
       }

On Oct 23, 2013, at 12:49 AM, Thomas Zander wrote:

Hi Albert,

thanks for your reply. I uploaded myfile.h5. In fact the command i used was meant as example.
More specific it is:
h5edit -c "MODIFY /Output/Model/HumanModel/Right/Leg/Mus/AdductorBrevisDistal1 Fm {0.111}; " myfile.h5
Hope the file is not too large (35MB).

Thanks,

Thomas

On 22.10.2013 19:46, Albert Cheng wrote:

Thomas,

Is it possible for you to give me a copy of your data file?
You can ftp to
"ftp://ftp.hdfgroup.uiuc.edu/pub/incoming/acheng/"

If it is not available, can you send me the output of h5dump on the data file,
$ h5dump -p -H myfile.h5

Thanks.

-Albert Cheng
THG Staff

On Oct 22, 2013, at 9:47 AM, Thomas Zander wrote

h5edit passed all checks during installation but i don't manage to modify my own h5 file:

h5edit -c "MODIFY /Output/Model/Fm {1.7};" myfile.h5

results in:

failed to open attribute /Output/Model/Fm
failed to get the definition of old attribute Fm

But i know from hdfview that Fm exists in /Output/Model/

I also can't DELETE /Output/Model.

I ran h5check without errors.

Has somebody an idea about this?

Thanks,

Thomas