Clustering image encodings with perceptual autoencoders

Autoencoders are used to learn efficient data encodings in an unsupervised manner. When using image data, autoencoders are normally trained by minimizing their reconstruction error (typically the mean squared error or MSE) in an identity mapping task. The error then represents the difference between the input image and the reconstruction …

more ...

Micro-averaged F1 optimization using neural networks

Recently I've been working on a multilabel classification problem that was evaluated using micro-averaged F1 score. In this post I will show one approach to optimizing the thresholding of probabilistic classifiers by means of a toy problem. Some assumptions have been made to simplify the explanation, but the general approach …

more ...

Kaggle: Digit Recognizer using simple CNN

In my recent experimenting with Keras I decided to try my hand at the classical handwritten digit dataset MNIST. MNIST ("Modified National Institute of Standards and Technology") is considered the standard "hello world" dataset of computer vision. The Digit Recognizer Kaggle competition tasks us with correctly identifying images of handwritten …

more ...


Python project directory structure

I have struggled with project directory structure for Python projects in the past. Some things (like relative imports in projects containing multiple modules in different folders) are not immediately clear to most people, which is why I'm posting a concise little write-up of my knowledge on the topic so far …

more ...

Performance rating for fuzzy binary classifiers

This post proposes an idea for rating the performance of a fuzzy binary classifier (yes, I made that name up myself). A friend asked me if I knew of a way to measure accuracy for a classifier that predicted the emotion showed by pictures of human faces with a probability …

more ...

Python: Mocking for tests

Software often relies on third party services to function. Third party services can be anything, from a random number generator to a REST API. We'll take a simple HTTP API as an example. When designing unittests for the parts of your code that interact with the API, you need some …

more ...

Dotfiles with GNU Stow

Once you start getting into Linux, you'll notice that most applications are configurable through dotfiles; files like .bashrc, .vimrc, .inputrc et cetera. These files normally reside inside your home directory, and this is often the cause of severe file clutter.

There's multiple ways to make this mess a lot more …

more ...

Kaggle: Facial Keypoints Detection

This week I've been working on the Facial Keypoint Detection competition hosted by Kaggle. The objective of the competition is to predict keypoint positions on face images.

We start out with three files: the training set training.csv, the test set test.csv and a list of 27214 keypoints to …

more ...