the biggest problem I see is this:
While NOT mstmInputStream.EOF
mstrTemp = Trim(mstmInputStream.ReadLine)
mstrSequence = mstrSequence + mstrTemp
Wend
This is probably what is costing you big time. try changing mstrTemp to an
array of string that you keep appending to, and that you will join at the
end.
Math
On 11/29/06, Burke Squires <[EMAIL PROTECTED]> wrote:
Hello all,
For a class project I am programming a basic hidden markov model
project. I need to read a text with with string in it with a total
size of about 5 megabytes. The file loading seems VERY slow...is there
anyway to speed it up? Am I doing something wrong?
If mfldInputFile <> Nil Then
txtPath(0).Text = mfldInputFile.AbsolutePath
mstmInputStream = mfldInputFile.OpenAsTextFile
While NOT mstmInputStream.EOF
mstrTemp = Trim(mstmInputStream.ReadLine)
mstrSequence = mstrSequence + mstrTemp
Wend
cHMM.SetSequence(mstrSequence)
End If
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>