(group) order not preserved
See original GitHub issueWhen inserting data into an h5py file object, the order is not preserved. The items (here: groups) are rather ordered alphabetically:
import h5py
with h5py.File("out.h5", "w") as f:
a = f.create_group("b")
b = f.create_group("a")
with h5py.File("out.h5", "r") as f:
print(f.keys())
Output:
<KeysViewHDF5 ['a', 'b']>
Expected output:
<KeysViewHDF5 ['b', 'a']>
I don’t know if this is a property of HDF5, a problem of the reader. or a problem of the writer.
Issue Analytics
- State:
- Created 4 years ago
- Comments:10 (7 by maintainers)
Top Results From Across the Web
Python Pandas: Is Order Preserved When Using groupby() ...
See this enhancement issue. The short answer is yes, the groupby will preserve the orderings as passed in. You can prove this by...
Read more >SQL Preserve the Order in group by
If you do not specify an order by for the result set of your first query then your data is not guaranteed to...
Read more >Solved: preserve order when using Table.Group
As documented, Table.Group "cannot guarantee to return a fixed order of rows". While this is bad for sorted data when used with Text....
Read more >Group by preserving the order
I have to group by preserving the order. with t as ( select 1 as col1, 5 as col2, 1 as col3 from...
Read more >Group by: split-apply-combine
For Python 3.5 and earlier, the order of **kwargs in a functions was not preserved. This means that the output column ordering would...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Hi guys, track_order works for me if instead of writing f.keys() I write f[“/”].keys()
So it does. @aparamon, can you take a look? I can reproduce it with 1.10.4.