dinosaurs eat everybody

for all your Dave Schwantes related needs

Thing A Week 19 - RecLab Online Presence

So this Thing a Week post is late because I was out of town from last Saturday until late yesterday night.

While I did make some progress on getting the RecLab Rails application to connect to Rocktopus (our audio processing library) the main thing we got accomplished last week was setting up our RecLab presence online.

A major part of this was building out a Launchrock page to point our domain at. So now if you go to reclaboratory.com you actually see something! Right now we’re just collecting email addresses, but building this out helped us think through some basic service descriptions, a tagline, and formalizing how to write the name. It’s officially RecLaboratory. Note the capital ‘R’ and ‘L’. It took us a surprising amount of discussion to decide on this convention.

We also cleaned up our Facebook, Twitter, and Instagram accounts, so those are ready to be used.

Feel free to follow us at any of those places as we’ll be starting to use them soon.

Thing A Week 18 - Wine Women and Song Cover

I didn’t really plan to do anything outside of RecLab work this week but yesterday I got in the mood to play and record some music so I ended up with a new recording for this week’s thing.

Eileen and I have been talking about doing more recording together (as Packets and Waves) and after a recent Hurray For the Riff Raff show, we were in the mood to do some old country songs. We settled on doing a cover of Loretta Lynn’s Wine Women and Song. It’s a short, simple song (which was important because we started learning it at about 11:30pm on Saturday night) and I just like the phrase “wine, women, and song”.

We didn’t want to it be an exact copy of the original so I tried to give it a dirty Black Keys-ish guitar sound and keep the guitar part pretty simple. I resisted to urge to layer on a bunch of random instruments and only used guitar, bass, and drums for most of the song. The piano was only added in the chorus and solo sections, even though I tried a few takes where I recorded some sporadic piano comping throughout the whole. In the end, the stripped down version just sounded cooler.

I’m really coming around the the virtual drummer in Logic Pro. At first I really resisted the idea of letting the software “write” my drum parts for me, but the sound is so much better than MIDI drums and I can actually get some interesting parts. For this song I used “Logan” with a retro sounding kit. I thought the tom driven verses worked out really well.

Eileen’s vocals turned out nicely, as usual. I was tempted to dirty up the vocal recording with a tube mic simulator, but I ended up just using a simple “out of the box” compressor effect, which sounded fine.

This ended up being a really fun little project. It only took a few hours from idea to finished product and the result was really satisfying. Enjoy our cover of Wine Women and Song!

Thing A Week 17 - RecLab and Drawing Class Update

This week, while I was busy with the first week of my new job, I did manage to get some RecLab work done. Also, I’m a few weeks into my drawing class, so I wanted to post an update from that.

While not the most productive RecLab week, I did finish the basic comment functionality for Users, Songs, and Tracks. I also learned about seed.rb and wrote some seed code for the Instruments data. The trick there was that I wanted to be able to run rake db:seed multiple times, so I needed seed code that would let me update or create records. I ended up with a nice solution that lets me break the instruments down into separate arrays by family and then loop through everything to create or update:

instruments = [[strings, "strings"], [woodwinds, "woodwinds"], [brass, "brass"], [percussion, "percussion"], [keys, "keys"], [other, "other"]]

instruments.each do |f|
  f[0].each do |i|
    instr = Instrument.where(name: i).first_or_initialize
    instr.family = f[1]
    instr.save!
  end
end

Now I’ll need to use a tagging system to attach both Instruments and general Tags to objects. I’m leaning toward As Taggable On, which apparently was written by an old childhood friend of mine. Awesome!

The art class is going well. Value and shading are still pretty tough for me because I’ve spent the last few years just doing line drawings for comics. I also have a tendency to draw pretty lightly (which is probably also a result of erasing pencil lines for comics). I don’t think I’ll leave this class a brilliant artist, but but I’m certainly learning things and getting better.

Thing A Week 16 - No Thing Again

Once again I didn’t have a great Thing a Week week. I actually didn’t even get to the point of planning a project for the week. But I did accomplish one thing: I got a new job.

I spent a bunch of time this week prepping for and going on interviews and on Thursday I accepted a position as a Senior Full-Stack Engineer at Couchsurfing. Today was my first day and so far it’s an awesome gig. The office is amazing, it’s full of dogs, and I get lunch and dinner provided everyday by the staff chefs. The work seems like it will be a lot of fun too. I’m doing Rails development and it seems like I’ll be able to have a lot of say in how the product gets architected.

While it wasn’t the most productive Thing a Week week, getting a new job certainly qualifies this as a pretty productive life week.

Thing A Week 15 - RecLab Song Collaboration

Once again this was another week where my main productivity was with RecLab. I’m back to mainly working on the Rails application now, focusing on building out some of the song access features.

Our big breakthrough this week was being able to actually collaborate on a song using RecLab. Bobby and I were able to record tracks on our individual computers, create new tracks in RecLab, and combine them together into a song. The process was pretty clunky and the interface is still very sparse but it felt like a big step to use the product for its intended purpose.

There is still lot of work to be done before we can even start letting other people try the product but hitting these little milestones feels good.

Thing A Week 14 - Drawing Class

This week I started something new. I’m taking a Drawing 101 class at Root Division art studio in the Mission. I’ve been drawing comics for a few years now, it seems like I should start learning how to draw.

The class seems like it’s going to cover the basics and have us work mainly with graphite and charcoal. I think it will be really good for me to take a step back and really learn some of these fundamentals. I haven’t had any formal art training since Jr. High, so I’m about due. I really feel like my comic art has started to hit a wall and I’m having a hard time getting some ideas down on to paper.

The drawing above is the first thing our instructor had us do: first draw an apple from memory, then he put an apple on the table for us to draw. Apples are kind of hard to draw.

Hopefully I’ll have some more impressive work from this class to post in the future.

bonus thing!

Eileen got me a copy of Logic Pro X for my birthday and so the first thing I did with it was play with all the amp models and pile a bunch of guitar parts on top of each other. The resulting 30 second piece ended up sounding like some kind of epic video game music:

Thing A Week 13 - RecLab and Rocktopus

This week was another mainly RecLab week. Actually I didn’t get much done on the RecLab Rails site outside of updating the look and feel with the new logo we’ve settled on (shown here…). I spent most of my time on our audio processing API, Rocktopus.

The Rocktopus work has been going well. It’s nice to get back into writing some Python again and I’ve been enjoying working with Flask. One of my favorite recent additions is the require_auth decorator. Python decorators are pretty awesome and make it really simple to roll some common functionality into several methods.

This allows me to write Flask endpoints like this:

@app.route('/path_name', methods=['POST'])
@require_auth
def path_method():
  # do a bunch of stuff for this endpoint
  # but make sure the POST body contains the proper authentication

The decorator itself is pretty simple and works something like this:

def require_auth(f):
    @wraps(f)
    def wrapped(*args, **kwargs):
        data = request.get_json(force=True)
        if not validate_auth(data):
            return response_arm.auth_fail() # return 401

        return f(*args, **kwargs)
    return wrapped

Rocktopus is really coming along nicely and I’m really close to getting it hooked up to the Rails site soon.

This week I start my drawing classes. I haven’t had any formal art training since grade school and it seemed time to learn a bit more about drawing, given my interest in comics, so I signed up for a Drawing 101 course at a local art studio. Hopefully I’ll have some cool work from the class over the next few weeks to show off in these posts.

Thing A Week 12 - FilterFilter

So this week I actually made a thing. Back in week’s 4 and 5 I was working on a project to listen to Twitter for pictures with a certain #hastag so I could display them at our wedding. I also wanted to build something similar for Instagram and have it feed into the same database. This became FilterFilter.

The Instagram API works differently than Twitter’s. In order to get real-time information you have to register a callback endpoint with Instagram. This endpoint has to respont to a GET call with a validation code sent by Instgram and then respond to POST with whatever you want. Instagram only notifies you of an event (such as a photo being posted with a certain #hashtag), they don’t actually provide the media info, so you have to find that yourself, which is a bit annoying and kind of clunky.

Here is the Sinatra code you might used to create the GET and POST endpoints to register and use the Instagram API:

get '/instagram_stuff' do
  params['hub.challenge'] # for when you register your callback endpoint
end

post '/instagram_stuff' do
  # do stuff when Instagram tells you something 
  #    new has been posted
end

I was able to use a lot of the code I wrote for BirdWatcher (the Twitter listener) to store this info, so that was nice. I still need to write a front end to display all of these photos but that will be done some other week. It would be nice to bundle all of this together and create some sort of product for people where they provide a hashtag or keyword and I provide a nice display of photos from various services with those keywords. Maybe someday, when I have time to clean up this code a bit.

Of course I spent time this week working on RecLab, too. I got some S3 stuff set up and built out a few site forms. We were able to get a rough prototype of the basic track uploading and song creation functionality, which was fun to see. I also spent a bit of time working on our audio processing API. It’s starting to come together and it’s been very interesting designing something like this from the ground up.

To help us learn more about the types of people who might use RecLab I’ve put together a quick 10 question survey. If you are a musician, please take a minute and fill this out, it would be a big help! RecLab Musician Survey

Thing A Week 11 - More RecLab

Once again this week’s work was devoted more to a long term project than to anything that could be finished in 7 days. I put more work into the site and the audio processing tools for RecLab and we’ve been doing some good planning, too.

The site is pretty straight forward Rails, so far. Nothing too out of the ordinary there. I’m starting to get deeper into the music objects and business logic of the site, which is fun. I’ve also been working a bit with Flask as a wrapper around some of the audio processing stuff. After Week 7 I had been looking for a good Flask project and now I’ve found one! I’ve found some great resources on building good APIs in Flask, such as this one which have been really helpful for designing non-trivial stuff. I have a bit of experience building APIs with a micro web framework from building the Unofficial Fitocracy Runs API in Sinatra, but this will be a bit more complex than that.

Hopefully we’ll have something that I can actually show off soon. We’ll certainly need early testers. I do still hope to have work on a few small projects that I can show off from week to week.

Thing A Week 10 - RecLab Site

Once again I feel like I’m stretching the rules of A Thing a Week (which is ok because I sort of just made them up). This week I focused on starting the website for a new larger project I’ve started working on with a friend. We’re trying to build a good way for musicians to collaborate online. There are a few things out there trying to address something similar to this, but none of them seem to have serious traction and it looks like there’s a lot of room for refinement.

This week we did a lot of planning and architecture for the project and I started building the Rails application for the site. This is my first non-trivial Rails 4 project and it’s been interesting to see some of the little differences. The biggest one I’ve come across so far is the removal of attr_accessible and moving that functionality into the controller. I need to learn a bit more about how that totally works but so far I’ve been able to use a lot of what I learned building Rails 3.2 stuff.

I’ve been really impressed with the Rails 4 gem compatibility, as well. Major stuff I like to use such as Devise, Active Admin, and Paperclip are all working just fine. Python could learn a lot here!

This week I was able to get the basic site together, make it look nice enough to work in for a while, build basic user/user profile and login functionality, and start building out some of the core business logic for working with recorded tracks. I also started putting together some survey questions so, musician friends, expect to be bugged to be asked questions soon. It might be a little while before we have an actual site for people to try but I’m always interested in talking with people about the idea.

Now I need to balance working on this with doing a couple other single-week projects, especially the stuff that is needed for the wedding.