Re: installing libraries like numpy scipy matplotlib

2015-07-05 Thread Jens Thoms Toerring
memilanuk wrote: > On 07/04/2015 07:58 AM, Jens Thoms Toerring wrote: > > PIYUSH KUMAR wrote: > >> I have never used linux in my life.. only windows based computing.. So I > >> have problems in installing third party libraries in python. > > > > It depend

Re: installing libraries like numpy scipy matplotlib

2015-07-04 Thread Jens Thoms Toerring
package for your distro you don't need to worry at all - all dependencies will get installed automatically (so if you want to install package A and that needs package B, B will installed automatically before A is installed). > I also had problems installing PYKE last month. What were these p

Re: Help needed to create a Python extension library for an existing shared memory hash table library

2014-03-23 Thread Jens Thoms Toerring
ce I haven't used any of the alternatives I can't comment on how good they are. A list of them can be found here https://wiki.python.org/moin/IntegratingPythonWithOtherLanguages Regards, Jens -- \ Jens Thoms Toerring ___ j...@toerring.de

Re: Updating a filename's counter value failed each time

2013-06-17 Thread Jens Thoms Toerring
MRAB wrote: > On 17/06/2013 19:32, Jens Thoms Toerring wrote: > > As I wrote you need *single* quotes around strings in > > SQL statements. Double quotes won't do - this is SQL > > and not Python so you're dealing with a different lan- > > guage and thus dif

Re: Updating a filename's counter value failed each time

2013-06-17 Thread Jens Thoms Toerring
Νίκος wrote: > On 17/6/2013 8:54 μμ, Jens Thoms Toerring wrote: > > Also take care to check the filename you insert - a malicous > > user might cobble together a file name that is actually a SQL > > statement and then do nasty things to your database. I.e. never > >

Re: Updating a filename's counter value failed each time

2013-06-17 Thread Jens Thoms Toerring
eturns the number of rows modified by an INSERT or UPDATE. > Since for sure the filename the user selected is represented by a record > inside 'files' table why its corresponding counter never seems to get > updated? I would guess because you

Re: How to create new python file with increament number, if doesn't exist?

2013-05-27 Thread Jens Thoms Toerring
ythons open() function which rather likeky is based on C's fopen() function). The best advice to avoid such problems is probably not to open files with a predictable name (or better to use one of the methods to create files with names guaranteed to be unique by the system) in directories to wh

Re: in need of some help...

2013-05-12 Thread Jens Thoms Toerring
Chris Angelico wrote: > On Mon, May 13, 2013 at 7:56 AM, Jens Thoms Toerring wrote: > > Chris “Kwpolska” Warrick wrote: > >> Gmail automatically hides long quotes. This is helpful in situations > >> like this one. More mail software should implement that > >

Re: in need of some help...

2013-05-12 Thread Jens Thoms Toerring
Chris “Kwpolska” Warrick wrote: > (slightly offtopic, sorry.) > On Sun, May 12, 2013 at 12:20 AM, Jens Thoms Toerring > wrote: > > PS: If I may ask you a favor: consider refraining from using Google's > > completely broken interface to newsgroups - your post cons

Re: in need of some help...

2013-05-11 Thread Jens Thoms Toerring
Alex Norton wrote: > On Wednesday, 1 May 2013 13:15:28 UTC+1, Jens Thoms Toerring wrote: > > Of course, it might be nicer to have a "result" label some- > > where in the graphical interface which you set to the text > > instead of printing it out to the console.

Re: Making safe file names

2013-05-07 Thread Jens Thoms Toerring
rtists name) to a number. The drawback, of course, is that you can't translate back from the hash value to the original name (if that would be simple the whole thing wouldn't work;-) Regards, Jens -- \ Jens Thoms Toerring ___ j...@toerring.de \__ http://toerring.de -- http://mail.python.org/mailman/listinfo/python-list

Re: Why do Perl programmers make more money than Python programmers

2013-05-05 Thread Jens Thoms Toerring
In comp.lang.python Roy Smith wrote: > In article , > j...@toerring.de (Jens Thoms Toerring) wrote: > > Well, that didn't have a happy ending:-( Should have listened to > > my parents when they told me again and again "Never use Perl, just > > say no!". S

Re: Why do Perl programmers make more money than Python programmers

2013-05-05 Thread Jens Thoms Toerring
In comp.lang.python Rainer Weikusat wrote: > j...@toerring.de (Jens Thoms Toerring) writes: > > In comp.lang.python Steven D'Aprano > > wrote: > >> On Sun, 05 May 2013 12:11:11 -0500, Ignoramus16992 wrote: > > > >> > According to CIO.com

Re: Why do Perl programmers make more money than Python programmers

2013-05-05 Thread Jens Thoms Toerring
nd should I, while it lasts, get the Perl or the Python salary, or the mean or both combined? Got to consider that when applying for my next job! Regards, Jens -- \ Jens Thoms Toerring ___ j...@toerring.de \__ http://toerring.de -- http://mail.python.org/mailman/listinfo/python-list

Re: Help with loading file into an array

2013-05-05 Thread Jens Thoms Toerring
and hopefully will get you started. Concerning reading other files: here I may not understand your problem since it looks rather trivial to me by simply passing the open() method of 'Image' the name of a file in a different directory. Regards, Jens --

Re: Sum operation in numpy arrays

2013-05-02 Thread Jens Thoms Toerring
ive us what you actually use if you want something more helpful. Regards, Jens -- \ Jens Thoms Toerring ___ j...@toerring.de \__ http://toerring.de -- http://mail.python.org/mailman/listinfo/python-list

Re: in need of some help...

2013-05-01 Thread Jens Thoms Toerring
emoves Water, you win!' ) ... Now, when during the game the 'Air' button is clicked this function will get called. Of course, it might be nicer to have a "result" label some- where in the graphical interface which you set to the text instead of printing it out to the console. And you also will probably add some "Quit" button to end the game. Regards, Jens -- \ Jens Thoms Toerring ___ j...@toerring.de \__ http://toerring.de -- http://mail.python.org/mailman/listinfo/python-list

Re: File Read issue by using module binascii

2013-04-28 Thread Jens Thoms Toerring
haracter (i.e. single letter strings) and re- assembled it using join() and a for loop: r = list( rawdata( ) z = ''.join( x for x in r ) The second line alone took about 1.7 times longer than the whole, seemingly convoluted c1() function! What I take away from this is that a lot of the assumption one is prone to make when coming from e.g. a C/C++ background can be quite misleading when extrapolating to Python (or other in- terpreted languages)... Best regards, Jens -- \ Jens Thoms Toerring ___ j...@toerring.de \__ http://toerring.de -- http://mail.python.org/mailman/listinfo/python-list

Re: Nested For loop not running full

2013-04-26 Thread Jens Thoms Toerring
esponding value from the file (what you assign to 'classification') is simply the value of the dictionary for the key given by 'reg_num'. i.e. classification = d[ reg_num ] Regards, Jens -- \ Jens Thoms Toerring ___ j...@toerring.de \__ http://toerring.de -- http://mail.python.org/mailman/listinfo/python-list

Re: subprocess.call

2013-04-19 Thread Jens Thoms Toerring
"¶m4={3}¶m5={4}'" ) .format( value1, value2, value3, value4, value5 ) ] Note that there was one value for creating the string to be passed to lynx was mising. Regards, Jens -- \ Jens Thoms Toerring ___ j...@toerring.de \__ http://toerring.de -- http://mail.python.org/mailman/listinfo/python-list

Re: Writing to same file from two threads

2013-02-27 Thread Jens Thoms Toerring
Antoine Pitrou wrote: > Jens Thoms Toerring toerring.de> writes: > > > > Paul Rubin nospam.invalid> wrote: > > > jt toerring.de (Jens Thoms Toerring) writes: > > > > in garbled output (i.e. having some output from A inside a > > > > line

Re: Writing to same file from two threads

2013-02-26 Thread Jens Thoms Toerring
Paul Rubin wrote: > j...@toerring.de (Jens Thoms Toerring) writes: > > in garbled output (i.e. having some output from A inside a > > line written by B or vice versae) because the "main thread" or > Yes they do get garbled like that. Preferred Python style is put a

Writing to same file from two threads

2013-02-26 Thread Jens Thoms Toerring
d nothing else), what I'm worried about are context switches somewhere within the very innards of what write() does. -- \ Jens Thoms Toerring ___ j...@toerring.de \__ http://toerring.de -- http://mail.python.org/mailman/listinfo/python-list

Re: Messing with the GC

2013-01-20 Thread Jens Thoms Toerring
Terry Reedy wrote: > On 1/20/2013 3:09 PM, Jens Thoms Toerring wrote: > > thank you for the explanations. I had overlooked the > > cyclic nature of what I had produced here and, of course, > > the GC can't be blamed for not collecting objects that are > > par

Re: Messing with the GC

2013-01-20 Thread Jens Thoms Toerring
nd best regards, Jens -- \ Jens Thoms Toerring ___ j...@toerring.de \__ http://toerring.de -- http://mail.python.org/mailman/listinfo/python-list

Messing with the GC

2013-01-19 Thread Jens Thoms Toerring
efore. But then there are obviously no calls of the destructors of neither the second instance of the X class nor of the Y class instance. Shouldn't they be invoked before the program ends? Thanks and best regards, Jens -- \ Jens Thoms Toerring ___ j...@toerring.de \__ http://toerring.de -- http://mail.python.org/mailman/listinfo/python-list

Re: how to solve complex equation?

2013-01-01 Thread Jens Thoms Toerring
ed derivative of the function with respect to SN+1 (wbich you can take to be x). Regards, Jens -- \ Jens Thoms Toerring ___ j...@toerring.de \__ http://toerring.de -- http://mail.python.org/mailman/listinfo/python-list

Re: Strange effect with import

2012-12-21 Thread Jens Thoms Toerring
lobal variables;-) Probably the guys that wrote the SocketServer module indeed didn't expect people as dense as me to use their module and thus didn't mention that passing additional information to a handler object can be done this way... Best regards,

Re: Strange effect with import

2012-12-20 Thread Jens Thoms Toerring
sting at a first glance. Thank you for these ideas, I'll need a bit of time to figure out these new concepts and I don't think I'm up to it tonight any- more;-) Best regards. Jens -- \ Jens Thoms Toerring ___ j...@toerring.de \__ http://toerring.de -- http://mail.python.org/mailman/listinfo/python-list

Re: Strange effect with import

2012-12-20 Thread Jens Thoms Toerring
o accept just one argument, 'self'. And even if I would change the method to accept more arguments and that wouldnt blow up into my face, where would they be coming from (and from where would I pass them)? Best regards, Jens -- \ Jens Thoms T

Re: Strange effect with import

2012-12-20 Thread Jens Thoms Toerring
Thanks a lot to all three of you: that helped me understand the errors of my ways! You just saved me a few more hours of head-scratching;-) A few replies to the questions and comments by Steven: Steven D'Aprano wrote: > On Thu, 20 Dec 2012 20:39:19 +0000, Jens Thoms Toerring wrote: &g

Strange effect with import

2012-12-20 Thread Jens Thoms Toerring
simulate a kind of global variable shared between different files. Best regards, Jens -- \ Jens Thoms Toerring ___ j...@toerring.de \__ http://toerring.de -- http://mail.python.org/mailman/listinfo/python-list