def unpickle(fname):
 with smart_open(fname, 'rb') as f:
  if (sys.version_info > (3, 0)):
   return _pickle.load(f, encoding='latin1')
  else:
   return _pickle.loads(f.read())

def unpickle ( fname ) : with smart_open ( fname , 'rb' ) as f : if ( sys . version_info > ( 3 , 0 ) ) : return _pickle . load ( f , encoding = 'latin1' ) else : return _pickle . loads ( f . read ( ) )
load pickled object from fname .