Instructions for Battle Droid on STAP from the Droid Developer Kit (9748)

As a teenager (and even during my years at college), I had a blast playing with the LEGO Mindstorms sets. One of them ones was the Droid Developer Kit (9748). Basically, it allowed you to build Star Wars droids and put them in action using the included Micro Scout (which included a motor, a light sensor, and seven built-in programs). I still have my original kit and with the Star Wars fever caused by The Mandalorian (and all the announced shows coming in the near future), I thought this Christmas break was the perfect occasion to jump back into this set.

Read More

Adding LDraw Models to Bricklink Studio

Recently, I started getting into LEGO again. More interestingly, I started experimenting with Bricklink Studio (or Studio, in short), a great CAD tool for creating your own (virtual) models brick by brick. One of its best features is the wide variety of parts at your disposal. However, every now and then you can come across a part or two that aren’t registered in Studio’s catalogue, but that exist already as a model. This is especially true if you are using parts from very old sets. Fortunately, there is a way to add them and make them available for your creations.

Read More

Leveraging Cookiecutter to Publish Python Packages

I started working on my first Python package (which is far from ready, but I will definitely post about it when I have a version worth sharing). When trying to find resources of how to publish it to make it available for the community, I felt a bit overwhelmed. The setup for it to work properly involves a lot of individual files. These need to be in the right structure with the right content. As you can imagine, this is very prone to errors.

Read More

Automatically Generating Tag Posts for GitHub Pages using Jekyll

Recently, I migrated my personal website from Wordpress to GitHub Pages using Jekyll. After some trial and error, I managed to have everything up and running. However, Jekyll tagging (i.e., generating the pages that contain a collection of posts filtered by a tag) requires additional plugins which are not supported by GitHub Pages. Long Qian wrote a fantastic tutorial on how to implement this functionality with a Python script. Unfortunately, this still requires running the script, adding the files to the staging area, committing them, and pushing them to GitHub. That’s a lot of steps for every time that I want to add a new tag. Not only is it prone to errors, but let’s be honest: ain’t nobody got time for that.

Read More

Creating a Shareable Bokeh Dashboard with Binder

Recently, I finished a personal project in which I analyzed the results of the “Who is your favorite Pokemon” survey. After that, I wanted to generate a more interactive visualization in which the user could choose a specific Pokemon and see its results. After pondering different options, I decided to do so in Bokeh because of a few reasons. First of all, you can generate your visualizations using Python only. Furthermore, it is very easy to incorporate Bokeh in Jupyter notebooks, which is great to generate a first version of the prototype. Lastly, a few colleagues of mine have used it for their projects at work and have been very happy with it.

Read More

Who is Your Favorite Pokémon? (Interactive)

Previously, I looked into Pokémon’s popularity from all 7 generations. However, I felt the visualizations were a bit static. Furthermore, you couldn’t get details on your preferred Pokémon. Therefore, I decided to extend this project and created an interactive dashboard using Bokeh and Binder to visualize the results of the survey. It allows you to choose whatever Pokémon you want and see its preference ranking compared to all Pokémon, compared to all Pokéon of its generation, and how did people voted for it in time during the period in which the survey was open (notice how the color of that plot corresponds to the Pokémon’s dominant color)

Read More

Who is Your Favorite Pokémon?

The newest entries of the Poké main series, Pokémon Sword and Pokémon Shield will be released later this year. However, the new generation of pocket monsters came with the news that you won’t be able to complete the national Pokédex. In other words, you won’t be able to capture all the Pokémon from previous 7 generations. In a series where “Gotta catch’em all” is its catch phrase, this caused a huge backslash by some members of the community. Their main argument was that “every Pokémon is someone’s favorite”. Is this actually true?

Read More

ECG Noise Removal Using Segmented-beat Modulation

For some strange reason, I stumbled with a paper that I had downloaded long time ago. It explains a simple algorithm for removing artifacts in ECG signal. Since I have a short time-off after the submission of my PhD thesis (yey!), I thought it would be cool to actually code the algorithm and give it a go.

Top: median cardiac cycle. Bottom: clean ECG signal in blue; (removed) motion artifact in gray.

Read More

ECG IIR Notch Filtering Using Transient Suppression

Recently, I was going through my undergraduate lecture notes. I stumbled upon an exercise which I found interesting. The task consisted in implementing the algorithm proposed by Pei and Tseng, which uses vector projection to minimize the problem of transient values when applying an IIR notch filter to an ECG signal.

Top: original ECG signal with AC interference noise. Middle: filtered ECG signal using a typical IIR notch filter. Bottom: filtered ECG signal using an IIR notch filter with the proposed transient suppression technique.

Read More