Sunday, April 13, 2014

Wait... you do what?

Now comes the time for me to finally explain what is means to be a Computational Scientist...

Let's start by looking at the two words first. When doing this, I first consult our good, old(1806, in fact) friend Merriam-Webster.

They define Computational to mean:
The act or action of computing; or, the use or operation of a computer [Source] 
And Scientist as:
A person who is trained in a science and whose job involves doing scientific research or solving scientific problems [Source]
Now, to combine those two definitions in a some-what eloquent way:
  A person whose job involves doing scientific research or solving scientific problems through the use or operation of a computer [Source]
Boom. That's my best definition. Now, the source of all knowledge, WIKIPEDIA.
computational scientist is a person skilled in scientific computing. This person is usually a scientist, an engineer, or an applied mathematician who applies high-performance computers in different ways to advance the state-of-the-art in their respective applied disciplines in physicschemistry or engineering. Scientific computing has increasingly influenced other areas including economics, biology and medicine. [Source]

Well, that's essentially what I said... A person who performs science using a computer. Now, that's a broad term. Anyone who does science with a computer is a computational scientist? Well, by these definitions, maybe.

By the way that I've experienced Computational Science, which it should be noted is purely academic, it is more specialized than that. Most Computational Science majors that I've met have been really involved in a few things:

  1. Mathematics
  2. Programming
  3. SCIENCE
  4. Simulation (or Modeling)
That's right... 300%. It's possible through computational science

And it is in point number 4 that I see a stark difference between a Biologist, Economist, Physicist (etc) and a Computational Scientist. The former seek to use computers (sometimes) to examine their empirical data and make decisions based upon their actual, real-world data. That means they go out and do some real data collection, experiments in the case of Biology and Physics and research in the case of Economics. Then, they sometimes plug this data into databases, spreadsheets, and commercial software to understand what is actually happening. Now, this is in no way meant to undermine the work that any of these folks do, because what I hope to do wouldn't be possible with out it. These guys are the backbone of Scientific Research because at the end of the day, a computer can only simulate things that you explain and teach to it, it can't come up with anything close to a real-world situation on its own.

Now, a computational scientist, in my experience, tackles problems a different way. We figure out what parameters effect a situation, how it can best be modeled and tracked. What behavior does a specific bird take, how does it react when hungry and within 5 meters of another bird. How does light behave when it enters a room? What does a sudden increase in inflation do to the stock prices as well as consumer spending habits of an individual family? What does a head of household do when suddenly their salary is reduced to a mere 50% of its maximum? Then, a Computational Scientist, who is trained in the field that they are studying, creates a model or a simulation of the situation. They assume away things that don't seem to be important until they reach the heart of the subject matter.
Example of Data from a Simulation that was written for a Mathematical Modeling Competition (oops...crash)
When they get to the center of what is important, they digest it. They think on it. They use it to generate as much data as possible, and then compare that data to actual data. If that data lines up and passes statistical tests, then the Computational Scientist has developed a good, accurate model. If not, they go back to those parameters and remove some, and repeat until the model is accurate. If it doesn't happen, they scratch the model and try a different approach.

This, in my opinion, is the heart of a computational scientist. Wet-lab results with only the cost of a few days programming. No contamination, no lost results. We create a model with enough wiggle room to generate varied sets of data, and use this data to analyze the real world. We setup mini-verses that allows us to view and control every aspect.

With that in mind, who wouldn't want to give it a try?

If you have any thoughts or opinions on Computational Science, and what it really means, comment below! I'd love to hear your ideas!

Choruses for Coding

I'm going to regularly be updating a list of music that I listen to while coding!

Hence,
Choruses for Coding!

These are songs/bands/albums that I think help make me more productive, and at the very least are very enjoyable!


First,
St. Paul and the Broken Bones - Half the City
Grooveshark | iTunes | Official Website

This is one awesome band! To be honest, I learned of them through a random morning talk show on which they were featured. They played two of their "most popular" songs, Broken Bones and Pocket Change and Half the City (the title track). Imagine if Otis Redding had been an accountant until his mid 30's and then realized he had an amazing voice, so he started a band of other amazing 30-somethings. That's St. Paul and the Broken Bones. Each and every track on their one and only album is amazing, yet not distracting in a way that keeps me from being able to focus on my work. I can just play their music on repeat in the background and do work!

Next,
Steep Canyon Rangers and Steve Martin - Red Bird Alert
Grooveshark | iTunes | Official Website

Wow. If you haven't Steep Canyon Rangers, you're missing out. Their "Red Bird Alert" album, which features THE Steve Martin, is quite simply amazing. Don't have any favorites here, and honestly, I learned about this album/collaboration from Steve's Reddit AMA. Someone asked where he had been the last 5 years, and it turns out he was making music. If you haven't heard this album, give it a listen now. If you can't be productive to some good, old fashion blue-grass, maybe you can't be productive at all.

Yep, you heard that right. Steve Martin + Banjo. Wow...

Finally,
The Black Keys- El Camino (A throwback to the Freshman year)
Grooveshark | iTunes | Official Website
Right right, the Black Keys, if you're thinking to yourself "They're old news..." or "Who cares about them anymore?", well you're wrong. They're albums are all amazing, but my favorite is, and will always be, El Camino. The level of productivity that I experience while listening to this album is insane. They just have a way of calming me down, especially during moments of frustration when debugging, etc. So honestly, this is my most recommended album on this whole blog post. This album is simply amazing...


      Yes, I am that unproductive without music 

Friday, April 11, 2014

From the Ground up (GSoC Part 3)

Well, this was it. I knew I was a fish out of water (unfortunately I didn't have a helmet either). There was no way I would be able to start this entire project over from scratch. But I knew this is what I had to do, I had been selected for this project for a reason.

I knew I had to get the most basic features down before I could do anything else. And in my mind, nothing was simpler than a box showing up on the screen. I set forth attempting to get a box to show up on the screen...

And this took me about two days. Two days just to get a box on the screen. This could not end well, but as I continued to work, and continued to add features to this "box," I realized I was actually accomplishing something. I used some of the old prototype code (stuff that I would never have been able to write), and implemented it in the new code base. I repeatedly visited API's, forums, and blogs. These were my life blood for the entirety of the summer.

Each and every day, I found myself accomplishing things that I never imagined I could do. I was working with the backend of Eclipse, and IDE that I used in my introduction to Programming class just one semester before. How could I possibly be working to improve that software? What did I know that I should be implementing new features? But, I kept working. I kept getting closer and closer to a finished project.

When time came for our midterm evaluation, I gave my mentor the best possible marks in all categories. His mentoring style was exactly what I needed. I got one email from him every week, and it asked "How is your progress this week?" I would respond with a detail list of exactly what was happening in the code that week. And every week I would get "Very nice! Keep up the good work!" That was it. That was all I needed. When I got my evaluation email from Google, it said I passed with the highest marks possible. (Which was great, because I knew I was doing as much as I could, so if I had received poor marks, it would have meant I wasn't cut out for this program!)

Sadly, at the midterm evaluation, I lost my partner from Egypt. He was dealing with some major issues in his home country that kept him from being able to work as much as he had anticipated. So I was alone in my endeavors! So, for the remainder of the summer, I kept working and chugging along.

When it came time for "soft pencils down," meaning this was the date that Google suggested we should be done coding and begin documentation and code cleanup. I was more than ready for a good break, and I took advantage of the two week down time to make sure my code was easy to understand and full of comments (remembering the lesson I learned day 1 of the experience). Then came for the "hard pencils down" date, which was the absolute deadline... Code must be turn-in ready at this point. *Gulp*

On the day before submission, my mentor asks me to send him the completed version of the code, which I was happy to do. He attempts to install it on his machine, key word being attempts. It didn't work. This code I spent 8-10 weeks developing didn't work. What was I supposed to do, it was to be turned in in less than 24 hours. I was devastated. I skipped all of my classes that day to fix the problems I was having. I put in an extra ~15 hours in the one day to make sure the code was perfect. (and implement at least 2 new features that my mentor "forgot" to mention).

But, I did it. I developed this whole plug-in from a silly prototype that lacked basic functionality, to a full-fledged Eclipse Open-Source plugin.

Here's a preview of what the plugin looks like.
Here's a really small picture, but you know... it's the thought that counts


Here's the link to my completed work! Eclipse Array Explorer
And here is a link to the announcement from the University in Vienna!

Oh! I almost forgot the most important part! Look at my awesome t-shirt!

Well, this isn't actually MY shirt, but I have one just like it...

If you have any questions/comments about my GSoC experience, let me know!


Thursday, April 10, 2014

Let There Be Legal Pads (Google Summer of Code Experience Part 2)

So, when we last left off, I was just accepted into the program.

First of all, I left off some climactic details of my acceptance. About a week before I was accepted, my future mentor let me know that I was a strong candidate to be accepted (which made me very, very excited). Thus, the waiting game was on. And about a minute before the results were to be posted, the GSoC site crashed (probably due to all of the applicants logging on at once...). LUCKILY! I received an email at precisely 3:00 PST (6:00 my time), which congratulated me on my acceptance into the program.

So there we have it. Freshly accepted into the program and more excited than I can reasonably express.




So, now that I've been accepted into the program...


What now?

That was the question I asked myself for the next two weeks, when finally I got word from my mentor about how to proceed. He said, "Go learn the prototype, figure out how it works."

"Figure out how it works."

What an intriguing idea. This was to be my first experience reading actually reading someone else's code (outside of an academic environment). So I began my tasking, thinking to myself, "This seems like a fairly basic program, just a few frames and tables and graphs... shouldn't be too complicated..." And, I'm here to tell you, I was wrong. The prototype was at least 20 classes, mostly written using Eclipse JDT (which I had never seen before).

I did the only thing that I could see actually helping and I bought 3 yellow legal pads. It was the only way I knew how to handle such a large coding base. I had my three legal pads, and 2 new pens, and I picked a class and began going through line-by-line to see if I could unravel the mystery. This was when I learned my first lesson from GSoC... use comments (please, for the love of all that is good and holy). This code (~2,500 lines) had a total of 20 helpful comments. I spent the next two weeks writing note after note after note until I figured out exactly what each class did, and exactly how each fit into the puzzle that was this protoype.

Finally, I began to understand what these terribly commented classes actually did. I spent weeks pouring over them.

On the first day of the "Coding" period, my mentor told me "Okay, your first task is to create a clean project and start from the ground up."

From the ground up?

Not possible...

Wednesday, April 9, 2014

Am I Google Material? (Google Summer of Code Part 1)

Hello all!

I figured I would dedicate my first official blog post (excluding mandatory hello world post) to an overview of my experience with Google Summer of Code (GSoC).

First of all, you might not know what GSoC is! So let's start there. First, from the Google Summer of Code wikipedia:
The Google Summer of Code (GSoC) is an annual program, first held from May to August 2005,[1] in which Google awards stipends (of US$5,500, as of 2014)[2] to all students who successfully complete a requested free and open-source software coding project during the summer. The program is open to students aged 18 or over – the closely relatedGoogle Code-In is intended for students under the age of 18.
 Now, my way of explaining. So just imagine, there are tons of companies and universities out there who have these grand project ideas (which they want to give out for free), but they can't afford to dedicated paid employees to create them (since they want to give them out for free), so Google had this great idea. They realized that some people in colleges and universities all around the world love to code (and to get paid for it). Thus, this program was created. Organizations need free labor to produce awesome, open-source software. Students need a chance to get hands-on, open-source experience. Google loves to help people. A beautiful relationship was formed.

Now that we're all on the same page, I'll explain a little bit about my involvement with GSoC.

One professor here at Mercer University is a self-described Google "fan-girl." She directed me towards this program last February, and I was intrigued. Get paid $5,500 just to do some programming over the summer (when I didn't have anything planned anyway), yes please! So I began to scour the Google Summer of Code webpage. I searched through the database of possible mentoring organizations (those colleges and universities I mentioned earlier) to find the "one" that would have that perfect project that would make me rich and famous... Turns out, I couldn't find the "one". As a matter of fact, it took my weeks to decide on any organization, let alone a specific project. [Sure, I could have proposed my own project, but I had never done any real coding outside of a classroom, what did I know about the real world.] Finally, I found a project that actually related to a problem I had...

For those of you who have never used the Eclipse Debugger, particularly when working with Arrays, Array Lists, pretty much any collection, consider yourself lucky. The interface is terrible for debugging these types. Honestly, at one point, I had to go through 5 levels of indentation to get to a single value. 5 levels of indentation. Horrifiying.

Thankfully, a PhD student at the University of Technology in Vienna had an idea for a way to improve this much outdated debugging software. He had a prototype for an Eclipse Array Explorer plugin which would allow users to quickly and easily debug all sorts of Java collections. I was amazed by the features of the prototype! (The Eclipse Array Explorer Prototype Paper can be found here) I knew this was the project on which I wanted to work.

I spent the next few days contact this PhD student, asking him how I could set myself apart from other candidates wanting to work with the University. As it turns out, there were a lot more of these candidates than I had expected (~20 students). I was tasked with several small projects before I had even written a proposal for the Array Explorer project. Fortunately for me, I was able to vastly exceed expectations on the project.

Finally, I wrote a proposal for the actual project I on which I hoped to work. As it turns out, I was an over-achiever. The average proposal length is supposed to be around 2 pages, this is not a hard requirement and it is never posted anywhere on ANY of the websites about GSoC. So there I was with an 8 pages proposal with detailed graphs, images, flow charts, and Gantt charts detailing my work almost down to the day. I sent this lengthy proposal to my mentor, and he emailed back within 10 minutes, "Yes, it is good. Now where is the short version"... The short version?? What do you mean?? I wrote 8 pages! How can this not be good enough! So I rushed to weed out, cut out, shorten as much as I could. Finally, I submitted 2.5 pages (I needed that Gantt chart!) After waiting for 3 weeks, I finally heard back that I was accepted to the program...

Tuesday, April 8, 2014

Hello World!

cout << "Hello World!" << endl;
System.out.println("Hello World!");
print *, "Hello World!"
print "Hello World!"

Well, there you have it. The obligatory "Hello World!" program.

I guess I should begin this journey by explaining why I decided to start this blog. As I was searching for some code snippets a few days ago, I stumbled upon many programming blogs. They were all really good at being technical or being really simple. They were all great at covering C++, Java, or Python. They were specific, or too vague to be useful. Then the thought occurred to me, I should write start a blog that tip-toes these lines. I'll write a blog that is technical, but not overwhelming. That is simple, but required readers to think outside of the box. I'll cover interesting features in all of the languages I know (currently C++, C, Java, Python, Old and new Fortran). I'll discuss interesting tools, how to get them up and running on your machine, and how to actually use them. I haven't been able to find this all in one place yet. So, here's my attempt at filling that spot.

As far as the name "Audible Programming" goes, audible means "capable of being heard" or "actually heard" and programming is, well... isn't that why we're here?

-JT