Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8651993
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T14:12:13+00:00 2026-06-12T14:12:13+00:00

I have been trying to process a good chunk of data (a few GBs)

  • 0

I have been trying to process a good chunk of data (a few GBs) but my personal computer resists to do it in a reasonable time span, so I was wondering what options do I have? I was using python’s csv.reader but it was painfully slow even to fetch 200,000 lines. Then I migrated this data to an sqlite database which retrieved results a bit faster and without using so much memory but slowness was still a major issue.

So, again… what options do I have to process this data? I was wondering about using amazon’s spot instances which seem useful for this kind of purpose but maybe there are other solutions to explore.

Supposing that spot instances is a good option and considering I have never used them before, I’d like to ask what can I expect from them? Does anyone have experience using them for this kind of thing? If so, What is your workflow? I thought I could find a few blog posts detailing workflows for scientific computing, image processing or that kind of thing but I didn’t find anything so if you can explain a bit of that or point out some links, I’d appreciate it.

Thanks in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T14:12:15+00:00Added an answer on June 12, 2026 at 2:12 pm

    I would try to use numpy to work with your large datasets localy. Numpy arrays should use less memory compared csv.reader and computation times should be much faster when using vectorised numpy functions.

    However there may be a memory problem when reading the file.
    numpy.loadtxt or numpy.genfromtxt also consume a lot of memory when reading files.
    If this is a problem some (brand new) alternative parser engines are compared here. According to this post, the new pandas (a library which is built on top of numpy) parser seems to be an option.

    As mentioned in the comments I would also suggest to store your data in a binary format like HDF5 when you have read your files once. Loading the data from a HDF5 file is really fast from my experience (would be interesting to know how fast it is compared to sqlite in your case). The simplest way I know to save your array as HDF5 is with pandas

    import pandas as pd
    
    data = pd.read_csv(filename, options...)
    store = pd.HDFStore('data.h5')
    store['mydata'] = data
    store.close()
    

    loading your data is than as simple as

    import pandas as pd
    
    store = pd.HDFStore('data.h5')
    data = store['mydata']
    store.close()
    
     
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I just wasted invested a good chunk of time trying to determine why a
I have been trying to get a form in HTML/PHP to process to into
I have been trying to get this to work with several tutorials/answers here, but
I have been trying to connect sphinx server with nodejs and limestone module. But
I have been trying to optimize some code which handles raw pixel data. Currently
I've been looking around the net for a good few hours now, trying to
I have been trying to use the command to rollback the last process of
I have been trying to find a good definition, and get an understanding, of
Lately, I have been trying to automate our build process on Amazon EC2 and
Have been trying to encrypt an xml file to a string so that I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.