PyX on Windows

2006-05-13 Thread Tom Longridge
Hi,

I'm trying to use PyX to draw some diagrams with text in. I want to
change the font, so need to change the text mode from TeX to LaTeX.
However I get an error when I do so:

pyx.text.TexResultError: unhandled TeX response (might be an error)
The expression passed to TeX was:
  \documentclass{article}%
  \PyXInput{3}%
After parsing the return message from TeX, the following was left:
  *
  *(C:\Program Files\MiKTeX\tex\latex\base\article.cls
  Document Class: article 2004/02/16 v1.4f Standard LaTeX document
class
  (C:\Program Files\MiKTeX\tex\latex\base\size10.clo))

I'm using MikTek on Windows to run LaTeX; does anyone know if is this
likely to be the problem?

Many thanks,
Tom

-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Strings and Lists

2005-04-19 Thread Tom Longridge
Thank you all very much for your responses. It's especially reassuring
to hear about other Python GA's as I have had some scepticism about
Python's speed (or lack of it) being too big a problem for such an
application.

With regard to using numeric, arrays or integer lists -- I didn't
mention that these strings can also contain wild cards (so I suppose
it's not really binary -- sorry). This is traditionally done using a
'#' symbol, but I was imagining using a value of None in a boolean list
to represent this. Also there is currently a fair bit of research going
into other representations (floating-point values, paired values etc)
so I was hoping to be able to keep my framework extensible for the
future.

Many thanks again for your help. I will ``take the plunge'' and give
the boolean list a go I think!

-- 
http://mail.python.org/mailman/listinfo/python-list


Strings and Lists

2005-04-18 Thread Tom Longridge
My current Python project involves lots repeatating code blocks,
mainly centred around a binary string of data. It's a genetic
algorithm in which there are lots of strings (the chromosomes) which
get mixed, mutated and compared a lot.

Given Python's great list processing abilities and the relative
inefficiencies some string operations, I was considering using a list
of True and False values rather than a binary string.

I somehow doubt there would be a clear-cut answer to this, but from
this description, does anyone have any reason to think that one way
would be much more efficient than the other? (I realise the best way
would be to do both and `timeit` to see which is faster, but it's a
sizeable program and if anybody considers it a no-brainer I'd much
rather know now!)

Any advice would be gladly recieved.
-- 
http://mail.python.org/mailman/listinfo/python-list