You can subscribe to this list here.
2006 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
(1) |
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
|
---|---|---|---|---|---|---|---|---|---|---|---|---|
2007 |
Jan
|
Feb
|
Mar
(5) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2008 |
Jan
(9) |
Feb
|
Mar
|
Apr
|
May
(4) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
|
2010 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(2) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(4) |
2011 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
(6) |
Dec
|
2012 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(5) |
From: <bm...@us...> - 2008-01-17 20:05:19
|
Revision: 303 http://gnuplot-py.svn.sourceforge.net/gnuplot-py/?rev=303&view=rev Author: bmcage Date: 2008-01-17 12:04:37 -0800 (Thu, 17 Jan 2008) Log Message: ----------- add myself Modified Paths: -------------- trunk/CREDITS.txt Modified: trunk/CREDITS.txt =================================================================== --- trunk/CREDITS.txt 2008-01-14 22:15:19 UTC (rev 302) +++ trunk/CREDITS.txt 2008-01-17 20:04:37 UTC (rev 303) @@ -42,3 +42,6 @@ Matthew Fulmer contributed a patch to add the "filename" argument to Data and GridData. +Benny Malengier will push out new versions if the need arises starting +from 1.8 + This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <bm...@us...> - 2008-01-14 22:15:14
|
Revision: 302 http://gnuplot-py.svn.sourceforge.net/gnuplot-py/?rev=302&view=rev Author: bmcage Date: 2008-01-14 14:15:19 -0800 (Mon, 14 Jan 2008) Log Message: ----------- allow svg output, add test Modified Paths: -------------- trunk/NEWS.txt trunk/termdefs.py trunk/test.py Modified: trunk/NEWS.txt =================================================================== --- trunk/NEWS.txt 2008-01-14 21:30:39 UTC (rev 301) +++ trunk/NEWS.txt 2008-01-14 22:15:19 UTC (rev 302) @@ -7,6 +7,8 @@ Version 1.8: +* hardcopy allows for terminal='svg' (using a patch from Spyros Blanas) + * Use with_ instead of with as that will be a python keyword in the future. Modified: trunk/termdefs.py =================================================================== --- trunk/termdefs.py 2008-01-14 21:30:39 UTC (rev 301) +++ trunk/termdefs.py 2008-01-14 22:15:19 UTC (rev 302) @@ -469,3 +469,11 @@ BareStringArg(argname='fontsize'), ] +terminal_opts['svg'] = [ + BareStringArg(argname='size', fixedword='size'), # tuple of two doubles + KeywordOrBooleanArg(options=['fixed', 'dynamic']), + StringArg(argname='fname', fixedword='fname'), + BareStringArg(argname='fsize', fixedword='fsize'), + KeywordOrBooleanArg(options=['enhanced', 'noenhanced']), + StringArg(argname='fontfile', fixedword='fontfile'), + ] Modified: trunk/test.py =================================================================== --- trunk/test.py 2008-01-14 21:30:39 UTC (rev 301) +++ trunk/test.py 2008-01-14 22:15:19 UTC (rev 302) @@ -243,6 +243,16 @@ wait('Testing hardcopy options: fontsize=20') g.hardcopy('gp_test.ps', fontsize=20) + print '******** Generating svg file "gp_test.svg" ********' + wait() + g.plot(Gnuplot.Func('cos(0.5*x*x)', with_='linespoints 2 2', + title='cos(0.5*x^2)')) + g.hardcopy('gp_test.svg', terminal='svg') + + wait('Testing hardcopy svg options: enhanced') + g.hardcopy('gp_test.ps', terminal='svg', enhanced='1') + + print '############### test shortcuts ##############################' wait('plot Func and Data using shortcuts') g.plot('sin(x)', d) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <bm...@us...> - 2008-01-14 21:30:36
|
Revision: 301 http://gnuplot-py.svn.sourceforge.net/gnuplot-py/?rev=301&view=rev Author: bmcage Date: 2008-01-14 13:30:39 -0800 (Mon, 14 Jan 2008) Log Message: ----------- prepare for 1.8 release Modified Paths: -------------- trunk/Gnuplot.html trunk/README.txt Modified: trunk/Gnuplot.html =================================================================== --- trunk/Gnuplot.html 2008-01-14 21:21:24 UTC (rev 300) +++ trunk/Gnuplot.html 2008-01-14 21:30:39 UTC (rev 301) @@ -25,7 +25,7 @@ project page</a> on SourceForge. <li> Download the <a href="http://sourceforge.net/project/showfiles.php?group_id=17434"> - current version (version 1.7)</a> (includes documentation) + current version (version 1.8)</a> (includes documentation) <li> The <a href="http://gnuplot-py.sourceforge.net/doc">online documentation</a> @@ -68,6 +68,10 @@ <h2>News</h2> +<p> (January 2008) Gnuplot.py version 1.8 is out. This version +includes bugfixes and improvements that have piled up since 1.7. +For more information, read the <tt>NEWS.txt</tt> file in the distribution. </p> + <p> (17 October 2003) Gnuplot.py version 1.7 is out. This version includes a change of license from GPL to LGPL, support for sending data to Gnuplot via FIFOs (named pipes) under unix, and preliminary @@ -132,11 +136,11 @@ <ol> <li> <a href="http://sourceforge.net/project/showfiles.php?group_id=17434">Download</a> - either <code>gnuplot-py-1.7.tar.gz</code> or <code> - Gnuplot-1.7.zip</code>. + either <code>gnuplot-py-1.8.tar.gz</code> or <code> + Gnuplot-1.8.zip</code>. <li> Gunzip and untar (or unzip) it, which will create a directory - called <code>gnuplot-1.7</code>. + called <code>gnuplot-1.8</code>. <li> Refer to <tt>README.txt</tt> in that directory for further instructions. Usually it should be enough to type <code>python Modified: trunk/README.txt =================================================================== --- trunk/README.txt 2008-01-14 21:21:24 UTC (rev 300) +++ trunk/README.txt 2008-01-14 21:30:39 UTC (rev 301) @@ -54,7 +54,7 @@ Quick instructions: -1. Download gnuplot-py-1.7.tar.gz or gnuplot-py-1.7.zip. +1. Download gnuplot-py-1.8.tar.gz or gnuplot-py-1.8.zip. 2. Extract the archive to a temporary directory. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <bm...@us...> - 2008-01-14 21:22:10
|
Revision: 300 http://gnuplot-py.svn.sourceforge.net/gnuplot-py/?rev=300&view=rev Author: bmcage Date: 2008-01-14 13:21:24 -0800 (Mon, 14 Jan 2008) Log Message: ----------- prepare for 1.8 release Modified Paths: -------------- trunk/ANNOUNCE.txt trunk/NEWS.txt Modified: trunk/ANNOUNCE.txt =================================================================== --- trunk/ANNOUNCE.txt 2007-03-30 12:52:17 UTC (rev 299) +++ trunk/ANNOUNCE.txt 2008-01-14 21:21:24 UTC (rev 300) @@ -1,4 +1,4 @@ -This is to announce the release of version 1.7 of Gnuplot.py. +This is to announce the release of version 1.8 of Gnuplot.py. Gnuplot.py is a Python [1] package that allows you to create graphs from within Python using the gnuplot [2] plotting program. @@ -35,16 +35,11 @@ other using Gnuplot.py to produce a crude animation. New features in this version: + + Various bug fixes + + an option "filename" to Data and GridDat + This allows saving the data to a permanent, rather than temporary + + pdf terminal definition - + Relaxed license from GPL to LGPL. - + Added support for sending data to gnuplot via FIFOs (named pipes). - This eliminates the ambiguity about when temporary files can be - deleted, and thereby removes a common source of problems with - Gnuplot.py. Unfortunately, FIFOs only work under forms of unix. - + Added preliminary support for running Gnuplot.py under Jython, the - Java implementation of the Python language. It partly works but - depends on JNumeric, which is still beta-level. - Features already present in older versions: + Two and three-dimensional plots. @@ -65,8 +60,10 @@ + Partly table-driven to make it easy to extend. New terminal types can be supported easily by adding data to a table. + Install via distutils. + + LGPL license . + + Support for sending data to gnuplot via FIFOs (named pipes, linux only). + + Preliminary support for running Gnuplot.py under Jython - Footnotes: ---------- [1] Python <http://www.python.org> is an excellent object-oriented Modified: trunk/NEWS.txt =================================================================== --- trunk/NEWS.txt 2007-03-30 12:52:17 UTC (rev 299) +++ trunk/NEWS.txt 2008-01-14 21:21:24 UTC (rev 300) @@ -3,9 +3,13 @@ This file describes the changes introduced in each version of the Gnuplot.py package. +Version ?.? -Version ?.?: +Version 1.8: +* Use with_ instead of with as that will be a python keyword in the + future. + * Added an option "filename" to Data and GridData in PlotItems.py. This allows saving the data to a permanent, rather than temporary, file. (Patch contributed by Matthew Fulmer.) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: Andreas <mai...@An...> - 2008-01-11 17:26:37
|
Hello! TortoiseCVS itself uses this, and it works to checkout TortoiseCVS-files: CVSROOT=:pserver:ano...@to...:/cvsroot/tortoisecvs > CVSROOT=:pserver:kn...@gn...:443/svnroot/gnuplot-py > CVSROOT=:pserver:ano...@gn...:443/svnroot/gnuplot-py None works. Thanks a lot! Andreas |
From: Andreas <mai...@An...> - 2008-01-11 17:16:25
|
Hello! Now I have spent a whole afternoon, just because I wanted to upgrade to python 2.5.1 (from 2.3.5). Everything worked fine, only gnuplot.py is not working anymore because of the Numeric -> numpy change. Grrrr... I have never before used CVS/SVN, and even went through the hassle of installing tortoiseCVS, but still could not check out the newest files is this wrong? What is wrong? CVSROOT=:pserver:kn...@gn...:443/svnroot/gnuplot-py I cannot put the password anywhere, using tortoiseCVS, and tortoiseCVS doesn't ask for it. So I also tried CVSROOT=:pserver:ano...@gn...:443/svnroot/gnuplot-py Do I need some "editing rights" or something else to use the CVS/SVN of gnuplot-py on sourceforge, or is it open to any SF-user? If not, please grant me those rights. please help me someone with this versioning stuff, I'd really like to start using it. And probably easier for users who do not want to spend whole afternoons just to get a working version of gnuplot.py, is this solution: PLEASE someone PUBLISH A NEW ARCHIVE WITH THE NEWEST FILES FROM THE CVS. Thanks a lot! Andreas |
From: Andreas <mai...@An...> - 2008-01-11 17:02:19
|
Hello! Now I have spent a whole afternoon, just because I wanted to upgrade to python 2.5.1 (from 2.3.5). Everything worked fine, only gnuplot.py is not working anymore because of the Numeric -> numpy change. Grrrr... I have never before used CVS/SVN, and even went through the hassle of installing tortoiseCVS, but still could not check out the newest files is this wrong? What is wrong? CVSROOT=:pserver:kn...@gn...:443/svnroot/gnuplot-py I cannot put the password anywhere, using tortoiseCVS, and tortoiseCVS doesn't ask for it. So I also tried CVSROOT=:pserver:ano...@gn...:443/svnroot/gnuplot-py Do I need some "editing rights" or something else to use the CVS/SVN of gnuplot-py on sourceforge, or is it open to any SF-user? If not, please grant me those rights. please help me someone with this versioning stuff, I'd really like to start using it. And probably easier for users who do not want to spend whole afternoons just to get a working version of gnuplot.py, is this solution: PLEASE someone PUBLISH A NEW ARCHIVE WITH THE NEWEST FILES FROM THE CVS. Thanks a lot! Andreas P.S.: Please answer also to my email address, as I have not (yet?) joined the mailing list |
From: <mh...@us...> - 2007-03-30 12:52:16
|
Revision: 299 http://svn.sourceforge.net/gnuplot-py/?rev=299&view=rev Author: mhagger Date: 2007-03-30 05:52:17 -0700 (Fri, 30 Mar 2007) Log Message: ----------- "with" will be a Python keyword starting in Python 2.6 (and Python 2.5 already emits warnings if "with" is used as an identifier. So... Do not use "with" as an identifier within Gnuplot.py (including the test and demo scripts). Rename the PlotItem "with" parameter to "with_". However, for backwards compatibility (and through the magic of Python varargs processing), accept "with" as an alternative spelling of this option. This version runs on my computer, but I only have Python 2.4 installed, so I can't really test it. Modified Paths: -------------- trunk/PlotItems.py trunk/demo.py trunk/test.py Modified: trunk/PlotItems.py =================================================================== --- trunk/PlotItems.py 2007-03-30 11:27:17 UTC (rev 298) +++ trunk/PlotItems.py 2007-03-30 12:52:17 UTC (rev 299) @@ -83,11 +83,12 @@ _option_list = { 'axes' : lambda self, axes: self.set_string_option( 'axes', axes, None, 'axes %s'), - 'with' : lambda self, with: self.set_string_option( - 'with', with, None, 'with %s'), + 'with' : lambda self, with_: self.set_string_option( + 'with', with_, None, 'with %s'), 'title' : lambda self, title: self.set_string_option( 'title', title, 'notitle', 'title "%s"'), } + _option_list['with_'] = _option_list['with'] # order in which options need to be passed to gnuplot: _option_sequence = [ @@ -101,8 +102,8 @@ Keyword options: - 'with=<string>' -- choose how item will be plotted, e.g., - with='points 3 3'. + 'with_=<string>' -- choose how item will be plotted, e.g., + with_='points 3 3'. 'title=<string>' -- set the title to be associated with the item in the plot legend. @@ -215,7 +216,7 @@ into gnuplot itself. The argument to the contructor is a string that should be a mathematical expression. Example:: - g.plot(Func('sin(x)', with='line 3')) + g.plot(Func('sin(x)', with_='line 3')) As shorthand, a string passed to the plot method of a Gnuplot object is also treated as a Func:: Modified: trunk/demo.py =================================================================== --- trunk/demo.py 2007-03-30 11:27:17 UTC (rev 298) +++ trunk/demo.py 2007-03-30 12:52:17 UTC (rev 299) @@ -44,7 +44,7 @@ # written to a temporary file once. d = Gnuplot.Data(x, y1, title='calculated by python', - with='points 3 3') + with_='points 3 3') g.title('Data can be computed by python or gnuplot') g.xlabel('x') g.ylabel('x squared') Modified: trunk/test.py =================================================================== --- trunk/test.py 2007-03-30 11:27:17 UTC (rev 298) +++ trunk/test.py 2007-03-30 12:52:17 UTC (rev 299) @@ -73,7 +73,7 @@ g.replot() wait('Style linespoints') - g.plot(Gnuplot.Func('sin(x)', with='linespoints')) + g.plot(Gnuplot.Func('sin(x)', with_='linespoints')) wait('title=None') g.plot(Gnuplot.Func('sin(x)', title=None)) wait('title="Sine of x"') @@ -86,7 +86,7 @@ wait('Original') g.plot(f) wait('Style linespoints') - f.set_option(with='linespoints') + f.set_option(with_='linespoints') g.plot(f) wait('title=None') f.set_option(title=None) @@ -103,20 +103,20 @@ g.plot(Gnuplot.File(filename1)) wait('Style lines') - g.plot(Gnuplot.File(filename1, with='lines')) + g.plot(Gnuplot.File(filename1, with_='lines')) wait('using=1, using=(1,)') - g.plot(Gnuplot.File(filename1, using=1, with='lines'), - Gnuplot.File(filename1, using=(1,), with='points')) + g.plot(Gnuplot.File(filename1, using=1, with_='lines'), + Gnuplot.File(filename1, using=(1,), with_='points')) wait('using=(1,2), using="1:3"') g.plot(Gnuplot.File(filename1, using=(1,2)), Gnuplot.File(filename1, using='1:3')) wait('every=5, every=(5,)') - g.plot(Gnuplot.File(filename1, every=5, with='lines'), - Gnuplot.File(filename1, every=(5,), with='points')) + g.plot(Gnuplot.File(filename1, every=5, with_='lines'), + Gnuplot.File(filename1, every=(5,), with_='points')) wait('every=(10,None,0), every="10::5"') - g.plot(Gnuplot.File(filename1, with='lines'), + g.plot(Gnuplot.File(filename1, with_='lines'), Gnuplot.File(filename1, every=(10,None,0)), Gnuplot.File(filename1, every='10::5')) @@ -130,7 +130,7 @@ wait('Original') g.plot(f) wait('Style linespoints') - f.set_option(with='linespoints') + f.set_option(with_='linespoints') g.plot(f) wait('using=(1,3)') f.set_option(using=(1,3)) @@ -163,8 +163,8 @@ g.plot(Gnuplot.File(filename1)) wait('Same thing, inline data') g.plot(Gnuplot.Data(d, inline=1)) - wait('with="lp 4 4"') - g.plot(Gnuplot.Data(d, with='lp 4 4')) + wait('with_="lp 4 4"') + g.plot(Gnuplot.Data(d, with_='lp 4 4')) wait('cols=0') g.plot(Gnuplot.Data(d, cols=0)) wait('cols=(0,1), cols=(0,2)') @@ -199,13 +199,13 @@ g.plot(Gnuplot.File(filename1)) wait('Same thing, inline data') g.plot(Gnuplot.funcutils.compute_Data(x, math.cos, inline=1)) - wait('with="lp 4 4"') - g.plot(Gnuplot.funcutils.compute_Data(x, math.cos, with='lp 4 4')) + wait('with_="lp 4 4"') + g.plot(Gnuplot.funcutils.compute_Data(x, math.cos, with_='lp 4 4')) print '############### test hardcopy ###############################' print '******** Generating postscript file "gp_test.ps" ********' wait() - g.plot(Gnuplot.Func('cos(0.5*x*x)', with='linespoints 2 2', + g.plot(Gnuplot.Func('cos(0.5*x*x)', with_='linespoints 2 2', title='cos(0.5*x^2)')) g.hardcopy('gp_test.ps') @@ -249,12 +249,12 @@ print '############### test splot ##################################' wait('a 3-d curve') - g.splot(Gnuplot.Data(d, with='linesp', inline=0)) + g.splot(Gnuplot.Data(d, with_='linesp', inline=0)) wait('Same thing, saved to a file') Gnuplot.Data(d, inline=0, filename=filename1) - g.splot(Gnuplot.File(filename1, with='linesp')) + g.splot(Gnuplot.File(filename1, with_='linesp')) wait('Same thing, inline data') - g.splot(Gnuplot.Data(d, with='linesp', inline=1)) + g.splot(Gnuplot.Data(d, with_='linesp', inline=1)) print '############### test GridData and compute_GridData ##########' # set up x and y values at which the function will be tabulated: This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mh...@us...> - 2007-03-30 11:27:20
|
Revision: 298 http://svn.sourceforge.net/gnuplot-py/?rev=298&view=rev Author: mhagger Date: 2007-03-30 04:27:17 -0700 (Fri, 30 Mar 2007) Log Message: ----------- Add directory ".pc" to svn:ignore. This is another directory used by the quilt patch manager. Property Changed: ---------------- trunk/ Property changes on: trunk ___________________________________________________________________ Name: svn:ignore - *.class *.pyc *.pyo MANIFEST build dist doc docs.tar.gz gp_test.ps patches + *.class *.pyc *.pyo MANIFEST build dist doc docs.tar.gz gp_test.ps patches .pc This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mh...@us...> - 2007-03-30 11:25:26
|
Revision: 297 http://svn.sourceforge.net/gnuplot-py/?rev=297&view=rev Author: mhagger Date: 2007-03-30 04:25:28 -0700 (Fri, 30 Mar 2007) Log Message: ----------- Delete the information comment line "Automatically adapted for numpy.oldnumeric Sep 22, 2006 by alter_code1.py" as (1) it doesn't need to be permanently documented in the modified files and (2) it screws up the "#!" line needed to execute the files under Unix. Modified Paths: -------------- trunk/PlotItems.py trunk/funcutils.py trunk/test.py trunk/utils.py Modified: trunk/PlotItems.py =================================================================== --- trunk/PlotItems.py 2007-03-30 10:57:31 UTC (rev 296) +++ trunk/PlotItems.py 2007-03-30 11:25:28 UTC (rev 297) @@ -1,5 +1,3 @@ -## Automatically adapted for numpy.oldnumeric Sep 22, 2006 by alter_code1.py - # $Id$ # Copyright (C) 1998-2003 Michael Haggerty <mh...@al...> Modified: trunk/funcutils.py =================================================================== --- trunk/funcutils.py 2007-03-30 10:57:31 UTC (rev 296) +++ trunk/funcutils.py 2007-03-30 11:25:28 UTC (rev 297) @@ -1,5 +1,3 @@ -## Automatically adapted for numpy.oldnumeric Sep 22, 2006 by alter_code1.py - #! /usr/bin/env python # $Id$ Modified: trunk/test.py =================================================================== --- trunk/test.py 2007-03-30 10:57:31 UTC (rev 296) +++ trunk/test.py 2007-03-30 11:25:28 UTC (rev 297) @@ -1,5 +1,3 @@ -## Automatically adapted for numpy.oldnumeric Sep 22, 2006 by alter_code1.py - #! /usr/bin/env python # $Id$ Modified: trunk/utils.py =================================================================== --- trunk/utils.py 2007-03-30 10:57:31 UTC (rev 296) +++ trunk/utils.py 2007-03-30 11:25:28 UTC (rev 297) @@ -1,5 +1,3 @@ -## Automatically adapted for numpy.oldnumeric Sep 22, 2006 by alter_code1.py - #! /usr/bin/env python # $Id$ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mh...@us...> - 2007-03-30 10:58:44
|
Revision: 296 http://svn.sourceforge.net/gnuplot-py/?rev=296&view=rev Author: mhagger Date: 2007-03-30 03:57:31 -0700 (Fri, 30 Mar 2007) Log Message: ----------- Reinstate workaround for spelling error in old distutils versions, as Gnuplot.py is still documented to work with versions of Python back to 2.2 (see Gnuplot.html). Modified Paths: -------------- trunk/setup.py Modified: trunk/setup.py =================================================================== --- trunk/setup.py 2007-03-30 10:47:49 UTC (rev 295) +++ trunk/setup.py 2007-03-30 10:57:31 UTC (rev 296) @@ -29,8 +29,11 @@ author_email='mh...@al...', url='http://gnuplot-py.sourceforge.net', license='LGPL', - # fixed as of python2.3 - # licence='LGPL', # Spelling error in distutils + # This line is a workaround for a spelling error in earlier + # versions of distutils. The error has been fixed as of + # python2.3, but we leave this line here for compatibility with + # older python versions. + licence='LGPL', # Description of the package in the distribution package_dir={'Gnuplot' : '.'}, This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mh...@us...> - 2007-03-30 10:47:49
|
Revision: 295 http://svn.sourceforge.net/gnuplot-py/?rev=295&view=rev Author: mhagger Date: 2007-03-30 03:47:49 -0700 (Fri, 30 Mar 2007) Log Message: ----------- Add "patches" directory to svn:ignore. (This directory is used by quilt, a patch manager.) Property Changed: ---------------- trunk/ Property changes on: trunk ___________________________________________________________________ Name: svn:ignore - *.class *.pyc *.pyo MANIFEST build dist doc docs.tar.gz gp_test.ps + *.class *.pyc *.pyo MANIFEST build dist doc docs.tar.gz gp_test.ps patches This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <par...@us...> - 2006-11-07 02:33:17
|
Revision: 294 http://svn.sourceforge.net/gnuplot-py/?rev=294&view=rev Author: parejkoj Date: 2006-11-06 18:33:08 -0800 (Mon, 06 Nov 2006) Log Message: ----------- Changes required to move from Numeric support over to numpy. All import commands now import numpy instead of Numeric. Comments involving Numeric were simply changed to numpy, except for JNumeric, which may not yet have a numpy version. Some syntax changed as well: NewAxis -> newaxis Float -> float_ Float32 -> float32 typecode() -> dtype.char Also, some brain-dead error handling in utils.float_array(m): the most common reason for a conversion error is a mis-match of array dimensions. It should be better about reporting that. Finally, *set -> *data in PlotItems.Data(). set is now a reserved word for the built-in set class, and I wanted to avoid collisions there. Modified Paths: -------------- trunk/ANNOUNCE.txt trunk/FAQ.txt trunk/NEWS.txt trunk/PlotItems.py trunk/README.txt trunk/TODO.txt trunk/_Gnuplot.py trunk/__init__.py trunk/demo.py trunk/funcutils.py trunk/setup.py trunk/test.py trunk/utils.py Modified: trunk/ANNOUNCE.txt =================================================================== --- trunk/ANNOUNCE.txt 2006-07-16 17:48:06 UTC (rev 293) +++ trunk/ANNOUNCE.txt 2006-11-07 02:33:08 UTC (rev 294) @@ -9,7 +9,7 @@ Prerequisites (see footnotes): the Python interpreter [1] - the Python Numeric module [3] + the Python numpy module [3] the gnuplot program [2] or, to use it under Java (experimental): @@ -20,7 +20,7 @@ Some ways this package can be used: -1. Interactive data processing: Use Python's excellent Numeric package +1. Interactive data processing: Use Python's excellent numpy package to create and manipulate arrays of numbers, and use Gnuplot.py to visualize the results. 2. Web graphics: write CGI scripts in Python that use gnuplot to @@ -76,7 +76,7 @@ portable plotting program with a command-line interface. It can make 2-d and 3-d plots and can output to myriad printers and graphics terminals. -[3] The Numeric Python extension <http://numpy.sourceforge.net/> is a +[3] The numpy Python extension <http://www.scipy.org> is a Python module that adds fast and convenient array manipulations to the Python language. [4] Jython <http://www.jython.org> is a Python interpreter that runs Modified: trunk/FAQ.txt =================================================================== --- trunk/FAQ.txt 2006-07-16 17:48:06 UTC (rev 293) +++ trunk/FAQ.txt 2006-11-07 02:33:08 UTC (rev 294) @@ -17,7 +17,7 @@ #! /usr/bin/python2 import Gnuplot, Gnuplot.funcutils -from Numeric import * +from numpy import * g = Gnuplot.Gnuplot() g.plot([[0,1.1], [1,5.8], [2,3.3], [3,4.2]]) Modified: trunk/NEWS.txt =================================================================== --- trunk/NEWS.txt 2006-07-16 17:48:06 UTC (rev 293) +++ trunk/NEWS.txt 2006-11-07 02:33:08 UTC (rev 294) @@ -235,10 +235,10 @@ dataset; e.g., what used to be written as g = Gnuplot.Gnuplot() - x = Numeric.arange(100)/10.0 + x = numpy.arange(100)/10.0 y = x**2 # Create an array of (x,y) pairs: - g.plot(Gnuplot.Data(Numeric.transpose((x, y)))) + g.plot(Gnuplot.Data(numpy.transpose((x, y)))) can now be shortened to Modified: trunk/PlotItems.py =================================================================== --- trunk/PlotItems.py 2006-07-16 17:48:06 UTC (rev 293) +++ trunk/PlotItems.py 2006-11-07 02:33:08 UTC (rev 294) @@ -1,3 +1,5 @@ +## Automatically adapted for numpy.oldnumeric Sep 22, 2006 by alter_code1.py + # $Id$ # Copyright (C) 1998-2003 Michael Haggerty <mh...@al...> @@ -21,7 +23,7 @@ except ImportError: from StringIO import StringIO -import Numeric +import numpy import gp, utils, Errors @@ -504,12 +506,12 @@ return _FileItem(filename, **keyw) -def Data(*set, **keyw): - """Create and return a _FileItem representing the data from *set. +def Data(*data, **keyw): + """Create and return a _FileItem representing the data from *data. Create a '_FileItem' object (which is a type of 'PlotItem') out of - one or more Float Python Numeric arrays (or objects that can be - converted to a Float Numeric array). If the routine is passed a + one or more Float Python numpy arrays (or objects that can be + converted to a float numpy array). If the routine is passed a single with multiple dimensions, then the last index ranges over the values comprising a single data point (e.g., [<x>, <y>, <sigma>]) and the rest of the indices select the data point. If @@ -543,29 +545,29 @@ """ - if len(set) == 1: - # set was passed as a single structure - set = utils.float_array(set[0]) + if len(data) == 1: + # data was passed as a single structure + data = utils.float_array(data[0]) # As a special case, if passed a single 1-D array, then it is # treated as one value per point (by default, plotted against # its index): - if len(set.shape) == 1: - set = set[:,Numeric.NewAxis] + if len(data.shape) == 1: + data = data[:,numpy.newaxis] else: - # set was passed column by column (for example, + # data was passed column by column (for example, # Data(x,y)); pack it into one big array (this will test # that sizes are all the same): - set = utils.float_array(set) - dims = len(set.shape) + data = utils.float_array(data) + dims = len(data.shape) # transpose so that the last index selects x vs. y: - set = Numeric.transpose(set, (dims-1,) + tuple(range(dims-1))) + data = numpy.transpose(data, (dims-1,) + tuple(range(dims-1))) if 'cols' in keyw: cols = keyw['cols'] del keyw['cols'] - if type(cols) is types.IntType: + if isinstance(cols, types.IntType): cols = (cols,) - set = Numeric.take(set, cols, -1) + data = numpy.take(data, cols, -1) if 'filename' in keyw: filename = keyw['filename'] or None @@ -585,7 +587,7 @@ # Output the content into a string: f = StringIO() - utils.write_array(f, set) + utils.write_array(f, data) content = f.getvalue() if inline: return _InlineFileItem(content, **keyw) @@ -661,7 +663,7 @@ raise Errors.DataError('data array must be two-dimensional') if xvals is None: - xvals = Numeric.arange(numx) + xvals = numpy.arange(numx) else: xvals = utils.float_array(xvals) if xvals.shape != (numx,): @@ -670,7 +672,7 @@ 'the first dimension of the data array') if yvals is None: - yvals = Numeric.arange(numy) + yvals = numpy.arange(numy) else: yvals = utils.float_array(yvals) if yvals.shape != (numy,): @@ -705,17 +707,17 @@ # documentation has the roles of x and y exchanged. We ignore # the documentation and go with the code. - mout = Numeric.zeros((numy + 1, numx + 1), Numeric.Float32) + mout = numpy.zeros((numy + 1, numx + 1), numpy.float32) mout[0,0] = numx - mout[0,1:] = xvals.astype(Numeric.Float32) - mout[1:,0] = yvals.astype(Numeric.Float32) + mout[0,1:] = xvals.astype(numpy.float32) + mout[1:,0] = yvals.astype(numpy.float32) try: # try copying without the additional copy implied by astype(): - mout[1:,1:] = Numeric.transpose(data) + mout[1:,1:] = numpy.transpose(data) except: # if that didn't work then downcasting from double # must be necessary: - mout[1:,1:] = Numeric.transpose(data.astype(Numeric.Float32)) + mout[1:,1:] = numpy.transpose(data.astype(numpy.float32)) content = mout.tostring() if (not filename) and gp.GnuplotOpts.prefer_fifo_data: @@ -726,10 +728,10 @@ # output data to file as "x y f(x)" triplets. This # requires numy copies of each x value and numx copies of # each y value. First reformat the data: - set = Numeric.transpose( - Numeric.array( - (Numeric.transpose(Numeric.resize(xvals, (numy, numx))), - Numeric.resize(yvals, (numx, numy)), + set = numpy.transpose( + numpy.array( + (numpy.transpose(numpy.resize(xvals, (numy, numx))), + numpy.resize(yvals, (numx, numy)), data)), (1,2,0)) # Now output the data with the usual routine. This will Modified: trunk/README.txt =================================================================== --- trunk/README.txt 2006-07-16 17:48:06 UTC (rev 293) +++ trunk/README.txt 2006-11-07 02:33:08 UTC (rev 294) @@ -65,8 +65,8 @@ Obviously, you must have the gnuplot program if Gnuplot.py is to be of any use to you. Gnuplot can be obtained via -<http://www.gnuplot.info>. You also need Python's Numerical -extension, which is available from <http://numpy.sourceforge.net>. +<http://www.gnuplot.info>. You also need a copy of the numpy package, which +is available from the Scipy group at <http://www.scipy.org/Download>. Gnuplot.py uses Python distutils <http://www.python.org/doc/current/inst/inst.html> and can be Modified: trunk/TODO.txt =================================================================== --- trunk/TODO.txt 2006-07-16 17:48:06 UTC (rev 293) +++ trunk/TODO.txt 2006-11-07 02:33:08 UTC (rev 294) @@ -33,4 +33,3 @@ * Support gnuplot's new abilities to allow user interaction via the mouse. I believe this will require 2-way communication between Gnuplot.py and gnuplot. - Modified: trunk/_Gnuplot.py =================================================================== --- trunk/_Gnuplot.py 2006-07-16 17:48:06 UTC (rev 293) +++ trunk/_Gnuplot.py 2006-11-07 02:33:08 UTC (rev 294) @@ -239,8 +239,8 @@ 'items' is a sequence of items, each of which should be a 'PlotItem' of some kind, a string (interpreted as a function - string for gnuplot to evaluate), or a Numeric array (or - something that can be converted to a Numeric array). + string for gnuplot to evaluate), or a numpy array (or + something that can be converted to a numpy array). """ Modified: trunk/__init__.py =================================================================== --- trunk/__init__.py 2006-07-16 17:48:06 UTC (rev 293) +++ trunk/__init__.py 2006-11-07 02:33:08 UTC (rev 294) @@ -128,9 +128,9 @@ Restrictions: - - Relies on the Numeric Python extension. This can be obtained from - "SourceForge", http://sourceforge.net/projects/numpy/. If you're - interested in gnuplot, you would probably also want NumPy anyway. + - Relies on the numpy Python extension. This can be obtained from + the Scipy group at <http://www.scipy.org/Download>. If you're + interested in gnuplot, you would probably also want numpy anyway. - Only a small fraction of gnuplot functionality is implemented as explicit method functions. However, you can give arbitrary Modified: trunk/demo.py =================================================================== --- trunk/demo.py 2006-07-16 17:48:06 UTC (rev 293) +++ trunk/demo.py 2006-11-07 02:33:08 UTC (rev 294) @@ -13,7 +13,7 @@ """ -from Numeric import * +from numpy import * # If the package has been installed correctly, this should work: import Gnuplot, Gnuplot.funcutils @@ -28,7 +28,7 @@ g = Gnuplot.Gnuplot(debug=1) g.title('A simple example') # (optional) g('set data style linespoints') # give gnuplot an arbitrary command - # Plot a list of (x, y) pairs (tuples or a Numeric array would + # Plot a list of (x, y) pairs (tuples or a numpy array would # also be OK): g.plot([[0,1.1], [1,5.8], [2,3.3], [3,4.2]]) raw_input('Please press return to continue...\n') @@ -36,7 +36,7 @@ g.reset() # Plot one dataset from an array and one via a gnuplot function; # also demonstrate the use of item-specific options: - x = arange(10, typecode=Float) + x = arange(10, dtype='float_') y1 = x**2 # Notice how this plotitem is created here but used later? This # is convenient if the same dataset has to be plotted multiple @@ -71,8 +71,8 @@ # Make a 2-d array containing a function of x and y. First create # xm and ym which contain the x and y values in a matrix form that # can be `broadcast' into a matrix of the appropriate shape: - xm = x[:,NewAxis] - ym = y[NewAxis,:] + xm = x[:,newaxis] + ym = y[newaxis,:] m = (sin(xm) + 0.1*xm) - ym**2 g('set parametric') g('set data style lines') Modified: trunk/funcutils.py =================================================================== --- trunk/funcutils.py 2006-07-16 17:48:06 UTC (rev 293) +++ trunk/funcutils.py 2006-11-07 02:33:08 UTC (rev 294) @@ -1,3 +1,5 @@ +## Automatically adapted for numpy.oldnumeric Sep 22, 2006 by alter_code1.py + #! /usr/bin/env python # $Id$ @@ -14,19 +16,19 @@ """ -import Numeric +import numpy import Gnuplot, utils -def tabulate_function(f, xvals, yvals=None, typecode=None, ufunc=0): +def tabulate_function(f, xvals, yvals=None, dtype=None, ufunc=0): """Evaluate and tabulate a function on a 1- or 2-D grid of points. f should be a function taking one or two floating-point parameters. If f takes one parameter, then xvals should be a 1-D array and - yvals should be None. The return value is a Numeric array + yvals should be None. The return value is a numpy array '[f(x[0]), f(x[1]), ..., f(x[-1])]'. If f takes two parameters, then 'xvals' and 'yvals' should each be @@ -37,7 +39,7 @@ If 'ufunc=0', then 'f' is evaluated at each point using a Python loop. This can be slow if the number of points is large. If - speed is an issue, you should write 'f' in terms of Numeric ufuncs + speed is an issue, you should write 'f' in terms of numpy ufuncs and use the 'ufunc=1' feature described next. If called with 'ufunc=1', then 'f' should be a function that is @@ -49,34 +51,34 @@ if yvals is None: # f is a function of only one variable: - xvals = Numeric.asarray(xvals, typecode) + xvals = numpy.asarray(xvals, dtype) if ufunc: return f(xvals) else: - if typecode is None: - typecode = xvals.typecode() + if dtype is None: + dtype = xvals.dtype.char - m = Numeric.zeros((len(xvals),), typecode) + m = numpy.zeros((len(xvals),), dtype) for xi in range(len(xvals)): x = xvals[xi] m[xi] = f(x) return m else: # f is a function of two variables: - xvals = Numeric.asarray(xvals, typecode) - yvals = Numeric.asarray(yvals, typecode) + xvals = numpy.asarray(xvals, dtype) + yvals = numpy.asarray(yvals, dtype) if ufunc: - return f(xvals[:,Numeric.NewAxis], yvals[Numeric.NewAxis,:]) + return f(xvals[:,numpy.newaxis], yvals[numpy.newaxis,:]) else: - if typecode is None: - # choose a result typecode based on what '+' would return + if dtype is None: + # choose a result dtype based on what '+' would return # (yecch!): - typecode = (Numeric.zeros((1,), xvals.typecode()) + - Numeric.zeros((1,), yvals.typecode())).typecode() + dtype = (numpy.zeros((1,), xvals.dtype.char) + + numpy.zeros((1,), yvals.dtype.char)).dtype.char - m = Numeric.zeros((len(xvals), len(yvals)), typecode) + m = numpy.zeros((len(xvals), len(yvals)), dtype) for xi in range(len(xvals)): x = xvals[xi] for yi in range(len(yvals)): Modified: trunk/setup.py =================================================================== --- trunk/setup.py 2006-07-16 17:48:06 UTC (rev 293) +++ trunk/setup.py 2006-11-07 02:33:08 UTC (rev 294) @@ -29,7 +29,8 @@ author_email='mh...@al...', url='http://gnuplot-py.sourceforge.net', license='LGPL', - licence='LGPL', # Spelling error in distutils + # fixed as of python2.3 + # licence='LGPL', # Spelling error in distutils # Description of the package in the distribution package_dir={'Gnuplot' : '.'}, Modified: trunk/test.py =================================================================== --- trunk/test.py 2006-07-16 17:48:06 UTC (rev 293) +++ trunk/test.py 2006-11-07 02:33:08 UTC (rev 294) @@ -1,3 +1,5 @@ +## Automatically adapted for numpy.oldnumeric Sep 22, 2006 by alter_code1.py + #! /usr/bin/env python # $Id$ @@ -15,8 +17,7 @@ """ import os, time, math, tempfile -import Numeric -from Numeric import NewAxis +import numpy try: import Gnuplot, Gnuplot.PlotItems, Gnuplot.funcutils @@ -59,7 +60,7 @@ f = open(filename1, 'w') filename2 = tempfile.mktemp() try: - for x in Numeric.arange(100)/5. - 10.: + for x in numpy.arange(100.)/5. - 10.: f.write('%s %s %s\n' % (x, math.cos(x), math.sin(x))) f.close() @@ -141,10 +142,10 @@ g.plot(f) print '############### test Data ###################################' - x = Numeric.arange(100)/5. - 10. - y1 = Numeric.cos(x) - y2 = Numeric.sin(x) - d = Numeric.transpose((x,y1,y2)) + x = numpy.arange(100)/5. - 10. + y1 = numpy.cos(x) + y2 = numpy.sin(x) + d = numpy.transpose((x,y1,y2)) wait('Plot Data against its index') g.plot(Gnuplot.Data(y2, inline=0)) @@ -187,7 +188,7 @@ g.plot(Gnuplot.Data(d, title='Cosine of x')) print '############### test compute_Data ###########################' - x = Numeric.arange(100)/5. - 10. + x = numpy.arange(100)/5. - 10. wait('Plot Data, computed by Gnuplot.py') g.plot( @@ -259,14 +260,14 @@ print '############### test GridData and compute_GridData ##########' # set up x and y values at which the function will be tabulated: - x = Numeric.arange(35)/2.0 - y = Numeric.arange(30)/10.0 - 1.5 + x = numpy.arange(35)/2.0 + y = numpy.arange(30)/10.0 - 1.5 # Make a 2-d array containing a function of x and y. First create # xm and ym which contain the x and y values in a matrix form that # can be `broadcast' into a matrix of the appropriate shape: - xm = x[:,NewAxis] - ym = y[NewAxis,:] - m = (Numeric.sin(xm) + 0.1*xm) - ym**2 + xm = x[:,numpy.newaxis] + ym = y[numpy.newaxis,:] + m = (numpy.sin(xm) + 0.1*xm) - ym**2 wait('a function of two variables from a GridData file') g('set parametric') g('set data style lines') @@ -299,12 +300,12 @@ wait('Use compute_GridData in ufunc and binary mode') g.splot(Gnuplot.funcutils.compute_GridData( - x,y, lambda x,y: Numeric.sin(x) + 0.1*x - y**2, + x,y, lambda x,y: numpy.sin(x) + 0.1*x - y**2, ufunc=1, binary=1, )) wait('Same thing, with an intermediate file') Gnuplot.funcutils.compute_GridData( - x,y, lambda x,y: Numeric.sin(x) + 0.1*x - y**2, + x,y, lambda x,y: numpy.sin(x) + 0.1*x - y**2, ufunc=1, binary=1, filename=filename1) g.splot(Gnuplot.File(filename1, binary=1)) Modified: trunk/utils.py =================================================================== --- trunk/utils.py 2006-07-16 17:48:06 UTC (rev 293) +++ trunk/utils.py 2006-11-07 02:33:08 UTC (rev 294) @@ -1,3 +1,5 @@ +## Automatically adapted for numpy.oldnumeric Sep 22, 2006 by alter_code1.py + #! /usr/bin/env python # $Id$ @@ -15,30 +17,34 @@ """ import string -import Numeric +import numpy - def float_array(m): - """Return the argument as a Numeric array of type at least 'Float32'. + """Return the argument as a numpy array of type at least 'Float32'. Leave 'Float64' unchanged, but upcast all other types to 'Float32'. Allow also for the possibility that the argument is a - python native type that can be converted to a Numeric array using - 'Numeric.asarray()', but in that case don't worry about + python native type that can be converted to a numpy array using + 'numpy.asarray()', but in that case don't worry about downcasting to single-precision float. """ try: # Try Float32 (this will refuse to downcast) - return Numeric.asarray(m, Numeric.Float32) + return numpy.asarray(m, numpy.float32) except TypeError: # That failure might have been because the input array was - # of a wider data type than Float32; try to convert to the + # of a wider data type than float32; try to convert to the # largest floating-point type available: - return Numeric.asarray(m, Numeric.Float) + # NOTE TBD: I'm not sure float_ is the best data-type for this... + try: + return numpy.asarray(m, numpy.float_) + except TypeError: + # TBD: Need better handling of this error! + print "Fatal: array dimensions not equal!" + return None - def write_array(f, set, item_sep=' ', nest_prefix='', nest_suffix='\n', nest_sep=''): This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mh...@us...> - 2006-07-16 17:48:17
|
Revision: 293 Author: mhagger Date: 2006-07-16 10:48:06 -0700 (Sun, 16 Jul 2006) ViewCVS: http://svn.sourceforge.net/gnuplot-py/?rev=293&view=rev Log Message: ----------- Import Errors. Problem and suggested solution come from Debian bug #353642. This commit should fix that bug. Modified Paths: -------------- trunk/_Gnuplot.py Modified: trunk/_Gnuplot.py =================================================================== --- trunk/_Gnuplot.py 2006-03-03 09:49:04 UTC (rev 292) +++ trunk/_Gnuplot.py 2006-07-16 17:48:06 UTC (rev 293) @@ -14,7 +14,7 @@ import sys, string, types -import gp, PlotItems, termdefs +import gp, PlotItems, termdefs, Errors class _GnuplotFile: This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: Michael H. <mh...@al...> - 2006-06-14 19:03:55
|
Hello, I have created a new mailing list: gnu...@li... This mailing list will automatically receive a message every time that somebody commits something to the Gnuplot.py Subversion repository. People who are interested in following the development of Gnuplot.py should subscribe to the new mailing list by visiting the following web page: https://lists.sourceforge.net/lists/listinfo/gnuplot-py-svn Please continue to use the gnuplot-py-users mailing list for discussions. Michael |