Re: [Tutor] OpenMP

2010-10-09 Thread Ahmed AL-Masri
Thanks for fast responding. I will try to use the threads and see how the performance would be.. actually I am using that for my artificial neural network and the problem is regarding to the ANN limitation when I used a big no of inputs. so one way to overcome this problem is by distributing and

Re: [Tutor] WRITING XLS FROM OS.WALK()

2010-10-09 Thread Steven D'Aprano
On Sun, 10 Oct 2010 03:59:26 am Emile van Sebille wrote: > On 10/8/2010 8:55 PM Steven D'Aprano said... > > > I'm sorry to tell you that you've just reinvented the wheel. This > > was already solved, a long, long time ago. It is called the glob > > module: > > Only if glob now descends into the fil

Re: [Tutor] IDE for Python

2010-10-09 Thread Brian Jones
On Thu, Oct 7, 2010 at 11:23 AM, Juan Jose Del Toro wrote: > Dear List; > > In your experience what is the best IDE for Python? > > I've used SPE and IDLE, I've also seen people using Eclipse but which one > do you recommend? > There is no 'best for Python'. IDEs are made to please people, not l

Re: [Tutor] OpenMP

2010-10-09 Thread ALAN GAULD
Forwarding to the liist. Please use Reply All on responses. Alan Gauld Author of the Learn To Program website http://www.alan-g.me.uk/ - Original Message > From: Ahmed AL-Masri > To: Alan Gauld > Sent: Saturday, 9 October, 2010 19:50:58 > Subject: Re: [Tutor] OpenMP > > Thanks fo

Re: [Tutor] WRITING XLS FROM OS.WALK()

2010-10-09 Thread Alan Gauld
"David Hutto" wrote I'll put my questions in a knew thread if this is considered hijacking the OP. Well, it doesn''t have much to do with XLS files thats for sure so yes, if you are interested in further pursuing approaches to teaching programming a separate thread is probably better. :-)

Re: [Tutor] WRITING XLS FROM OS.WALK()

2010-10-09 Thread David Hutto
I'll put my questions in a knew thread if this is considered hijacking the OP. ___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor

Re: [Tutor] WRITING XLS FROM OS.WALK()

2010-10-09 Thread David Hutto
On Sat, Oct 9, 2010 at 2:23 PM, David Hutto wrote: > On Sat, Oct 9, 2010 at 1:58 PM, Alan Gauld wrote: >> >> "David Hutto" wrote should learn to program in assembler (or even microcode) then move to C and then to Python(or similar) and finally to 4G languages. >>> >>> Even old sch

Re: [Tutor] WRITING XLS FROM OS.WALK()

2010-10-09 Thread David Hutto
On Sat, Oct 9, 2010 at 1:58 PM, Alan Gauld wrote: > > "David Hutto" wrote >>> >>> should learn to program in assembler (or even microcode) then move >>> to C and then to Python(or similar) and finally to 4G languages. >> >> Even old schooler though would be that we're just directing electrical >>

Re: [Tutor] WRITING XLS FROM OS.WALK()

2010-10-09 Thread Alan Gauld
"David Hutto" wrote should learn to program in assembler (or even microcode) then move to C and then to Python(or similar) and finally to 4G languages. Even old schooler though would be that we're just directing electrical flow from an ac outlet through a dc converter and streaming it throu

Re: [Tutor] WRITING XLS FROM OS.WALK()

2010-10-09 Thread Alan Gauld
"David Hutto" wrote And in other news, is it better to be a programmer, or an electrician first? Well, I started as an electronic engineer writing software, then became a software engineer writing software for electronic engineers then gradually the software got bigger and more abstract and

Re: [Tutor] OpenMP

2010-10-09 Thread Alan Gauld
"Ahmed AL-Masri" wrote say I have two loops and I want to test in which processer go through... my question is how to do that and is it possible in python No, its not possible to do that explicitly and it shouldn't be. The OS (and interpreter if applicable) is best placed to decide how the CP

Re: [Tutor] OpenMP

2010-10-09 Thread Emile van Sebille
On 10/9/2010 9:55 AM Ahmed AL-Masri said... Hi, I have searched about how to use openMP using python and I couldn't fine any helpful info. anyone can help me on this. My idea is that to use the different processer core for each section. for ex. lets say I have two loops and I want to test in wh

Re: [Tutor] OpenMP

2010-10-09 Thread Evert Rol
> Hi, > I have searched about how to use openMP using python and I couldn't fine any > helpful info. anyone can help me on this. No openMP, but iPython could do what you want (parallel and some distributed computing): http://ipython.scipy.org/doc/stable/html/ Evert > > My idea is that to

Re: [Tutor] WRITING XLS FROM OS.WALK()

2010-10-09 Thread Emile van Sebille
On 10/8/2010 8:55 PM Steven D'Aprano said... I'm sorry to tell you that you've just reinvented the wheel. This was already solved, a long, long time ago. It is called the glob module: Only if glob now descends into the file system... which is why you'd choose os.walk instead. Emile __

[Tutor] OpenMP

2010-10-09 Thread Ahmed AL-Masri
Hi, I have searched about how to use openMP using python and I couldn't fine any helpful info. anyone can help me on this. My idea is that to use the different processer core for each section. for ex. lets say I have two loops and I want to test in which processer go through. ## core one should

Re: [Tutor] WRITING XLS FROM OS.WALK()

2010-10-09 Thread David Hutto
And in other news, is it better to be a programmer, or an electrician first? ___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor

Re: [Tutor] WRITING XLS FROM OS.WALK()

2010-10-09 Thread David Hutto
On Sat, Oct 9, 2010 at 4:12 AM, Alan Gauld wrote: > "David Hutto" wrote > >> > I'm sorry to tell you that you've just reinvented the wheel. This > was >> > already solved, a long, long time ago. It is called the glob > module: >> >> Hey,  buddy pal. Isn't it true that newbs should take of advanta

Re: [Tutor] Interpolation

2010-10-09 Thread David Hutto
Thanks buddy pal. ___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor

Re: [Tutor] WRITING XLS FROM OS.WALK()

2010-10-09 Thread Jed Smith
On Fri, Oct 8, 2010 at 3:34 PM, Susana Iraiis Delgado Rodriguez wrote: > for i in allfiles: >  print i >   a.write(i) >   a.write("\n") Are you sure you want to write bare data to a file ending in .xls? That might be confusing Excel, unless it has grown a sizable brain with respect t

Re: [Tutor] list of dict question

2010-10-09 Thread Alan Gauld
"Francesco Loffredo" wrote > On the next iteration you overwrite those two dictionaries > with new values then append them to the list again. > So you wind up with 2 copies of the updated dictionaries. > ... This is difficult for me too: why does this happen? Or, more correctly, why should th

Re: [Tutor] WRITING XLS FROM OS.WALK()

2010-10-09 Thread Alan Gauld
"Steven D'Aprano" wrote The specialist replied "The bill is $10 for my time, and $490 for knowing which was the right tool to use." Interesting modern variant on the version I heard A man's washing machine broke down so he called the plumber. The plumber looks at it for a few minutes th

Re: [Tutor] WRITING XLS FROM OS.WALK()

2010-10-09 Thread Alan Gauld
"David Hutto" wrote > I'm sorry to tell you that you've just reinvented the wheel. This > was > already solved, a long, long time ago. It is called the glob > module: Hey, buddy pal. Isn't it true that newbs should take of advantage of the fact that you have to solve the problem pythonica

Re: [Tutor] list of dict question

2010-10-09 Thread Francesco Loffredo
On 09/10/2010 9.37, Steven D'Aprano wrote: On Sat, 9 Oct 2010 06:05:57 pm Francesco Loffredo wrote: Alan's answer to Roelof made me think... I'm sorry, I don't know what your question is. You seem to have quoted various bits and pieces of text from earlier emails (text beginning with> signs).

Re: [Tutor] Interpolation

2010-10-09 Thread Steven D'Aprano
On Sat, 9 Oct 2010 05:32:29 pm David Hutto wrote: > Maybe I missed it, even in the google searches/manuals, but does > someone know of an introduction to python interpolation that show the > different forms of % > , as in %s = string, and %d = digit(i think, or correct me). http://docs.python.org/

Re: [Tutor] list of dict question

2010-10-09 Thread Steven D'Aprano
On Sat, 9 Oct 2010 06:05:57 pm Francesco Loffredo wrote: > Alan's answer to Roelof made me think... I'm sorry, I don't know what your question is. You seem to have quoted various bits and pieces of text from earlier emails (text beginning with > signs). Apart from the sentence beginning with "Al

Re: [Tutor] FW: list of dict question

2010-10-09 Thread Francesco Loffredo
On 08/10/2010 19.20, Roelof Wobben wrote: ... Oke, What I try to achieve is this : 1) Look if a team is known in stand. 2) If no, take care that the team is known in stand (this part I have written with your help) 3) if yes, make wedstrijden one more so wedstrijden is equal to number of pla

[Tutor] list of dict question

2010-10-09 Thread Francesco Loffredo
Alan's answer to Roelof made me think... On 08/10/2010 13.40, Francesco Loffredo wrote: Il 08/10/2010 10.02, Alan Gauld ha scritto: "Roelof Wobben" wrote I have this programm : tournooi = [{'thuis': 'A','uit': "B",'thuisscore': 20, 'uitscore': ... This was your answer to Roelof: On the