cpyquickhelper.fastdata

cpyquickhelper.fastdata.df2array (df, check = True)

Converts a dataframe into a numpy.array without copying. pandas is merging consecutive columns sharing the same type into one memory block. The function can be used only if the data is stored in one block and one type as a consequence.

cpyquickhelper.fastdata.df2arrays (df, sep = ‘,’, check = True)

Converts a dataframe into a list of a list of tuple (column name, :epkg:`numpy:array`) without copying. pandas is merging consecutive columns sharing the same type into one memory block. That’s what the function extracts