Simple CLI Script with Argparse

Let’s face it, most of the Python programs we write are going to be used from the command line. There are tons of command line interface helper libraries out there. My preferred CLI method is the style of Django’s management utility. More on this later, when we hopefully publish a library that gives us that out of the box (we use it in many of our projects already). Sometimes though, you just want a simple CLI script. These days we use the standard library argparse module to parse commands off the command line. Here is my basic script that I use for most of my projects: ...

January 10, 2016 · 1 min · 157 words · Benjamin Bengfort

Basic Python Project Files

I don’t use project templates like cookiecutter. I’m sure they’re fine, but when I start a new project I like to get a cup of coffee, go to my zen place and manually create the workspace. It gets me in the right place to code. Here’s the thing, there is a right way to set up a Python project. Plus, I have a particular style for my repositories — particularly how I use Creative Commons Flickr photos as the header for my README files. ...

January 9, 2016 · 3 min · 590 words · Benjamin Bengfort

Frequently Copied and Pasted

I have a bit of catch up to do — and I think that this notepad and development journal is the perfect resource to do it. You see, I am constantly copy and pasting code from other projects into the current project that I’m working on. Usually this takes the form of a problem that I had solved previously that has a similar domain to a new problem, but requires a slight amount of tweaking. Other times I am just doing the same task over and over again. ...

January 8, 2016 · 2 min · 384 words · Benjamin Bengfort

One Big Gift Selection Algorithm

My family does “one big gift” every Christmas; that is instead of everyone simply buying everyone else a smaller gift; every person is assigned to one other person to give them a single large gift. Selection of who gives what to who is a place of some (minor) conflict. Therefore we simply use a random algorithm. Unfortunately, apparently a uniform random sample of pairs is not enough, therefore we take 100 samples to vote for each combination to see who gets what as follows: ...

December 25, 2015 · 2 min · 273 words · Benjamin Bengfort

Natural Language Processing and Hadoop

Natural Language Processing and Hadoop Description Benjamin Bengfort and Sean Murphy discuss how NLP can be integrated with Hadoop to gain insights in big data.

November 2, 2013 · 1 min · 25 words · Benjamin Bengfort

Unbound Concepts: Columbia TechBreakfast Dec. 2012

Description Presentation by the CTO of Unbound Concepts, Benjamin Bengfort, at the Columbia TechBreakfast 2012.

December 12, 2012 · 1 min · 15 words · Benjamin Bengfort