I need to process a CSV file with ~12 million rows. Each row has ~20 columns. Currently using pandas:
df = pd.read_csv('huge_file.csv')
result = df.groupby('category').sum()
This loads everything into memory and crashes on my 8GB machine. What are the best alternatives? I've heard about chunking and Polars but not sure which to start with.
Carlos Ribeiro
asked 2 months ago1
Answers116
Upvotes11200
ViewsI'm building a web scraper that needs to handle 1000+ URLs concurrently. I've read about three approaches:
My task is HTTP requests (I/O-bound). Is asyncio always the right choice? What's the overhead comparison?
1
Answers21
Upvotes7600
Views