Denormal number at inference in PyTorch

The other day at work I noticed a slowdown in runtime between a model with random weights compared to tuned ones. It turned out to be due to denormal numbers computation on the cpu being much slower than the normal arithmetic. Denormal numbers are very low magnitude floats, treated differently to keep precision. For deep learning, those are largely below significance and can be flushed to zero without accuracy loss. To do so for example in PyTorch, either set the appropriate flag: torch.

Basic watermark removal in videos

The general problem of completing images and videos depending on a mask is called inpainting, and numerous methods exists to tackle this problem in ingenuous ways. However most approaches are relatively costly to run, especially without a graphic card, so I wanted to see what result we could get with simple and fast methods. You can find the code for the steps below in this repository. To start, we need to find the mask, which correspond to the location of pixels to remove.

Space filling curves and CNN

πŸ‘·πŸ» this is a work in progress πŸ”§ Sometimes by exploring incongruous ideas, one can make interesting discoveries. This is know as serendipity in science, with penicillin being a famous example of an unplanned discovery. What I experimented with this week-end… is no such case. πŸ˜… In the spirit of not holding back negative results though, and for the unlikely possibility that it turns out helpful for someone, I’ll share it regardless!

Creating a static blog, the convoluted way

TLDR: I wanted to create a static blog while being able to type articles from a nice UI, from anywhere. It is quite straightforward with forestry + hugo + github pages. Jump to the solution. Motivation If you’re looking to create a blog, you’re in luck! There are countless tools to help you get up and running in a few minutes. For example Hugo will generate a static site from a few markdown files, and pushing it to github in a repository named YOUR_USERNAME.