Thanks @minching for trying this. Just to be 100% sure. What happens if the two files reside in a directory on a local drive such as C:? That, presumably, works fine, which means there’s something weird going on here. Presumably h5py gets the file names via H5Fget_name on the IDs, which seems to suggest that the library is not confused as far as file handles go, and maybe a few wires are crossed in h5py? G.
Thank you @gheber. Yes, if the two files are in the local drive this doesn’t happen. But in my case I need to work continuesly with multilple GB size files residing on supercomputers, moving them to the local drive everytime is quite time and disk space consuming.
Do you feel comfortable to write a little C program that goes throught the same exercise? That way we could eliminate Python as a source and get a new data point. (The fact that MATLAB doesn’t show the problem suggests that the C program will behave just fine, but we won’t know until we try.) If you can’t, I’ll write a little test this afternoon and pass it on. G.
Thanks for trying this. It appears that, at least for this simple example, the C-library can tell the two files and objects apart. It’s too simple though to conclude that the problem is with h5py. Maybe we have to dig a little deeper into your setup. Can you describe in a little more detail your sshfs / Google drive setup? Are you using Cygwin or WSL? G.
I set up my sshfs mounted folder following exactly this tutorial: https://www.youtube.com/watch?v=uiXOuxdadms
I am using windows 10 Home, build version 10.0.18363.
I haven’t tried with google drive, the post on stackoverflow I linked above it’s not mine, but perfectly resembles my problem, so I guess you could use that setup to reproduce more easily the problem.
Hi, do you find solution for your problem?
I have the same error in the same condition with c++ hdf5:
One open file:
file1.h5 -> data1
file2.h5 -> data2
Two open files:
file1.h5 -> data1
file2.h5 -> data1