[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: Plotting with 3.2.0 on Windows is SLOOOOOOWWWW
From: |
Tatsuro MATSUOKA |
Subject: |
RE: Plotting with 3.2.0 on Windows is SLOOOOOOWWWW |
Date: |
Wed, 5 Aug 2009 09:27:19 +0900 (JST) |
Sorry
I have manually change the code
and
> > ! if (isempty (str))
Is forgotten.
octave.exe:11>for i = 1:n*m
> x = rand (2,N);
> subplot (n,m,i);
> plot (x(1,:),x(2,:));
> end
octave.exe:12>cputime()-ts
ans = 0.76563
octave.exe:13>
octave.exe:13>N = 100;
octave.exe:14>n = 2;
octave.exe:15>m = 2;
octave.exe:16>tic
octave.exe:17>for i = 1:n*m
> x = rand (2,N);
> subplot (n,m,i);
> plot (x(1,:),x(2,:));
> end
octave.exe:18>toc
Elapsed time is 3.2813 seconds.
cputime is surely reduced on the computer in my university (cpu is HT-pentium).
I will test again at home.
Regards
Tatsuro
I will check again at home
Regards.
--- Tatsuro MATSUOKA wrote:
> Hello
>
> --- Olli Saarela wrote:
>
> > I was looking for a CPU consuming loop in the C++ code, but there might
> > actually be some in the script files. Does this help?
> >
> > *** __gnuplot_get_var__.m~ Tue Jun 9 23:22:14 2009
> > --- __gnuplot_get_var__.m Mon Aug 3 13:52:35 2009
> > ***************
> > *** 125,135 ****
> > fflush (ostream);
> >
> > str = {};
> > while (isempty (str))
> > str = char (fread (istream)');
> > ! if (! isempty (str))
> > str = regexp (str, "OCTAVE:.*", "match");
> > str = str{end}(8:end);
> > endif
> > fclear (istream);
> > endwhile
> > --- 125,137 ----
> > fflush (ostream);
> >
> > str = {};
> > while (isempty (str))
> > str = char (fread (istream)');
> > ! if (isempty (str))
> > ! sleep(0.05);
> > ! else
> > str = regexp (str, "OCTAVE:.*", "match");
> > str = str{end}(8:end);
> > endif
> > fclear (istream);
> > endwhile
> >
> >
> > On my multicore machine the tic-toc timing is practically the same, but
> > cputime() shows a significant speed-up.
> >
>
> First
> > ! if (isempty (str))
> > ! sleep(0.05);
> > ! else
>
> I have tested on computer in my home (cpu Celerron M 1.3GHz)
> Why 'else' is here?
> With this 'else' plot was failled.
>
> I remove 'else' and tested argument of sleep from 0.05 to 1 with task manager
> active.
> Octave consumed 99% cpu time while loop of this test.
> N = 100;
> n = 2;
> m = 2;
> tic
> for i = 1:n*m
> x = rand (2,N);
> subplot (n,m,i);
> plot (x(1,:),x(2,:));
> end
> toc
>
>
> Regards
>
> Tatsuro
>
> --------------------------------------
> Power up the Internet with Yahoo! Toolbar.
> http://pr.mail.yahoo.co.jp/toolbar/
> _______________________________________________
> Help-octave mailing list
> address@hidden
> https://www-old.cae.wisc.edu/mailman/listinfo/help-octave
>
--------------------------------------
Power up the Internet with Yahoo! Toolbar.
http://pr.mail.yahoo.co.jp/toolbar/
- Re: Plotting with 3.2.0 on Windows is SLOOOOOOWWWW, Tatsuro MATSUOKA, 2009/08/01
- Re: Plotting with 3.2.0 on Windows is SLOOOOOOWWWW, Matthias Brennwald, 2009/08/03
- RE: Plotting with 3.2.0 on Windows is SLOOOOOOWWWW, Tatsuro MATSUOKA, 2009/08/04
- RE: Plotting with 3.2.0 on Windows is SLOOOOOOWWWW, Tatsuro MATSUOKA, 2009/08/05
- RE: Plotting with 3.2.0 on Windows is SLOOOOOOWWWW, John W. Eaton, 2009/08/05
- RE: Plotting with 3.2.0 on Windows is SLOOOOOOWWWW, Tatsuro MATSUOKA, 2009/08/05
- Re: Plotting with 3.2.0 on Windows is SLOOOOOOWWWW, Jaroslav Hajek, 2009/08/06
- Re: Plotting with 3.2.0 on Windows is SLOOOOOOWWWW, Tatsuro MATSUOKA, 2009/08/06
- Re: Plotting with 3.2.0 on Windows is SLOOOOOOWWWW, Jaroslav Hajek, 2009/08/07
- Re: Plotting with 3.2.0 on Windows is SLOOOOOOWWWW, Tatsuro MATSUOKA, 2009/08/07