1. 27

This is the weekly thread to discuss what you’ve done recently and are working on this week.

Please be descriptive and don’t hesitate to ask for help, advice or other guidance.

  1.  

  2. [Comment removed by author]

    1. 2

      i love the idea of this

      i’d love something like this on black holes, say.

    2. 8

      Over the weekend I made a morse code interpreter in Python, which was fun. I like using mypy because it forces me to program with types, and I think this will help when I finally really learn Haskell.

      I’m continuing to write the backend to my custom crowdfunding app in Clojure. I have to build a client library for trello, so that is taking me a bit more time.

      On that note, does anyone have recommendations on best-practices for building client libraries in Clojure? Or examples of well-designed libraries? I watched Ian Barber’s talk, but converting his ideas to a specific implementation is difficult for me.

      1. 5

        Ha! Try it out on the Twilio API - instead of putting .json at the end of the URL, put .morse. Probably the most important feature I shipped while I was there

        1. 2

          Never discourage you from learning, but you should know there are no prerequisites to learning Haskell. My coauthor had never programmed before learning Haskell.

          I like the idea of writing a morse code interpreter, this is an exercise that has some nice properties. I hope you won’t mind if I steal it :)

          1. 1

            I know, I’ve heard that before (from your writing, and others'), and I’ve tried to learn Haskell before, but I couldn’t. First I didn’t fully understand types, and then I didn’t understand generics. I’m also not very good with math or algebra, so algebraic data types took me a while to grasp. Luckily I have @ChadSki to teach me these things over IRC while he should be working. I’ll get there eventually.

            Do as you like with it :) A coworker told me that MapQuest used to use this exercise for their hiring challenge, but I just did it for fun.

            1. 2

              It took me five years to learn Haskell well enough to use it for my work. It doesn’t have to take that long! My coauthor had never programmed before and can write modest programs now in Haskell herself after several months.

              Hell, despite struggling with it personally, I’m writing a book for learning Haskell.

              One of the mistakes people make is in thinking learning fast == prodigy or facility.

              No! The slow learners are sometimes the careful, more thoughtful learners! We need those people too :)

              So please don’t give up. Sounds like you’re in good hands but ping me if you ever need help.

              1. 1

                Oh, don’t worry. I certainly won’t give up. Once I have some extra cash and time, I’ll buy some Haskell books and dive in, study it hard over the course of a month. I expect that to happen sometime before autumn. Thanks for the offer to help, I’ll likely take you up on it at some point :)

                1. 2

                  The book won’t be done by autumn, but if you’d be willing to be a reviewer for us you’d be able to read what’s in our book so far at no charge. We’ve been testing with others and it’s been pretty successful so far I think, but more feedback wouldn’t hurt us. If you’re interested, please message or email me :)

                  1. 1

                    I’m curious, will the book have a lot of practical examples? This is how you build a web CMS in Haskell. This is how you grep through a bunch of files. This is how you implement Levenshtein distance, Euler’s method. This is how you step through with a debugger; how you profile, and optimise.

                    I am mostly ok with Haskell doing silly functional puzzles, but when it comes down to doing actual work, I get bogged down. I would like to see examples of the things I want to accomplish.

                    1. 1

                      Some, yes, a lot – no. It has more almost all of the other books, but it’s still mostly examples, exercises, & prose. The book is written for beginners to programming because you have to relearn how you think about programs anyway, so constraining ourselves to what works for beginners produces a book that works better for programmers.

                      People get frustrated, confused, and stuck because they leap into trying to make things too early.

                      Our exercises are representative of the sort of things you have to figure out in the course of writing Haskell programs, but they’re still focused exercises.

                      This stance is based on considerable experience teaching Haskell to programmers and non-programmers alike. There’s already a project-oriented book for learning Haskell – it didn’t work well for most and didn’t really teach you how to reason about Haskell code.

                      That said, the goal of the book is you leave you prepared to understand most Haskell libraries and projects so that you can make things yourself – the mistake is thinking the best way to do that for beginners is to chuck them into things they don’t understand. Some cargo-culting is necessary to teach things without explaining everything upfront or all at once – but project-oriented approaches take this too far and rarely bother to explain how the language itself works. It ends up being more of a show-and-tell, which we haven’t found to be effective by itself in any medium.

                      1. 1

                        Okay, how about this. I have some Python code that implements a silly algorithm. Could I pay you to translate the Python algorithm into idiomatic and performant Haskell?

                        Will you be my Haskell Chinese room? I don’t think you need to understand what the algorithm does, because I don’t want you to implement a different algorithm. I want you to take the Python and translate it into Haskell as literally as possible. Algorithms should not depend on the programming language, right? Any algorithm should be expressible in any programming language, right?

                        Can you do that?

                        1. 2

                          One can reuse almost any algorithm you want directly in Haskell.

                          Idiomatic and performant? 99% of Haskell code doesn’t need or use mutation, but I’m not sure a light sprinkling of mutable vectors is unidiomatic in production Haskell either. OTOH, I almost always use persistent vectors/maps/hashmaps/lists/sets if I need a collection.

                          There being a translation between two domains doesn’t say anything about learning processes.

        2. 7

          This weekend at our monthly paper group I presented “The Cathedral and the Bazaar”, or, “I read Eric Scott Raymond so you don’t have to”. My friends presented “Reflections on Trusting Trust” (a.k.a., “Love is over”), a paper on something involving Haskell, and the first of three talks on the implementation of Unix. It was a lot of fun. :)

          This week I am trying to work around a terrible memory leak in IE11 with their lineTo() implementation, by hopefully using WebGL to circumvent a broken graphics stack. I don’t think it’ll be particularly successful, but a person can dream.

          1. 1

            Do you have a video of the talk? I have only skimmed the paper and would love to hear a commentary. :)

            1. 2

              No video–honestly, the approach I took after reading it was to recap all the numbered points, and occasionally inject additional historical context where needed. The updated edition, for example, calls out the Mozilla experience (JWZ’s “open source is not magic pixie dust”), which I elaborated on a bit.

              We might start doing recordings though. :)

          2. [Comment removed by author]

            1. 4

              If you’re looking to relocate to SF (saw from Github that you’re in Ontario), Grand Rounds is looking for a lead devops eng, and we have quite a few folks from Toronto and Vancouver. If you’re interested, send me an email (firstname at lastname dot com).

              1. 3

                And how. If you are out in Berkeley CA, we have a DevOps position open. PM me if you are interested. lol

                1. 1

                  We make fake music maps in west Berkeley for mappable.com! It’d be fun to compare notes with you all some time, whether on the backend, WebGL, or otherwise.

              2. 5

                I just got a job offer last week at Ecometrica, which I have accepted! So this week I am in the middle of my two weeks' notice, documenting my work and doing the handover.

                I am very excited about the new job. It does mean that I will have to wait longer to start my own Octave-based business, but it also means I will get to learn cool stuff and improve myself.

                1. 5

                  I started learning Perl 6 because I want to prototype a DSL and Perl 6 grammars are amazing! I mean, just magical things that implement a PEG in the most intuitive way.

                  I think DLS creating is a lost art. I used to do a lot of it in my youth and maybe now that I am a big boy I can do a better job.

                  1. 2

                    Interestingly, the perlmonks link on grammars is from 2002. Have they not evolved the grammar stuff since then? In other words, is this still accurate?

                    1. 1

                      Ah, crazy. I didn’t realize it was that old. Most of it seemed to still work :/ It obviously isn’t the only resource I am using. Here is a link to the official perl 6 grammars docs.

                  2. 5

                    I got my Jetson TK1 the other day (http://www.nvidia.com/object/jetson-tk1-embedded-dev-kit.html) and I’m going to be setting it up and getting caffe running on it. Nifty!

                    1. 5

                      I started a new job doing operations <2 weeks ago. First real task after reading through internal documentation (which was, on the whole, good) is to improve on boarding docs. Most of the tech people and some others are remote, and they/we rely on some externally hosted services. Makes sense to document it while it’s still fresh in people’s memories. (BTW we’re still hiring for a remote Ops person. If interested, send me a PM.)

                      Outside work I just finished reading The Martian by Andy Weir. It’s a cracking book! Sat reading it at the pub on Saturday and “got something in my eye”. Luckily the waitress mistook me wiping my eyes with a napkin for hay fever issues. (Or she had a lot more tact than I gave her credit for.)

                      1. 5

                        We just launched Again, so this week I’m working on getting the word out.

                        It’s an app to help you create habits and be better about completing groups of recurring tasks. Think: “call each of your relatives” or “make different recipes for dinner” or “make sure you don’t accidentally lapse in giving each of your employees casual feedback.”

                        From a tech perspective, we wrote it with Ionic.

                        DM me if you want a promo code for the iOS App Store. Android users: it’s your lucky day… you don’t need one. :)

                        1. 1

                          Will you write up a technical blog post on it ? I’d love to hear about the process that went into making this.

                        2. 4

                          I’m trying to write a program to generate cool looking roller coasters. Crunch time before my talk for OSCON (see you there?); I spent the entire weekend working on my coaster generator. Got a bunch of stuff done, but still a bunch of work to do. https://github.com/kevinburke/rct/compare/a91fc41e91a5f339f857e07d88f03cfdf1fb42a7...master

                          • Fixed a ton of data consistency issues; some left turns were showing up as 0 change in sideways motion. Data consistency problems are a constant drag
                          • Wrote a “return the track to the station” helper to help the genetic algorithms out a little bit
                          • Experiments were generating 2.5GB of data - thank goodness for compression, which took this down to 80mb per experiment.
                          • Added more tests
                          • Wrote a server endpoint to take track data in JSON and turn it into a TD6 file readable by the game. Unfortunately I wasn’t able to get any of the tracks to load in-game (RCT2 keeps saying “Invalid data” and this part hasn’t been decompiled into C yet).
                          • Removed some tracks that wouldn’t work; for example a mine train coaster was trying to include MINI GOLF HOLE D as part of its track layout.
                          • Friend of mine tried working on the in-browser coaster viewer in three.js, but being able to view/zoom on coasters in the browser continues to be a pain. Three.js is hard, and 3d programming is not a strength, unfortunately

                          The next piece of the fitness function is going to be applying a penalty to tracks based on the number of collisions they have - a track can’t collide with itself. Was running into problems with tracks exceeding the bounds of an array I created to mark the track positions.

                          This is a great time to get involved! All of the track data is decompiled; there’s a framework for running experiments and storing the results of each one. I have a basic fitness function now, and a crossover algorithm. Now just need to iterate on the fitness function - adding more parameters and tuning it - and possibly tweak the parameters of the genetic algorithm to give more weight to successful nodes, or something.

                          1. 4

                            Continuing my research in e-ink displays. There seem to be three routes:

                            1) Drive the display panel yourself. This is still the least attractive route to me, as it involves a lot of work for relatively little payoff. I have found a couple blog posts where people succeeded at this endeavor, but the refresh rates seem abysmal. In theory you have ultimate control over the board, but it would take a lot of work to use this for anything other than digital signage.

                            2) Get a display+controller combo and drive it over SPI. This is much easier than driving the panel yourself, but refresh rates remain slow. A great option for digital signage, quick prototyping, or general fooling around. I covered this option last week, and MpicoSys’s displays (the 4.41" and larger panels) remain an attractive choice.

                            3) Use a Freescale EPD controller. This is the most interesting option to me. Unfortunately the market is not DIY-friendly in the slightest, and seems to cater exclusively to large corporations who will buy 1000s of chips at a time.

                            In yet another blog post, I found a clue:

                            Bunnie […] clued me in to the fact that the iMX6 SoC present in the aforementioned device contains an EPD (Electronic Paper Display) controller. Although the pins on the chip likely aren’t broken out to the board, it gives me hope. My hope is that in the future devices such as the Raspberry Pi, CubieBoard, or other single-board computers will break out the controller to a header on the main board.

                            Although it’s fairly easy to find cheap single-board-computers with i.MX6 processors, none of them seem to hook the controller up to any pins or headers. And so we drop a little further down the rabbit hole with these options:

                            3a) Print my own PCB featuring an i.MX6 chip. I know zilch about this topic, so I hope it doesn’t come to this.

                            3b) Connect an i.MX6-based COM (computer-on-module) to a carrierboard. The carrier should either have an EPD socket (what do these even look like?) or at the very least a set of pins I can hook up as needed.

                            3c) Hack an existing i.MX6-based device that already includes an e-ink screen. Surprisingly, this brings me full-circle back to the Kindle!

                            I was too quick to write off Kindle-hacking. The Kindle Paperwhite 2, for instance, contains a 1Ghz i.MX6 Solo (ARM Cortex A9) conveniently pre-connected to an e-ink display. This changes a hardware game into a software game. Can one drive the Kindle’s screen without Amazon software? Well, I’m still researching the answer to that question. Tune in next week…

                            1. 3

                              Made it to a local Code and Coffee meetup, so I was able to make some commits to Hython:

                              • Settled on a vanilla Interpreter monad. Tried to compose it with Haskeline to make a dope REPL but it ended in tears, so I’ll come back to it later. The Interpreter monad is one of the big differences in the rewrite: I’m separating the workings of the ad-hoc abstract machine used for executing the language from the interpretation of the language. Time will tell whether this is a good idea.

                              • Lots of thinking on whether I want to build the built-in types (int/string/etc) in Python or Haskell. In the previous incarnation of Hython, I took a hybrid approach. Leaning towards Haskell so I get more benefits from compiler chastising me.

                              This week:

                              • Add facilities for calling functions, and possibly exception handling to Interpreter monad
                              • Implement print builtin so I can resume running tests
                              • Stretch: Try again at implementing the semantics outlined in Python: The Full Monty
                              1. 2

                                @work: I plan on automating some of the tedious ops tasks at work using Ansible. Then I will jump to setting up a receiver for a github webhook that automatically builds and deploys our api docs.

                                @home: Still preparing the house for any buyers to walk through. I need to setup the Ansible scripts for the servers that will power my fun side project. I would have used Heroku but I find paying monthly for SSL to be a joke.

                                1. 2

                                  About a year ago I designed and ordered a batch of 300 dog collars with matching leashes, with the purpose of learning various marketing and brand-building skills while selling them. I’ve been really procrastinating on creating a nice landing page for them, (by way of over-designing).

                                  They’re a lot higher quality than typical overseas-manufactured goods. I’ve spent a lot of time iterating on them to make sure they have a good, high-end feel to them similar to designer handbags.

                                  1. 2

                                    Job hunting continues this week. I’ve got 4-5 interviews or interviews-to-set-up, so I’m having moderate success.

                                    Off to coding challenges!

                                    1. 2

                                      I’m trying to launch a new Co-Founder matchup site (similar to cofounderslab, founderdating, etc..). I’ve had some pretty bad experiences and it seems most of the cofounder matching sites seem to be lacking in certain areas.

                                      I’m working on combining the good features of existing sites into 1 product.
                                      Beta sign-up list is here - falgo.io

                                      Hope to put an mvp product out within the next 3-4 weeks.

                                      Would love if some folks could signup for the beta and give some feedback when it launches. Can also email me direct if you have some suggestions - jxm262@gmail.com

                                      1. 2

                                        Setting up the master package index system for Roost, my alpha-stage package manager for building and managing Swift projects without Xcode.

                                        Also experimenting with improving Jbuilder performance, especially with regard to working with caching systems.

                                        1. 2

                                          Visiting SF for the week. Nominally a buisness trip but I’m trying to take some time to meet internet friends in the bay area since this is my first “real” trip out. Hit me up [on twitter](twitter.com/arrdem) if you’re interested.

                                          $WORK

                                          • Apache SPARK
                                          • Makefiles and Clojure and parallel compilation and dynamic scope and burn everything. Actually it’s working rather nicely although hard to debug. Yes I know what year it is and yes I’m writing Make not using boot. There are good reasons for this.

                                          $!WORK

                                          • Working on quite the Clojure essay. It’s under wraps for now but will be out sometime this week.
                                          • Experimenting with what richer documentation for Clojure would look like for Grimoire, and thinking about where the implementation vs api line falls in Clojure due to the implications of what needs to be documented and what doesn’t need to be.
                                          • Exploring the Bay!
                                          1. 2

                                            I’m working on Helix Pi, which is a game development tool that enables people to make games without writing code.

                                            As a user, you describe the behavior of a game by making miniature animations, which are then turned into programs using genetic coding.

                                            I’m currently working on refactoring the structure of the generated programs so that they can be stored. Currently, they’re an array of closures, but good luck serializing a closure. Once I’ve done that, I’ll actually be able to store results, which means I can work on a game for longer than the lifetime of one tab.

                                            1. 1

                                              Threw the baby out with the bathwater with my home server and have (almost) started over from scratch. Previous data is intact, zones are all deleted & being recreated via puppet. Fresh zones are bootstrapped with a bash script via ssh, then puppet manifests rsync’d in and applied with puppet apply. Feels about the right level of control for my local network. No need to keep a master server running/available, but keeps everything under config management. Now to finish recreating the zones from before… (Next “I wonder” after that is managing the zones themselves with puppet from the global zone.)

                                              Outside of technology, more cycling and perhaps some swimming. Really getting back into the mechanical side of cycling as well as riding again, serviced & cleaned a friend’s bike this weekend, spent this evening tinkering with mine too.

                                              1. 1

                                                I’m migrating tpm plugins from bash to posix sh scripting, I plan to make it the default in a minimalist linux distribution I’m working on

                                                1. 1

                                                  Finally got my GLSL particle shader to work when the whole particle system also has an arbitrary rotation. Basically each particle system can now have a translation and rotation and each particle can also have a local translation. Turns out one of the problems I had was sending custom data with vertices, I was actually sending junk due to getting my offsets wrong. After I fixed that everything magically worked which was a relief!

                                                  1. 1

                                                    Finished my internship where i worked on an android app, an ios app (first time), web backend and some embedded stuff.

                                                    Dove into a new protocol, CoAP. A very interesting spec. The libraries are nice too.

                                                    Totally worried about what kind of job I should get since I like to do everything (except web frontend).

                                                    1. 1

                                                      @Work: Trying not to just up and quit my current position (recent management changes haven’t helped). Otherwise, helping my two summer interns on “Porchlight”, our system monitoring dashboard tool. Hopefully we’ll have time to open-source it before they leave (I know, like the world needs another open-source dashboard tool, but I didn’t want to use one that required Ruby).

                                                      !@Work: In the meantime, I’m prepping the first video in my “Docker” course that will either go up on Udemy or on my own site (probably the former for this video, then the rest on my site). Exploring doing a live full-day Docker workshop, probably in August/September.

                                                      1. 1

                                                        work: * more ontology matching, if the package upgrades ever end. It’s great to finally be live on https://mappable.com/

                                                        outside work: * finishing a minimal tool for loading flat JSON (or heka messages?) into a DB for ad-hoc analysis