The most popular choice for web apps, and the one I use myself, would
be Django. You might post your question in the Django group:
http://groups-beta.google.com/group/django-users
The only thing that I see that could be a problem would be the legacy
database. But that depends very much upon
I'm involved in a discussion thread in which it has been stated that:
Anything written in a language that is 20x slower (Perl, Python,
PHP) than C/C++ should be instantly rejected by users on those grounds
alone.
I've challenged someone to beat the snippet of code below in C, C++,
or
Thanks. Yes, there is a php-filepro extension that I could hook up
with using the command line interpreter. That may well be what I end
up doing. Or maybe port the php extension to python.
--
http://mail.python.org/mailman/listinfo/python-list
THe above is applied slavishly by those who value machine time over
peoples time. Do you want to work with them?
I understand where you are coming from. But in writing the code
snippet I learned something about pickling/unpickling, which I knew
*about* but had never actually used before. And
Thanks for the help. Yes, I see now that gdbm is really superfluous.
Not having used pickel before, I started from the example in Python
in a Nutshell which uses anydbm. Using a regular file saves some
time. By far, the biggest improvement has come from using marshall
rather than cPickel.
On Apr 17, 7:37 pm, Paul Rubin http://[EMAIL PROTECTED] wrote:
Therefore the likelihood of a C or asm program
being 20x faster including disk i/o is dim. But realistically,
counting just CPU time, you might get a 20x speedup with assembler if
you're really determined, using x86 SSE (128-bit
Does anyone know of a Python package or module to read data files from
the venerable old Filepro crossplatform database/IDE?
--
http://mail.python.org/mailman/listinfo/python-list
Thanks, all. Yes, Levenshtein seems to be the magic word I was looking
for. (It's blazingly fast, too.)
I suspect that if I strip out all the punctuation, etc. from both the
itemnumber and description columns, as suggested, and concatenate them,
pairing the record with its closest match in the
.
Thanks,
Steve Bergman
--
http://mail.python.org/mailman/listinfo/python-list
I'm on this general topic, the guide mentions a pet peeve about
inserting more than one space to line up the = in assignment
statements. To me, lining them up, even if it requires quite a few
extra spaces, helps readability quite a bit. Comments?
Thanks,
Steve Bergman
--
http://mail.python.org
Thanks for the responses.
The point about 132 columns is good. Pretty much any printer will
handle that today, though I reserve the right to change my mind about
the utility of 17cpi print after I'm 50. Hopefully, all printers will
be at least 1200dpi by then. ;-)
---
Yes, I dislike \ for
Bruce Eckel states the case pretty well in this interview:
http://www.artima.com/intv/aboutme.html
Bruce is the author of Thinking In Java and other excellent books,
but has migrated from the Java camp. (I'm excited to see him getting at
least a bit involved in TurboGears. He has a lot to offer
Just wanted to report a delightful little surprise while experimenting
with psyco.
The program below performs astonoshingly well with psyco.
It finds all the prime numbers 10,000,000
Processor is AMD64 4000+ running 32 bit.
Non psyco'd python version takes 94 seconds.
psyco'd version takes
Will McGugan wrote:
Some trivial optimizations. Give this a whirl.
I retimed and got 9.7 average for 3 runs on my version.
Yours got it down to 9.2.
5% improvement. Not bad.
(Inserting '2' at the beginning doesn't seem to impact performance
much.;-) )
BTW, strictly speaking, shouldn't I
[EMAIL PROTECTED] wrote:
BTW, can this code be made any more efficient?
I'm not sure, but the following code takes around 6 seconds on my
1.2Ghz iBook. How does it run on your machine?
Hmm. Come to think of it, my algorithm isn't the sieve.
Anyway, this is indeed fast as long as you
A couple of off the wall questions.
It seems to me that there is usually a solid *reason* for things in
Python and I'm wondering about the rationale for the way slicing works:
my_string[2:5]
gets you the 3rd through the 3rd through the 5th character of the
string because indexing starts at 0
Something like this should work:
==
for c in form.get('date'):
if c in string.letters:
print ERROR: You have to enter a date with numbers.
==
You have to import the string module. 'letters' is one of the
attributes defined in that module.
Other attributes
Kinda ugly, and I lifted it from an old post, but this should work:
import readline
readline.set_startup_hook(lambda:
readline.insert_text('supercalifragilisticexpialidocious'))
try:
new_value = raw_input()
finally:
readline.set_startup_hook(None)
--
Have you tried running python with '-u'? That turns off most buffering
within python at least. I'm not familiar with newspost, so I've no
idea what to do about any output buffering it might be doing.
--
http://mail.python.org/mailman/listinfo/python-list
You can also access this group through Google Groups:
http://groups.google.com/group/comp.lang.python
which has nice search features.
I found O'Reilly's Learning Python to be helpful in combination with
O'Reilly's Python in a Nutshell. Learning python is a nice
introduction to Python but is
There is also TurboGears, which (IMO) is greatness in the making.
Though unfortunately, the documentation is still catching up to the
greatness. I'm using it and loving it, though.
http://www.turbogears.org
DJango is great for content management. TurboGears is (IMO) a more
generalized
The indentation is wrong. Python cares about indentation.
print
print This \autotp\ program will create raw bitmap test pattern
images.
print
print Please read the information below thoroughly:
print
print 1. Graphic files MUST be TIFF images.
print 2. Images MUST have been ripped though
Welcome to Python! :-)
You may find this mailing list useful:
http://mail.python.org/mailman/listinfo/tutor
--
http://mail.python.org/mailman/listinfo/python-list
Hi,
I am trying to come up with a clean and simple way to sort a list of
objects (in this case SQLObject instances) by multiple attributes.
e.g. a Person object may have an age, a lastName, and a firstName.
I'd like to be able to arbitrarily sort by any combination of those in
any order.
I
to get your results as a dictionary.
-Steve Bergman
--
http://mail.python.org/mailman/listinfo/python-list
Leif K-Brooks wrote:
But remember that Python bytecode can be easily decompiled with a
publicly-available program.
I hope it is not considered too antisocial to bring it up here, but
there is always PyObfuscate:
http://www.lysator.liu.se/~astrand/projects/pyobfuscate/
-Steve Bergman
Wouter van Ooijen (www.voti.nl) wrote:
Yes, and you must also include a blank sheet, signed by you in blood.
I thought you only had to do that if you were submitting a patch to
MySQL, Qt, OpenOffice, or OpenSolaris. ;-)
-Steve Bergman
--
http://mail.python.org/mailman/listinfo/python-list
Fredrik Lundh wrote:
(sanitizing HTML data by running filters over encoded 8-bit data is hardly
ever the right thing to do...)
I'm very much open to suggestions as to the right way to do this. I'm
working on this primarily as a learning project and security is my
motivation for wanting
is OK. But it seems like there should be more straightforward way
that I just haven't figured out. Is there?
Thanks,
Steve Bergman
--
http://mail.python.org/mailman/listinfo/python-list
George Sakkis wrote:
If by straightforward you mean one-liner, there is:
''.join(c for c in input_string if c not in string.printable)
If you care about performance though, string.translate is faster; as always,
the best way to decide
on a performance issue is to profile the alternatives on
I'm waiting for the release of the next edition of Programming Python
from O'Reilly. It's due out in December. The current edition is rather
oldish. From 2001, I believe.
Steve
--
http://mail.python.org/mailman/listinfo/python-list
elegant way of which I am unaware?
I still like the portability of pgdb though. So, does anyone have any
recommendations? Perhaps a module that does for inserts and updates
kind of what dtuple does for selects?
Thank you for any guidance.
Steve Bergman
--
http://mail.python.org/mailman/listinfo
32 matches
Mail list logo