Re: readAsciiTable memory problem

From: Mary Haley <haley_at_nyahnyahspammersnyahnyah>
Date: Wed Sep 12 2012 - 10:21:24 MDT

Dear Yongfei,

Under the hood, readAsciiTable is reading the table and then writing a temporary file
to a directory like /tmp without the header information, and then reading this temporary
file back in. It does remove this temporary file before leaving the function.
It's also generating some string arrays, which can be expensive if you are doing this a lot.

If you can send me some examples of your ASCII files, there might be another
way to read them without using readAsciiTable, and hence avoiding the writing
of that temporary file.

By they way, how many is "a bunch"? :-)

--Mary

On Sep 12, 2012, at 9:10 AM, Yongfei wrote:

> Dear all,
>
> I need to read a bunch of ascii files, so I looped over the files and
> read the data from each file into one matrix. As it goes on, it
> takes more and more time to read one single file. I'm wondering what's
> going on here. Is there any temporary variable that is causing the
> memory issue? Has anyone met the same problem before? Thanks!
>
> Best,
> Yongfei
>
> --
> Yongfei Zhang
> Jackson School of Geosciences
> The University of Texas at Austin
> Austin, Texas 78712
> Email: yfzhang.nju@gmail.com
> yongfei@utexas.edu
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Wed Sep 12 10:21:33 2012

This archive was generated by hypermail 2.1.8 : Thu Sep 13 2012 - 14:22:31 MDT