From urnerk at qwest.net Thu Jul 7 06:48:37 2005 From: urnerk at qwest.net (Kirby Urner) Date: Wed, 6 Jul 2005 21:48:37 -0700 Subject: [Edu-sig] More news from Europython Message-ID: <20050707044842.384341E4004@bag.python.org> So one of the biggest developments was Guido's approval to enhancements around 'yield', making a new gen.send(arg) method to supplement the already-defined gen.next(). gen.send(arg) will feed arguments to a yield *expression* i.e. a yield on the right side of an assignment operator, e.g. x = yield. gen.send(None) is equivalent to gen.next(). http://www.opensubscriber.com/message/patches at python.org/1624403.html http://www.python.org/peps/pep-0342.html I'm hoping we'll build some simpler examples than those provided in the PEP, using simple math concepts or just skeletal "means nothing" code. Kirby From peter at mapledesign.co.uk Sat Jul 9 11:57:41 2005 From: peter at mapledesign.co.uk (Peter Bowyer) Date: Sat, 09 Jul 2005 10:57:41 +0100 Subject: [Edu-sig] SOT: authoring course material Message-ID: <6.2.1.2.0.20050709105641.03cd87c8@127.0.0.1> Hi, As I sit down to write my course material I was wondering - what software do you use? Traditionally material in the physics department has always been written in LaTeX (uugh), with a printed copy given to the student, and a PDF of the printed copy available online. I need to produce a printable set of notes, but would also like to do a true web-based version. We've talked about testing the students with online multiple-choice quizzes and I'm keen to have expandable sections of the notes online (so the more advanced students don't have to read the basics, but can see advanced questions the others cannot). However, from past experience if there are not full printed notes there will be complaints, and as the computers aren't dual-monitor it would be hard to read online notes while working. What have you found works when teaching introductory programming? Also, have you found tools such as wikis useful when either developing the teaching material or writing the following report? Thanks, Peter From urnerk at qwest.net Mon Jul 18 20:18:18 2005 From: urnerk at qwest.net (Kirby Urner) Date: Mon, 18 Jul 2005 11:18:18 -0700 Subject: [Edu-sig] Writing presentation manager for OSCON, in Pygame In-Reply-To: <6.2.1.2.0.20050709105641.03cd87c8@127.0.0.1> Message-ID: <20050718181824.4C4D41E4002@bag.python.org> Sort of relevant to the queries below, I'm developing source materials for my upcoming presentation at OSCON 2005. I've determined that using closed source presentation software i.e. PowerPoint, would not be appropriate to this venue (smart me, huh?), and furthermore, using Impress or other OpenOffice-like PPT clone wouldn't be sufficiently Pythonic. Ergo, I'm writing my own presentation management software in Pygame. The basic structure is an outer event loop driven by keystrokes (no mouse) and rather few of them at that (left/right arrow, Stop, Restart, Pause, Unpause). Class definitions define slide content in terms of various resources: Autoflipimage, Movieplayer, Scrolltextfile, Stillimage and so on. Each slide is composed by a function, which calls the necessary parameters on the resources, all of which get sent as a list to a Scene object, which actually operates the content objects at runtime (e.g. by passing through keystrokes). Resources with internal dynamism (e.g. an Autoflipimage or MPEG movie clip) get their own threads, i.e. are subclassed from threading.Thread (plus an interface-like mixin). This is necessary to keep the outmost keystroke thread alive to the keyboard (it wouldn't do to get sucked into a resource and have to sit through a boring MPEG, even if you were ready to move on). In other words, I've leveraging that I know how to code, to cut right to the runtime display engine, completely bypassing / ignoring any need for GUI tools to define and structure the slides at design time. That's all done "programmatically" as they say -- which is too much work for most office cubies, but is far less work than coding a design time GUI, if you're a one-man-year-per-year type shop (my shop is somewhat more than that, but this OSCON thing I'm doing on my own time). I'm going to upload all this stuff with the GPL once my talk is done. I want the first venue (the showcase debut) to be at OSCON itself (first week in August, here in PDX). On my next Saturday Academy gig, I'll plan to keep using this Python + Pygame solution, as I'll be able to guide 'em around the source code, illustrating how one can do a lot with Python in < 1K lines of code. Kirby > -----Original Message----- > From: edu-sig-bounces at python.org [mailto:edu-sig-bounces at python.org] On > Behalf Of Peter Bowyer > Sent: Saturday, July 09, 2005 2:58 AM > To: edu-sig at python.org > Subject: [Edu-sig] SOT: authoring course material > > Hi, > > As I sit down to write my course material I was wondering - what software > do you use? Traditionally material in the physics department has always > been written in LaTeX (uugh), with a printed copy given to the student, > and > a PDF of the printed copy available online. > > I need to produce a printable set of notes, but would also like to do a > true web-based version. We've talked about testing the students with > online multiple-choice quizzes and I'm keen to have expandable sections of > the notes online (so the more advanced students don't have to read the > basics, but can see advanced questions the others cannot). However, from > past experience if there are not full printed notes there will be > complaints, and as the computers aren't dual-monitor it would be hard to > read online notes while working. > > What have you found works when teaching introductory programming? > > Also, have you found tools such as wikis useful when either developing the > teaching material or writing the following report? > > Thanks, > Peter > > _______________________________________________ > Edu-sig mailing list > Edu-sig at python.org > http://mail.python.org/mailman/listinfo/edu-sig From delza at livingcode.org Mon Jul 18 20:57:53 2005 From: delza at livingcode.org (Dethe Elza) Date: Mon, 18 Jul 2005 11:57:53 -0700 Subject: [Edu-sig] Writing presentation manager for OSCON, in Pygame In-Reply-To: <20050718181824.4C4D41E4002@bag.python.org> References: <20050718181824.4C4D41E4002@bag.python.org> Message-ID: Best wishes on your presentation, Kirby! At the Vancouver Python Conference last year, Paul Prescod joked that I was the only one writing my own presentation software. I also used PyGame, but in my case each "slide" was a mini-game (or game-in- progress). I'll note that it was the last time I ever used PyGame and I would have abandoned it sooner if I hadn't committed to doing a presentation about it. It reminded me of doing programming on the Mac in the 68K days, when you had to write your own main loop, your own event management, etc. Very primitive. If I need slide-show type presentations these days, I tend to go with S5[1] using Safari or Firefox. On the other hand, the next presentation I did for Paul (at the VanPyZ monthly meeting last February), I wrote the presentation software using Cocoa (OS X framework), Python, XML, and Renaissance (framework for turning XML into Cocoa UI). So perhaps I am a glutton for punishment. --Dethe [1] http://meyerweb.com/eric/tools/s5/ On 18-Jul-05, at 11:18 AM, Kirby Urner wrote: > > Sort of relevant to the queries below, I'm developing source > materials for > my upcoming presentation at OSCON 2005. I've determined that using > closed > source presentation software i.e. PowerPoint, would not be > appropriate to > this venue (smart me, huh?), and furthermore, using Impress or other > OpenOffice-like PPT clone wouldn't be sufficiently Pythonic. Ergo, > I'm > writing my own presentation management software in Pygame. > > The basic structure is an outer event loop driven by keystrokes (no > mouse) > and rather few of them at that (left/right arrow, Stop, Restart, > Pause, > Unpause). Class definitions define slide content in terms of various > resources: Autoflipimage, Movieplayer, Scrolltextfile, Stillimage > and so > on. Each slide is composed by a function, which calls the necessary > parameters on the resources, all of which get sent as a list to a > Scene > object, which actually operates the content objects at runtime > (e.g. by > passing through keystrokes). > > Resources with internal dynamism (e.g. an Autoflipimage or MPEG > movie clip) > get their own threads, i.e. are subclassed from threading.Thread > (plus an > interface-like mixin). This is necessary to keep the outmost > keystroke > thread alive to the keyboard (it wouldn't do to get sucked into a > resource > and have to sit through a boring MPEG, even if you were ready to > move on). > > In other words, I've leveraging that I know how to code, to cut > right to the > runtime display engine, completely bypassing / ignoring any need > for GUI > tools to define and structure the slides at design time. That's > all done > "programmatically" as they say -- which is too much work for most > office > cubies, but is far less work than coding a design time GUI, if > you're a > one-man-year-per-year type shop (my shop is somewhat more than > that, but > this OSCON thing I'm doing on my own time). > > I'm going to upload all this stuff with the GPL once my talk is > done. I > want the first venue (the showcase debut) to be at OSCON itself > (first week > in August, here in PDX). > > On my next Saturday Academy gig, I'll plan to keep using this Python + > Pygame solution, as I'll be able to guide 'em around the source code, > illustrating how one can do a lot with Python in < 1K lines of code. > > Kirby > > > >> -----Original Message----- >> From: edu-sig-bounces at python.org [mailto:edu-sig- >> bounces at python.org] On >> Behalf Of Peter Bowyer >> Sent: Saturday, July 09, 2005 2:58 AM >> To: edu-sig at python.org >> Subject: [Edu-sig] SOT: authoring course material >> >> Hi, >> >> As I sit down to write my course material I was wondering - what >> software >> do you use? Traditionally material in the physics department has >> always >> been written in LaTeX (uugh), with a printed copy given to the >> student, >> and >> a PDF of the printed copy available online. >> >> I need to produce a printable set of notes, but would also like to >> do a >> true web-based version. We've talked about testing the students with >> online multiple-choice quizzes and I'm keen to have expandable >> sections of >> the notes online (so the more advanced students don't have to read >> the >> basics, but can see advanced questions the others cannot). >> However, from >> past experience if there are not full printed notes there will be >> complaints, and as the computers aren't dual-monitor it would be >> hard to >> read online notes while working. >> >> What have you found works when teaching introductory programming? >> >> Also, have you found tools such as wikis useful when either >> developing the >> teaching material or writing the following report? >> >> Thanks, >> Peter >> >> _______________________________________________ >> Edu-sig mailing list >> Edu-sig at python.org >> http://mail.python.org/mailman/listinfo/edu-sig >> > > _______________________________________________ > Edu-sig mailing list > Edu-sig at python.org > http://mail.python.org/mailman/listinfo/edu-sig > Life is extinct on other planets. Their scientists were more advanced than ours. --Mark Russell -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 2488 bytes Desc: not available Url : http://mail.python.org/pipermail/edu-sig/attachments/20050718/884c9561/smime.bin From john.zelle at wartburg.edu Mon Jul 18 21:03:33 2005 From: john.zelle at wartburg.edu (John Zelle) Date: Mon, 18 Jul 2005 14:03:33 -0500 Subject: [Edu-sig] Writing presentation manager for OSCON, in Pygame In-Reply-To: <20050718181824.4C4D41E4002@bag.python.org> References: <20050718181824.4C4D41E4002@bag.python.org> Message-ID: <42DBFD05.8040802@wartburg.edu> Kirby, Is there any chance I could talk you into posting some of your code sooner, or at least an example of how the code to define a simple presentation might look? I've just begun working on a very similar project. I'm using PyQT (it's a learning project) rather than PyGame. I agree with the "programming" slides approach, but I've been around and around on the API, and am still not really satisfied. Eventually, I intend my work to be a platform for stereographic (VR) presentations allowing regular text and graphics to be interspersed with stereographic pictures, videos, and application demos. I'd be very interested in seeing your intended API for the slides. I might be able to build on what you're doing. If not, having a common API might still be useful (we could share slides). Any thought about how you might generate handouts of the slides? --John Kirby Urner wrote: > Sort of relevant to the queries below, I'm developing source materials for > my upcoming presentation at OSCON 2005. I've determined that using closed > source presentation software i.e. PowerPoint, would not be appropriate to > this venue (smart me, huh?), and furthermore, using Impress or other > OpenOffice-like PPT clone wouldn't be sufficiently Pythonic. Ergo, I'm > writing my own presentation management software in Pygame. > > The basic structure is an outer event loop driven by keystrokes (no mouse) > and rather few of them at that (left/right arrow, Stop, Restart, Pause, > Unpause). Class definitions define slide content in terms of various > resources: Autoflipimage, Movieplayer, Scrolltextfile, Stillimage and so > on. Each slide is composed by a function, which calls the necessary > parameters on the resources, all of which get sent as a list to a Scene > object, which actually operates the content objects at runtime (e.g. by > passing through keystrokes). > > Resources with internal dynamism (e.g. an Autoflipimage or MPEG movie clip) > get their own threads, i.e. are subclassed from threading.Thread (plus an > interface-like mixin). This is necessary to keep the outmost keystroke > thread alive to the keyboard (it wouldn't do to get sucked into a resource > and have to sit through a boring MPEG, even if you were ready to move on). > > In other words, I've leveraging that I know how to code, to cut right to the > runtime display engine, completely bypassing / ignoring any need for GUI > tools to define and structure the slides at design time. That's all done > "programmatically" as they say -- which is too much work for most office > cubies, but is far less work than coding a design time GUI, if you're a > one-man-year-per-year type shop (my shop is somewhat more than that, but > this OSCON thing I'm doing on my own time). > > I'm going to upload all this stuff with the GPL once my talk is done. I > want the first venue (the showcase debut) to be at OSCON itself (first week > in August, here in PDX). > > On my next Saturday Academy gig, I'll plan to keep using this Python + > Pygame solution, as I'll be able to guide 'em around the source code, > illustrating how one can do a lot with Python in < 1K lines of code. > > Kirby > > > >>-----Original Message----- >>From: edu-sig-bounces at python.org [mailto:edu-sig-bounces at python.org] On >>Behalf Of Peter Bowyer >>Sent: Saturday, July 09, 2005 2:58 AM >>To: edu-sig at python.org >>Subject: [Edu-sig] SOT: authoring course material >> >>Hi, >> >>As I sit down to write my course material I was wondering - what software >>do you use? Traditionally material in the physics department has always >>been written in LaTeX (uugh), with a printed copy given to the student, >>and >>a PDF of the printed copy available online. >> >>I need to produce a printable set of notes, but would also like to do a >>true web-based version. We've talked about testing the students with >>online multiple-choice quizzes and I'm keen to have expandable sections of >>the notes online (so the more advanced students don't have to read the >>basics, but can see advanced questions the others cannot). However, from >>past experience if there are not full printed notes there will be >>complaints, and as the computers aren't dual-monitor it would be hard to >>read online notes while working. >> >>What have you found works when teaching introductory programming? >> >>Also, have you found tools such as wikis useful when either developing the >>teaching material or writing the following report? >> >>Thanks, >>Peter >> >>_______________________________________________ >>Edu-sig mailing list >>Edu-sig at python.org >>http://mail.python.org/mailman/listinfo/edu-sig > > > _______________________________________________ > Edu-sig mailing list > Edu-sig at python.org > http://mail.python.org/mailman/listinfo/edu-sig > > -- John M. Zelle, Ph.D. Wartburg College Professor of Computer Science Waverly, IA john.zelle at wartburg.edu (319) 352-8360 From gvanrossum at gmail.com Mon Jul 18 21:04:40 2005 From: gvanrossum at gmail.com (Guido van Rossum) Date: Mon, 18 Jul 2005 12:04:40 -0700 Subject: [Edu-sig] Writing presentation manager for OSCON, in Pygame In-Reply-To: References: <20050718181824.4C4D41E4002@bag.python.org> Message-ID: At EuroPython I saw several PyGame-based presentations. Armin Rigo has been doing this for years and with impressive results (visualizing Greenlets for example). But the best one I saw was Gustavo Niemeyer's Solving Puzzles with Python: http://www.python-in-business.org/ep2005/talk.chtml?talk=1194&track=687 Very cool visalizations of the puzzles and their solutions. On 7/18/05, Dethe Elza wrote: > At the Vancouver Python Conference last year, Paul Prescod joked that > I was the only one writing my own presentation software. I also used > PyGame, but in my case each "slide" was a mini-game (or game-in- > progress). I'll note that it was the last time I ever used PyGame > and I would have abandoned it sooner if I hadn't committed to doing a > presentation about it. It reminded me of doing programming on the > Mac in the 68K days, when you had to write your own main loop, your > own event management, etc. Very primitive. If I need slide-show > type presentations these days, I tend to go with S5[1] using Safari > or Firefox. > > On the other hand, the next presentation I did for Paul (at the > VanPyZ monthly meeting last February), I wrote the presentation > software using Cocoa (OS X framework), Python, XML, and Renaissance > (framework for turning XML into Cocoa UI). So perhaps I am a glutton > for punishment. -- --Guido van Rossum (home page: http://www.python.org/~guido/) From urnerk at qwest.net Mon Jul 18 22:45:18 2005 From: urnerk at qwest.net (Kirby Urner) Date: Mon, 18 Jul 2005 13:45:18 -0700 Subject: [Edu-sig] Writing presentation manager for OSCON, in Pygame In-Reply-To: Message-ID: <20050718204525.4A3FB1E400D@bag.python.org> > From: edu-sig-bounces at python.org [mailto:edu-sig-bounces at python.org] On > Behalf Of Guido van Rossum > Sent: Monday, July 18, 2005 12:05 PM > To: Dethe Elza > Cc: edu-sig at python.org; Kirby Urner > Subject: Re: [Edu-sig] Writing presentation manager for OSCON, in Pygame > > At EuroPython I saw several PyGame-based presentations. Armin Rigo has > been doing this for years and with impressive results (visualizing > Greenlets for example). But the best one I saw was Gustavo Niemeyer's > Solving Puzzles with Python: > http://www.python-in-business.org/ep2005/talk.chtml?talk=1194&track=687 > > Very cool visalizations of the puzzles and their solutions. Yes. I also recall a Pygame-based presentation of how Psyco works. One of the Europython 5 min talks was on the need to work on a presentation package that provides features missing from PowerPoint (e.g. the source code). I don't have a way to actually access the shell from *within* Pygame (access to the Python shell without fiddling with windows being a desirable feature), but as I boot from IPython with a slide-number argument (default 0), I *am* able to easily drop out to shell by escaping from pygame (runs full screen), and then resume at the appropriate place. I envision my talk featuring both this Pygame thing, and the geometry-based VPython hypertoon during Q&A (like I did at Europython). BTW, my hypertoons article was accepted and is supposedly queued for publication in Pyzine any day now :-D. Kirby PS: I copied John Zelle my latest draft of the presentation manager per his special interest. John, your prototypes sound way more sophisticated (given your eventual goal of mixing in VR) than my lowly effort, as you'll shortly see. My API is still evolving e.g. some very basic parameters, such as slide title font color, are hard coded for now. I tend to hard code a lot to get things moving, then go back later and tease an API out of it, so that all parameters eventually come under programmatic control -- we hope in an easy-enough way. From rsenra at acm.org Tue Jul 19 03:56:06 2005 From: rsenra at acm.org (Rodrigo Dias Arruda Senra) Date: Mon, 18 Jul 2005 22:56:06 -0300 Subject: [Edu-sig] Writing presentation manager for OSCON, in Pygame In-Reply-To: <42DBFD05.8040802@wartburg.edu> References: <20050718181824.4C4D41E4002@bag.python.org> <42DBFD05.8040802@wartburg.edu> Message-ID: <20050718225606.2830eec4@Goku> [ John Zelle ] ------------------------------------------------------------ | I've just begun working on a very similar | project. I'm using PyQT (it's a learning project) rather than PyGame. I | agree with the "programming" slides approach, but I've been around and | around on the API, and am still not really satisfied. Eventually, I | intend my work to be a platform for stereographic (VR) presentations | allowing regular text and graphics to be interspersed with stereographic | pictures, videos, and application demos. | | I'd be very interested in seeing your intended API for the slides. I | might be able to build on what you're doing. If not, having a common API | might still be useful (we could share slides). | | Any thought about how you might generate handouts of the slides? At Europython(Goteborg), my two presentations were created using py2slide, an alpha-quality tool I've been coding to generate from reST [1] blocks into Eric Meyer's S5 HTML [2] format. My motivation was rapid presentation development based on reusing slides to better fit a particular audience. I also plan to have a Pygame backend, so I look forward to colaborate in a slide2pygame tool. py2slide presentations looks like the following: from py2slide.py2slide import BasePresentation, BaseSlide, get_slides from py2slide.py2slide import RestSlide as _ import py2slide.rodskin as myskin roadmap = _(""" This speech talks about ======================= * How **big** is the Brazilian Python Community (BPC) ? * How **fast** does it grow ? * First Conference **PyConBrasil** held April 2005 * Who's **Who** * What are we doing with Python, Zope and Plone """) growth = _(""" How big can it get ? ==================== .. image:: images/sucuri.png """) base = BasePresentation( presenter_name = 'Rod Senra (rsenra at acm.org)', presenter_affiliation = 'IC-Unicamp/GPr', location_and_date = 'Europython 2005', slide_footer = myskin.slide_footer ) base.custom_stylesheet_files.append(myskin.mycss) base.title = 'The Python Community in Brazil' base.slides = [me, roadmap, growth, mailing, lists, portal, portal2, pyconbr1, fisl6, fisl6b, conclusion, thanks, eve] base.save_html(output_dir='pybr') [1] http://docutils.sourceforge.net/docs/user/rst/quickstart.html [2] http://www.meyerweb.com/eric/tools/s5/ best regards, Rod Senra -- Rodrigo Senra ------------------------------------------------ GPr Sistemas http://www.gpr.com.br Blog http://rodsenra.blogspot.com IC - Unicamp http://www.ic.unicamp.br/~921234 ------------------------------------------------ From urnerk at qwest.net Tue Jul 19 04:17:44 2005 From: urnerk at qwest.net (Kirby Urner) Date: Mon, 18 Jul 2005 19:17:44 -0700 Subject: [Edu-sig] Writing presentation manager for OSCON, in Pygame In-Reply-To: <20050718225606.2830eec4@Goku> Message-ID: <20050719021751.52EC41E4007@bag.python.org> > roadmap = _(""" > This speech talks about > ======================= > > * How **big** is the Brazilian Python Community (BPC) ? > * How **fast** does it grow ? > * First Conference **PyConBrasil** held April 2005 > * Who's **Who** > * What are we doing with Python, Zope and Plone > > """) Interesting work Rodrigo. My setup code is not so friendly.[1] A Linux Journal issue I think it was, a few months back, was about coding as art project, i.e. you're doing a one-off but using code in some interesting, inspiring way. That's probably the fate of my particular pgtest1.py -- it won't go anywhere far beyond OSCON, and yet will make ripples, in its own way. Kirby [1] example, a scene I just finished, using a slightly more advanced copy of the source than sent Zelle & Bauman. """ Urner, GPL """ ... def setscene14(s): graphics = [] for i in range(1,12): filename = "cubanim"+str(i).zfill(2) graphics.append(fpath + filename + ".png" ) mobj0 = Content() mobj0.content_type = 'autoflip' mobj0.topleft = (400,100) mobj0.imagelist = graphics mobj0.milliseconds = 100 mobj1 = Content() mobj1.content_type = 'stilltext' mobj1.filename = fpath + "ccp.py" mobj1.fontsize = 20 mobj1.topleft = (60,200) mobj2 = Content() mobj2.content_type = 'coderunner' mobj2.topleft = (450,350) def ccp(): shell, accum = 1,1 yield (shell, accum) f = 1 while True: shell = 10*f*f + 2 f += 1 accum += shell yield shell,accum mobj2.generator = ccp mobj2.milliseconds = 1000 mobj3 = Content() mobj3.content_type = 'autoflip' mobj3.topleft = (350,400) mobj3.imagelist = [fpath + 'smbellbigkite.jpg', fpath + 'vesphere.jpg'] mobj3.milliseconds = 1000 mobj4 = Content() mobj4.content_type = 'stillimage' mobj4.topleft = (750,200) mobj4.filename = fpath + 'tetrapack.gif' scene = Scene( s, 'white', 'Closest Packing of Spheres', 13, contents = [mobj2, mobj0, mobj1, mobj3, mobj4]) return scene From rsenra at acm.org Tue Jul 19 05:13:24 2005 From: rsenra at acm.org (Rodrigo Dias Arruda Senra) Date: Tue, 19 Jul 2005 00:13:24 -0300 Subject: [Edu-sig] Writing presentation manager for OSCON, in Pygame In-Reply-To: <200507190231.j6J2VYB03552@maceio.ic.unicamp.br> References: <20050718225606.2830eec4@Goku> <200507190231.j6J2VYB03552@maceio.ic.unicamp.br> Message-ID: <20050719001324.04622a29@Goku> [ Kirby Urner ] ------------------------------------------------------------ | Interesting work Rodrigo. Thank you. By the way, I hope you have found your missing coat. (I was the one giving speech right after yours at Goteborg ;o) | My setup code is not so friendly. It is friendly enough to be weaved (someday) into my py2slide tool as something like: | def setscene14(s): | graphics = [] | for i in range(1,12): | filename = "cubanim"+str(i).zfill(2) | graphics.append(fpath + filename + ".png" ) | mobj0 = Content() | mobj0.content_type = 'autoflip' | mobj0.topleft = (400,100) | mobj0.imagelist = graphics | mobj0.milliseconds = 100 | .... | #cut anim1 = _(""" Closest Packing of Spheres ========================== .. scene:: setscene14 """) Therefore, I could mix classic static slides with *cool* live-action slides as long as the target format (in this case: pygame) supports it. ** off-topic, but education related --> from this point on ** By the way, I did not have the opportunity during Europython to tell you (Kirby) about an experiment I did here in Brazil while teaching introductory courses. So I'll dare telling it now to you and edu-sig as well. The motivation was the huge heterogeneity of students backgrounds in introductory courses. Some students knew how to program in C++, VB, PHP, etc while others barely had experience with computers (although that was an outlier). The idea is called: The Big Brother. It's goal is to foster experienced students to "adopt, tutor, and monitor" the development of less experienced students during the course. In the beginning of the course everybody took a clustering exam, to classify students into: experienced (big brothers), grey, newbie. Students in grey zone can choose not to participate, or to migrate for any of the other two clusters. The catch is the following: A fraction of the measured progress in the newbie's grades goes to its respective big brother's grades. There was a fierce battle to adopt the student that failed badly during the clustering exam. I beleive this is a win-win-win situation: - the teacher gets many free-of-charge assistants - newbies get the close attention they usually need - experienced students have a chance to earn extra credit I only had few opportunities to put that in practice. # One of them teaching Python to Comp.Science undergraduates. So if you like the idea, and do it, I'm interested in feedback. best regards, Rod Senra -- Rodrigo Senra ------------------------------------------------ GPr Sistemas http://www.gpr.com.br Blog http://rodsenra.blogspot.com IC - Unicamp http://www.ic.unicamp.br/~921234 ------------------------------------------------ From urnerk at qwest.net Tue Jul 19 16:39:21 2005 From: urnerk at qwest.net (Kirby Urner) Date: Tue, 19 Jul 2005 07:39:21 -0700 Subject: [Edu-sig] Writing presentation manager for OSCON, in Pygame In-Reply-To: <20050719001324.04622a29@Goku> Message-ID: <20050719143929.51FC91E4002@bag.python.org> > [ Kirby Urner ] > ------------------------------------------------------------ > | Interesting work Rodrigo. > > Thank you. By the way, I hope you have found your missing coat. > (I was the one giving speech right after yours at Goteborg ;o) > Thank you. I *did* find it, in the upstairs breakfast area, student center, next morning. A zippered fleece paired with my windbreaker, but removable, black, word 'Flex' on it. Glad to get it back. :-D > Therefore, I could mix classic static slides with *cool* live-action > slides as long as the target format (in this case: pygame) supports it. > Yes, that's the idea. I don't well understand Pygame vis-?-vis PyOpenGL so what all capabilities my slides could have I'm not sure. I'm going to demo on the Toshiba at Wwwanderers this AM -- that's a group I belong to, meets at Linus Pauling's boyhood home a few blocks from here (a move afoot to change name of Hawthorne Blvd. to Linus Pauling Ave. or something, but that'd be for local merchants to contemplate (it's not a street I own a biz on, unless you count the Fred Meyer's). > > I only had few opportunities to put that in practice. > # One of them teaching Python to Comp.Science undergraduates. > So if you like the idea, and do it, I'm interested in feedback. > > best regards, > Rod Senra Your clustering then mentoring idea is excellent; stratification into classes, with upper tasked to assist the lower in making a next step -- not a competitive "keep them down behind me" circus. As faculty at St. Dom's in JCNJ, I allowed similar "pairing" -- i.e. "accepted student authorities" (an assortment) in the subject I was teaching (which was mostly some brand of text book math) were openly consulted by other students during work times -- the more math-adept became my para-teachers. Kirby From urnerk at qwest.net Wed Jul 20 01:53:42 2005 From: urnerk at qwest.net (Kirby Urner) Date: Tue, 19 Jul 2005 16:53:42 -0700 Subject: [Edu-sig] Writing presentation manager for OSCON, in Pygame In-Reply-To: <20050719143929.51FC91E4002@bag.python.org> Message-ID: <20050719235348.B3C7F1E4002@bag.python.org> Some spam assassin has been getting between John Zelle and myself, so I've gone ahead and created a stub web page with a link to my presentation manager source insofar as I've updated it (I'll refresh it from time to time, as I fine tune the code -- it's basically finished in that if I had to give the talk today, I could). http://www.4dsolutions.net/ocn/oscon2005.html Kirby From urnerk at qwest.net Sun Jul 24 22:34:34 2005 From: urnerk at qwest.net (Kirby Urner) Date: Sun, 24 Jul 2005 13:34:34 -0700 Subject: [Edu-sig] Hypertoons! In-Reply-To: <20050315063313.D7A711E4006@bag.python.org> Message-ID: <20050724203439.C3D151E4007@bag.python.org> > > http://www.4dsolutions.net/ocn/python/hypertoons/ > > My proposal to speak at OSCON this year was accepted. This Hypertoon > concept will be a part of my talk, along with Elastic Interval Geometry > and some other stuff. > > Kirby > On the Hypertoons front, I thought we were done with the drafts for Pyzine, as I'd sent several, and only got back suggestions the problem was on that end, with parsing software. I even went to the trouble to convert it to restructured text, which is an unnecessary step if we're not yet in final formatting. Now it turns out the article is unacceptable as it stands, is in need of a substantial rewrite. News to me. I'm tired of working with Pyzine and will no longer give them the option to publish my article. Kirby From rsenra at acm.org Sun Jul 24 23:12:41 2005 From: rsenra at acm.org (Rodrigo Dias Arruda Senra) Date: Sun, 24 Jul 2005 18:12:41 -0300 Subject: [Edu-sig] Hypertoons! In-Reply-To: <20050724203439.C3D151E4007@bag.python.org> References: <20050315063313.D7A711E4006@bag.python.org> <20050724203439.C3D151E4007@bag.python.org> Message-ID: <20050724181241.5939d82c@Goku> [ Kirby Urner ] ------------------------------------------------------------ | Now it turns out the article is unacceptable as it stands, is in need of a | substantial rewrite. News to me. I'm tired of working with Pyzine and will | no longer give them the option to publish my article. That is sad news. Nevertheless, I'm convinced that many of us nourish hope of seeing your article surface somewhere else. By the way, even though [1] makes reference to [2] and therefore to Hypertoons, maybe mentioning Hypertoons directly in [1] would be appropriate ? [1] http://www.python.org/sigs/edu-sig/ [2] http://www.4dsolutions.net/ocn/cp4e.html best regards, Rod Senra -- Rodrigo Senra ------------------------------------------------ GPr Sistemas http://www.gpr.com.br Blog http://rodsenra.blogspot.com IC - Unicamp http://www.ic.unicamp.br/~921234 ------------------------------------------------ From urnerk at qwest.net Sun Jul 24 23:26:28 2005 From: urnerk at qwest.net (Kirby Urner) Date: Sun, 24 Jul 2005 14:26:28 -0700 Subject: [Edu-sig] Hypertoons! In-Reply-To: <20050724181241.5939d82c@Goku> Message-ID: <20050724212635.9C9D41E4007@bag.python.org> > -----Original Message----- > From: edu-sig-bounces+urnerk=qwest.net at python.org [mailto:edu-sig- > bounces+urnerk=qwest.net at python.org] On Behalf Of Rodrigo Dias Arruda > Senra > Sent: Sunday, July 24, 2005 2:13 PM > To: edu-sig at python.org > Subject: Re: [Edu-sig] Hypertoons! > > [ Kirby Urner ] > ------------------------------------------------------------ > | Now it turns out the article is unacceptable as it stands, is in need > of a > | substantial rewrite. News to me. I'm tired of working with Pyzine and > will > | no longer give them the option to publish my article. > > That is sad news. Nevertheless, I'm convinced that many of us nourish > hope of seeing your article surface somewhere else. I just slapped it up on my cp4e.html, where it could have been all along. But since an editor of Pyzine approached me at Pycon, having sat through my open space session (people could book them at will), and suggested I submit an article to his magazine, I was giving Pyzine first dibs. That commitment stretched through many weeks and months (Pycon was last March), but was never infinite. I'll just self-publish, charge nothing, and enjoy whatever circulation the reading deserves. Yes, it's possible that reworking with some Pyzine editor could have substantially improved it, but the process wasn't working, as I'd already been asked to reformat in restructured text, whereas Word PDFs were fine for advancing copy or proofs. > > By the way, even though [1] makes reference to [2] and therefore to > Hypertoons, maybe mentioning Hypertoons directly in [1] would be > appropriate ? > > [1] http://www.python.org/sigs/edu-sig/ > [2] http://www.4dsolutions.net/ocn/cp4e.html > > best regards, > Rod Senra > Now that Hypertoons! has a link from the cp4e page, I think we've got a clean linking architecture. A goal with sigs/edu-sig (the web page) is not to promote my own projects too much. Kirby From urnerk at qwest.net Thu Jul 28 20:06:50 2005 From: urnerk at qwest.net (Kirby Urner) Date: Thu, 28 Jul 2005 11:06:50 -0700 Subject: [Edu-sig] More Pythonic Mathematics Message-ID: <20050728180658.3D3B11E4002@bag.python.org> This morning I posted to the Math Forum about how an algebra student, armed with Python, might explore 'composition of functions' using operator overloading. Wrap ordinary function definitions in the Function class below, and you still have __call__ (to get range outputs from domain inputs), plus you have the ability to write h = f * g where f and g and Function objects, and h is a new function object such that h(x) == f(g(x)) for all x. An important aspect of algebra is polymorphism around * and + (multiplication and addition). These become known in terms of their field, ring and group properties, somewhat obscuring their origins in basic arithmetic. We multiply matrices and polynomials, quaternions and permutations. Python's operator overloading makes it easier to see what's going on: we're putting the definition of __mul__ under the programmer-mathematician's control One of the most primitive of all functions is the mapping of letters to letters, e.g. A->R, B->Q, C->C, D->Z... according to whatever random shuffle. The composition of P1 and P2 then becomes the result of mapping A to R per P2, then R to whatever per P1 (say Z), such that A->Z is the result of P1 * P2. The notions of inverse and identity mapping are well defined. Group properties may be explored (the beginning of abstract algebra). Notice that my algebraic functions below (a quadratic and a linear) need to have their inverses specified by the programmer, should it be that negative powering is likely to happen (for example). Some languages attempt to provide this automatically in simple cases, leaving it to the user to supply it otherwise (I'm thinking of J in particular). I'm not trying to be that fancy. Kirby Relevant post to math-teach: http://mathforum.org/kb/plaintext.jspa?messageID=3863728 #===================================== >>> def f(x): return x*x >>> def g(x): return 2*x + 3 >>> class Function(object): def __init__(self, f, invf = None): self.f = f self.invf = invf def __call__(self,x): return self.f(x) def __mul__(self, other): def newf(x): return self.f( other.f(x)) return Function( newf ) def __pow__(self, exp): if exp==1: return self newself = Function(self.f) if exp < 1: newself = Function(self.invf) for i in range(exp-1): newself *= self return newself #--- composition of function objects using __mul__ >>> of = Function(f) >>> og = Function(g) >>> oh = of * og >>> oh(10) 529 >>> oj = og * of >>> oj(10) 203 >>> import math >>> def invf(x): return math.sqrt(x) #--- expanding to integer powers (including negative powers). >>> of = Function(f, invf) >>> newf = of**(-1) >>> h = newf * of >>> h(10) 10.0 >>> h(20) 20.0 From urnerk at qwest.net Thu Jul 28 23:38:34 2005 From: urnerk at qwest.net (Kirby Urner) Date: Thu, 28 Jul 2005 14:38:34 -0700 Subject: [Edu-sig] Thinking about Open Source Message-ID: <20050728213841.1564D1E4003@bag.python.org> I just read Andy Oram's article about an audience outburst after some guy at a Linux conference used Windows + PowerPoint to do a presentation: http://www.onlamp.com/pub/wlg/7438 I'll be interested what reactions I get to using a WinXP laptop to present at OSCON (I used a Linux box last year). My Toshiba Satellite is my best laptop by far, and though I *could* run my Python + Pygame presentation on my daughter's Compaq under Mandrake 9.2, that'd be less satisfying. Open Source is a layered affair, as Tim O'Reilly likes to point out. You've got this LAMP layer that's open, but then groups like Amazon and Google build these web applications that are not really open, even if they sit atop LAMP in a big way. Plus the chips are proprietary. And even when a layer is open, you *still* need years of training to dive in, in many cases. The idea that the OS kernel is free is a good one, but let's not forget that free means extrinsic barriers of secrecy and property rights have been addressed -- but there's *still* the intrinsic barrier of needing to learn how the kernel works, before you mess with it. The tension is between "information" and "knowledge." Source code on a hard drive is information that may turn into knowledge in the mind of someone who can read and understand it. FOSS is about making information freely available. But that doesn't remove the need for training and expertise. If you don't know how to read, Project Gutenberg won't be of such direct help or relevance. So Python source code provides this layer in the stack. I've got this presentation manager that runs on Linux or Windows or Mac. The content of the presentation may be closed, secret or otherwise restricted. The platform on which the Python runs may be more or less open (in the case of WinXP, it's closed). But in the middle, you've got code that a Python programmer might read and improve upon -- open source, released under the GPL. I think when humans encounter one another, this is a lot how it is: we'll be perfectly open about some things, closed about others. But the stuff we're open about may not register with others, as they're not prepared to deal with the information we're sharing. I talk about some area of math (open source) and they glaze over. Or they do, and I do. Only sometimes, do I freely communicate on a wavelength that another is equally able to interpret. In those times, a meeting of the minds occurs -- a rare enough event, especially among specialists with a lot of deep knowledge and divergent interests. Kirby From urnerk at qwest.net Fri Jul 29 07:20:33 2005 From: urnerk at qwest.net (Kirby Urner) Date: Thu, 28 Jul 2005 22:20:33 -0700 Subject: [Edu-sig] More Pythonic Mathematics In-Reply-To: <20050728180658.3D3B11E4002@bag.python.org> Message-ID: <20050729052039.EB6BA1E4002@bag.python.org> # excerpt from class Function (see earlier in thread): > def __pow__(self, exp): > if exp==1: return self > newself = Function(self.f) > if exp < 1: > newself = Function(self.invf) > for i in range(exp-1): > newself *= self > return newself Note that my __pow__ definition fails to return the identify function (e.g. def e(x): return x) when the exponent is 0. f**0 should return e, where f is some Function object. Rather than fix my code right here and now, I'll leave it broken and point to this note as a cue to readers (and I'm one of those readers): feel free to add the missing functionality. Good habit in open source world: feel free to fix stuff that's broken. Sometimes the original coder just didn't need what you're adding, so it may be your job to put icing on the cake or whatever it is (hey, maybe the original coder didn't like icing). In the other hand, be aware that your fixing stuff may also break stuff, which is why in collaborative environments we like to have an audit trail and sometimes a way of rolling back repository commits, if only to establish a branch point along which to pursue some alternative (forked) development. We might call this a "schism" but often it's far friendlier than that: two promising stratagems suggest themselves and crews explore both possibilities -- no crime in that. Kirby PS: I useful title/chapter for guiding explorations of permutations, per a recommended connected topic at this point is: I.N. Herstein. Abstract Algebra. New York: Macmillan Publishing Company (c) 1986. ISBN 0-02-353820-1. See: Chapter 1, Sec. 4: A(S) (The Set of 1-1 Mappings of S Onto Itself).