I have a pkl file from MNIST dataset, which consists of handwritten digit images.
I\'d like to take a look at each of those digit images, so I need to unpack the pkl fil
Handy one-liner
pkl() ( python -c 'import pickle,sys;d=pickle.load(open(sys.argv[1],"rb"));print(d)' "$1" ) pkl my.pkl
Will print __str__ for the pickled object.
__str__
The generic problem of visualizing an object is of course undefined, so if __str__ is not enough, you will need a custom script.