bytes more, but
no copy
after this, my python process takes about 80 meg. names like
big_object are just names, and they reference an object in memory.
if you say a=big_object, you are saying that the name "a" should also
reference that same object.
t one
Is there a way to stream an unzip, so it behaves more like a file?
thanks,
Brian Blais
--
Brian Blais
[EMAIL PROTECTED]
http://web.bryant.edu/~bblais
--
http://mail.python.org/mailman/listinfo/python-list
are you using matplotlib for the plots?
bb
--
Brian Blais
[EMAIL PROTECTED]
http://web.bryant.edu/~bblais
--
http://mail.python.org/mailman/listinfo/python-list
o read it into a python dict.
It misses anything not a scalar, but you can easily modify it to
include arrays, etc... in the xml.
hope it's useful. certainly a neat site!
bb
--
Brian Blais
[EMAIL PROTECTED]
http://web.bryant.edu/~bblais
from __f
t link, I also had to manually re-point python, pydoc,
idle, etc... in /usr/local/bin
Is there a reason for this, or is it just a small oversight on the
install script?
thanks,
Brian Blais
--
Brian Blais
[EMAIL PROTEC
questions will get me a
long
way. Let me know what you think! Please be gentle, because this is really my
first
somewhat significant python project, so there is probably some cruft from my
Matlab
and C experience (stray semi-colons here and there, etc.)
thanks,
thanks,
Brian Blais
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.edu/~bblais
--
http://mail.python.org/mailman/listinfo/python-list
thod would be clearer.
If-statements could possibly be used with some sort of random
behavior (if
rand()<0.5 ...).
Drunkard's Walk.
yes, that was the kind of thing I was thinking about.
thanks!
bb
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.e
both
places at the same time.
bb
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.edu/~bblais
http://bblais.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
more of a pain for my students.
thanks,
Brian Blais
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.edu/~bblais
http://bblais.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
turtle can
travel? it seems I can keep moving off of the screen. Is there a
way to make it so that a forward(50) command, at the edge, either
raises an exception (at the wall) or simply doesn't move the turtle
because of the limit?
thanks!
bb
--
Brian Blai
n, but I'd like to know what is a solution for x,
and for y. Why isn't it in a dictionary? Am I doing something wrong?
thanks,
Brian Blais
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.edu/~bblais
--
http://mail.python.org/mailman/listinfo/python-list
On Oct 12, 2009, at 15:18 , Falcolas wrote:
Glad to hear, by the way, that you don't use gotos in Python. =D
actually, it is there. http://entrian.com/goto/
I particularly like the comefrom construct!
bb
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.edu/~b
any sample code?
bb
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.edu/~bblais
--
http://mail.python.org/mailman/listinfo/python-list
turtle.circle(self.r)
self.turtle.fill(False)
self.turtle.penup()
for i in range(5):
c=Circle(randint(-350,350),randint(-250,250),10,"red")
T=Turtle()
T.forward(100)
T.forward(100)
thanks,
bb
--
Bria
bb
On Sun, Jan 31, 2010 at 4:27 PM, Brian Blais
wrote:
I'm on Python 2.5, but using the updated turtle.py Version 1.0.1 -
24. 9.
2009. The following script draws 5 circles, which it is supposed
to, but
then doesn't draw the second turtle which is supposed to simply move
fo
n or return
a button=-1 or something.
thanks,
Brian Blais
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.edu/~bblais
http://bblais.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
king about this incorrectly.
Any help would be great! Pointers to other examples of using
multiprocessing, especially with games, would be fantastic.
thanks,
Brian Blais
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.edu/~bblais
http://bblais.blogs
On Feb 13, 2010, at 12:54 , MRAB wrote:
Brian Blais wrote:
I've been thinking about implementing some simple games
Forget about global variables, they're not worth it! :-)
Think in terms of messages, sent via pipes, sockets or multiprocessing
queues.
okay...let's mak
too!"
x=3.2
if x in range(1,10):
print "yay!"
if 1<=x<10:
print "yay too!"
output:
yay!
yay too!
yay too!
bb
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.edu/~bblais
http://bblais.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
my own (1-line) .bat file, but I didn't
want to reinvent the wheel. Perhaps there is a better way for me to do this,
ideally in a platform independent way.
thanks,
Brian Blais
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.edu/~bblais
http:/
On Dec 13, 2010, at 12:30 PM, Godson Gera wrote:
>
>
> On Mon, Dec 13, 2010 at 10:46 PM, Brian Blais wrote:
>> Hello,
>>
>> I was wondering if there is any standard or suggested way of installing
>> packages *without* going to the commandline. I often
nd skimmed the section:
http://docs.python.org/tutorial/datastructures.html
which describes list comps, and didn't see any mention of this
behavior. it's probably there, but it certainly doesn't jump out.
bb
--
Brian Blais
bbl...@bryant.edu
http://web.
isual Studio
to do it?
bb
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.edu/~bblais
http://bblais.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
me the standard.
I guess that answers that one! :)
bb
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.edu/~bblais
http://bblais.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
On Jun 10, 2010, at 4:28 , Gregory Ewing wrote:
Brian Blais wrote:
In this whole discussion, I haven't seen anyone mention wax (http://
zephyrfalcon.org/labs/wax_primer.html)
Just had a quick look at that. In the third example code box:
def Body(self):
self.te
shown if one does: help(myobject)
thanks,
Brian Blais
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.edu/~bblais
http://bblais.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
On Jun 27, 2010, at 22:37 , Red Forks wrote:
Read you doc file and set the __doc__ attr of the object you want
to change.
On Monday, June 28, 2010, Brian Blais wrote:
I know that the help text for an object will give a description of
every method based on the doc string. Is there a way
,
Chris
so that gets back to my original question: can I change this text at
runtime. Doesn't look like I can, because it is defined for classes
rather than instances. Am I thinking about this correctly?
bb
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.edu/~b
rens are a bit more irritating than just a print
2) in my quick-and-dirty scripts, I often want to get rid of all of
the prints after it works.
3) being able to redefine print vastly outweighs the irritation
caused by the extra parens
bb
--
Brian Blais
bbl...@bryan
e, True],
[ True, False, True, False, False, False, False],
[False, False, False, False, False, False, False]], dtype=bool)
just like matlab.
bb
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.edu/~bblais
http://bblais.blogspot.com/
--
http://mail.python.org
for two open source
projects that I own:
http://code.google.com/p/ssdf/
this is fantastic! what a great format! I've been looking for
something like this for quite some time.
thanks!
bb
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.edu/~bblais
twice("an int parameter")
--
Brian Blais
bbl...@bryant.edu
http://web.bryant.edu/~bblais
--
http://mail.python.org/mailman/listinfo/python-list
codeDecodeError: 'ascii' codec can't decode byte 0xc2 in position 0: ordinal
not in range(128)
am I doing something stupid here?
of course, as a workaround, I can do: ''.join([c for c in s if ord(c)<128])
but I thought the encode call should work.
.x,event.y)
turtle.reset()
turtle.speed(0)
c=turtle.getcanvas()
c.bind("", gothere)
turtle.pendown()
but this seemed to draw in the wrong place (like the coordinates were wrong).
Is there a good way to do this?
thanks,
bb
--
Brian Blais
bb
On Nov 12, 2010, at 8:05 PM, Steven D'Aprano wrote:
> On Fri, 12 Nov 2010 19:24:50 -0500, Brian Blais wrote:
>
>> I'd like to draw on a turtle canvas, but use the mouse to direct the
>> turtle. I don't see a good way of getting the mouse coordinates and the
On Nov 13, 2010, at 1:31 AM, Dennis Lee Bieber wrote:
> On Fri, 12 Nov 2010 20:48:34 -0500, Brian Blais
> declaimed the following in gmane.comp.python.general:
>
>> turtle.ondrag(turtle.goto)
>> turtle.pendown()
>>
>>
> I'm not familiar with th
On Nov 12, 2010, at 8:48 PM, Brian Blais wrote:
>
> On Nov 12, 2010, at 8:05 PM, Steven D'Aprano wrote:
>
>> On Fri, 12 Nov 2010 19:24:50 -0500, Brian Blais wrote:
>>
>>> I'd like to draw on a turtle canvas, but use the mouse to direct the
>>&g
101 - 138 of 138 matches
Mail list logo