Did you know? DZone has great portals for Python, Cloud, NoSQL, and HTML5!
Python Zone is brought to you in partnership with:
  • submit to reddit
Stoimen Popov05/16/12
1376 views
1 replies

Algorithm of the Week: Karatsuba Fast Multiplication

Typically multiplying two n-digit numbers require n2 multiplications. That is actually how we, humans, multiply numbers. Let’s take a look of an example in case we’ve to multiply two 2-digit numbers. . .

Corey Goldberg05/16/12
213 views
0 replies

Taking Browser Screenshots With No Display (Selenium/Xvfb)

In my last two blog posts, I showed examples of using Selenium WebDriver to capture screenshots, and running in a headless (no X-server) mode. This example combines the two solutions to capture screenshots inside a virtual display.

William Soprano05/15/12
377 views
0 replies

Video: Pydata Workshop Tutorial

In this video tutorial from the 2012 PyData Workshop, John Hunter, author of matplotlib is going to give you some advanced insight into the plotting library.

Giuseppe Vettigli05/14/12
931 views
0 replies

Prime Factor Decomposition of a Number

Check out this useful python snippet for to computing the prime factors of an integer.

William Soprano05/13/12
803 views
0 replies

Video: Performance Management From A to Z'

This session will cover the challenges of creating a production application performance monitoring system for Python.

William Soprano05/11/12
790 views
0 replies

Video: New Django Hosting Platforms

In this panel, we speak to a number of the people behind these new platforms to discuss what benefits they offer, what challenges they face, and what the Django project/community can do to encourage their growth.

Steven Lott05/11/12
2524 views
0 replies

Rants On The Daily Grind of Building Software

For some people, Tools Trump Language. Sadly, I've also had customers with ancient code they could no longer compile or maintain because the tools were out of support.

William Soprano05/10/12
516 views
0 replies

Djangocon Videos Continued

This video will go over how to handle many common solutions not currently described in the core documentation and give an in-depth look (with demonstration) at the how and why of several advanced security topics.

David Winterbottom05/10/12
591 views
0 replies

Using Pip and Requirements.txt to Install From the Head of Github Branch

Solving the problem of running pip install -r requirements.txt which will not pick any commits after d636b803 until requirements.txt is updated.

Stoimen Popov05/09/12
1004 views
0 replies

Bonus Algorithm: Run-Length Encoding

Run-length encoding is a data compression algorithm that helps us encode large runs of repeating items by only sending one item from the run and a counter showing how many times this item is repeated.

Stoimen Popov05/09/12
4971 views
0 replies

Algorithm of the Week: Determine if a Number is Prime

Stoimen Popov is back with another episode in his Algorithm of the Week series, and this week he tackles prime numbers. Stoimen begins with a very basic (brute force) approach, and then refines his algorithm to be far more effective, though it still works best for smaller numbers.

William Soprano05/08/12
1064 views
0 replies

Two Videos From DjangoCon

This talk will go through the deployment system that we have built at Urban Airship and introducing the concepts of caching/covering the best practives of using Djangos cache backend.

Eli Bendersky05/08/12
795 views
0 replies

Making code compatible with Python 2 and 3

In my opinion, to make the migration easier, it makes sense to write code that can run on both Python 2 and 3, at least for some time.

Steve Ferg05/08/12
507 views
0 replies

A Look into Python Decorators

In this post I will show you what the wrong end of the stick looks like, and point out why I think it is wrong. And I will show you what I think the right end of the stick looks like.

William Soprano05/07/12
491 views
0 replies

The Science of Community Management: DjangoCon Keynote

Django con keynote speaker gives his two cents on social communities involving developers

Chase Seibert05/03/12
2244 views
0 replies

Deploying Django Staticfiles to Heroku via Hudson/Jenkins

In this post, Chase Seibert discusses two asset managers for Django that bundle static resources for deployment to a CDN. With both libraries still in development, Chase ran into a couple of issues starting off and he tells us how to avoid these.

Chase Seibert05/07/12
937 views
0 replies

Django Performance: Latency Kills

Do you know how many database queries your Django pages are making? If you're like me, you probably don't know exactly. That's the beauty of the ORM; it abstracts database access to such a level that you rarely have to think about it.

Corey Goldberg05/06/12
588 views
0 replies

Python - Search a Local or Remote Splunk Server

Corey Goldberg gives us some basic instructions for searching Splunk and Python and then walks us through the process of using the tools.

Mike Driscoll05/05/12
1868 views
0 replies

eBook Review – Guide to: Learning Iteration and Generators in Python

Last month around the time of PyCon USA 2012, Matt Harrison sent me a copy of his newest book, Guide to: Learning Iteration and Generators in Python. I’ve been wanting to learn more about generators anyway, so I thought this was pretty fortuitous. We’ll take a quick look at the good and the bad after the jump.

Corey Goldberg05/05/12
1049 views
0 replies

Codeswarm - An Awesome Python Core Commit Visualization Video

Check out this really cool video outlining data source which is the commit log from cpython mercurial trunk.

Steven Lott05/03/12
1870 views
0 replies

My Django Application Refresh: The Joys of Deleting Code

Steven Lott has been refurbishing an older project, built using Django 1.0.1 and Python 2.5, to make it compatible with Django 1.3. In this post, Steven explains the process he took, and why he loves deleting old code.

Mike Driscoll05/01/12
826 views
0 replies

Making Menus With wxPython

How-to: Creating menus and popup menus for use of editing preferences or configuring the program.

Mahdi Yusuf05/01/12
777 views
0 replies

Python is Beautiful

I have put together a list of applications that use python and are extremely well designed. Python is certainly not ugly.

A. Jesse Jiryu Davis04/30/12
922 views
0 replies

Python's Swap is Not Atomic

I rewrote PyMongo’s connection pool and among the concurrency issues I had to nail down were: if a thread is resetting the connection pool as another thread is using the pool, how do I keep them from stepping on each other? I thought the swap would be atomic...

Chris Smith04/30/12
1773 views
0 replies

The Ever-Useful and Neat Subprocess Module

Shrikant Sharat has put together this amazing tutorial on Python subprocesses in which he covers a simple usage case, the Popen class, IO Streams, Killing and Dieing, and launching commands in a terminal emulator (for both Linux and Windows).