| |
thread by: amdescombes |
last post Oct 19 '07 by: AMD
Hi,
I am using Python 2.5.1
I have an application that reads a file and generates a key in a
dictionary for each line it reads. I have managed to read a 1GB file and
generate more than 8 million keys on an Windows XP machine with only 1GB
of memory and all works as expected. When I use the same program on a
Windows 2003 Server with 2GB of...
|
thread by: milan_sanremo |
last post Oct 19 '07 by: Lawrence Oluyede
I've read the library entry for pickle a couple of times, and I'm
still not
sure what data is maintained when an item is pickled and sent over a
socket.
Two importable modules:
class envelope():
def __init__(self, rec, d):
self.recipient = rec
|
thread by: abarun22 |
last post Oct 19 '07 by: abarun22
Hi
I am facing a problem while including a C header file in the SWIG
interface file. However the problem does not occur when i directly
copy the contents of header file in the same place.
My interface file read as follows.
/* interface file dep.i */
%module dep
%{
#include "dep.h"
|
thread by: Ixiaus |
last post Oct 19 '07 by: Grant Edwards
I have recently (today) just started learning/playing with Python. So
far I am excited and impressed (coming from PHP background).
I have a few questions regarding Python behavior...
val = 'string'
li = list(val)
print li.reverse()
returns nothing, but,
|
thread by: Robin Becker |
last post Oct 19 '07 by: Robin Becker
I'm using deepcopy in some code which eventually ends up by crash witht he
following rather long winded error. I'm not directly using _hashlib.HASH, but I
suppose something else along the way could be. Is there some nice way to make
copy/deepcopy give more information when this error happens? I know what the top
level object is, but presumably...
|
thread by: SingingDoughnut |
last post Oct 19 '07 by: KaezarRex
Hi Im currently building a script game, soon to be image game. Having trouble with a part of a code.
ranger_join = raw_input("\nWill you let him?(y/n)? ")
if ranger_join == "y":
print "The ranger joins you on your trip. Yay."
elif ranger_join == "n":
print "The ranger is offended and draws his sword.\n"
# attacking the...
|
thread by: Abandoned |
last post Oct 19 '07 by: Hrvoje Niksic
I want to convert a string to command..
For example i have a string:
a=""
I want to do this list..
How can i do ?
|
| |
thread by: Tim Arnold |
last post Oct 19 '07 by: Tim Arnold
Hi, I'm using the Image module to resize PNG images from 300 to 100dpi for
use in HTML pages, but I'm losing some vertical and horizontal lines in the
images (usually images of x-y plots).
Here's what I do:
import Image
def imgResize(self,filename):
img = Image.open(filename)
dpi = img.info.get('dpi')
if dpi and 295 < int(dpi) < 305:
|
thread by: zooey |
last post Oct 19 '07 by: kyosohma
Hi there,
I want to make transparent/launcher-like window application using python.
(similar as Enso, Launchy, etc. I know Enso written in python.)
Is there any open source project like it or any example?
Thanks,
|
thread by: jipjip |
last post Oct 19 '07 by: Marc 'BlackJack' Rintsch
Hello all,
just new to python..
Suppose i have a directory only with an empty file "pickle.py".
In this directory i start the python interpreter and say:
What happens?
I get an error message:
Traceback (most recent call last):
|
thread by: Frank Aune |
last post Oct 19 '07 by: Vinay Sajip
Hello,
I've been playing with the python logging module lately, and I manage to log
to both stderr and MySQL database.
What I'm wondering, is if its possible to specify the database handler in a
config file like:
class=DBHandler
|
thread by: Bierny |
last post Oct 19 '07 by: Bierny
Hi All!
I am writting a small script that will find a parent pid and from this point find a parent of a parent in order to kill this last parent :-)
I know it sounds stange (at least ... ) but this is really what i have to do. So
When the script starts it find it's parent pid, like this
ppid = os.getppid()
Afterwards a list of active...
|
thread by: Thomas Guettler |
last post Oct 19 '07 by: Thomas Guettler
Hi,
CGIHTTPServer does not support redirects
Is there an other python-only way to get a web server
running wich can execute python code?
Since I already use flup. I think there is not much
missing to get it serving as http server.
|
thread by: dmitrey |
last post Oct 19 '07 by: dmitrey
Hi all,
I have the code like this one:
from myMisc import ooIter
class MyClass:
def __init__(self): pass
iterfcn = lambda *args: ooIter(self) # i.e pass the class instance
to other func named ooIter
field2 = val2
field3 = val3 # etc
|
thread by: Pradnyesh Sawant |
last post Oct 19 '07 by: Pradnyesh Sawant
Hello,
I have the following single line in my .py file:
from PyQt4 import QtCore, QtGui
if i run it from eric, i get the following error:
unhandled RuntimeError
"the PyQt4.QtCore and qt modules both wrap the QObject class"
|
| |
thread by: Ixiaus |
last post Oct 19 '07 by: Ixiaus
I have just come across a site that discusses Python's 'for' and
'while' loops as having an (optional) 'else' structure.
At first glance I interpreted it as being a bit like the 'default'
structure in PHP's switch block... But the switch block isn't a loop,
so, I am now confused as to the reason for using 'else' with the for
and while...
|
thread by: minkoo.seo |
last post Oct 19 '07 by: bambam
Hi.
I've got a question on the differences and how to define static and
class variables. AFAIK, class methods are the ones which receives the
class itself as an argument, while static methods are the one which
runs statically with the defining class.
Hence, my understanding is that static variables must be bound to the
class defining the...
|
thread by: tedpottel |
last post Oct 18 '07 by: Andreas Kraemer
Hi,
Does any one know whare I can find some code to phrase a rss feeds?
Thank you,
Ted
|
thread by: Sami Vaisanen |
last post Oct 18 '07 by: Sami Vaisanen
Hello group,
I'm writing a C++ based application that embeds the python engine. Now I
have a problem regarding exception/error information. Is there a way to
get the exception message and possibly the traceback into a string for
example? I've been eyeballing the PyErr_ module and it seems fairly
limited. In other words PyErr_Print() calls...
|
thread by: noroi |
last post Oct 18 '07 by: noroi
Hi,
I got problems while running Eric Blossom's FM receiver's example codes
from the GNURadio tutorial page; the RF front end reads the signal input
from daughter board, and when the compiler tried to call mothods to set
values for IF and gain, such as set_AGC(), get_output_freq(), etc... it
seems not able to find those methods/...
|
thread by: nayloon |
last post Oct 18 '07 by: nayloon
www.nayloon.com business2business website.Full dynamic and 2 language
10 pages.You post your products you can find customer from all over
world.Try it.You will see the different.
|
thread by: Simon Pickles |
last post Oct 18 '07 by: Simon Pickles
Hello,
I have several servers which link to each other (and of course, to clients).
At present, I am starting them in turn manually. Is there a way with
python to say, "open gateway.py in a new interpreter window"?
I looked at execv, etc, but they seem to replace the current process.
Ah, maybe I need spawnv().
|
thread by: Debajit Adhikary |
last post Oct 18 '07 by: Luis Zarrabeitia
I'm writing this little Python program which will pull values from a
database and generate some XHTML.
I'm generating a <tablewhere I would like the alternate <tr>'s to be
<tr class="Even">
and
<tr class="Odd">
What is the best way to do this?
|
| |
thread by: ApoorvaDesai |
last post Oct 18 '07 by: bartonc
just for info I am using BOA constructor and python 2.3
I am writting a query which works if i break it up as follows (and it also works if I run it in SQL view of access)
stn_name = whatever
xf_name = whatever2
Query_MDB_grid1 ="""SELECT EMS_StationName, EMS_XFName, EMS_XFMRName, FromBusName, FromKV, ToBusName, ToKV,...
|
thread by: fabdeb |
last post Oct 18 '07 by: fabdeb
Hi every one,
I m a sysadmin who want to know how to use python.
I dont know anything about oriented object programation, i only know
bash and a little perl.
I have some simple questions about python.
the first: what is the differences between a function and a classe?
In which case i should use a function ?
In which case i should use a...
|