[pypy-dev] Re: [Edu-sig] Properties use case
lac at strakt.com
Tue Mar 21 20:09:00 CET 2006
Douglas Blank just sent this to edu-sig.
I want to use PyPy to control Robots. Just think of the demos
we could make! :-)
In a message of Tue, 21 Mar 2006 12:58:55 EST, "Douglas S. Blank" writes:
>On Tue, 2006-03-21 at 11:57 -0500, Arthur wrote:
>> I am of course thinking whether I have been knee-jerk in bringing Numer
>> into play as a fundamental tool for my application.
>> Which I why I then move on to trying to get serious about gaining some
>> profiling skills. Gain some intelligence about the trade-offs of doing
>> kind of simple linear algebra my application requires in pure Python, v
>> what I may gaining by the creepy calls to laplack.
>> Judgment calls need to be made in the end, but I take them seriously en
>> to want them to be informed judgment calls.
>I've been wrestling with these issues. I've built a Python robotics 2D
>simulator in 99% Python, 1% Numeric. It works amazingly well: fast
>enough and realistic enough to do the job. The robot can have sonar, IR,
>and bumpers; lights, and light bulbs; a 2D camera with pan-zoom, and a
>gripper to pick up things. The world has some simple physics (bump a
>puck head-on and it will slide, with some friction).
>Then I extended it to be a 3D simulator. Still, amazingly, fast enough
>and realistic enough to do the job.
>On the one hand, I like all of the source code to be accessible to the
>student. We say that it is "Pythons all the way down". And that also
>makes it portable. But on the other hand, it has to run fast enough.
>We are able to do it all in Python, expect for the nitty gritty vision
>and image processing code, which we use SWIG and C++.
>I did some profiling, and was surprised at where some of the time was
>spent. (This simulator is also controlled over sockets, so I had some
>additional items to speed up). But, was able to refactor some, and get
>some very substantial speedup, just in the Python portion. castRay() is
>still the most expensive bit in Python.
>I am also looking at IronPython for .NET and Mono, and am wondering how
>much I can get in one layer (without going to C/C++) and how fast it
>Here are some pictures:
>> No conclusions as yet.
>Douglas S. Blank Computer Science
>Assistant Professor Bryn Mawr College
>Edu-sig mailing list
>Edu-sig at python.org
More information about the Pypy-dev