File name having japanese characters

Need to read file with name contains Japanese characters. API H5FOpen failing. Any known work around to solve this issue?

Saw similar ques but pretty old thread.So, posting again.


Is this on Windows or on a POSIX-y system like Linux?

Unfortunately HDF5 does not properly support non-ASCII filenames. It’s not an easy task with newer libraries because against their own policy HDF5 developers use the filename although they shouldn’t. I am not sure this has been fixed in later versions though.

Here’s how I fixed it in earlier (1.8.x) versions:

  1. Internal convention: use utf-8

  2. Replace the read/write functions of the low level drivers with ones that use for Windows and Linux utf8/utf16 compliant OS calls with appropriate conversions

I am working on windows

Unfortunately, we do not support non-ASCII filenames on Windows at this time.

HDF5 doesn’t support the unicode characters. The workaround to open the hdf file is to convert the path(with japanese characters) into the shortpath and you can open the file.