Hello Mark,
Thanks for the quick reply. I am Indeed using H5Aiterate2. Here is the
sample code for reference.
H5Aiterate2(id, H5_INDEX_CRT_ORDER, H5_ITER_INC, NULL, iterate_attributes,
&parent_group);
Here is the callback method implementation.
herr_t iterate_attributes(hid_t group_id, const char *attribute_name,
const H5A_info_t *ainfo, void *pgroup) {
hid_t attribute_id = H5Aopen_name(group_id, attribute_name
);
}
The only way I can see how to open the Attribute is to call the
H5Aopen_name();
Thanks,
Deepak Kumar
From: "Miller, Mark C." <[email protected]>
To: HDF Users Discussion List <[email protected]>
Date: 07/13/2017 12:20 PM
Subject: Re: [Hdf-forum] H5Aopen_name() is taking almost 11 minutes
to read 56000 attributes and 3200 groups.
Sent by: "Hdf-forum" <[email protected]>
Hmm. That *does* sound really bad.
I don't have a lot of experience with attributes but am wondering about
H5Aiterate.
Would using that approach to accessing your attribute data improve
performance?
Reason I think it could possibly is that it wouldn't be constantly be
having to map an attribute name and if you are opening most of the
attributes on a given object, iterating them might go faster. But, that is
only a guess.
Mark
"Hdf-forum on behalf of Deepak 8 Kumar" wrote:
Hello!
I have a HDF5 based application to read the hdf5 file which has almost
3200 groups and 56000 attributes. The application is using the standard
hdf5 api and it took almost 11 minutes to read only the groups and
attributes. I used StopWatch and observed that H5Aopen_name() is taking
almost 97 percent of the total time. I am using HDF 1.10.1 Windows10 x64.
My question is that is this the expected behavior here with H5Aopen_name()
or I am not reading it properly?
What approach we should take in this kind of file with large number of
attributes?
Any insight is greatly appreciated.
Thanks,
Deepak Kumar _______________________________________________
Hdf-forum is for HDF software users discussion.
[email protected]
https://urldefense.proofpoint.com/v2/url?u=http-3A__lists.hdfgroup.org_mailman_listinfo_hdf-2Dforum-5Flists.hdfgroup.org&d=DQICAg&c=p0oa49nxxGtbbM2qgM-GB4r4m9OlGg-sEp8sXylY2aQ&r=aVpsmDSm2bBgznM4DES61bNo7E_uMhhiIutsE14aYRg&m=M1dgdSv4QChcMTvMIHcWUfXREyf2RqqhkBLh4ZSr2JU&s=c28-Rp-JEqKrjEL4WSUjG6zkVcwjqnw0NibVNiBbLT4&e=
Twitter:
https://urldefense.proofpoint.com/v2/url?u=https-3A__twitter.com_hdf5&d=DQICAg&c=p0oa49nxxGtbbM2qgM-GB4r4m9OlGg-sEp8sXylY2aQ&r=aVpsmDSm2bBgznM4DES61bNo7E_uMhhiIutsE14aYRg&m=M1dgdSv4QChcMTvMIHcWUfXREyf2RqqhkBLh4ZSr2JU&s=93qmyGzSXSFGMj6BrwNdK40xApoMV54Hde5LvTpyKrY&e=
_______________________________________________
Hdf-forum is for HDF software users discussion.
[email protected]
http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org
Twitter: https://twitter.com/hdf5