RSSAmplifier

Blog

Michael Mior

Personal blog of Michael Mior

michael.mior.caRSS feed ↗21 posts

Latest posts

Game of Firsts

A lot of things seem to serve to unintentionally nerd snipe me. Over the weekend, a friend introduced me to The Initials Game . The gist of it is that you are given two letters and a series of clues. The goal is to guess a two-word phrase that starts with the given letters. It’s a pretty entertaining game and I wondered how easy it would be to generate such puzzles. The next day I was able to hack…

LLMs for Schema Augmentation

I have recently been experimenting with the use of large language models (LLMs) to augment JSON Schemas with useful features. While ChatGPT gets most of the press, there are many other LLMs that are specifically designed to work with code. The idea is that these LLMs can be used to augment incomplete schemas with additional useful information. Consider an example schema such as the one below. This…

Zotero reMarkable sync

I’ve really been enjoying my reMarkable tablet the past several months. (I wrote a short review last year if you care to see a few more details). One of the biggest gripes I have about the device is that it can be a pain to get documents on it. There’s currently no web app so the only choice is desktop apps for Windows and macOS or a mobile app for Android. Once I saw someone had released a…

LaTeX Skeleton

A repeated task I run into when I start working on a new paper is the laying out the initial structure of the repository to store the paper text. I recently pushed a simple skeleton that I use a starting point to GitHub. There’s nothing really fancy here, but it’s a good starting point. I use latexmk to build all my documents since it takes care of running BibTeX among other things. One of the…

Reinforcement learning for Las Vegas

During a department board games night, we were playing Las Vegas when a fellow player remarked that he wondered how an AI for the game would perform. Since I had been meaning to spend some time learning to implement neural network techniques, this seemed like a great opportunity. One of the first things that came to mind was a paper from the DeepMind team on using deep neural networks to implement…

reMarkable review

As an academic, I spend a lot of time reading papers. I generally hate the idea of printing out a paper for a one-time read since it feels wasteful, but I also don’t enjoy the reading experience of viewing papers on a desktop screen. I’ve always liked the look of the Sony Digital Paper that my advisor uses but it’s rather expensive and not easy to find. I used a Samsung Galaxy Tab 3 for several…

Benchmarking ScyllaDB

ScyllaDB is an alternative to Apache Cassandra which claims to have 10x higher throughput than Cassandra while remaining the same positive properties of scalability and ease of use. Scylla functions as a drop-in replacement for Cassandra applications using CQL (currently with some disparity in features ). Fortunately, my past work in NoSQL schema design for Cassandra only makes use of features…

A Calcite adapter for Apache Cassandra

For those not familiar, Apache Calcite is a generic SQL query optimizer which can execute SQL queries over multiple backend data sources. This is a powerful concept because it allows complex queries to be executed over sources which provide much simpler interfaces from CSV files to MongoDB . Calcite is also leveraged as the cost-based-optimizer framework for the Apache Hive data warehouse. Much of…

Automated Testing of Dotfiles

Several years ago I started managing my dotfiles based on Zach Holman’s dotfiles repo . His setup is quite nice and I found it relatively easy to adapt to my own purposes. My workflow generally consisted of making a bunch of local changes until I was happy and then pushing to my own GitHub fork . The big problem I eventually found is that I wasn’t fully capturing the correct steps to reproduce my…

Apache Cassandra benchmarking

I was recently trying to run some benchmarks against Apache Cassandra on EC2 since unfortunately the servers I had in our machine room were destroyed in a fire. For all my local testing, I used a single instance running on my desktop machine, but I wanted to ramp things up for the real benchmarks and use three nodes. Since my workload is read-only and the dataset is fairly small, I also wanted a…

Node.js skeleton project

Unfortunately, it’s obviously been a long time since this blog has been updated. Since the last post, I’ve been hard at work rewriting our Web app in Django (finally got rid of our old PHP) and picking up iPhone app development. Keep an eye out for some cool stuff coming up in the near future. In my spare time, I’ve been playing around with Node.js development. I decided to release the sample…

Unit testing Django model mixins

I recently found myself having to unit test some model mixins and I thought I would share the technique I used in case anyone else finds it useful. You could just pick a model which uses the mixin and run the test on instances of that model. But the goal of a mixin is to provide reusable functionality independent of any model. Instead, we create a dummy model we can use for testing. The model…

MySQL Client Configuration

Perhaps I’m the only one who didn’t know this, but a while back, I discovered a handy trick for configuring the MySQL client. You can create a configuration file in your home directory, ~/.my.cnf and set options for the MySQL client to use. Really handy if you’re constantly connecting to the same server and tired of entering hostname and port parameters. Here’s an example: [client] host =…

Coloured SSH terminals

With the looming prospect of deploying software to production systems and horror stories of accidental commands executed on production systems instead of development machines, I wanted to try to find a way to ensure this never happened to me. My first thought was to change the background colour of the terminal as that would be a clear indicator of the system I’m connected to. Unfortunately,…

RUBBoS

While working on my Masters thesis, I needed a solid database benchmark. RUBBoS is a fairly common benchmark in the field, but unfortunately is a few years out of date. While it was fantastically simple to set up, I did run into a few issues associated with newer versions of PHP and Java as well as a few minor bugs. Since the benchmark is fully open-source, I decided to release my modifications.…

Designing an Offline CMS

First the obvious question. What on earth is an offline CMS? Isn’t the whole point of having a CMS that you don’t have to change anything offline? Well, yes that’s true. But recently I ran into a problem. When I started my Masters degree, the department wanted me to create a webpage, but all I could really do was serve boring old static content. Well, that’s not entirely true, since there was an…

Octotweets

Below is a few more links from my latest tweets from the end of October. As always, you can follow me as @michaelmior on Twitter. For a list of all the links I’ve shared, you can view my delicious page . This list is generated by the wonderful Packrati.us app. Octobot - High Throughput Distributed Task Queue I will admit that this one makes the list partially because the project’s awesome URL. But…

The Dangers of strlen

I’ll keep this post brief, but I wanted to share something I just found about the C strlen function. It’s slow. It can make a big difference in program execution time. For example, I had a function in an external which consumes a string, so I call strdup each time around a loop to make sure I have a copy for the next iteration. In my case, the function I was calling already had the length of the…

Tweets of the Week

In an effort to keep the blog postings more regular, I thought I would start sharing a selection of the most popular links from my Twitter feed in-between more detailed posts. Movember Man Hypothesis – Adam Doran This one goes at the top because it’s for good friend and a good cause. Check out this video we produced to help put our weight behind Prostate Cancer Canada‘s Movember campaign. Share…

DBUS for cross-machine screensaver locking

I typically work with two computers on a regular basis. When I bring my laptop into the office, that makes three. I have a habit of locking my computer(s) when I step out, but it gets to be a pain when I have three machines running at once. I decided that I wanted to be able to lock one machine, and have the rest follow suit. I discovered that this is possible using DBUS since gnome-screensaver…

Welcome!

This is my new blog which I’ve been meaning to put up for some time now. I’ve been looking for a way to share some of the various scripts I’ve written and tips I’ve come up with. Hopefully someone out there in the blogosphere will find these useful. I plan to post on a fairly wide range of topics, but all centred around programming and the web. If you’re not ready to subscribe just yet, you can…