File name having japanese characters


#1

Hi,
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.

Thanks.
Sateesh


#2

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


#3

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


#4

I am working on windows


#5

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


#6

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.