11
votes
What programming/technical projects have you been working on?
This is a recurring post to discuss programming or other technical projects that we've been working on. Tell us about one of your recent projects, either at work or personal projects. What's interesting about it? Are you having trouble with anything?
I've finally polished up doppl.io enough to share. It's a small webapp that creates Twitter Lists for you based on the people a target user is following. Effectively, this lets you see Twitter from their perspective. I use it to get out of my filter bubble and peek into the alternate reality right-wing pundits live in. If that sounds like something you want to try, benshapiro's way up there in terms of having an extremely biased feed - he reads almost no dissenting content.
Thats actually really brilliant. One question, how do you pronounce it? Does it sound like "Dop-leo" or as written, "doppl dot i o"?
Thanks! It’s “doppel” as in doppelgänger.
As mentioned last week, I have been getting back into Genetic Algorithms. Last week it was specifically Genetic Programming (evolving programs to do some task). This week I went back to a project I had been working on previously but shelved because I didn't have much time for it.
The program attempts to find a tight oriented bounding box around a 3D object. An oriented bounding box is a box that contains the entire object, but is minimal in size. Therefore, it might not be aligned with the x, y, and z axes. The program starts by getting the axis-aligned bounding box and then starts randomizing it from there. It scales, translates, and rotates it, finds the best solutions, then mates them using crossover and mutation.
After spending a few hours getting back up to speed, and realizing that I had a glaring bug or two, I have it working reasonably well, though I'm a little disappointed in how long it takes to find good solutions.
I've also hit some sort of bug that I'm stuck on. When it generates an oriented bounding box, it is often not very tight. Looking at the result on screen you can easily see that one side or another could be moved closer. This should be really easy to do, but for some reason, I can't get it right. The bounding box is stored as a center point, a 3-axis rotation, and 3 half widths for the 3 dimensions. I'm going through all the points in the convex hull of the object and finding the minimum and maximum distance from those points to the +x, +y, and +z planes bounding the box. I should then be able to move each face so that it just touches the outermost point of the model in each direction. But for some reason, I'm moving the faces too far in some dimensions and not far enough in others. So I'm not really sure what I'm doing wrong. Anyway, that should keep me busy this week.
Same project as I mentioned a few weeks ago, a little 2D ASCII garden. Made some good progress, since then the biggest change is that I've changed storage formats for the templates. I had been using like a custom text format, but it was super fragile. Ended up using JSON for most metadata with a separate file with the ASCII sprite data in it.
As a side note, is there a better way to approach major changes to code? While updating the storage format I also included a few more capabilities into the "plant template" struct, ANSI colors and support for combining diacritical marks. I don't mind it too much, but after a big change to a core struct like that I often end up going back and forth asking the compiler what I should fix next. And I'm writing this in Go, but if I was writing in an interpreted language I wouldn't be able to do that at all, it's likely I'd be able to get it running fairly quickly only for it to crash and burn when I hit a method that hasn't been updated yet. Is there maybe a better approach where I don't have to harass the compiler so much?
I purchased a ten key keyboard called the Ginny like a few months ago and it finally arrived a week ago. During those months I practiced asetniop, a ten key keyboard layout that works by using chords (pressing multiple keys at the same time) to bind more than just ten keys. For example, to press m you press n and p at the same time. There's also a bit of prediction wizardry involved, by pressing more complex chords. I've gotten pretty fast at this layout so I can type around eighty words per minute.
The Ginny runs an open source keyboard firmware called qmk, which is really cool becasue it means I can totally modify it's inner workings to do what I want. By default the Ginny comes with a basic form asetniop loaded out of the box, however it doesn't include a lot of the predictive features that asetniop has. This is mainly because of hardware limitations of the atmega32u4 chip. For the predictive features to work, you need to have access to an English dictionary, which wouldn't fit, and would probably be too slow to search through anyway.
However qmk has a super neat feature that helped me solve this problem: steno support. Essentially, you can bind keys to steno keys and it'll just output the chords pressed over serial. With this, I was able to create some pc side software to process the chords more accurately, and now I'm able to type at around eighty words per minute again, but with dedicated hardware.
I think there are some benefits to typing with a ten key layout. First of all it's more comfortable, many people talk about maximizing ergonomics while typing and cite layouts like dvorak which have more commonly used keys on the home row, however with a ten key layout, every key is on the home row. Furthermore, with less keys, the keyboard can be cheaper, smaller, and potentially more embeddable. However it does also come with some obvious drawbacks, namely less keys - for shortcuts, and slower max speed. Also vim is much harder to use.
I'm in the early stages of a centralized SSH public key management project. The idea is that instead of adding all your public keys to each and every server, you add them to a central server that other servers communicate with. I may name the project Chatelaine.