Blog

Chips 101 and Nvidia

2023-05-30 ~1600 words
Last week, Nvidia’s stock exploded…. The AI arms race has heated up and is even getting the attention of normal people through stock prices (among other news), so I’m sure this won’t be the last time I explain GPUs to someone without a computer science degree. I’m using this post as a chance to organize my Chips 101 talking points.

Tech for Teaching

2023-04-21 ~200 words

I taught a tutorial at PyCon a few days ago. It went well, but what I want to discuss are some technical things I did that went well and (I think) made the presentation easier for students to follow.

Python Exceptions: Bonus Content

2022-12-10 ~1800 words

This post is a followup to my article The Basics of Exceptions in Python, but should make sense on its own as long as you are familiar with raise and try/except.

Let’s cover a few more advanced aspects of the Python exception system. We’ll move a bit faster and talk at a higher level than we did in the last post.

Topics we’ll hit:

The Basics of Exceptions in Python

2022-12-04 ~2000 words

This post was originally meant to be a small part of my discussion of the Go programming language (coming soon) as a way of drawing contrast between Python and Go, but turned out to be extensive enough to justify its own post.

Python’s model of exceptions is quite similar to that of other popular object-oriented languages like Ruby, JavaScript, and Java1. Errors flow differently than regular data; if not “handled”, they rise up through the entire function stack and crash the program. Developers are encouraged to write code to anticipate those exceptions, handle them before everything explodes, and change the logic flow of the program accordingly.

What exactly needs to be done in that “handling” step typically depends on what went wrong, and so there are many types of errors. Programmers can check the type of an error to determine what went wrong and react accordingly. Errors can be thought of as objects and their types as classes that can be subclassed like any other class. But unlike other data, they follow an error-specific path through the code, short-circuitiing functions all the way up the stack until handled.

Gym Etiquette 101

2022-12-03 ~1700 words

When I first started going to the gym, I was self-conscious every second. There’s a particular code of unwritten rules in the weightroom. Having a mentor really helps, and without one, it’s easy to be so uncomfortable that you don’t want to come back.

Over the years I’d like to think I’ve picked up most of the “rules”. Here’s a list I wish someone had given me when I was starting.

Careers in Programming

2022-10-07 ~200 words
I recently visited Westville Correctional Facility, an Indiana penitentiary, to talk about jobs in the field of computing. It was an unusual opportunity that was honestly somewhat eye-opening; never have I had so enthusiastic and engaged an audience. I was sponsored through the Moreau College Initiative, a program in which residents of the facility are able to take full academic courses and potentially earn a bachelors degree before re-entering society. You can read more about the program here, if you are so interested.

Too Good To Be True?

2022-08-16 ~1400 words
The Too Good To Go app has been my fixation this summer. Since moving to a new neighborhood two months ago, I’ve picked up 43 surprise bags (all the more absurd because I didn’t discover the app until two weeks after moving). Dramatically increasing my consumption of sandwiches and pastries wasn’t in my original goals for the summer, but here we are. Too Good To Go lists “bags” that restaurants will sell you at a steep discount, though their contents will be a surprise.

Crafting Interpreters

2022-06-07 ~1500 words
In January, during some time off between jobs, I started working through Crafting Interpreters by Robert Nystrom. I think I originally discovered the book via r/ProgrammingLanguages. There aren’t that many accessible books for programming language design and implementation, so discovering the book (and that it was free to read online!1) was very exciting. The awesome book cover It’s an absolutely incredible book, in which you learn about programming languages while implementing your own.

Timezones

2022-06-01 ~1600 words
Probably once a year, I end up back in the same discussion about timezones. I don’t like timezones and apparently I bring that up a lot. The Usual Griping Programmers’ hatred for timezones is a bit of a meme. (I just googled “xkcd timezones” with absolute confidence there would be a comic, and of course I was right.) Computer systems don’t play nice with different times across the world. If I run a retail website, “weekend” sales should begin Saturday morning and end Sunday evening your time, even if it happens to mean that’s not the weekend where I am.

Is PyScript a Big Deal?

2022-05-10 ~1500 words
I went to PyCon a few weeks ago and while there, saw Peter Wang’s keynote on a new project called PyScript. PyScript is, essentially, a set of tools for running Python code in the browser – potentially even user-submitted code. I think that’s going to have a significant impact on the Python world, though maybe not in the way you’d first expect. Some Background For years now, various groups have been working on finding a way to “run” Python in the browser.