Studio711.com – Ben Martens

Geek

Render.NET

Let me start by saying that I know this is a duplicate post, but unless you’ve been reading since 2008, you probably haven’t seen this one before. Besides, I think it’s worth retelling the story of the programming contest that eventually got me into Microsoft.

In college, I joined a programming club sponsored by Microsoft. I don’t remember exactly what the club did, but I remember them giving out free food which is about all it takes to get a college kid to join a club. They also handed out a thick set of CDs that represented an early beta of Visual Studio .NET. This was the first time the world had seen the .NET languages, and to get us into the tool, the club sponsored a programming contest in 2002 which would have been the end of my senior year. The rules of the contest were to write something that uses as many languages and features of .NET as possible. They wanted us to show off the capabilities of the language.

I had been spending a lot of time working on building a giant library of digital Lego specifications in a tool called POV-Ray and making digital Lego movies, but the slowest part of that process was rendering out the movie frames. It would take about 15 minutes to render a single frame at a measly 320×180 resolution. So my programming contest entry was a system that would orchestrate the rendering of a movie over a bunch of different computers.

The main server had a list of all the frames that needed to be rendered. Clients would connect via a web API and request work. They would be sent the text file representing a single frame, render the file locally in POV-Ray, and then send the image back to the server. To score more points, the client, server, and web API were all written in different .NET languages and all the interaction was tracked in a SQL database that had a web front end for displaying progress and participation points.

It took me FOUR MONTHS of work to get this all going, but with help from a friend, the final presentation really wowed the judges and we captured 85% of the first-place votes. If I remember correctly, the grand prize was an original Xbox and an HP Jornada with a WiFi card.

I did use the software to get rendering help with some Lego movies. The stories are garbage but I’m still proud of the technology that went into them. This stuff is simple now, but 20 years ago, it was unique. You can view an older post about it here: https://studio711.com/the-lego-movie/.

So how did this land me a job at Microsoft? Fast forward four years. I had just finished up my Masters degree and was looking to leave New Jersey. I had been trying to apply to Microsoft but it’s a challenge to make yourself stand out in the veritable flood of applications that they receive. I decided to cold call the head of the Microsoft club from Purdue. We hadn’t talked in four years, and I had to get his contact info through a mutual friend, but it worked! He happened to have a position open on his team and within a couple weeks, I had made it through the interview process and had a job offer.

One of my main recommendations for kids going into high school and college is to do more than the bare minimum. Getting good grades is important, but you need to be an interesting human too. “Passion” is hard to define, but I know it when I see it in a job candidate and that passion goes a long way to opening doors for new opportunities.

Piano Music Without A Piano

I wrote a while back about using some digital software to take the output from my piano and run it through an extremely high quality piano recording. I’ve quietly continued to make recordings of the various pieces I learn. Some of them end up on my YouTube channel. I usually post them there if it was especially hard for me to learn and/or I don’t see any other recordings of that particular arrangement. When you’re learning a new piece, it’s nice to hear someone else play it first so that’s my contribution.

In the last couple weeks, I’ve found some new (to me) technology that has opened up new possibilities: I’m now able to take a piece of sheet music, and turn it into a recording without ever touching a piano. Here’s the process:

  1. I start by scanning in the sheet music and making it a PDF file.
  2. MuseScore is a free download for creating and editing digital sheet music. I’ve used it before to create simpler versions of songs for Elijah when he was taking lessons, but it also has the ability to import a PDF. So I give I the PDF from the previous step and it spits out a Muse Score file.
  3. The digital sheet music has been very close to correct in my experience but usually needs some fixes so I make those right in MuseScore. I save the output to a MIDI file.
  4. At this point I have a MIDI file which has all the right notes, but it sounds very robotic because every note is timed exactly correctly and there’s no use of the sustain pedal. I suppose I could add the sustain pedal into the sheet music, but I’ve found it easier to add the pedal via the free MidiEditor software.
  5. I have already purchased the “Embertone Walker 1955 Concert D” piano software which renders a MIDI file out into an unbelievably good sounding audio file. It’s available for as little as $39.
  6. Now that I have a good MIDI file, I import it into the free Cakewalk software and set Cakewalk to render out through the Embertone piano software. I adjust the volume levels a bit and voila, in a few seconds I have an MP3 or WAV file.

The output sounds great! I suspect that many people would never know that it was produced without touching a piano. I’m interested in playing with the MIDI file even more to see if I could make it sound even more realistic. I’m curious how it would sound if I wrote some code to slightly alter the timing and velocity of each note to give it a bit more of the variability that you’d get from a human.

Today I’m using this to help our choir at church. I can easily scan in each piano piece and make recordings of the full accompaniment without taking the time to learn it. I also make manual recordings (because it’s faster) of the individual parts. All those files get posted to a share and now everyone can easily practice at home.

Have I ruined music by making it too nerdy? Not in my book. I still end up needing to play a lot of this live, but it’s really handy to have all these tools in my back pocket to pull out when they fit the situation.

P.S. If you’re not overwhelmed by software recommendations yet, I’ll throw in one more recommendation for Nail the Pitch which is a free app that tells you what note you are singing. As I practice the choir song, I can visually see if I’m hitting the right notes.

Message Privacy

These days, companies are using any data they can get their hands on to build profiles of us, market to us, and sell information they’ve derived about us. It’s mostly unavoidable, but it’s nice to exert some control when possible, which is one of the reasons why I use Signal for messaging. This isn’t a sponsored post or anything, but I thought I’d share in case you didn’t know about this but would find it helpful.

Text messages are unencrypted. Anybody in between you and the recipient can read them. I’m not saying telephone companies are mining data out of text messages, but I assume they are regardless of what their privacy policies claim. At the very least they have the ability to do it. Text messages are where I’m the quickest to say something that could easily be taken out of context and even if nobody is reading them now, I’d rather not have them sit around for years.

The three main reasons that I now use the Signal messaging app are:

  • The app encrypts your data end to end. Even the Signal employees can’t read your messages.
  • Each message thread can be configured to delete messages after a certain amount of time. I usually set mine to 4 weeks
  • Pictures and videos are sent at much higher quality. No more being annoyed at low quality images when sharing between iPhone and Android users!

Apps are available for most platforms. I use it on my phone, but I also run the Windows app on my desktop. There’s no cost to use it. The group that runs it is a non-profit that exists on funding from investors and donations from users.

The only downside to using it is that the people you chat with need to be on it for it to be useful. Thankfully, that’s the case for most of the people I chat with, but some chats still happen in an SMS app. It’s not that big of a deal to just tap the notification for whichever app received the message and open it up.

So chat however you want, but if you get a little itchy when you think about how companies are potentially using your data, this is a really easy way to decrease your attack surface.

GPT and LLMs

ChatGPT made a big splash last fall and large language models (LLMs) in general continue to be a hot topic. My current favorite is using Bing AI (https://bing.com/chat) because it combines current search results with the information it already has in its model.

But there’s still a lot of confusion about what is powering these sites. How do they know things? Are they sentient? Stuff You Know Should Know did a great episode called Large Language Models and You and I think it’s worth a listen. I’ve heard LLMs previously described as “word salad”, and this episode gives another good example of explaining that it’s like an iteration on autocomplete in a text box. The algorithm just knows what words are most likely to come next and which words are related to each other. It has no concept of what it is saying. It only knows that those words are most likely to go together when it sees your prompt. So there’s no sentience or actual knowledge happening here, which is probably good but it’s also bad because it means that ridiculous answers can come out and be presented as fact.

The episode covers all of this and then also does a good job of how incredibly fast things are improving. Give it a listen if this topic interests (or scares) you.

Syncthing

Apps like OneDrive and Dropbox are good at syncing your files to the cloud, but what if your scenario is a little more complicated? I ended up with one such scenario due to my cheapskate reasons for wanting to keep an old Pixel phone for its free Google photos storage.

My old Pixel 4a has lifetime free photo storage on Google Photos. Any photo I upload from that phone is free whether it originated there or not. So that means that I need to take all the photos off of our new phones and push them to the old phone. I also like to keep a full resolution copy of all our photos on our file server. I had a manual way of making this work before, but this past week, I found something that seems to be working a little smoother.

There is an open source app called Syncthing. It’s available for most platforms, and while it’s not as user friendly as other options, it is pretty straightforward and has a lot of knobs for adjustment. The basic setup is this:

Syncthing runs on each of our phones. It’s configured to watch for any camera photos or other image files like screenshots or text message pictures that we save. When we’re connected to WiFi, those files get sent to our file server at home which is also running Syncthing. The file server saves them all to disk and then also sends them out to the old Pixel 4a. The Pixel 4a is also running Syncthing and is setup to receive files from the file server. It writes them to a folder on the phone and then Google Photos sees those new files and uploads them to our Google Photos account. Every file goes new phone to file server to old phone to Google Photos. It’s a lot of movement, but it’s automated.

The only hiccup is that the old Pixel 4a runs two user profiles (one for Tyla and one for me.) So I have to periodically flip back and forth between the profiles to let the syncing happen, but that’s a lot easier than it used to be.

Eureka Filming Site Visit

I’ve been burning through the Eureka (2006-2012) TV show episodes on Amazon Prime. I’m a Stargate fan and this was recommended to me as something with a similar vibe (and a lot of crossover actors.) Like Stargate, a lot of the filming happened in the Vancouver, BC area.

I was curious where the downtown Eureka scenes were filmed so over many episodes, I carefully looked for clues and searched and searched and searched around on Google Street View until I finally found a couple blocks on Wellington Ave in Chilliwack, BC which looked similar. (Shortly after that, I found this website which lists out all the filming locations for many different shows. Derp.) That’s only a couple hours from our house and it seemed like it could be a fun family adventure day so I looked up a few other possible activities and we set off.

Our first stop was the filming location and even though it has been 10 years, I was happy to see how much it felt like walking through Eureka. It wasn’t quite the same vibe I had walking through Radiator Springs at Disneyland, but it was similar.

With my own nerdery satisfied, we set off to find some food at Cookies Grill. I don’t remember how I stumbled on this place (Yelp?) but I suspected it would be a winner since Tyla and Elijah love breakfast and Cookies serves breakfast for lunch. It lived up to their expectations and they honestly talk about driving all the way back there to eat again some time.

While we were walking around Eureka, there were a few other people there looking in the shops, etc. One of the couples seemed like maybe they were Eureka fans too but that seemed unlikely and I wasn’t about to start that weird conversation. When we drove ~10 minutes to get to Cookies Grill in a random strip mall area, we got out of the car and the same couple was in the parking lot! Weird things happen in Eureka.

It was still raining but we went for a hike anyway to see Bridal Veil Falls. The path is almost smooth enough for a wheelchair (except for a couple stairs) and it’s only ~5-10 minutes long, but it’s steep. The falls are beautiful though and the length of the tiny hike was about perfect for our day.

From there we stopped for ~10 minutes at the Chilliwack Supercharger on Luckakuck Road and then continued our journey via Lickman Road. As we giggled about the street names, we drove to Chilliwack River Valley Honey where we picked up a few jars of delicious honey. (Before we left home, I verified that we could get back across the border with it.)

Our border entry into Canada had been quick and while the internet said the return trip would be quick, the line of about a dozen cars was moving very slowly. They were carefully inspecting everyone, searching a lot of cars, and even pulling some cars off to the side for additional inspections. As we approached the booth, I was prepared for a lot of questions, but apparently we are super boring and we were almost waved right on through.

Despite what the border guard must have thought of our story, we loved it! It was a lot of driving for one day, but Elijah had fun going to Canada for the first time that he can remember, and we all enjoyed the random sites. There were quite a few other attractions in Chilliwack that looked interesting (water parks, giant lakes/parks, disc golf, etc.) so who knows, maybe we’ll be back!

Remote Access to Home Network

Let’s say you’re the kind of person who is running a website within your home network and you want to access it while you’re away. Let’s also imagine you’re the kind of person who has at least a loose knowledge of your router configuration and what a VPN does. Yes, this one gets a little geeky, but maybe it will be helpful for someone else out there.

I run Teslamate to record a bunch of stats about our car, but one the reasons I check it most often is to see whether the car is asleep or not. Sleep mode for a Tesla is like standby on your computer. There’s normally a constant drain from the car when it’s sitting there, but if it goes into sleep mode, it uses almost no power. This is important especially in situations like when we’re away from home and I’m leaving it parked outside a hotel overnight. I like to be able to check in on whether it’s in sleep mode as well as the current battery state. Teslamate lets me check that without waking the car up. But Teslamate only works on my home network. How can I view it while I’m away? Obviously I could just open that port to Internet traffic but it’s an unsecured connection and I don’t really want to share all that personal info with anyone who happens to sniff my password. So how can I view that website securely while I’m away?

The first option I tried was using a feature of my Synology router. That router has an installable app called VPN Plus Server. There are a few different modes, but the simplest one gives me a VPN tunnel into my home network and the ability to browse to any internal website. During setup, the app walked me through creating an SSL certificate so that the traffic would be encrypted, and the app provides a nice portal experience where I can have links to any internal websites that I might want. There’s a more complicated version of the app that actually lets me set up a Windows VPN connection to my home network but I haven’t played around with that yet. It would be overkill for the scenario described here.

The second option is via NordVPN. I like to have a VPN subscription like NordVPN to encrypt my traffic when I’m on public WiFi like in a hotel or at a store. A side benefit of NordVPN is their MeshNet feature (but they recently announced that MeshNet is now free for everyone!) MeshNet allows for VPN-protected communication between two devices from anywhere in the world just as if they were on the same network along with other features like file sharing. So this also lets me access that Teslamate webpage from anywhere.

There are plenty of other ways to tackle this scenario, the most obvious of which is “this is dumb, stop worrying about it”, but these are two have that worked for me. The NordVPN is definitely the simpler one, but the Synology option gives me more control and more options.

18-Month Drone Timelapse

Ever since we moved here about 12 years ago, there has been a big open field behind our neighborhood. It provided a nice buffer as we looked out our back windows. As expected, the person who owned that eventually passed away and it was sold to a land developer. Over the course of about a year and a half, they tore out everything on the property, dug an enormous hole for a water retention box, and then put six house on top. The houses are selling for $1.8-2 million. Real estate around here is nuts.

I had gotten my drone earlier that year so I started capturing some photos and videos of the project. Then it occurred to me that if I could somehow fly the same pattern repeatedly, I could build a video drone timelapse! Thankfully there are plenty of apps like this already available and with very little effort, I had Dronelink up and running. I was a bit limited in the paths that I could run smoothly due to the speed of my old phone, but I got a basic one programmed in and started flying it every weekend. Over the course of the project, I added a couple more routes into the mix.

After 18 months of flying most weekends and then many hours of editing trying to align all the images and video, here’s the result:

Once you start a project like this, there really aren’t a lot of adjustments that can be made. You need to keep doing the same thing to get the timelapse and a lot of the learnings aren’t visible until you do all the editing at the end. If I had it to do over again, here are some things I’d do differently:

  1. Always fly in exactly the same lighting conditions. The cloudy days were the easiest to edit. Direct sunshine make it really difficult, but theoretically if ALL the shots were direct sunshine around the same time of day then it might be ok.
  2. Take the time to calibrate the gimbal and wait for extensive GPS lock before starting. Some of the shots were way out of the norm and it took a lot of time to try and twist the results into something that matched the shots around it.
  3. When editing, pick a clip in the middle and then work out toward both ends to align all the photos. Otherwise the error increases over the whole span of the video and by the end you have a huge area of black. I had to redo a couple sections because of this mistake and because I didn’t learn my lesson the first time.
  4. Pick paths that are far away from the action. Ideally they would have the full project in view for the whole flight. I wish I had just done a big circle around the project or something like that.
  5. As cool as the video idea is, I think the photo part of the timelapse worked the best. Doing a mix of the two is probably good because I still think the video could be done well, but it’s a higher degree of difficulty.

Hopefully I’ll never be in a situation where I’m think close to a major building project again so I’m glad I took advantage of the opportunity. That being said, I’m glad it’s over because it did get a bit boring as time went on.

Google Photos Replacement

We really enjoy Google Photos. All of our photos from our phone, our dSLR, screenshots, text messages, etc. all get sent to Google Photos. Proper backup of all those things is done with our 3-2-1 backup strategy, but Google Photos is our way to easily find photos. Their search engine makes it every easy to search for something like “Tyla Ben motorcycle 2018.” Their facial recognition is creepily good, even identifying baby photos of people who are much older now.

This was a free service for many years, but over the past year or two, they’ve started charging for it. That hasn’t impacted us becase we both use the Google Pixel 4a. Those phones have unlimited photo and video storage forever. That deal is for compressed versions of the photos and videos, but since we’re only using this to find photos, not for permanent backup, that’s not a problem.

But what happens when we eventually upgrade to a new phone? Hang on tight. We’re going to nerd out about all the options and the pros/cons of each one

1) Some people go the route of keeping their old Pixel 4a’s around and just using them to sync their pictures to Google Photos. A picture gets taken on the new phone, gets synced to the old phone, and then gets uploaded to Google Photos. That might work, but it gets a little more complex since we’ll probably end up giving Elijah one of our old phones. (Whether he gets a SIM card with it is a separate discussion.) Android does support multiple users on one phone, but I’ve never messed with that before and I imagine that I’d have to periodically switch back and forth between the two users to force them to sync so it gets pretty complicated and it’s not automatic.

2) We could pay for Google Photos. To estimate how much this would cost, I used Google Takeout to create an archive of all of my photos. Our compressed photos average 1.7MB per photo and we take about 15,000 photos per year. We took about 2000 videos last year at an average 100MB/video. That adds up to a little over 200GB/year. Looking at the plans, if we did photos only, we could get by with the $20/year plan but otherwise we’d very quickly need the $100/year plan. That’s not cheap but maybe it’s worth it once I consider the hassle of the other options.

3) We have an Amazon Prime account, and we probably always will. That comes with free unlimited, full resolution photo storage in Amazon Photos. I didn’t even realize that Amazon offered this service, but in many ways, it’s comparable to Google Photos. It differs from our current setup in that it doesn’t include video storage, and their sharing isn’t quite as nice either. Google Photos lets Tyla and I set up photo sharing and then anytime either of us take photos of anyone in the family, it automatically gets added to the other person’s account. If we want to see ALL the photos, we have to go into a separate folder. It works really well at automatically sharing the photos we generally care about the most. Switching to Amazon Photos would be a pain as I’d have to reupload everything which would hit my “unlimited” bandwidth limits at home. Then I’d also have to recreate albums and favorites. But even with all that work, it’s not impossible, and “free” is a nice price as long as we’re ok with not having videos uploaded there.

4) If I already have all the photos collected on a server at home, why do I need to reupload them anywhere? What I’m really looking for is a way to automatically tag and search our photos. It turns out that there are a ton of projects aiming to let you self-host this technology. I won’t try to compare them all, but this post does a good job of explaining many of them. Note that many of the projects have been improved since that was written, so you have to actually go look at each one to see its current feature list. Some of them look nice, but the drawback here is the extra time/pain of self-hosting. It all generally works fine, but when it doesn’t, then I’m tech support and I need to make it work. I also have to spend a lot more time trying to figure out how to safely expose this for us to access from outside the house. Additionally, most/all of these solutions end up making their own copies of all the photos, so I end up storing everything twice. Our entire photo collection is over three terabytes, and it’s duplicated across two physical drives so doubling that again means I’m going to have to add space.

When I look at all the work involved in switching, the cost of paying for Google Photos doesn’t seem so bad, but I’m a nerdy cheapskate at heart so this is still up for debate. Do you have any other solutions that I should consider? And yes, I realize we could give up on the idea of having all our photos be easily searchable, but once you’ve experienced that, it’s hard to give it up. We use it a lot!

ChatGPT

I’m going to assume by now that you’ve heard about ChatGPT, but as a quick intro in case you haven’t, it’s a conversational artificial intelligence. Where you might ask a regular search engine to find facts for you, ChatGPT can answer a lot more why/how questions or even create things from scratch. I recommend that you log into it and play with it a for a while to get your own glimpse of what it is capable of. The responses it gives are incredible. Here are some examples:

  • “I like Mexican food. Make a meal plan for this week.” It replied with a nicely formatted list of breakfast, lunch, and dinner ideas, including side dishes. I followed that up with “Give me a shopping list for that meal plan” and it provided that too.
  • “Write a sermon on Matthew 11.” I did that after coming home from listening to Pastor Erich give a sermon on the same verses. While Pastor Erich’s was better, ChatGPT did an incredible job of summarizing the text and then giving three Biblical takeaways to apply to your own life.
  • “Write a rap about brussel sprouts in the style of Flava Flav.” The result probably won’t win any Grammy’s but my favorite line was “They’re the ultimate in healthy snacks and they’ll put a pep in your step, no need for caffeine or crack.”
  • “Explain orbital mechanics to me like I’m 5.” I’m pretty confident that I could have read this to a five year old and they would get the basics.
  • “I want to destabilize western culture without anyone knowing what I’m doing.” I heard this one on a podcast and ChatGPT replied with an 8-point plan about starting social media campaigns to question authority, create alternative narratives, etc (basically everything that people are doing today.)
  • “Design a spacecraft that can carry humans to other planets.” This was an idea from a coworker who then proceeded to keep giving it more requirements and asking detailed design questions which it happily answered.
  • I asked it one of my favorite questions that I use in interviews. It explained the approach in English, rewrote that as a list of steps, and then generated a solution in Python. It was a better answer than I get from 90% of job applicants.

As a software engineer, I love this. It’s a great example of what technology is capable of today, and a reminder that technology is improving exponentially quickly at a faster rate than we can comprehend.

What I don’t like is that this plays into what people think of when they hear “artificial intelligence.” People think of AI being robots in movies, but artificial intelligence is an enormous field with many different applications. While ChatGPT may give you the willies, how do you feel about your doctor using a model to figure out the best course of treatment for you, a cloud provider deciding which hard drives are going to fail in the next 24 hours, or a system telling third world farmers when to plant their crops. Most people would agree that those are great scenarios but how many would recognize those as “artificial intelligence”? We need a different word for AI when it applies to creepy things you can converse with. (And yes, I know there ARE different words for that category of AI, but they aren’t used in the general population.)

Or maybe I should have just let ChatGPT write that last paragraph:

There are many reasons why people may be afraid of artificial intelligence (AI). Some people may fear that AI will become too advanced and surpass human intelligence, potentially leading to loss of control over the technology. Others may be concerned about the potential for AI to be used for nefarious purposes, such as surveillance or manipulation. Additionally, some people may be concerned about the potential for AI to take over jobs and lead to widespread unemployment. Overall, the fear of AI likely stems from a fear of the unknown and a lack of understanding about the technology and its capabilities.

There are many potential uses for AI that do not scare people. For example, AI can be used to improve healthcare by analyzing medical data and providing personalized treatment recommendations. AI can also be used to improve transportation by helping to develop self-driving cars and other advanced transportation systems. Additionally, AI can be used in education to provide personalized learning experiences and to assist with grading and other administrative tasks. Overall, the key is to use AI in a way that is transparent, accountable, and beneficial to society.

https://chat.openai.com/chat when asked “Why are people afraid of AI?” and “What are some uses of AI that don’t scare people?”