By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,548 Members | 1,497 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,548 IT Pros & Developers. It's quick & easy.

Very simple speed benchmark of few string substitions ways

P: n/a
I was curious of performance new Python 2.4 "Simpler String Substitutions"
so I decided to benchmark it. What I get

bluszcz@akira:~/python/benchmarks$ python template.py
Normal python string substition = 0.017546 seconds
PEP 292: Simpler String Substitutions = 0.243750 seconds
Jinja template system = 0.821844 seconds
Cheetah template system = 26.842872 seconds
bluszcz@akira:~/python/benchmarks$

To get i wrote small soft:
http://wiki.bluszcz.net/PythoneTempl...SpeedBenchmark

Cheers,

--
Rafał つた Zawadzki
http://bluszcz.net http://wiki.bluszcz.net
Jul 16 '06 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Rafal Zawadzki wrote:
I was curious of performance new Python 2.4 "Simpler String Substitutions"
so I decided to benchmark it. What I get

bluszcz@akira:~/python/benchmarks$ python template.py
Normal python string substition = 0.017546 seconds
PEP 292: Simpler String Substitutions = 0.243750 seconds
Jinja template system = 0.821844 seconds
Cheetah template system = 26.842872 seconds
That's interesting. You know what? I compared my swiss knife and my spoon
recently and found that my swiss knife is slower in handling as it requires
additional opening. So I decided to stop using it. I just don't get why they
keep producing these things.

Stefan
Jul 16 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.