Since early in life, I was interested in programming. This section includes projects and code samples in different programming languages. I hope my code will be useful to other people.
Projects:
- Bitarray module for Python — This module defines an object type which can efficiently represent a list of bool objects.
- Generic Perfect Hash Generator — Generate a minimal perfect hash function for a set of keys. Using code template, templates can easily be constructed for any programming language. Explanation of the underlying algorithm.
- Python bytecode to XML — A tool to convert .pyc files to XML. This allows you to see all the information contained in a .pyc file in a human readable form.
- Desktop text search engine — This program allows text based search a filesystem. The engine itself is written in Python and uses PostgreSQL as a backend. Queries may be entered from (i) the command line (ii) another Python program (iii) a web front end.
- 3D vector class in Python — This class is derived from numpy.ndarray and the code therefore very small (100 lines), since most attributes are inherited.
- tsh (tiny shell) — Small Unix shell written in Python.
- colorize.py — Python module which converts various source code into HTML.
- histogram — Program that creates histograms for the red, green and blue components of a digital picture.
Documents:
- SAT based Sudoku solver in Python using the pycosat library. I wrote this as a developer blog post while working at Continuum Analytics (now Anaconda, Inc.).
- The Early History of the Anaconda Distribution — written 2018, about the early years (2012 - 2013) of the Anaconda Distribution.
-
Huffman coding in Python using bitarray
explains what Huffman coding is and how Huffman codes can be constructed
using Python, and how the Python
bitarray
library can be used to efficiently encode and decode data. - Using Python as a C library In this article, we want to show something unusual: how to write a simple C program that uses only the Python C library.
- Presentation on the slice object, which I gave at the Austin Python user group December 11, 2019.
- Multi dimensional slicing in Python — Explaining the concept of multidimensional arrays and how their syntax is handled in Python.
- An introduction to Python I prepared: HTML | Multi-page HTML
- Data abstraction — a small and easy essay which tries to explains the concept.
- CHM92 algorithm — Illustration and explanation of an algorithm for generating perfect hash functions.
Random stuff:
- PSO (Particle swarm optimization) — A visualization of this agent based algorithm for a minimization problem in two dimensional space.
- Small example that shows how Ajax works.
- Few examples of using PovRay.
- Using XSLT.
- Untangle — This is a small game written in svg+javascript. The objective is to move the circles in such a way that the lines do not cross each other.
- A Fractal tree written in svg+javascript where you can change the shape, it runs on your browser.
- redirectport — This script provides a simple proxy server which records in- and out-bound traffic for a local server.