<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>rss python-science RSS Feed</title>
    <description>rss python-science</description>
    <link>http://www.logilab.org/view?rql=Any%20B%2CC%20ORDERBY%20C%20DESC%20WHERE%20B%20creation_date%20C%2C%20B%20is%20BlogEntry%2C%20X%20tags%20B%2C%20X%20is%20Tag%2C%20X%20name%20%22python-science%22&amp;vtitle=rss%20python-science</link>
<item>
<guid isPermaLink="true">http://www.logilab.org/blogentry/18838</guid>
  <title>First contact with pupynere</title>
  <link>http://www.logilab.org/blogentry/18838</link>
  <description>&lt;p&gt;I spent some time this week evaluating &lt;a class=&quot;reference&quot; href=&quot;http://dealmeida.net/projects/pupynere&quot;&gt;Pupynere&lt;/a&gt;, the PUre PYthon NEtcdf REader written by Roberto De Almeida. I see several advantages in pupynere.&lt;/p&gt;
&lt;p&gt;First it&#39;s a pure Python module with no external dependency. It doesn&#39;t even depend on the &lt;a class=&quot;reference&quot; href=&quot;http://www.unidata.ucar.edu/software/netcdf/&quot;&gt;NetCDF&lt;/a&gt; lib and it is therefore very easy to deploy.&lt;/p&gt;
&lt;img alt=&quot;http://www.unidata.ucar.edu/software/netcdf/netcdf1_sm.png&quot; class=&quot;align-right&quot; src=&quot;http://www.unidata.ucar.edu/software/netcdf/netcdf1_sm.png&quot; /&gt;
&lt;p&gt;Second, it offers the same interface as &lt;cite&gt;Scientific Python&lt;/cite&gt;&#39;s NetCDF bindings which makes transitioning from one module to another very easy.&lt;/p&gt;
&lt;p&gt;Third pupynere is being integrated into &lt;a class=&quot;reference&quot; href=&quot;http://www.scipy.org/&quot;&gt;Scipy&lt;/a&gt; as the &lt;tt class=&quot;docutils literal&quot;&gt;scypi.io.netcdf&lt;/tt&gt; module. Once integrated, this could ensure a wide adoption by the python community.&lt;/p&gt;
&lt;p&gt;Finally it&#39;s easy to dig in this clear and small code base of about 600 lines. I have just sent several fixes and bug reports to the author.&lt;/p&gt;
&lt;img alt=&quot;http://docs.scipy.org/doc/_static/scipyshiny_small.png&quot; class=&quot;align-right&quot; src=&quot;http://docs.scipy.org/doc/_static/scipyshiny_small.png&quot; /&gt;
&lt;p&gt;However pupynere isn&#39;t mature yet. First it seems pupynere has been only used for simple cases so far. Many common cases are broken. Moreover there is no support for new NetCDF formats such as long-NetCDF and NetCDF4, and important features such as file update are still missing. In addition, The lack of a test suite is a serious issue. In my opinion, various bugs could already have been detected and fixed with simple unit tests. Contributions would be much more
comfortable with the safety net offered by a test suite. I am not certain
that the fixes and improvements I made this week did not introduce regressions.&lt;/p&gt;
&lt;p&gt;To conclude, pupynere seems too young for production use. But I invite people
to try it and provide feedback and fixes to the author. I&#39;m looking forward to using this project in production in the future.&lt;/p&gt;
</description>
  <dc:date>2009-11-06T17:36-01:00</dc:date>
  <dc:creator>Pierre-Yves David</dc:creator>
</item>
<item>
<guid isPermaLink="true">http://www.logilab.org/blogentry/9853</guid>
  <title>EuroSciPy&#39;09 (part 1/2): The Need For Speed</title>
  <link>http://www.logilab.org/blogentry/9853</link>
  <description>&lt;img alt=&quot;http://www.logilab.org/image/9852?vid=download&quot; class=&quot;align-right&quot; src=&quot;http://www.logilab.org/image/9852?vid=download&quot; /&gt;
&lt;p&gt;The &lt;a class=&quot;reference&quot; href=&quot;http://www.euroscipy.org/&quot;&gt;EuroSciPy2009&lt;/a&gt; conference was held in Leipzig at the end of July and was
sponsored by Logilab and other companies. It started with three talks about speed.&lt;/p&gt;
&lt;div class=&quot;section&quot; id=&quot;starving-cpus&quot;&gt;
&lt;h3&gt;&lt;a&gt;Starving CPUs&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;In his keynote, Fransesc Alted talked about &lt;a class=&quot;reference&quot; href=&quot;http://www.euroscipy.org/talk/893&quot;&gt;starving CPUs&lt;/a&gt;. Thirty years back,
memory and CPU frequencies where about the same. Memory speed kept up for about
ten years with the evolution of CPU speed before falling behind. Nowadays,
memory is about a hundred times slower than the cache which is itself about
twenty times slower than the CPU. The direct consequence is that CPUs are
starving and spend many clock cycles waiting for data to process.&lt;/p&gt;
&lt;p&gt;In order to improve the performance of programs, it is now required to know
about the multiple layers of computer memory, from disk storage to CPU. The
common architecture will soon count six levels: mechanical disk, solid state
disk, ram, cache level 3, cache level 2, cache level 1.&lt;/p&gt;
&lt;p&gt;Using optimized array operations, taking striding into account, processing data
blocks of the right size and using compression to diminish the amount of data
that is transfered from one layer to the next are four techniques that go a long
way on the road to high performance. Compression algorithms like Blosc increase
throughput for they strike the right balance between being fast and providing
good compression ratios. Blosc compression will soon be available in &lt;a class=&quot;reference&quot; href=&quot;http://www.pytables.org/&quot;&gt;PyTables&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Fransesc also mentions the &lt;a class=&quot;reference&quot; href=&quot;http://code.google.com/p/numexpr/&quot;&gt;numexpr&lt;/a&gt; extension to &lt;a class=&quot;reference&quot; href=&quot;http://numpy.scipy.org/&quot;&gt;numpy&lt;/a&gt;, and its combination with
PyTables named tables.Expr, that nicely and easily accelerates the computation
of some expressions involving numpy arrays. In his list of references, Fransesc
cites Ulrich Drepper article &lt;a class=&quot;reference&quot; href=&quot;http://people.redhat.com/drepper/cpumemory.pdf&quot;&gt;What every programmer should know about memory&lt;/a&gt;.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&quot;section&quot; id=&quot;using-pypy-s-jit-for-science&quot;&gt;
&lt;h3&gt;&lt;a&gt;Using PyPy&#39;s JIT for science&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;Maciej Fijalkowski started his talk with a general presentation of the &lt;a class=&quot;reference&quot; href=&quot;http://pypy.org/&quot;&gt;PyPy&lt;/a&gt;
framework. One uses PyPy to describe an interpreter in RPython, then generate
the actual interpreter code and its JIT.&lt;/p&gt;
&lt;p&gt;Since &lt;a class=&quot;reference&quot; href=&quot;http://pypy.org/&quot;&gt;PyPy&lt;/a&gt; is has become more of a framework to write interpreters than a
reimplementation of Python in Python, I suggested to change its misleading name to
something like &lt;cite&gt;gcgc the Generic Compiler for Generating Compilers&lt;/cite&gt;. Maciej
answered that there are discussions on the mailing list to split the project in
two and make the implementation of the Python interpreter distinct from the GcGc
framework.&lt;/p&gt;
&lt;p&gt;Maciej then focused his &lt;a class=&quot;reference&quot; href=&quot;http://www.euroscipy.org/talk/894&quot;&gt;talk&lt;/a&gt; on his recent effort to rewrite in RPython the part
of &lt;a class=&quot;reference&quot; href=&quot;http://numpy.scipy.org/&quot;&gt;numpy&lt;/a&gt; that exposes the underlying C library to Python. He says the benefits
of using PyPy&#39;s JIT to speedup that wrapping layer are already visible. He has
&lt;a class=&quot;reference&quot; href=&quot;http://morepypy.blogspot.com/2009/07/pypy-numeric-experiments.html&quot;&gt;details&lt;/a&gt; on the PyPy blog. Gaël Varoquaux added that David Cournapeau has
started working on making the C/Python split in numpy cleaner, which would
further ease the job of rewriting it in RPython.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&quot;section&quot; id=&quot;crosstwine-linker&quot;&gt;
&lt;h3&gt;&lt;a&gt;CrossTwine Linker&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;Damien Diederen talked about his &lt;a class=&quot;reference&quot; href=&quot;http://www.euroscipy.org/talk/895&quot;&gt;work&lt;/a&gt; on &lt;a class=&quot;reference&quot; href=&quot;http://crosstwine.com/linker/&quot;&gt;CrossTwine Linker&lt;/a&gt; and compared it
with the many projects that are actively attacking the problem of speed that
dynamic and interpreted languages have been dragging along for years. &lt;a class=&quot;reference&quot; href=&quot;http://www.parrot.org/&quot;&gt;Parrot&lt;/a&gt;
tries to be the über virtual machine. &lt;a class=&quot;reference&quot; href=&quot;http://psyco.sourceforge.net/&quot;&gt;Psyco&lt;/a&gt; offers very nice acceleration, but
currently only on 32bits system. &lt;a class=&quot;reference&quot; href=&quot;http://pypy.org/&quot;&gt;PyPy&lt;/a&gt; might be what he calls the Right
Approach, but still needs a lot of work. Jython and IronPython modify the
language a bit but benefit from the qualities of the &lt;a class=&quot;reference&quot; href=&quot;http://en.wikipedia.org/wiki/JVM&quot;&gt;JVM&lt;/a&gt; or the &lt;a class=&quot;reference&quot; href=&quot;http://en.wikipedia.org/wiki/Common_Language_Runtime&quot;&gt;CLR&lt;/a&gt;. &lt;a class=&quot;reference&quot; href=&quot;http://code.google.com/p/unladen-swallow/&quot;&gt;Unladen
Swallow&lt;/a&gt; is probably the one that&#39;s most similar to CrossTwine.&lt;/p&gt;
&lt;p&gt;CrossTwine considers CPython as a library and uses a set of C++ classes to
generate efficient interpreters that make calls to CPython&#39;s
internals. CrossTwine is a tool that helps improving performance by
hand-replacing some code paths with very efficient code that does the same
operations but bypasses the interpreter and its overhead. An interpreter built
with CrossTwine can be viewed as a JIT&#39;ed branch of the official Python
interpreter that should be feature-compatible (and bug-compatible) with CPython.
Damien calls he approach &amp;quot;punching holes in C substrate to get more speed&amp;quot; and
says it could probably be combined with Psyco for even better results.&lt;/p&gt;
&lt;p&gt;CrossTwine works on 64bit systems, but it is not (yet?) free software. It
focuses on some use cases to greatly improve speed and is not to be considered a
general purpose interpreter able to make any Python code faster.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&quot;section&quot; id=&quot;more-readings&quot;&gt;
&lt;h3&gt;&lt;a&gt;More readings&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;&lt;a class=&quot;reference&quot; href=&quot;http://cython.org/&quot;&gt;Cython&lt;/a&gt; is a language that makes writing C extensions for the Python language as
easy as Python itself. It replaces the older &lt;a class=&quot;reference&quot; href=&quot;http://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/&quot;&gt;Pyrex&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;The &lt;a class=&quot;reference&quot; href=&quot;http://conference.scipy.org/proceedings/SciPy2008/&quot;&gt;SciPy2008&lt;/a&gt; conference had at least two papers talking about speeding Python:
&lt;a class=&quot;reference&quot; href=&quot;http://conference.scipy.org/proceedings/SciPy2008/paper_16/&quot;&gt;Converting Python Functions to Dynamically Compiled C&lt;/a&gt; and
&lt;a class=&quot;reference&quot; href=&quot;http://conference.scipy.org/proceedings/SciPy2008/paper_17/&quot;&gt;unPython: Converting Python Numerical Programs into C&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;David Beazley gave a very interesting talk in 2009 at a Chicago Python Users group meeting about the effects of the
&lt;a class=&quot;reference&quot; href=&quot;http://www.dabeaz.com/python/GIL.pdf&quot;&gt;GIL on multicore&lt;/a&gt; machines.&lt;/p&gt;
&lt;p&gt;I will continue my report on the conference with the second part titled
&amp;quot;Applications And Open Questions&amp;quot;.&lt;/p&gt;
&lt;/div&gt;
</description>
  <dc:date>2009-07-29T20:43-01:00</dc:date>
  <dc:creator>Nicolas Chauvat</dc:creator>
</item>
<item>
<guid isPermaLink="true">http://www.logilab.org/blogentry/9145</guid>
  <title>Reading SPE files</title>
  <link>http://www.logilab.org/blogentry/9145</link>
  <description>&lt;img alt=&quot;http://upload.wikimedia.org/wikipedia/commons/thumb/a/a1/CCD.jpg/300px-CCD.jpg&quot; class=&quot;align-right&quot; src=&quot;http://upload.wikimedia.org/wikipedia/commons/thumb/a/a1/CCD.jpg/300px-CCD.jpg&quot; style=&quot;height: 100px;&quot; /&gt;
&lt;p&gt;If you would like to read SPE files from &lt;a class=&quot;reference&quot; href=&quot;http://en.wikipedia.org/wiki/CCD_camera&quot;&gt;charge-coupled device (CCD) cameras&lt;/a&gt;, I have contributed a recipe to the SciPy cookbook, see &lt;a class=&quot;reference&quot; href=&quot;http://scipy.org/Cookbook/Reading_SPE_files&quot;&gt;Reading SPE files&lt;/a&gt;.&lt;/p&gt;
</description>
  <dc:date>2009-05-11T15:37-01:00</dc:date>
  <dc:creator>Andre Espaze</dc:creator>
</item>
<item>
<guid isPermaLink="true">http://www.logilab.org/blogentry/7867</guid>
  <title>LUTIN77: Logilab Unit Test IN fortran 77</title>
  <link>http://www.logilab.org/blogentry/7867</link>
  <description>&lt;p&gt;We&#39;ve just released a new project on logilab.org : lutin77. It&#39;s a test framework for Fortran77.&lt;/p&gt;
&lt;p&gt;The goal of this framework is to make unit tests in fortran 77 by having few dependencies: a POSIX environment with C and fortran 77 compilers. Of course, you can use it for making integration or acceptance tests too. The 0.1 version has just been released here: &lt;a class=&quot;reference&quot; href=&quot;http://www.logilab.org/project/lutin77&quot;&gt;http://www.logilab.org/project/lutin77&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;If you are new to the unit tests way of building software, I must admit it lacks examples. For an introduction to the techniques involved, you can have a look at &lt;a class=&quot;reference&quot; href=&quot;http://www.mockobjects.com/book/&quot;&gt;Growing Object-Oriented Software, Guided by Tests&lt;/a&gt; even if mocked subroutines will be for later. But remember that if you do not like to write tests, you are probably not writing unit tests.&lt;/p&gt;
</description>
  <dc:date>2009-01-28T15:19-01:00</dc:date>
  <dc:creator>Andre Espaze</dc:creator>
</item>
<item>
<guid isPermaLink="true">http://www.logilab.org/blogentry/5930</guid>
  <title>qgpibplotter is (hopefully) working</title>
  <link>http://www.logilab.org/blogentry/5930</link>
  <description>&lt;p&gt;My latest personal project, &lt;a class=&quot;reference&quot; href=&quot;http://www.logilab.org/project/pygpibtoolkit&quot;&gt;pygpibtoolkit&lt;/a&gt;, holds a simple &lt;a class=&quot;reference&quot; href=&quot;http://en.wikipedia.org/wiki/HPGL&quot;&gt;HPGL&lt;/a&gt; plotter trying to emulate the  &lt;a class=&quot;reference&quot; href=&quot;http://www.hpmuseum.net/display_item.php?hw=73&quot;&gt;HP7470A&lt;/a&gt; GPIB plotter, using the very nice and cheap &lt;a class=&quot;reference&quot; href=&quot;http://prologix.googlepages.com/&quot;&gt;Prologix&lt;/a&gt; USB-GPIB dongle.
This tool is (for now) called qgpibplotter (since it is using the &lt;a class=&quot;reference&quot; href=&quot;http://trolltech.com/products/qt/&quot;&gt;Qt4&lt;/a&gt; toolkit).&lt;/p&gt;
&lt;p&gt;Tonight, I took (at last) the time to make it work nicely. Well, nicely with the only device I own which is capable of plotting on the GPIB bus, my &lt;a class=&quot;reference&quot; href=&quot;http://www.home.agilent.com/agilent/product.jspx?cc=US&amp;amp;lc=eng&amp;amp;ckey=3562A:epsg:pro&amp;amp;nid=-536900193.536897245.00&amp;amp;id=3562A:epsg:pro&quot;&gt;HP3562A&lt;/a&gt; DSA.&lt;/p&gt;
&lt;p&gt;Now, you just have to press the &amp;quot;Plot&amp;quot; button of your test equipment, and bingo! you can see the plot on your computer.&lt;/p&gt;
&lt;img alt=&quot;http://www.logilab.org/image/5837?vid=download&quot; class=&quot;align-center&quot; src=&quot;http://www.logilab.org/image/5837?vid=download&quot; style=&quot;width: 450px;&quot; /&gt;
</description>
  <dc:date>2008-09-05T00:41-01:00</dc:date>
  <dc:creator>David Douard</dc:creator>
</item>
<item>
<guid isPermaLink="true">http://www.logilab.org/blogentry/5690</guid>
  <title>SciPy and TimeSeries</title>
  <link>http://www.logilab.org/blogentry/5690</link>
  <description>&lt;img alt=&quot;http://www.enthought.com/img/scipy-sm.png&quot; class=&quot;align-left&quot; src=&quot;http://www.enthought.com/img/scipy-sm.png&quot; /&gt;
&lt;p&gt;We have been using many different tools for doing statistical analysis with Python, including R, SciPy, specific C++ code, etc. It looks like the growing audience of SciPy is now in movement to have dedicated modules in &lt;a class=&quot;reference&quot; href=&quot;http://scipy.org/&quot;&gt;SciPy&lt;/a&gt; (lets call them &lt;a class=&quot;reference&quot; href=&quot;http://scipy.org/scipy/scikits/&quot;&gt;SciKits&lt;/a&gt;). See this &lt;a class=&quot;reference&quot; href=&quot;http://projects.scipy.org/pipermail/scipy-user/2008-August/017760.html&quot;&gt;thread&lt;/a&gt; in SciPy-user mailing-list.&lt;/p&gt;
</description>
  <dc:date>2008-08-04T10:56-01:00</dc:date>
  <dc:creator>Nicolas Chauvat</dc:creator>
</item>
<item>
<guid isPermaLink="true">http://www.logilab.org/blogentry/5656</guid>
  <title>Python for applied Mathematics</title>
  <link>http://www.logilab.org/blogentry/5656</link>
  <description>&lt;img alt=&quot;http://www.ams.org/images/siam2008-brain.jpg&quot; class=&quot;align-right&quot; src=&quot;http://www.ams.org/images/siam2008-brain.jpg&quot; style=&quot;width: 200px; height: 141px;&quot; /&gt;
&lt;p&gt;The presentation of Python as a tool for applied mathematics got &lt;a class=&quot;reference&quot; href=&quot;http://www.ams.org/ams/siam-2008.html#python&quot;&gt;highlighted&lt;/a&gt; at the 2008 annual meeting of the american Society for Industrial and Applied Mathematics (SIAM). For more information, read this &lt;a class=&quot;reference&quot; href=&quot;http://fdoperez.blogspot.com/2008/07/python-tools-for-science-go-to-siam.html&quot;&gt;blogpost&lt;/a&gt; and the &lt;a class=&quot;reference&quot; href=&quot;https://cirl.berkeley.edu/fperez/talks/0807_siam_intro_python_scicomp.pdf&quot;&gt;slides&lt;/a&gt;.&lt;/p&gt;
</description>
  <dc:date>2008-07-29T10:17-01:00</dc:date>
  <dc:creator>Nicolas Chauvat</dc:creator>
</item>
<item>
<guid isPermaLink="true">http://www.logilab.org/blogentry/5288</guid>
  <title>SciLab passe en logiciel libre</title>
  <link>http://www.logilab.org/blogentry/5288</link>
  <description>&lt;img alt=&quot;http://www.scilab.org/images/homepage/scilab_logo.png&quot; class=&quot;align-right&quot; src=&quot;http://www.scilab.org/images/homepage/scilab_logo.png&quot; /&gt;
&lt;p&gt;Bienvenue à SciLab version 5.0 dans le monde du logiciel libre. SciLab 5.0, plateforme open source de calcul scientifique sous licence &lt;a class=&quot;reference&quot; href=&quot;http://www.cecill.info&quot;&gt;CeCill&lt;/a&gt;, est une alternative crédible et maintenant reconnue comme telle à Matlab. Pour assurer le développement pérenne de Scilab, le consortium &lt;a class=&quot;reference&quot; href=&quot;http://www.scilab.org/fr/&quot;&gt;Scilab&lt;/a&gt; rejoint &lt;a class=&quot;reference&quot; href=&quot;http://www.digiteo.fr/accueil_fr.html&quot;&gt;DIGITEO&lt;/a&gt;, parc de recherche d&#39;envergure mondiale dans le domaine des sciences et
technologies de l&#39;information en Île-de-France.&lt;/p&gt;
</description>
  <dc:date>2008-06-16T17:33-01:00</dc:date>
  <dc:creator>Arthur Lutz</dc:creator>
</item>
<item>
<guid isPermaLink="true">http://www.logilab.org/blogentry/5085</guid>
  <title>Testing for NaN without depending on Numpy</title>
  <link>http://www.logilab.org/blogentry/5085</link>
  <description>&lt;p&gt;How can I test if a python float is &amp;quot;not a number&amp;quot; without depending on numpy? Simple, a nan value is different to any other value, including itself:&lt;/p&gt;
&lt;pre class=&quot;literal-block&quot;&gt;
def isnan(x):
    return isinstance(x, float) and x!=x
&lt;/pre&gt;
</description>
  <dc:date>2008-05-27T11:23-01:00</dc:date>
</item>
  </channel>
</rss>