-
Notifications
You must be signed in to change notification settings - Fork 682
Python_index_1
C Fractal using iteration method
C Fractal using recursion
C function decorator
C struct decorator
C#-Style Events in Python
C++-like iostream syntax in Python
C-style enumerations
Cache decorator in python 2.4
Cache decorator in python 2.4
Cache file contents to speed access
Cache function/method result
Cache Handling Wrapper for Slow File Processing Functions
Cached Class
Cached Property
Caching and aliasing with descriptors
Caching and throttling for urllib2
Caching decorator with timeout, selective invalidation
Caching iterable wrapper
Caching object creation
Caching Singleton class (subclassable)
Caesar cipher
Caesar Ciphers Program in Python
Calculate distance from .kmz files
Calculate Easter (Western) given a year
Calculate Pi using Monte Carlo Simulations in Python (Vectorized)
Calculate the distance matrix for n-dimensional point array
Calculate the MRO of a class
Calculate Trailing Zeroes in a Factorial
Calculating Apache hits per IP
Calculating distance between two geographic points
Calculating e using Continued Fraction
Calculating PI using random numbers (Monte Carlo method)
Calculating PI using trigonometric iterations
Calculating Swatch Internet Time (or Beats)
Calculating the distance between zip codes
Calculations on huge (memmap-)arrays
Calculations with error propagation, and semi-formal expressions
Calculator
Calculator of pesticide concentration
Calendar Maker
Call a Callback when a Tkinter.Text is Modified
call a function/method X times per second
Call out to an external editor
Callback Pattern
Caller and Callee
Caller and Callee
Calling (C-level) finalizers without del
calling a superclass's implementation of a method
Calling a web service using soappy
Calling Windows API using ctypes and win32con
CallPipe: Call the methods of an object in a remote process
CallQueue: Easy inter-thread communication
Capitalizing ISO 3166 country names correctly
Capturing the output and error streams from a unix shell command
car.py (Ctypes ARchiver in PYthon [libarchive ffi wrapper])
Case insensitive filename on *nix systems - return the correct case filename
Case Insensitive Sort
Case Insensitive Strings
Case-insensitive Dictionary
case-insensitive sort of list of strings
Case-insensitive string replacement
caselessDict
caselessList
Catalog multiple drives
Cataloging and adding IPTC keywords to digital photos
catenateFilesFactory
CGI Directory Contents
CGI doc string reader
CGI Image Viewer
cgi-shell
cgi-shell
cgiproxy.py
chain execution of functions using generators
Chained map lookups
ChainedList and ChainedListView: Exposing Multiple Lists as a Single Sequence
Change a Function's Closure!
Change image properties
Change line endings
Change tabs/spaces with regular expressions
Change the wallpaper under Windows
Change Windows Console Character Attribute (Color)
ChangeDirectory context manager
Changing a closed-over value (in a "cell")
changing file attributes on windows
Changing return value for mutating list methods (meta programming)
Changing shortcut on a usb key V2
Changing the background color of the menu bar in a wxPython Windows app
Changing the indentation of a multi line string
Chaotic Function Analysis Graph
Chat server & client using select.select
chatbox megawidget for tkinter
Cheap-date trick; a different way to parse
Check for package updates on PyPI (works best in pip+virtualenv)
Check for package updates on PyPI (works best in pip+virtualenv)
Check HTTP Content Type
Check PC Power
Check that a string represents an integer number
Check uptime and version whith ftplib
Check web page exists
Check xml well-formedness
Check your Windows sound system
check_svn_number_for_all_modules
Checked exceptions
Checking for a keypress without stop the execution (unix way)
Checking multiple endings
Checking whether a string contains a set of chars
Checks for a valid POSIX filename
Cheetah template processor for CSV and XML data
Chek if a number is a power of two
cherrypy RESTResource
Chess Notation Player
chomp equivalents
Chomsky random text generator
Choose a random k-subset of {1,2, ..., n}
chroma
Chunks
Circle
Circle Inversion Fractals
Class Adoption
Class decorator to check that methods are implemented.
Class for writing content to Excel and formatting it
class matrix
Class to calculate increment of variables based on time (units per seconds)
Class with default method handler
Class-only Methods
Classes for Working with URIs
Classic ASP script analyzer, finds all functions, includes, duplicite functions
Classifying characters using nested conditional expressions
Classifying letters as vowels or consonants and counting their frequencies
Classmethod emulation in python2.1
Clean a .py file full of constant chr(x) calls
Clean preceeding and trailing whitespace in complex list dictionary tuple structures
Clean up init() methods that contain only attribute assignments.
Clean up a directory tree
Cleaning up when killed
CleanupManager for with statements
Clear Only Project Modules
Clear screen and beep for various platforms.
clear the screen
ClearModules
Click counter for Windows
CLOS-like around/before/after auxiliary methods
Closest elements in a target array for a given input array
Closures For Highly Readable Sequence Sorting Customization
CMS page range validator.
co_pickle , a module to serialize code objects
Code to solve Smoluchowsky Equation
Code to source and back
Code To Store Encrypted Password in a File
Code_Fouad_Teniou
Coding Standard Adaptor
Collection
Collection Pipeline in Python
collections.MutableMapping wrapper around _winreg
Collpsible frame for Tkinter or Collapsible panel
Colo(u)rs Inside Text Mode Python...
Color Module (for Windows only)
Color Study 1
Colorize Python -- Sourcecode Syntax Highlighting
Colorize Python source using the built-in tokenizer
Colorize xml source using the sax ContentHandler, LexicalHandler and Declhandler interfaces
colormap: Returns an RGB tuple on a 0 to 255 scale for graphical packages
Colour Bar And Greyscale Generator For Standard Text Mode Python.
Coloured / highlighted version of string
ColumnSorterMixin with a Virtual wx.ListCtrl
combination
Combinations of a sequence without replacement using dynamic programming
combining GUIs and asynchronous I/O with threads and pygtk
Combining simple and specific property creation
Combobox Autocomplete
comixGetter
Commafying an integer
Command line interface class
Command Line Options and Args Hate'em? Me Too!
command line query
Command Line Windows Alarm Clock
Command Threads
Commandline Macro Expander
CommentEditor: HTML editor for online comments
Communicate between processes using mmap
Compare algorithms for heapq.smallest
Compare CSV Inventory files
Compare MySQL DB
Compare passed day of week to today's day of week
Compare speeds of different kinds of access to variables
compare(), making filter() fun again
Comparing two images
Comparing version info
Compile-time regex's and pattern-based dispatching
Compile.py
Completer with history viewer support and more features
Complex Boolean Regular Expression Class
Complex Methods to Compute Pi in Python
Complex Polynomial Roots Fractal
Component architecture through data descriptors and function decorators
Components and Abilities (different implementation of Component architecture)
Composable Functions
Compose HTML Mail with embedded images from URL or local file
Composing a POSTable HTTP request with multipart/form-data Content-Type to simulate a form/file upload.
Composite design-pattern using dictionaries
Composition of classes instead of multiple inheritance
compress data to printable ascii data
Compute Memory footprint of an object and its contents
Compute Memory footprint of an object and its contents
Compute relative path from one directory to another
Computing permutations with duplicates
Computing simple list functions recursively
Concrete Class Finder
Concurrent buffer for generators
Concurrent Generator
Conditionnal Breakpoint
ConfigObj - Lightweight Config File Parser
Configurable JSON Extensions for Python
Configurable password generator/checker
Connect 4 (DEMO)
Connect PyGTK object events to class methods automatically
Connect to an IRC server and store messages into a file
Connecting to running instances of IE on your computer
ConntrackEventListener
Console (text) progress indicator class
Console built with Cmd object
Console CD Player
Console progress dots using threads and a context manager
Consolidate group of modules into one recipe
Constant Object Passing
Constant types in Python
Constants in Python
Constellation Finder
Constraint-based Sudoku Solver
Constructing DAGs to Avoid Redundancy in Trees
Constructor and Destructor Chaining
Consumer Application Skeleton
Container
Container
Context manager for a daemon pid file
Context Manager for an Arbitrary Number of Files in Python
Context manager for calling a method when exiting a 'with' statement
Context manager for low-level redirection of stdout/stderr
Context manager for managing a test file
Context manager for restoring a value
Context manager to atomically replace a file
Context manager to prevent calling code from catching exceptions
Context manager to temporarily set an attribute on an object
Continous Fractions
continuator
Continued fractions
Contract verification in Python
Control break report generation example
Control break report using a dictionary
Control CPU Usage by using ctypes (Win32 Platform)
Control your mouse with the Microsoft Kinect using OpenKinect
Controlling gzipped I/O
Controlling Windows Services
Controlling XSLT stylesheet loading
Convenience 'timeit' function
Convenience class for algorithm development
Convenient Utility for Making Dictionaries
Conversion in base 2
Conversion of PIL Image and numpy array
Convert a cmp function to a key function
convert a directory full of png images to a (wxPython) module
Convert a formula string with implied multiplication to proper form
Convert a nested Python data structure to XML
Convert a string into a raw string
Convert a transcript with Ansi escape sequences to HTML
Convert a youtube transcript in srt subtitle
Convert Audio CD track in iTunes with Python
Convert Base64 encoded embedded ASCII text into binary files
Convert Byte Size to String Representation
Convert CSV to XML
Convert CSV to XML
Convert datetime in python to user friendly representation.
Convert datetime.datetime objects to/from Boost.python posix time
Convert DB Fixed-Width Output to CSV Format
Convert Dictionary to XML
Convert doc and docx files to pdf
Convert doc and docx files to pdf
Convert Excel to PDF with xlwings and xtopdf
Convert from decimal to any base number
Convert from decimal to base-n for any positive n less than or equal to 10
convert hierarchy of data files into a convenient Python dictionary
Convert HTML text to PDF with Beautiful Soup and xtopdf
Convert HTML text to PDF with Beautiful Soup and xtopdf
Convert HTML to PDF with the PDFcrowd API
Convert Image Format
Convert Image Format
Convert JSON to PDF with Python and xtopdf
Convert Microsoft Word files to PDF with DOCXtoPDF
Convert Microsot Excel (XLSX) to PDF with Python and xtopdf
Convert PDF to plain text
Convert PDF to TIFF on Mac OS X
Convert PyQt properties to Python properties
Convert Spelled out Integers (e.g. three thousand two hundred fifty) into Integers (e.g. 3250) and Vice Versa
Convert Spelled out Integers (e.g. three thousand two hundred fifty) into Integers (e.g. 3250) and Vice Versa
Convert string to hex
Convert strings like '5d' and '60s' to timedelta objects
Convert Subnetmask from CIDR notation to dot.decimal form
Convert text/enriched MIME to text/html
Convert to something objects from string arguments
Convert Trac wiki markup to HTML
Convert wildcard text files to PDF with xtopdf (e.g. report*.txt)
Convert Wordpress Export File to multiple html files
Convert Wordpress Export File to multiple html files
Convert XML files to structurally equivalent garbage
Convert XML into JSON (Python dicts and lists structure)
Convert XML to Dictionary
Converter
Converting a list of equal length lists into XML
Converting arbitrary size Python integers to packed binary data strings
Converting between ASCII numbers and characters
Converting Between Different Naming Convetions
Converting DBI results to a list of dictionaries
Converting directories of text files from Unix to Windows ...
Converting DOT graphs to SVG
Converting MySQL database to an Amazon Simple DB database
converting numbers to their alphabetical style
Converting numeric strings to integers
Converting OLE datetime values into Python datetime objects
converting windows 64 bit time to python useable format
Converting Word documents to text
Converting XML to dict (for a XPATH-like access syntax) and back to XML
Converting XML to Dictionary and back
Converts a DOM node object of type element to an ElementTree Element
Converts doc files into text files on Windows platform
Converts from decimal to any base ( between 2 and 26 )
Converty decimal/integer number to binary string in Python
Convex hull and diameter of 2d point sets
Convolving Gaussian
Conway's Game of Life In Python
CookieInfo
cookielib Example
Cooperative multithreading with generators and signal handling
Coordinates of numpy array from index and shape
Copy audio files from exported playlist of iTunes (using plistlib)
Copy directory tree recursively while ignoring cvs, git and svn directories
Copy files over SSH using paramiko
Copy gmail.com contacts onto your mobile phone via gnokii
Copy huge files on Windows avoiding system cache misbehaviour
Copy-move forgery detection in images
Copying and Pasting Directories (and Files)
Copying Generators
Coroutines in Python
Correctly reading CSV files in arbitrary encodings
Cosign Handler
Count commits to a Subversion repository
Count items and sort by incidence
Count PDF pages
Count tags in a document
Count up transfer for 3 mobile broadband on a mac
Countdown Timer
Countdown to screenshot (PIL).
Counter class
Counter class
Counter class
Counting decorator
Counting pages of PDF documents on Mac OS X.
Covert color space from HSV to RGB and RGB to HSV
Covert Microsoft Office InfoPath 2003 files to CSV report
COW with DDX
CRC64 - Calculate the cyclic redundancy check.
Create .m3u playlists on the fly for mp3 dowloads
Create a nested dictionary from os.walk
Create a restricted python function from a string
Create a Table of Contents for an ebook with XMLtoPDFBook
Create a temporary mailbox
Create a unique CVS/RCS/SCCS keyword line
create a unique session key
create a unique web session id
Create a zip bomb, for testing
create an account in MS active directory
Create an ODBC data source
Create and apply filters to lists of file paths
Create book index.
Create Calendars on PDF with a few lines
Create module dependency graph
Create module directly from a filesystem path
Create Numeric/numarray/numpy array from iterator
Create objects from variable class names
Create on-the-fly class adapters with functools.partial
Create PDF at the end of a Unix pipeline with PDFWriter
Create PDF control break reports with itertools.groupby and xtopdf
Create replica of the existing directory structure with only specified extension files.
Create SHA Hashes of a Directory
Create Sierpinski Carpet (Fractal) FAST
Create simple PDF text calendars with xtopdf
Create single-file executables for windows
Create SQL tables from CSV files
Create tabular PDF reports with xtopdf and tablib in Python
Create Tiles of Images with fitz / MuPDF (PyMuPDF)
[Created on 2017-08-](https://github.com/ActiveState/code/tree/master/recipes/Python/Draw Sine Function in PDF/)
[Created on 2017-09-](https://github.com/ActiveState/code/tree/master/recipes/Python/Combination without using factorials/)
[Created on 2017-09-](https://github.com/ActiveState/code/tree/master/recipes/Python/Matrix Operations without numpy/)
Created on 2017-10-
Creating a daemon the Python way
Creating a Local dict
creating a share on windows with python
Creating a single instance application
Creating a single instance application
Creating a single instance application (Linux version)
Creating a tar archive (without using the tarfile module)
Creating beautiful urls from user generated text
Creating Browser-Based Desktop Apps with CherryPy 2.1
Creating fake data using numpy
Creating java class description files.
Creating methods of a class at construction time
Creature Population Simulator
Creature Population Simulator
Credit card number check
Credit Card Validation
Cricket GUI
Criteria-based cascading priority queue
Cron-like Triggers
Crop PDF File with pyPdf
cross-platform import hook for end-of-line conversion
Cross-platform startfile and mailto functions
Cross-site scripting (XSS) defense
crossword puzzle homework
Crypt
Cryptogram
csc prototype to arduino board with python API. part II
CSV export / import of PDF bookmarks (table of contents)
CSV to Flat File Converter
CSV to XML with configuration
ctype Enumeration class
ctypes CDLL with automatic errno checking
Cubic
Cubic spline interpolator
Curious Recursive Decorator Pattern
Curried functions
Curry
curry -- associating parameters with a function
custom django login_required decorator
Custom import script for Salesforce
Custom Made CGI Module
Custom String Representations of Bases
Custom Windows Alarm Clock
Customizing Distutils to Recognize Subversion Committed Revision Numbers
Customizing polar plots in matplotlib
Customizing the urllib library to fetch web pages the way you want
Cycle-aware tree transformations
Cycling a sequence
Daemon to create a wifi hotspot on linux
dal_1.py
dal_2.py
dal_3.py
dal_4.py
dal_5.py
dal_6.py
Data (A Class For Arbitrary Data)
Data Mining with Neural Nets
Data over ICMP
Data Processing Shell
data_dump.py, like the Unix od (octal dump) command
Date & time RFC822 formatted for RSS2, etc (straw man)
Date difference
Date to Day of the Week
DateTimeSyncer with Daylight Savings Time adjustment
DBAttrib
DBF reader and writer
DBF reader and writer -- selective fields and nullreplace
DDE Client
de Polignac's Formula
De-chunk and decompress HTTP body
dealing with directory paths with ~
Debug dynamically loaded C extensions with gdb
Debug runtime objects using gc.get_objects()
Debug with garbage collection
Debugging a running python process by interrupting and providing an interactive prompt
Debuging of object instantiation
Decimal and binary prefix Python snippet
Decimal Number To Byte(s) And String To Byte(s) Converter.
Decimal to Binary Conversion
Decimal to Roman numerals
Deciphering Caesar code
Decision Maker
Decision_Analysis
Declaring properties and checking typos
Decode in Python
Decoding a Shift (or Rotation, or Caesar) Cipher (or Code)
Decoding Binary Files
Decorate an output stream with print-like methods
Decorator and context manager from a single API
Decorator for appending author info to the function docstring (Python 2.4)
Decorator for BindingConstants at compile time
Decorator for BindingConstants at compile time
Decorator for defining functions with keyword-only arguments
decorator for doctests
Decorator for main method
Decorator for writing polymorphic functions
Decorator to check if needed modules for method are imported
Decorator to check method param types
Decorator to expose local variables of a function after execution
Decorator to expose local variables of a function after execution [alternative implementation]
Decorator to make a decorated call in a separate thread with timeout
Decorator to run decorated function not often than defined time interval
decorator: suppressable
Decorators for adding aliases to methods in a class
Decoupled Proxy of a State Bearing Object in a Multiprocessing Environment
Decrypt a PDF using fitz / MuPDF (PyMuPDF)
Deep list() to convert a nested tuple-of-tuples
Deep rename
Deeply applying str() across a data structure
Default arg special action
Default Dictionary
defdict
Defining Python class methods in C
Delaunay triangulation
Delayed Decorator
Delete a Gtk.TreeView row
Delete all message older than a given date in a pop account
Delete directories except special administration ones
Delphi-like property class for Python 2.2
Delta Debug - DDMin
DEMO Kids Level Python RF Attenuator...
Demonstrate Rochambeau
Dendrogram drawing
Dependable URL startfile (Windows)
Dependencies graph of a script or module
dependency generator for makefiles
Dependency Injection The Python Way
Dependency Injection The Python Way
Dependency resolution
Dependency resolver
Dependency resolver
deprecate decorator which accepts arguments
Deprecated decorator
Depth first search generator
deque collection class
Design by contract on python vanilla
Design mini-lanugage for data input
Design Pattern -- Inherit from an instance
Destroying Directories
Detach Thunderbird emails and keep links
Detect character encoding in an XML file
Detect when system is idle
Determinant of matrix of any order
Determination of relatively frequency distribution
Determine bytes needed to hold integer (Python3)
Determine credit card type by number
Determine function execution time in a Pythonic manner
determine google count by automatisation
Determine size of console window on Windows
Determine the available desktop area (primary monitor) on Windows
Determining Current Function Name
Determining if another instance of a script already running in MSW
Determining the current functions name (at the time it is called)
dfs and bfs graph traversal
dhcp query
Dialect for sort by... then by...
Dice
Dice
Dice Roll
Dict-like string formatting from an object by named atttributes
dict2xml
Dictionary / Class / List Indexes into Database Query Results
Dictionary Mixin / Framework
Dictionary of Function Parameters
Dictionary of Methods/Functions
Dictionary tool for lazy typers
Dictionary Tools
Dictionary Tools
Dictionary Who's Keys Act Like Attributes As Well
Dictionary with attribute-style access
dictproperty: properties for dictionary attributes
Dicts from lists
DictSet - A specialized Python container datatype for managing collections of sets.
Diff Two Dictionaries
digest authentication
Dijkstra Shortest Path Algorithm
Dijkstra shortest path implementation
Dijkstra's algorithm for shortest paths
Dijkstra's algorithm for shortest paths
dir_lower
Directory & File Counter
Directory Cleaner
Directory Deleter
Directory Iterator
Directory Pruner 1
Directory Pruner 2
Directory Pruner 3
Directory Pruner 4
Directory Size (Console)
Directory Size (GUI)
Directory Size Lister for Windows
Directory Walker Generator
Directory Walking File Renamer
Dirt simple map/reduce
Disable File System Redirector
Discover exchange in active directory
Discreet Simulation of Round Robin Scheduling
Discrete Cosine/Sine Transformations
Discrete Fourier Transform
Discrete PID Controller
Disk Dumper
Disk space usage displayed as a tree
Disk usage
disk.py
disk_demo.py
Display an Image from a specified file
Displaying Decoded Hotkeys for Shortcuts in MSW
DistCC 'top'
Distributed lock manager for Python
Distributed publish/subscribe middleware architecture.
Distributed request/reply middleware architecture.
division digit-by digit calculation
DLA Fractals
DnTree
Do What I Mean (dwim)
Docstring coverage.
Docstring inheritance class decorator
Docstring inheritance decorator
doctest, unittest, and python 2.4's cool doctest.DocFileSuite
DoDefaultMixin
Doomsday Algorithm
Dot-style nested lookups over dictionary based data structures
DoubleDict
Download a file via Trivial File Transfer Protocol (TFTP)
download a URL with a console progress meter
Download all lolcat images from iCanHasCheezburger.com
Download and rename RIDGE radar images
Download chromium browser nightly builds for any OS (with proxy support)
Download satellite images from NASA's site
download the Activestate cook book recipe
download the Activestate cook book recipe
Downloading a File from the Web
Downloading website's favicon
Draft for an sqlite3 based DBM
Draggable desktop Note or Sticky Notes in Tkinter
Dragon Fractal Curve
Dragon Fractal using iteration method
Dragon Fractal Using Iteration Method
Dragon IFS Fractal
Dragon Lexical Analyzer
Drain of Pesticide Solution Calculation
Draw a diamond with asterisks using recursion
Draw SVG Images In Python
Draw SVG Images In Python (Python recipe) - enhanced Version
Draw Text To Image
Drawing inheritance diagrams with "Dot"
Drive which Python functions are executed via a text file
driving gnuplot with the popen function
Droids ( a text adventure )
Droids 2 ( IF )
Drop a minimal, valid Windows executable file to disk, for testing
Drop shadows with PIL
Dropbox file uploader via web interface using Python with urllib2 and mechanize
DUAL 4 Bit Vertical Coloured Analogue Bar Graph Generator DEMO...
dualmethod descriptor
Dummy object
Dummy Objects
Dump all Active Directory Information using LDAP scripting
Dump all the attributes of an object
Dump Informix schema to text
Dump Oracle db schema to text
Dump PostgreSQL db schema to text
Dumping and loading variables in ascii format
dunderdoc, a simple Python introspection tool
Dupinator -- detect and delete duplicate files
Durand-Kerner method for solving polynomial equations
DVM_Versus_CAPM
Dynamic Class Construction a la DSLs
Dynamic Classes
Dynamic function composition decorator
Dynamic function parameters using annotations
Dynamic generation of a dispatcher class
Dynamic Generation of image labels
Dynamic system tray icon (wxPython)
Dynamical Billiards Simulation
Dynamical Billiards Simulation
Dynamical Billiards Simulation Map
Dynamically added methods to a class
Dynamically change the Python system path
dynamically changing encoder (for json) with metaclass (class factory)
Dynamically create a dictionary of ascending paths
Dynamically determine execution path of a file
Dynamically format a comment block
Dynamically Generated Python State Machine
Dynamically modifying class attributes at runtime