radioML / dataset

Open RadioML Synthetic Benchmark Dataset
244 stars 140 forks source link

When uploading the RML 2016a Data set shows Error #26

Open sudhirrt10 opened 5 years ago

sudhirrt10 commented 5 years ago

Hello When Try to import the data set which is in .pkl format in python 3.7 it shows error

Annotation 2019-09-20 183654
roman-popenov commented 3 years ago

You need to specify encoding. I believe it's a byte string for python 3.7. You can try something like this:

    def load_dataset_with_pickle(self):
        with io.open(self.file, "rb") as datasetFile:
            unpickler = pickle.Unpickler(datasetFile, encoding='bytes')

            return unpickler.load()