>>> unpickled_df = pd.read_pickle("./dummy.pkl")
>>> unpickled_df
foo bar
0 0 5
1 1 6
2 2 7
3 3 8
4 4 9
# use pickle format to save columns with complex data (like list)
# and keep their structure
>>> original_df = pd.DataFrame({"foo": range(5), "bar": range(5, 10)})
>>> original_df
foo bar
0 0 5
1 1 6
2 2 7
3 3 8
4 4 9
>>> original_df.to_pickle("./dummy.pkl") # use read_pickle to read the dataframe
# save and load of DataFrames
dateiTraining = "daten/Training.zip"
trainDataFrame.to_pickle( self.dateiTraining )
if ( os.path.exists( dateiTraining ) ):
testDataFrame = panda.read_pickle( dateiTraining )