An Hour A Day

Welcome to my blog about random thoughts and explorations in software

University College London - Part 1

I wrote my last final this week, and so I wanted to take the opportunity to give a recap of my first two terms in Machine Learning at University College London. First weeks in London While courses started mid-October, I ended up moving to London sometime mid-September to give me some time to get settled in. Notably, I spent about 2 weeks reviewing “Mathematics for Machine Learning” by Deisenroth et al....

May 24, 2024 · 9 min

University College London - Part 0

This September I am taking a leave from my job at $dayjob$ to pursue a Master’s of Science in Machine Learning at University College London. As I am opening a new chapter in my life, I want to reflect and write down some of the key themes from my first 5 years in industry. Background Context At $dayjob$, the bulk of my work was focused on time series forecasting for supply chain management....

September 9, 2023 · 8 min

Meta-strategies for Software Development

A lot of blog posts discuss the correct architecture or strategy for a given situation. In this post, we will not discuss strategies or architectures, but rather a meta-strategy. A meta-strategy is a strategy for choosing strategies. In the context of software development, a meta-strategy would not be a recommendation of a particular architecture or tech stack, but rather actionable advice on how to evaluate and choose architectures and implenentations. In this post, I will outline 6 core concepts and how they fit together to form my own personal meta-strategy:...

September 12, 2023 · 9 min

Effective Ownership in Software Development

From low-level design to high-level project planning, ownership is central to succesfully enacting change. In this post, I will talk about what ownership is, and several ways to achieve effective ownership. What is ownership? Before we can talk about what ownership means and how to achieve it, we need to agree on a definition of ownership. For me, ownership has three pillars: the authority to influence outcomes, responsibility for the outcomes, and a commitment to making sure that the things that need to be done, get done....

September 11, 2023 · 3 min

Principled Development

I am a very strong believer in consistency. In fact, I think that consistency is at the heart of any engineering endeavor. Towards this end, I implemented what I call “Principled Development” into my daily work as a Machine Learning developer. In this post, “Principled Development” refects to having a framework of clear and actionable heuristics for making technical decisions, and evaluating designs and implementations. Having a framework for making consistent technical decisions is incredibly valuable, it allows for alignment and a unified technical vision within the team, provides a scaffold for ideologically consistent development over time, and increases overall code quality....

September 10, 2023 · 9 min

Generators and Coroutines in Python

Generators and Coroutines are very powerful tools in Python that can help simplify logic, speed up data-intensive programs or provide flexible and re-useable APIs. In this post, we will explore three main concepts in Python : Generators, Coroutines and Cogenerators. Generators Generators in Python are objects that contain some sort of internal state, and know how to produce the “next” value in a sequence. Before we talk about what generators are, we should talk about what problems they can help solve!...

May 10, 2022 · 8 min

Reproducible software in research using Python - Part 1

One of the big issues in Machine Learning research is reproducibility. In fields like biology that have many experimental variables and uncertainties, it is expected that results may be difficult to reproduce due to small sample sizes and the inherent complexity of the research. However, there is no excuse for Machine Learning research to be anything but trivial to reproduce. In this blog post, I will be demonstrating ways to make the software environment used for an experiment easily replicated as well as ways to add testing as a part of the experimental process to catch errors that might threaten the integrity of the results....

June 19, 2021 · 8 min

Monads in Python

Monads are a super interesting and useful design pattern often seen in functional programming languages such as Haskell. That being said, it is pretty simple to implement our own monads in Python. When talking about Monads, there are three “main” things that I use to describe in practical terms what a Monad is and what it does: Monads are essentially containers for values. In other words, you will have a Monad that will contain some arbitrary value or variable....

February 16, 2021 · 9 min

Decorators in Python

In python, you may have seen some syntax that looks a little like this: @something def foo(): pass The @something statement is called a decorator and is syntactic sugar allow you to concisely implement and use interesting concepts from functional programming called “Higher-order Functions” and “currying”. Before we get into how and why we might use decorators in Python, let’s talk about functional programming, Higher-Order Functions and currying. Currying Currying is a technique for taking a function that takes multiple inputs, and converting it into a sequence of single-input functions....

February 1, 2021 · 4 min

Implementing Neural Networks in Python

One of the more interesting Machine Learning models is the Neural Network. A Neural Network is a highly non-linear mathematical model that can be fitted to very complicated datasets, from image classification to text translation. In this blog post, we’ll be implementing our own simple Neural Network library in python, then test how our model performs through a practical example on an image classification dataset. What is a Neural Network? There are several types of Neural Networks, however we will be examining the simplest variant : a simple Feed-Forward Neural Network....

January 23, 2021 · 12 min