group/dataset sequence

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

group/dataset sequence

674438511
Hi,

I am a newer to HDF5. I have a question, and didn't find the solution on internet. Could you help me? Thanks.

I create three group named "fileHead" "auxiliaryInfo" "observationData" in sequence. But the HDFView show is  "auxiliaryInfo" "fileHead" "observationData" by alphabet. I want to show by the creation sequence. So what should I do when I create these groups?
The dataset is also has this phenomenon.

Thanks for your help.

HaijunYu



 



 



 


_______________________________________________
Hdf-forum is for HDF software users discussion.
[hidden email]
http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org
Twitter: https://twitter.com/hdf5
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: group/dataset sequence

bljones

Hello Haijun,

 

The HDFView tool allows you to change the order that groups are displayed. This is a property in the file that can be modified.

However, please note that the property  must be set when the file is created in order to change the display order in HDFView.

 

To change the order in HDFView, select the “Tools” drop down menu and then select “User Options”.

A “User Options” window will pop up.  At the bottom of the window you will see “Display Indexing Options”. You have the choice of

selecting “By Name” or “By Creation Order”. You must close the file and reopen it for the changes to take place.

 

To change the order that groups are displayed in the file you use the Group Creation Property API, H5Pset_link_creation_order.

For example, you would create an instance of the Group Creation Property, modify it by calling H5Pset_link_creation_order, and

then pass that into the H5Gcreate call (in the group creation property parameter):

 

gcpl = H5Pcreate (H5P_GROUP_CREATE);

                status = H5Pset_link_creation_order( gcpl, H5P_CRT_ORDER_TRACKED |

                                H5P_CRT_ORDER_INDEXED );

group = H5Gcreate (file, "index_group", H5P_DEFAULT, gcpl, H5P_DEFAULT);

                …

status = H5Pclose (gcpl);

 

There are the H5Literate* and H5visit/H5Ovisit APIs for traversing the objects in a file. You can specify the index to be used (by name or by creation

order).

 

On the Examples page you can find many  different examples. See:

                https://www.hdfgroup.org/HDF5/examples/

 

Please look at the examples “By API” for examples of modifying the group creation order and traversing a file.

 

Specifically for C examples By API, look under the “Groups:” section:

                https://www.hdfgroup.org/HDF5/examples/api18-c.html#grps

 

On this page see the following examples:

 

To track links in a group by creation order, see:   h5ex_g_corder.c

This example also shows how to traverse a group by creation order and by name.

 

To traverse a file also see:

 

h5ex_g_iterate.c

h5ex_g_traverse.c

h5ex_g_visit.c

 

Examples “By API” are also provided for other languages (Fortran, Java, …) from the Examples page.

 

Let me know if you have further questions!

 

-Barbara

[hidden email]

 

 

 

From: Hdf-forum [mailto:[hidden email]] On Behalf Of ???
Sent: Thursday, June 23, 2016 8:11 PM
To: [hidden email]
Subject: [Hdf-forum] group/dataset sequence

 

Hi,

 

I am a newer to HDF5. I have a question, and didn't find the solution on internet. Could you help me? Thanks.

 

I create three group named "fileHead" "auxiliaryInfo" "observationData" in sequence. But the HDFView show is  "auxiliaryInfo" "fileHead" "observationData" by alphabet. I want to show by the creation sequence. So what should I do when I create these groups?

The dataset is also has this phenomenon.

 

Thanks for your help.

 

HaijunYu

 

 

 

 

 

 

 


_______________________________________________
Hdf-forum is for HDF software users discussion.
[hidden email]
http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org
Twitter: https://twitter.com/hdf5
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: group/dataset sequence

674438511

   Wonderful! Thank barbara for your help. It solved my problem.


At 2016-06-28 23:36:43, "Barbara Jones" <[hidden email]> wrote:

Hello Haijun,

 

The HDFView tool allows you to change the order that groups are displayed. This is a property in the file that can be modified.

However, please note that the property  must be set when the file is created in order to change the display order in HDFView.

 

To change the order in HDFView, select the “Tools” drop down menu and then select “User Options”.

A “User Options” window will pop up.  At the bottom of the window you will see “Display Indexing Options”. You have the choice of

selecting “By Name” or “By Creation Order”. You must close the file and reopen it for the changes to take place.

 

To change the order that groups are displayed in the file you use the Group Creation Property API, H5Pset_link_creation_order.

For example, you would create an instance of the Group Creation Property, modify it by calling H5Pset_link_creation_order, and

then pass that into the H5Gcreate call (in the group creation property parameter):

 

gcpl = H5Pcreate (H5P_GROUP_CREATE);

                status = H5Pset_link_creation_order( gcpl, H5P_CRT_ORDER_TRACKED |

                                H5P_CRT_ORDER_INDEXED );

group = H5Gcreate (file, "index_group", H5P_DEFAULT, gcpl, H5P_DEFAULT);

                …

status = H5Pclose (gcpl);

 

There are the H5Literate* and H5visit/H5Ovisit APIs for traversing the objects in a file. You can specify the index to be used (by name or by creation

order).

 

On the Examples page you can find many  different examples. See:

                https://www.hdfgroup.org/HDF5/examples/

 

Please look at the examples “By API” for examples of modifying the group creation order and traversing a file.

 

Specifically for C examples By API, look under the “Groups:” section:

                https://www.hdfgroup.org/HDF5/examples/api18-c.html#grps

 

On this page see the following examples:

 

To track links in a group by creation order, see:   h5ex_g_corder.c

This example also shows how to traverse a group by creation order and by name.

 

To traverse a file also see:

 

h5ex_g_iterate.c

h5ex_g_traverse.c

h5ex_g_visit.c

 

Examples “By API” are also provided for other languages (Fortran, Java, …) from the Examples page.

 

Let me know if you have further questions!

 

-Barbara

[hidden email]

 

 

 

From: Hdf-forum [mailto:[hidden email]] On Behalf Of ???
Sent: Thursday, June 23, 2016 8:11 PM
To: [hidden email]
Subject: [Hdf-forum] group/dataset sequence

 

Hi,

 

I am a newer to HDF5. I have a question, and didn't find the solution on internet. Could you help me? Thanks.

 

I create three group named "fileHead" "auxiliaryInfo" "observationData" in sequence. But the HDFView show is  "auxiliaryInfo" "fileHead" "observationData" by alphabet. I want to show by the creation sequence. So what should I do when I create these groups?

The dataset is also has this phenomenon.

 

Thanks for your help.

 

HaijunYu

 

 

 

 

 

 

 



 


_______________________________________________
Hdf-forum is for HDF software users discussion.
[hidden email]
http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org
Twitter: https://twitter.com/hdf5
Loading...