Read file line by line

I used the excellent genfromtxt function to test.
But on real data, my file is very large and a memory error occurs.
How can I read a file line by line into an array, so that I can use the [;] section?



What do you mean by [;] section?
If you want to read the file in chunks, you could probably use this method.
Alternatively, you could use pd.read_csv with the chunksize argument.