[b]"What's the best way to read pd dataframe from local in Python?"[/b] or [b]"How do I read pd dataframe from loc

16 Replies, 1393 Views

Yo, CSV is slow af for big files.

Try `pd.read_csv(..., usecols=[...])` to only load the columns you need. Saves memory + time.

Also, set `dtypes` manually if you know them—stops pandas from guessing (which is slow).

For Excel, openpyxl is faster than xlrd for newer .xlsx files.

Messages In This Thread



Users browsing this thread: 1 Guest(s)