Skip to content

Instantly share code, notes, and snippets.

@2tony2
Created July 5, 2024 16:09
Show Gist options
  • Select an option

  • Save 2tony2/7e06961c3b248eeaa68a3a5e4e79fca0 to your computer and use it in GitHub Desktop.

Select an option

Save 2tony2/7e06961c3b248eeaa68a3a5e4e79fca0 to your computer and use it in GitHub Desktop.
import pandas as pd
# Example of reading a CSV file in chunks with Pandas
chunk_size = 1000
for chunk in pd.read_csv('large_file.csv', chunksize=chunk_size):
process(chunk) # Replace with your processing logic
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment