://microwar.sourceforge.net/faq.html
All logos used are tradmarks from the corresponding compagny. Use is
illustrative.
--
Pierre-Alain Dorangehttp://microwar.sourceforge.net/
Ce message est sous licence Creative Commons by-nc-sa-2.0
http://creativecommons.org/licenses/by-nc-sa/2.0
--
Pierre-Alain Dorange
Ce message est sous licence Creative Commons by-nc-sa-2.0
http://creativecommons.org/licenses/by-nc-sa/2.0/fr/
--
http://mail.python.org/mailman/listinfo/python-list
return the
right answer ;
('fr_FR','mac-roman')
My goal is to dertermine th user language define on the running system,
any helps ?
--
Pierre-Alain Dorange
Ce message est sous licence Creative Commons by-nc-sa-2.0
http://creativecommons.org/licenses/by-nc-sa/2.0/fr/
--
http
()
return 0
def main():
p=Prefs()
p.load()
print 'test %d (after load)' % p.test
p.test+=1
print 'test %d (before save)' % p.test
p.save()
print '--'
if __name__ == '__main__': main()
--
Pierre-Alain Dorange
Vidéo, DV et QuickTime
(preferences) have
to be stored in a special directory : ~/Library/Preferences, no problem.
But on other platform that's not the same directory and perhaps i would
also faced to permissions issues...
But first is there a way to determine on which platfrom the python
script is running ?
--
Pierre-Alain
(according to python
phylosophy).
--
Pierre-Alain Dorange
Vidéo, DV et QuickTime http://www.garage-video.com/
Clarus, the DogCowhttp://clarus.chez.tiscali.fr/
--
http://mail.python.org/mailman/listinfo/python-list
render (group.draw) in the order i need. Easy and efficient.
- There seems to be support for video overlay, i.e. is it possible to
have an external program paint an image from a camera into a portion of
the screen while pyGame is running?
Don't know...
--
Pierre-Alain Dorange
Ce message est sous
gavino [EMAIL PROTECTED] wrote:
python vs smalltalk 80
which is nicer?
1st clue : Python got less letters in its name.
2nd clue : 80 is the year of the release of Alan Vega/Martin Rev album
3rd clue : Smalltalk began with an S, but Python with a P
--
Pierre-Alain Dorange
Ce message est
air force1 shoes [EMAIL PROTECTED] wrote:
air force1 shoes. air force1 high shoes. air force1 light shoes
File stdin, line 1
air force1 shoes. air force1 high shoes. air force1 light shoes
^
SyntaxError: invalid syntax
--
Pierre-Alain Dorange
Ce message est sous licence
game (a spaceinvader like)
between 800-1400 fps using dirtyrect.
I can also run without modification on Windows and Unbuntu using WMWare
on the same machine.
--
Pierre-Alain Dorange
http://microwar.sourceforge.net/
Ce message est sous licence Creative Commons by-nc-sa-2.0
http
it was not pythonic, but i'm sure
someone will tell is it's not.
--
Pierre-Alain Dorangehttp://microwar.sourceforge.net/
Ce message est sous licence Creative Commons by-nc-sa-2.0
http://creativecommons.org/licenses/by-nc-sa/2.0/fr/
--
http://mail.python.org/mailman/listinfo/python-list
, there are
fast.
For the audio analysis i thought the module must be written in C or
something very fast, because python, due to it's nature, would probably
not compute spectrum as fast as real time : 44100 samples per seconds is
a lot of work...
--
Pierre-Alain Dorangehttp
super-bomb)
* adding Saucer explosion : generate Virus that can infect PC
* clean the screens handling
--
Pierre-Alain Dorange
Ce message est sous licence Creative Commons by-nc-sa-2.0
http://creativecommons.org/licenses/by-nc-sa/2.0/fr/
--
http://mail.python.org/mailman/listinfo/python-list
(Compiled) Pattern Matching Time: 0.12012
Ratio Compiled/NotCompiled: 0.981116048092
2nd time and more
Pattern Matching Time: 0.00257
(Compiled) Pattern Matching Time: 0.000619
Ratio Compiled/NotCompiled: 0.240856031128
Config python 2.5.1 / MacOS X 10.5
--
Pierre-Alain Dorange
be faster.
How do you implement this or is there any other module with a sign()
function ?
--
Pierre-Alain Dorangehttp://microwar.sourceforge.net/
Ce message est sous licence Creative Commons by-nc-sa-2.0
http://creativecommons.org/licenses/by-nc-sa/2.0/fr/
--
http://mail.python.org
Christian Heimes li...@cheimes.de wrote:
Pierre-Alain Dorange schrieb:
I don't find any sign(x) function in the math library (return the sign
of the value).
I've read that math module is a wrapper to C math lib and that C math
lib has not sign(), so...
Starting with Python 2.6
/ the precise one (IEEE 754) is also fast (1)
--
Pierre-Alain Dorangehttp://microwar.sourceforge.net/
Ce message est sous licence Creative Commons by-nc-sa-2.0
http://creativecommons.org/licenses/by-nc-sa/2.0/fr/
--
http://mail.python.org/mailman/listinfo/python-list
from -500 to +500
sign_0 : 0.37
sign_1 : 0.42 (+13%)
--
Pierre-Alain Dorangehttp://microwar.sourceforge.net/
Ce message est sous licence Creative Commons by-nc-sa-2.0
http://creativecommons.org/licenses/by-nc-sa/2.0/fr/
--
http://mail.python.org/mailman/listinfo/python-list
(+76%)
sign_3 : 0.498 (+33%)
It seems it don't change the relative results between the methods.
Using timeit make measure accurate and remove print/range footprints.
I also try Arnaud's proposition, it make sign_0 just a little better
(-1%)
--
Pierre-Alain Dorangehttp
color too?
Only if it's pythonic.
--
Pierre-Alain Dorangehttp://microwar.sourceforge.net/
Ce message est sous licence Creative Commons by-nc-sa-2.0
http://creativecommons.org/licenses/by-nc-sa/2.0/fr/
--
http://mail.python.org/mailman/listinfo/python-list
r rt8...@gmail.com wrote:
[...]
Well that shows that even lads with tiny nads can be brave, any of the
other trolls want to expose them selfs?
This thread is offtopic, please just keep silent and let it be closed...
--
Pierre-Alain Dorangehttp://microwar.sourceforge.net/
Ce message
and discover that the sign() function is the bottleneck
keeping your program slow.
In each frame i'll have to use about 10 to 20 sign() call, so it'll not
be the bottleneck.
--
Pierre-Alain Dorangehttp://microwar.sourceforge.net/
Ce message est sous licence Creative Commons by-nc-sa-2.0
nice indeed, but you forget ascii art need a fixed font...
--
Pierre-Alain Dorange
Ce message est sous licence Creative Commons by-nc-sa-2.0
http://creativecommons.org
r rt8...@gmail.com wrote:
Go to Google groups... it looks perfect :)
It's a usenet group here, nothing to do with google groups.
To get back to the group subject, what is your actual python projects ?
--
Pierre-Alain Dorange
Ce message est sous licence Creative Commons by-nc-sa-2.0
on board?
I've other real project on the run, no crusade just programming.
Google sketchup doesn't really interest me, sorry...
--
Pierre-Alain Dorange
Ce message est sous licence Creative Commons by-nc-sa-2.0
http://creativecommons.org/licenses/by-nc-sa/2.0/fr/
--
http://mail.python.org
?
--
Pierre-Alain Dorange
Ce message est sous licence Creative Commons by-nc-sa-2.0
http://creativecommons.org/licenses/by-nc-sa/2.0/fr/
--
http://mail.python.org/mailman/listinfo/python-list
-read the documentation of the
ascii() builtin - it probably does something completely different
from what you expect it to do.
s = str(hexlify(urandom(8)))[2:18]
And your question is?
The answer is probably 23.
--
Pierre-Alain Dorange
Ce message est sous licence Creative Commons by-nc
for pygame, 1.9.0
is ignored. The same with
Any clue ?
--
Pierre-Alain Dorange
http://microwar.sourceforge.net/
--
http://mail.python.org/mailman/listinfo/python-list
but i do not understand the
right way to do this. There is project for PyObjC but a can't make
working directly simple script project, so i continue to use terminal...
--
Pierre-Alain Dorangehttp://microwar.sourceforge.net/
Ce message est sous licence Creative Commons by-nc-sa-2.0
://docs.python.org/library/profile.html
--
Pierre-Alain Dorange
MicroWar 2.0 : tuez des PC
http://microwar.sourceforge.net/
--
http://mail.python.org/mailman/listinfo/python-list
needed
Excuse me, but what was the point? (id est, are you just saying this
or do you wish to ask a question?;)
Sorry, it was not clear.
But i want to know if i can make the package smaller, because the total
package weight 59.4 MB just for a small arcade game.
--
Pierre-Alain Dorange
an2(0, 0) would have been NaN too but
i'm not a math expert, but the limit of atan2 would be 45°, so pi/4
radians (0,7854).
As x,y are coordinates, the both infinite would tend toward 45°.
x only infinite would be 0° (0 radians)
y only infinite woudl be 180° (pi/2 radians)
--
pmx-bigmap>
the tkinter code is in pmx.py
the canvas class was TMap
GUI was created in main_gui.__init__()
callback function was main_gui.resize()
--
Pierre-Alain Dorange<http://microwar.sourceforge.net/>
Ce message est sous licence Creative Commons &q
nvalid...
--
Pierre-Alain Dorange<http://microwar.sourceforge.net/>
Ce message est sous licence Creative Commons "by-nc-sa-2.0"
<http://creativecommons.org/licenses/by-nc-sa/2.0/fr/>
--
https://mail.python.org/mailman/listinfo/python-list
map servers) :
user can drag the map to see a different portion.
So i except the map to be resized to show a bigger portion of the whole
map : no streching.
--
Pierre-Alain Dorange<http://microwar.sourceforge.net/>
Ce message est sous licence Creative Commons "by-n
cell where the canvas widget is put).
I think i can resize the canvas, but i can't find a way to get the
available space after resize.
Perhaps using the grid manager is not the godd idea for that ?
I except it was more understandable.
--
Pierre-Alain Dorange<http://microwar.sourcef
sed the correct
quadrant (for angle answer).
--
Pierre-Alain Dorange<http://microwar.sourceforge.net/>
Ce message est sous licence Creative Commons "by-nc-sa-2.0"
<http://creativecommons.org/licenses/by-nc-sa/2.0/fr/>
--
https://mail.python.org/mailman/listinfo/python-list
to do from that.
Any clue or advice or tutorial ?
--
Pierre-Alain Dorange<http://microwar.sourceforge.net/>
Ce message est sous licence Creative Commons "by-nc-sa-2.0"
<http://creativecommons.org/licenses/by-nc-sa/2.0/fr/>
--
https://mail.python.org/mailman/listinfo/python-list
just CENTERED... I do not explore
this, i just thought NSEW was also CENTERED.
Many Thanks.
--
Pierre-Alain Dorange<http://microwar.sourceforge.net/>
Ce message est sous licence Creative Commons "by-nc-sa-2.0"
<http://creativecommons.org/licenses/by-nc-sa/2.0/fr/&
Steven D'Aprano <st...@pearwood.info> wrote:
> > which infinity. There are many - some larger than others
>
> China has just announced a new supercomputer that is so fast it can run an
> infinite loop in 3.7 seconds.
Near a black hole 3.7 seconds can last an infinite time
e maximum value. So the
tendancy is always atan2(y,x) tend to pi/4 if you looks at lot od y and
x that will be grater and greater each time : the final frontier would
always be pi/4, even if t take a long time to reach it.
--
Pierre-Alain Dorange<http://microwar.sourceforge.net/>
C
hing". To be empty, something must exist first.
--
Pierre-Alain Dorange Moof <http://clarus.chez-alice.fr/>
Ce message est sous licence Creative Commons "by-nc-sa-2.0"
<http://creativecommons.org/licenses/by-nc-sa/2.0/fr/>
--
https://mail.python.org/mailman/listinfo/python-list
Marko Rauhamaa <ma...@pacujo.net> wrote:
> Note that the "valid point of view for external observers" is the only
> valid scientific point of view.
For a scientific point of view, right. But tell this to the one that
will be close to a blackhole ;-)
--
Pierre-Alain Dora
izing you should do "something" that perhaps will fill
the list (word.append("hello").
Then after do your job, you perhaps need to print it.
But initializing and just print, will do nothing else than initialize
and print the result...
As state before this code more or
-
More reduced :
--
u=raw_input('Enter calculation:")
print eval(u)
--
works and compute :
1+2+3+4-1+4*2
2+3.0/2-0.5
Perform better and shorter, but less educationnal of course...
--
Pierre-Alain Dorange
---
env={}
env["__builtins__"] = None
u=raw_input('Enter calculation:")
print eval(u,env)
-
--
Pierre-Alain Dorange Moof <http://clarus.chez-alice.fr/>
Ce message est sous licence Creative Commons "by-nc-sa-2.0"
<http://creativecommons.org/licenses/by-nc-sa/2.0/fr/>
--
https://mail.python.org/mailman/listinfo/python-list
DFS <nos...@dfs.com> wrote:
>
> 2 lines? Love it!
>
> But apparently eval==evil.
>
> http://nedbatchelder.com/blog/201206/eval_really_is_dangerous.html
>
> I bet you get hammered about it here on clp.
It was a software to be deploy, it was just for educatio
eb site (vigiecrue) : retrieve the page, extract data,
extract last river level and mean the 24h last levels.
<https://www.dropbox.com/sh/k5974t374zmcoj6/AACes_Xo5DrxCbE1RjSaeKXYa?dl=0>
Note : it was probably not beautiful python code, but it works for the
purpose it was written.
--
Pierre-Al
previously, do not
except python to understand your new syntax, just write a small
interpreter to translate your new language to python.
--
Pierre-Alain Dorange Moof <http://clarus.chez-alice.fr/>
Ce message est sous licence Creative Commons "by-nc-sa-2.0"
<h
n and all kind
of combinaison : strict interpretation, byte-code compilation, JIT
compilation, AOT compilation...
So yes Python compile (bytecode).
--
Pierre-Alain Dorange Moof <http://clarus.chez-alice.fr/>
Ce message est sous licence Creative Commons "by-nc-sa-2.0"
reted language, and i found strange the initial request.
And sure, i overinterpret or simplify thing (compiling)...
But it seems that all this talk do not interested the initial requester
(Mr Puneet) : at that time he has not answer to the thread.
--
Pierre-Alain Dorange Moof <htt
eur developer.
But what confuse me, is that Python require "real live" interpratation
of the code to work properly (or perhaps i also confuse on that but
Python rely on interpretation of the code to conform to its own
standard, ie variables can change type during execution...)
--
Pierre-A
means it is most definitely
> meant to be able to be caught.
Using compile() function yes.
So yes there is a way to check "syntax error" before executing code
(using compile function and exceptions) but it was not standard, nor
widely used... It was still a hack for me, but perha
requested but that only a
hack and should not be used in real world.
--
Pierre-Alain Dorange Moof <http://clarus.chez-alice.fr/>
Ce message est sous licence Creative Commons "by-nc-sa-2.0"
<http://creativecommons.org/licenses/by-nc-sa/2.0/fr/>
--
https://mail.python.org/mailman/listinfo/python-list
54 matches
Mail list logo