I've written a short Python script to read in a 12GB file:
start = time.time()
my_file = open('my_12GB_file.txt', 'rb')
my_file_lines = set(my_file.readlines())
end = time.time()
print "Time elapsed: %r" % (end - start)
my_file.close()
The script reads in the file, prints time elapsed, and then stalls (as if it has entered an infinite loop). Any ideas about what could be going wrong?
Update:
Program terminated after I changed:
my_file_lines = set(my_file.readlines())
to
my_file_lines = my_file.readlines()