Jul-16-2019, 11:06 AM
Hi all,
I was wondering if there is a way to save a CSV file as a python object in order to be read in to python quicker. The reason I am cocnerned about this is is that some of the CSV files i hold contain many thousands (10's to 100's of columns) plus many rows of features, ~30,000.
Now having the CSV file itself is not an issue.. but its bulky and takes some time to read in to python.
In r, these can be saved as an rds or r object.. which although they hold the same CSV file, the load time in to R is almost instant. Reading in the CSV file itself in to R takes a good 20-30 seconds.
Is there an equivalent for this in python as I will be reading in a lot of CSV files in to python, so having an object with CSV data would be useful if it means reading in is much faster.
Any advice would be appreciated. Thank you!
Amir
I was wondering if there is a way to save a CSV file as a python object in order to be read in to python quicker. The reason I am cocnerned about this is is that some of the CSV files i hold contain many thousands (10's to 100's of columns) plus many rows of features, ~30,000.
Now having the CSV file itself is not an issue.. but its bulky and takes some time to read in to python.
In r, these can be saved as an rds or r object.. which although they hold the same CSV file, the load time in to R is almost instant. Reading in the CSV file itself in to R takes a good 20-30 seconds.
Is there an equivalent for this in python as I will be reading in a lot of CSV files in to python, so having an object with CSV data would be useful if it means reading in is much faster.
Any advice would be appreciated. Thank you!
Amir