used a regular image viewer to pan and shrink/zoom. I had the drawing
portions of my script well separated from the data parsing and
manipulation so tweaking the script was simple.
YMMV, but PIL was the best way for me.
...
jay graves
--
http://mail.python.org/mailman/listinfo/python-list
billie wrote:
> I tried the export function of scite but it does not generate a proper HTML
> code that permit me to copy and paste it into another HTML page.
Works OK for me. What exactly is it doing wrong on your side?
> Does anyone got any suggestion?
I've used Webcpp before. http://webcpp.
Fredrik Lundh wrote:
> sounds like you've installed
> http://pyxml.sourceforge.net/
> on one of your machines, but not on the other.
or ActiveState Python on one and python.org Python on the other???
Just a guess. No STFWing was done before posting this message. ;-)
--
http://mail.python.or
see StringIO or cStringIO in the standard library.
--
http://mail.python.org/mailman/listinfo/python-list
Mark Dickinson wrote:
> Questions:
> (1) Can anyone else reproduce this behaviour, or is it just some quirk
> of my setup?
yes. I get 7 sec vs 1 sec on my laptop.
> (2) Any possible explanations? Is there some optimization that kicks
> in at a certain number of lines, or at a certain le
AFAIK, the cmd.exe program on Win2K/XP doesn't support ANSI escape
sequences. There are various other options on windows but they
probably won't work on Linux.
http://newcenturycomputers.net/projects/wconio.html
http://effbot.org/zone/console-handbook.htm
--
http://mail.python.org/mailman/listi
http://kodos.sourceforge.net/home.html
http://weitz.de/regex-coach/
HTH,
jay graves
--
http://mail.python.org/mailman/listinfo/python-list
Paul McGuire wrote:
> Jay -
> Thanks for the pyparsing plug.
NP. pyparsing is on my list of stuff to play around with. I'm just
waiting for the proper problem to present itself.
> Here is how the OP's program would look using pyparsing:
And the exact reason that I could 'plug' pyparsing is tha
[EMAIL PROTECTED] wrote:
> Beside rxb15, there is also redict, in the standard lib (Jay Graves
> shows the HD path):
> http://home.earthlink.net/~jasonrandharper/reverb.py
I knew there was a newer one out there but my google skills failed me.
Thanks for the link.
--
http://mail.p
Hmm.
>From an interactive interpreter this works for me.
import os
os.system('title Jay')
but the title returns to its previous value when I Ctrl-Z out of the
process.
If I save this as a file and run it, it seems to work without spawning
a new window but resets it the title after the program f
Cool. Let me know if you want a copy of p.py (in all of it's
hard-coded glory).
I can easily put it under Public Domain and you can copy whatever you
want out of it.
...
jay
--
http://mail.python.org/mailman/listinfo/python-list
Scott Simpson wrote:
> I have a loop
>
> for line in f:
> ...
>
> and if the line is over about 10,000 characters it lops it off. How do I
> get around this?
Hmmm. Works for me on Windows.
Python 2.4.1 (#65, Mar 30 2005, 09:13:57) [MSC v.1310 32 bit (Intel)]
on win32
Type "help", "copyright
Matthew Wilson wrote:
> I sometimes inadvertently create a new attribute on an object rather
> update a value bound to an existing attribute. For example:
> All comments are welcome. Is there a better way of implementing the
> above class, OR, is this approach generally wrong-headed? Am I the o
Chaos wrote:
> As my first attempt to loop through every pixel of an image, I used
>
> for thisY in range(0, thisHeight):
> for thisX in range(0, thisWidth):
> #Actions here for Pixel thisX, thisY
>
> But it takes 450-1000 milliseconds
>
> I want speeds less th
f about 4 seconds on my dev box) and almost every
other page is sub second.
> Thanks for any enlightenment.
Just my 2 cents.
...
jay graves
--
http://mail.python.org/mailman/listinfo/python-list
Christoph Haas wrote:
> On Thursday 03 August 2006 17:40, jay graves wrote:
> > How hard would it be to create this nested structure?
> Not hard. Instead of doing "INSERT INTO" I would add values to a dictionary
> or list. That's even simpler.
> > I
st that you could do would be to give a link to a zip
file and let the user choose the path they want to unzip to once they
have downloaded the file.
As for working with SVN, I really like TortoiseSVN but you would have
to install it on all machines which is what you are trying to avoi
under win32
> and can't find a pycairo package for it. Suggestions?
AGG (Anti-Grain Geometry) is one such engine that a couple of people
have interfaced to Python.
http://www.antigrain.com/
...
jay graves
--
http://mail.python.org/mailman/listinfo/python-list
ion Data\Google\Picasa
(probably not exactly right))
Also there is a Google Groups for Picasa and it might have some
pointers in the archives.
http://groups.google.com/group/Picasa?lnk=gschg&hl=en
Have fun!
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
ddtl wrote:
> My script uses re.compile() function, and while it rans without errors
> under Linux, when I ran that script under Windows I get the following
> error:
> Traceback (most recent call last):
> File "C:\a\projects\re.py", line 4, in ?
> import re
> File "C:\a\projects\re.py", li
verb = 'Verbose',
> filedir = 'C:/temp',
> )
>
> print mystruct.filedir
> #
Does 'Bunch' fit the bill?
http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/52308
...
jay graves
--
http://mail.python.org/mailman/listinfo/python-list
gene tani wrote:
> Plus, how do you order "https:", "ftp", URLs with "www.", "www2." ,
> named anchors etc?
Now is a good time to point out the urlparse module in the standard
library. It will help the OP with all of this stuff.
jus
BartlebyScrivener wrote:
> Yup. Did that before. That's what I mean. The d:\\python is there and
> it doesn't come from the PythonPath in my windows registry. Maybe it
> scans for any directory with python in the name?
Do you have any *.pth files in the C:\Python24 directory?
...
jay
--
http:/
Yves Glodt wrote:
> I seem to be unable to find a way to appends more keys/values to the end
> of a dictionary... how can I do that?
A dictionary doesn't have an 'end' because it is an unordered
collection.
> E.g:
> mydict = {'a':'1'}
> I need to append 'b':'2' to it to have:
mydict['b'] = '2'
p
Derick van Niekerk wrote:
> What are the string functions I would use and how would I use them? I
> saw something about html parsing in python, but that might be overkill.
> Babysteps.
Despite your reluctance, I would still recommend an HTML parsing
module. I like BeautifulSoup.
http://www.crummy.
shell=True)
You don't say what you are trying to do but if you are trying to drive
telnet maybe you want the pexpect module.
http://pexpect.sourceforge.net/
I've never had the need to use it myself so I can't offer any other
advice.
...
jay graves
--
http://mail.python.org/mailman/listinfo/python-list
the
> Filters-project (http://filters.sourceforge.net/) without having to
> compile or build the DLL myself, which is according to the authors very
> hard.
I don't have any experience with this specific library but I've used
ctypes in the past and it worked great.
HTH.
...
jay g
First google.com hit using your title.
http://www.google.com/search?q=py2exe
--
http://mail.python.org/mailman/listinfo/python-list
http://www.cartel-securite.fr/pbiondi/projects/scapy/
--
http://mail.python.org/mailman/listinfo/python-list
t, I used the data cleansing routines from Febrl to do this
with some success.
http://www.google.com/search?q=febrl
HTH.
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
On Jun 20, 10:43 am, Thorsten Kampe <[EMAIL PROTECTED]> wrote:
> * jvdb (Wed, 20 Jun 2007 08:22:01 -0700)
> http://www.ntwind.com/software/utilities/hstart.html
I'm not the OP but this looks very useful to me.
Thanks.
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
27;.
> But it doesn't work.
> Can anyone explain why?
Instead of doing it that way, you should use slicing.
>>> s='12345 4343 454'
>>> s = s[:-1] + 'r'
>>> print s
12345 4343 45r
>>>
See
http://docs.python.org/tut/node5.html#strings
HTH.
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
; Any code samples would be great.
Tim Golden is your man.
http://tgolden.sc.sabren.com/python/active_directory.html
HTH
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
search?q=firewall+client
But a quick test of trying to get python.org with 'urllib' did not
work.
> Any advice? Or better working example?
> Thanks a lot,
Sorry I wasn't able to help more. I'll try to poke at it a bit more
when I get a chance.
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
the
> string up the call stack.
Maybe you are looking for the 'code' module.
http://docs.python.org/lib/module-code.html
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
wnload links don't respond.
Someone else has it stashed somewhere, hopefully having the filename
will help.
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
On Sep 19, 10:06 am, "exhuma.twn" <[EMAIL PROTECTED]> wrote:
> And before someone says: "Use the DictCursor-factory to access column
> names". Yes I can do that. But a dict does not guarantee the same
> order of keys as the columns were specified in the query.
But you can iterate over the cursor.d
On Sep 21, 2:43 am, Tim Golden <[EMAIL PROTECTED]> wrote:
> Carl K wrote:
> > It seems there are 2 odbc modules - pyOdbc and mxOdbc - anyone know the
> > difference?
>
> In short, pyodbc is open source; mxOdbc requires a commercial license.
> pyodbc is a newcomer, but appears to work for everythin
On Nov 6, 8:29 am, Jeff <[EMAIL PROTECTED]> wrote:
> Django has a wonderful ORM that can be used separately from the
> framework, but it is pretty top-heavy as well. I'm afraid that size
> is the price you pay for abstraction. Your business logic code
> shrinks, but the supporting libraries grow.
e unmaintained.
>
I've used GraphViz before but never any of the Python bindings. It's
always been easy enough to just generate the .dot file that Graphviz
expects.
http://www.graphviz.org/
I've also book marked NetworkX but I've never used it.
https://networkx.lanl.go
an-my-code-discover-the-name-of-an-object
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
/webtoolkit/
Or its python counterpart, pyjamas?
http://code.google.com/p/pyjamas/
...
jay graves
--
http://mail.python.org/mailman/listinfo/python-list
instance).
> > What I need to do is very simple GUI automation : moving the
> > mouse cursor to and from specified screen coordinates, clicking, etc.
> > Thanks a lot.
>
> For Windows, try pyWinAutohttp://pywinauto.openqa.org/
dogtail is another
http://people.redhat.com/zc
z
> bal
>
If it is XML why not use ElementTree or some other XML DOM library?
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
On Feb 26, 3:23 pm, Krishna Kirti Das <[EMAIL PROTECTED]> wrote:
> I am a long-time user of Perl who comes to you in peace and is
> evaluating different scripting languages for use as a scripting
> platform for system administrators on the Windows platform. Perl
> already has many modules that allo
alues in column 'C'
count of unique combinations of columns 'A' and 'B'
count of unique combinations of columns 'A' and 'C'
count of unique combinations of columns 'B' and 'C'
in all cases, sum(D) and avg(E)
Since I need 'C
mirror.py script for
inspiration.
It should be in your Tools/scripts/ subdirectory of your Python
installation.
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
On Mar 10, 8:57 am, royG <[EMAIL PROTECTED]> wrote:
> i wrote a function to parse a given directory and make a sorted list
> of files with .txt,.doc extensions .it works,but i want to know if it
> is too bloated..can this be rewritten in more efficient manner?
Try the 'glob' module.
...
Jay
--
On Mar 10, 9:28 am, Robert Bossy <[EMAIL PROTECTED]> wrote:
> Personally, I'd use glob.glob:
>
> import os.path
> import glob
>
> def parsefolder(folder):
> path = os.path.normpath(os.path.join(folder, '*.py'))
> lst = [ fn for fn in glob.glob(path) ]
> lst.sort()
> return lst
>
Wh
On Mar 11, 12:21 am, royG <[EMAIL PROTECTED]> wrote:
> On Mar 10, 8:03 pm, Tim Chase wrote:
> in the version using glob()
>
> >path = os.path.normpath(os.path.join(folder, '*.txt'))
> >lst = glob.glob(path)
>
> is it possible to check for more than one file extension? here i will
> have to create
I'm attending Pycon this year and for the first time I have to pay for
myself. (All training/conference budgets have been zeroed out at my
company.)
I would like to take the cheaper option by staying at the Crowne Plaza
but as I understand it, the part of the conference I'll be attending
will be
On Feb 11, 9:13 am, jay graves wrote:
> I'm attending Pycon this year and for the first time I have to pay for
> myself. (All training/conference budgets have been zeroed out at my
> company.)
>
> I would like to take the cheaper option by staying at the Crowne Plaza
>
init__.py file (it doesn't matter if it's empty) in the
directory to turn it into a package.
http://www.python.org/doc/2.5.2/tut/node8.html#SECTION00840
HTH.
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
On May 15, 3:47 pm, [EMAIL PROTECTED] wrote:
> I'm cleaning up some old code, and want to see what orphan
> functions might be sitting around.
>
> Is there a static call tree analyzer for python?
How about
http://pycallgraph.slowchop.com/
...
Jay Graves
--
http://mail.python.org
.
use the 'pickle' module.
http://docs.python.org/lib/module-pickle.html
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
On May 16, 3:24 pm, globalrev <[EMAIL PROTECTED]> wrote:
> On 16 Maj, 21:22, jay graves <[EMAIL PROTECTED]> wrote:
> > On May 16, 2:17 pm, globalrev <[EMAIL PROTECTED]> wrote:
> > > i extract info from one file and put it into a dictionary.
> > > i wa
rogramming Collective Intelligence" by Toby Segaran is
great and has examples of clustering algorithms written in Python.
http://www.amazon.com/Programming-Collective-Intelligence-Building-Applications/dp/0596529325/
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
nt want to iterate the first
> row...how do i start at the second?
How about this?
mov = open(afile)
first = mov.next()
# check first for ':' and do whatever you need to do
# including the 'y' processing from below if required
for line in mov:
do y
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
On May 29, 4:30 pm, Nikhil <[EMAIL PROTECTED]> wrote:
> or a string iterable ? How can I do that. I have lots of '\r\n'
> characters in the string which I think can be easier if it were made
> into a list and I can easily see if the required value (its a numeral)
> is present in it or not after som
nerator expression instead of a list comprehension to avoid building
and throwing away a list.
"\n".join(str(o) for o in args)
http://www.python.org/dev/peps/pep-0289/
Very unlikely to yield a material time difference in this case but
cleaner IMO.
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
On Jun 2, 8:36 pm, "Gabriel Genellina" <[EMAIL PROTECTED]> wrote:
> Still nitpicking: using a generator expression in this case has no
> advantage. The first thing that str.join does is to create a list out of
> its argument (unless it is already a list or a tuple). In fact, a list
> comprehension
On Jun 3, 1:44 pm, tmallen <[EMAIL PROTECTED]> wrote:
> Is there a way to pick apart this text without resorting to regular
> expressions?
>
> p {
> color: black;
>
> }
>
> p -> element
> color -> property
> black -> value
http://code.google.com/p/cssutils/
--
http://mail.python.org/mailman/l
on Windows natively?
Get rid of the 'posix' check and use os.path.join to create
'tempfileName' and see if it works.
HTH.
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
On Jun 6, 1:22 pm, [EMAIL PROTECTED] wrote:
> I am thinking that the "g.open(tempFileName, 'a')" command is the
> issue. Is there anything different about opening a file in Windows?
> Does Windows understand "append", or would I have to do control checks
> for seeing if the file is created and the
On Jun 6, 3:19 pm, [EMAIL PROTECTED] wrote:
> This did not make a difference in my script. However, I did what you
> suggested, and tried the simple script it Windows, and it works as it
> should.
> (It's really annoying because it works on the Mac and Linux! (I just
> tested my script on the Mac
On Jun 11, 2:25 pm, geoffbache <[EMAIL PROTECTED]> wrote:
> Anyone have any better ideas?
How about ExeMaker?
http://effbot.org/zone/exemaker.htm
I have not used it but it seems to do what you want.
...
Jay
--
http://mail.python.org/mailman/listinfo/python-list
he updates are inserted into one transaction and committed
> as one, it is substantially faster.
In addition, if this is a one time conversion, look into using the
bulk import functions. (.import FILE TABLE)
Since you are coming from another database you know your constraints
are satisf
ror:
> from svn import core as svn_core
> ImportError: No module named svn
> Best regards
I believe that it is the python binding provided by Subversion.
You didn't say what platform you are on or what version of SVN you are
using so I can't point you any closer than:
http://su
you go about running a Python app as a Windows
> service without SRVANY?
I have used CherryPy sucessfully as a windows service.
You can probably glean what you need from.
http://tools.cherrypy.org/wiki/WindowsService
HTH.
...
Jay Graves
--
http://mail.python.org/mailman/listinfo/python-list
On Sep 2, 1:02 pm, cnb <[EMAIL PROTECTED]> wrote:
> over 17000 files...
>
> netflixprize.
http://wiki.python.org/moin/NetflixPrizeBOF
specifically:
http://pyflix.python-hosting.com/
--
http://mail.python.org/mailman/listinfo/python-list
ot; or maybe I'm just imagining that.
Also Mark Pilgrim's diveintomark.org blog
(http://diveintomark.org/archives/rooms/) has categories that are
reminiscent of the list. I think this was my first exposure to it.
HTH.
...
jay graves
--
http://mail.python.org/mailman/listinfo/python-list
Jay wrote:
> Is their any way of setting wear the Python Shell window appears on the
> screen when I run my program?
>
> I am testing a full screen program with no Window Frame on a comp with
> 2 monitors and I have to keep pressing the Key to bring the
> Shell to the front and then moving it manu
> find the errand CMD prompt and move it.
errand -> errant
--
http://mail.python.org/mailman/listinfo/python-list
73 matches
Mail list logo