MGXS File Type Problem

I used dump_to_file command and created a file in .pkl format. Files in the OpenMC tells me that the command Library.load_from_file will be reading my .pkl formatted file. But when I try to do that I face the error of NOT AN HDF5 FILE. But the back end files of OpenMC tells me that what I am trying to do is possible. I am really confused can someone please help me?