Introducing the 12 Cylon Challenge

A lot of people like to make new years resolutions but this year, Mark Zuckerberg took it one step further and set himself a challenge to build an AI that manages his house. Not one to be shown up by the Zuck, I decided to set my own challenge. You’ll find my whole schpeel in the Facebook post below but the long and short of it is: I’m going to build one robot every month for the entirety of 2016 and the whole thing will be called the 12 Cylon Challenge.

og_post

As I mentioned in the post, I want each robot to be simple enough that I can do it as a hobby project over the course of the month. That said, I don’t want to rebuild the same thing 12 times so each month I will pick a theme, a concept or piece of tech that I want to fiddle with, and base the bot around that. That way each one has a unique flavor. January’s robot will be a simple obstacle avoider and the theme for the month will be building a complete system out of off-the-shelf components (as opposed to a pre-packaged kit).

I want to keep people up to date on my progress; I like YouTube as a medium but sometimes you need to have text. So all my updates will be posted to this blog, but the updates may just be an embedded YouTube video with a little bit of intro text. That about covers all the background information I have for this post. You’ll find the first video of this challenge below where I talk about my first robot, component shopping and what you can expect from this challenge. Enjoy and let me know what you think!

How One Start-Up is Revolutionizing Egypt’s Food Scene

How One Start-Up is Revolutionizing Egypt’s Food Scene

A piece I wrote for Egyptian Streets about the rise of a new Egyptian tech start-up called Engezni, started by two friends of mine from university.

Egyptian Streets

Hungry? Just get out your phone and download Engezni when it goes live in May. Hungry? Just get out your phone and download Engezni when it goes live in May.

By Mostafa Rizk, contributor, EgyptianStreets.com

Sometimes it seems that any news you hear out of Egypt is bad news. Whether it’s about an increasing budget deficit, a new wave of violent clashes or another government screw up, it feels as if everybody is actively trying to make things worse. But that couldn’t be farther from the truth.

For every person out there not doing their job or actively making the country a worse place to live, there are a thousand more who are sick of the politics and stagnation, who just want to see Egypt flourish, and are working tirelessly to make that happen.

The team behind Egypt’s latest tech startup, Engezni, are some of those people.

This February, Engezni won second place at the University Mobile Challenge at the prestigious Mobile World…

View original post 1,689 more words

Modern Space Exploration: What You Should Know and Why You Should Support It

Recently it came to my attention that the US government was planning to decrease funding for NASA. While I was a little taken aback by this news, the decision itself was not what concerned me. The US may very well have good reason to cut its spending (although personally, I cringe whenever any kind of science/research funding is cut in any context) and there are plenty of governments and companies who would continue sending things into space even if the US slowed down. What concerned me was some of the opinions people had on space travel. I noticed that a lot of people view space exploration as a frivolous waste of resources, claiming that “we have enough problems down here” and space is just a distraction. I vehemently disagree. I believe space exploration is not only incredibly exciting but also of massive relevance to average people, whether that exploration is done by NASA or someone else.
Current Space Exploration
Image from Scientific American

SpaceX reusable rocket

To begin with, let’s talk about some of the exciting things that are going on in the space industry. With the deceleration of the space race in the decades following the moon landing, individuals from the private sector stepped in with their own ideas for picking it back up. Most famous of the lot is Richard Branson with Virgin Galactic, which if you hadn’t heard is a service offering touristic trips to space. He’s currently succeeded at garnering millions from ticket sales to thrill-seeking celebrities and his aircrafts have already gone supersonic. Of similar fame is Elon Musk’s SpaceX. Known for PayPal, Tesla Motors, SolarCity and most recently his audacious hyperloop idea, Musk is no less an amazing individual than Branson. He ultimately wants to colonize Mars but wanting to be practical, his main focus now is making rockets that are cheap and reusable. So far he’s succeeded at making a prototype of the reusable rocket and making SpaceX the first private company to resupply the international space station. Then there are the slightly crazier companies like Mars One which aims to launch and broadcast a Mars colonization mission by 2023, and Planetary Resources which wants to mine asteroids for resources. And of course NASA is ever-present in the field. Their primary focus seems to be Mars; after having discovered evidence it once was capable of supporting life and that life on earth may have actually come from Mars on an asteroid, they’re currently making plans to send more robots to study the matter.

Technologies Derived from Space Travel
 

Virgin Galactic

As you can see, the space age is far from dead. But how do any of these things help us? So a few rich people get joy-rides to space, what good does that do the rest of us? Well, their main objectives might be a little frivolous but the success of these ventures would bring benefits far beyond those objectives. Virgin Galactic may be selling tickets to the rich but the technology developed could mean planes that can exit the atmosphere, fly without air resistance slowing them down and re-enter. That means a commercial flight from London to Sydney could take as little as 4 hours, revolutionizing global transportation. The plan to mine asteroids might seem like an attempt by a group of  rich men to get even richer, but in doing so they would be helping solve the issue of resource scarcity. Unusually enough, the founders of Planetary Resources want to bring back platinum-group metals and lower the market price for them on earth. Currently, these metals cost $23,000 a pound and a reduction in their price would mean reduction in the price of medical devices and renewable energy products (among other products) that utilize them. Additionally, since the mining would require robotics technology that doesn’t yet exist, this project’s success would result in the development of that technology and consequently its use on earth in a variety of applications. And in the case of both of these companies, SpaceX’s work to make cheap, reusable rockets would complement their work and pave the way for other space-related business ideas to surface.

But that’s all quite speculative, what has space travel gained us so far? Well, while trying to make space travel possible, a lot of very tough engineering problems are encountered and the scientists and engineers working on them have to come up with creative and innovative solutions (if it costs billions to send another rocket you’d better be sure you’re going to think everything through very thoroughly). Much like the asteroid robots, these solutions can be applied to problems that affect everyone here on earth. This is a list of some of the most notable technologies developed/being developed by NASA as a result of space exploration. Some of these were patented and licensed out, earning them money (if you want to make an economic argument for funding the space program, this would be a good place to start) but money aside, some of the items on this list are hugely important! These include, but are not limited to, artificial limbs, heart pumps, water purifiers and high-performance solar cells. We may have plenty of problems “down here” that we need to focus on but space exploration isn’t as far removed from those problems as most people would tend to think.

Asteroid mining could transform the economy

The Future

Artist’s impression of Gliese 667cc

But all of that is just in the short term. We tend to wave away the long-term goals because they seem so far-fetched but they are goals worth striving for in their own right. A Martian colony may seem a little impractical now but imagine after we’ve got all the technology down and we take that step towards becoming an interplanetary species. A successful Martian colony would serve as an excellent backup for the human race. Granted, the earth is safe at the moment but with the climate changing, natural disasters wreaking havoc on our cities and radioactive material spilling into our oceans, there may come a time when we can’t survive here anymore and we’ll wish we had colonized Mars. But Mars is nearby and boring, what about the more interesting planets that are farther away? All the potentially habitable planets are light-years away from us but imagine if we could get to them in a few months or years? Although they’re still very far away from practical prototypes, physicists have devised plausible physical theories for building warp drives that could take us to the Gliese 667 system, where there are 3 potentially habitable planets, in as little as 2 years. It sounds implausible but NASA is already planning to have interstellar travel by 2100. Then of course there’s the holy grail of space travel: the discovery of alien life. Right now our best bet is the possibility of bacteria beneath the surface of Mars but what if we went to one of the Gliese planets and found intelligent life? Not only would it be the greatest scientific discovery in human history but just the knowledge of another intelligent species would have massive religious and philosophical implications. 

Inspiration of Future Generations
If that last paragraph has enthused you or gotten you daydreaming about a life aboard the enterprise, that leads me into my last point. Space is one of the few things that still has the power to capture all our imaginations. Think of kids hearing about these sorts of plans and how that gives them something to strive for. Speaking from personal experience, sci-fi and dreams of spacey tech is the reason I got into science. Having things like this going on will create the next generation of scientists and goodness knows we need them. Not just for space and research but in every branch of society. And on top of that, to be human is to dream. Elon Musk said it best when he said a life without dreams is meaningless. We have to dream we have to seek out something new otherwise, what’s the point? Nobody says we should invest too much of our effort in this field. At the end of the day, we live on earth, this is our home and there are a lot of problems we need to face. But that doesn’t mean there can’t be room for space travel as well. Even if it’s only 1% or 0.5% of our total activity as a civilization, it easily pays for itself with the technologies it produces, the young minds it inspires and the sense of wonder it instills in us all. And who knows, maybe one day it will change everything.

Zuckerberg’s Poltical Group: What To Know and What To Hope For

If you’ve been following recent tech news, you’ll know that Mark Zuckerberg is starting a new foray into the world of politics. The Facebook founder joined forces with a group of wealthy techies and put up $20 million to fund a new non-profit organization with the intent of lobbying the US congress on issues pertaining to technology. The group’s first order of business is immigration reform, specifically making it easier for skilled engineers from outside the US to obtain permanent visas. Zuckerberg and 100 other tech leaders already wrote to President Obama earlier this month highlighting their concerns. However, the group is also expected to give priority to educational reform. Zuckerberg is no stranger to advocacy, having donated $100 million to a New Jersey school district in 2010 (around the same time The Social Network came out) and recently participating in a campaign to promote the teaching of programming in schools along with Bill Gates, Twitter’s Jack Dorsey and many others.

That’s what is known so far. The group is still in its early stages, they have yet to make any public statements or even pick a name, leaving much to speculation about their future. The entry of a conglomeration of nerds into politics could bring a much needed scientific perspective to an array of critical issues. In that same vein, a gang of billionaires influencing political decisions regarding the regulation of their businesses is an broken record we don’t want to see replayed with the internet. So what exactly do we want to see then?

 

Protection of Internet Freedom

In 2012 SOPA and PIPA (along with other legislation around the world) threatened internet freedom by trying to grant government the power to regulate internet activity by blocking websites alleged to have infringed copyright. Widespread outrage and internet activism stopped them for a while but similar bills have appeared since then like CISPA. CISPA’s focus is cyber security as opposed to intellectual property and according to CNET it would remove legal barriers that prevent ISPs, cellphone companies and websites like Facebook from giving your data to the US government, even if the investigators don’t have a warrant.

Image courtesy of Alain-Christian

Since it pervades every aspect of modern life, it’s understandable that some individuals want the law to have some sort of presence on the internet. However, if laws like this are to be made then people who understand how the internet works and the implications of government regulation should be actively participating in the process. For example, in its recent transparency report, Google released data about government requests for user information revealing that over 2012 the US government alone made 16,000 requests, 88% of which were complied with to some extent. Someone from Google would know better than anyone what kind of information governments ask for and thus how much or how little they should be able to ask for. However, at this stage Google doesn’t seem to be involved with Zuckerberg’s group and it seems that Facebook itself is actually supporting CISPA along with Microsoft and many others, which means either that they have reviewed the bill and it’s not as bad as some claim to be or that these companies in some way benefit from this legislation.

 

Promotion of Scientific Research

No developed nation can stay developed for long if it isn’t actively funding scientific research. Scientific research may not necessarily pay off in the short run but it contributes a lot to GDP in the long run. Cutting funding even by a little bit can be detrimental economically. A report from Research Councils UK estimated that in the UK, cuts of just £1 billion annually could lower GDP by over £10 billion. On top of that, some (if not all) of the most amazing technologies of the modern era were a direct result of government funding of research. The internet was a result of DARPA researching networking and Google’s self driving car technology is built on advances made by several universities in the DARPA grand challenge.

Image Courtesy of smadness on flickr

Stanford’s car Stanley, winner of the DARPA grand challenge

Although I am not particularly a fan of anything to do with the military and I am not personally invested in the US economy (not directly at least), there is an important message here. Groups like Zuckerberg’s have a responsibility to give a voice to the geeks that usually sit out of politics. By pushing for strong government support of scientific research and development, they can ensure that the US continues to create scientific advances that benefit us all and set a precedent for wealthy techies elsewhere to do the same in their countries. After all, there is no such thing as too much knowledge.

 

Being a Voice of Reason

Scientists don’t normally do politics. It’s not their thing. Why bother with all that headache? This unfortunately means there aren’t many people in government to represent science. That means that you end up with people in the US Congress who believe embryology is a “lie from the pit of hell“, the earth is 9000 years old and that there is such a thing as “legitimate rape” and some of them end up being on the House Committee on Science, Space and Technology.

Image courtesy of KOMUNews

Todd Akin- The congressman who made the controversial “legitimate rape” comment

Again, I don’t want to get too much into US politics but this is a problem in a lot more places than just the US. Scientists for whatever reason are not always active in politics and are thus disenfranchised. While this is not the first time a group of scientists (yes, computer scientists count as scientists too) have tried to get involved, Zuckerberg’s group is unique in that it has a massive pool of money to fund itself from and it will be readily listened to by the media. In essence, if Zuckerberg’s group takes this route they can single-handedly give a voice to science in the US and give more legitimacy to science lobbies in other countries.

 

Zuckerberg’s new direction may come as a surprise to many but it was only a natural step for him to take. He changed the world once with some code he wrote in his dorm room but the question is: can he do it again from the seat of power? And will it be to the benefit of the rest of us?

Gapslot: Version 1

Overview

Last week, I was sitting with some friends as we discussed our newly assigned schedules for the semester. Naturally we were trying to figure out when everyone was free so we could hang out. As we scratched our heads trying to coordinate 6 or so schedules (each one more scattered and hideous than the last) I made a passing comment that it probably wouldn’t be too hard to write a program that solved this problem. One of my friends suggested that we instead just write everything down on a piece of paper. Anyone who knows a computer scientist will tell you how much comments like these make us twitch. Why? Because it is our (or at least my) firm belief that any task that can be automated should be automated.

So I took his statement as a challenge and decided to make an app just for fun. I worked on it intermittently over a week and this is what I came up with. It’s coded with python on Google App Engine (side-note, they limited my choice of names so I had to pick one I didn’t really like), using jinja2 for templates and I learned a little bit of javascript/jquery to make the interface. It’s quite lacking in the design area because I am not well versed at making things pretty but it should work well. There are a couple of bugs; I know. If you think these are bad, you should see the ones I spent the week fixing. I would have fixed the rest but this project was taking too long so I decided it’s better to post something that works with one or two bugs than to get sick of it, give up and have nothing to show for all my work. If I get around to making a V2 I’ll fix them but for now I’ll just note what I know about.

Here’s the link to the app if you want to check it out, and below is a walkthrough of the app’s functionality.

Walkthrough

I made the homepage as simple as possible. Apps should try to guide the user where they want to go and minimize confusion.

 

Assuming you’re a first time user you’ll click the right button and be taken to a page where you create a group. Obvious issues: nothing to stop you from messing up your password and nothing to stop a script making tons of groups. Worst case scenario: the app exceeds the datastore write limit and nobody can make new groups for a day. Precautions I DID take: passwords are hashed (with a salt to prevent the use of a rainbow lookup tables) and html is escaped.

 

Now you have a group, and you want to add your schedule.

 

Type in your name and click and drag to fill out the table. I tried to program the click and drag functionality myself using jquery so it gets a little funny sometimes. You can click slots individually if it does and submit when you’re done.

 

Once you submit you’ll be taken to your group schedule page. A slot is red if at least one person is busy. If you want to plan a group activity, go for white but if you find yourself free during one of the red slots, hover over to see who else is free. You can also navigate to this page from the “View Group Schedule” button. If you go back to the main page from this one you can try it but you’ll have to refresh the page or empty all fields except for the group name and password. This is another minor bug but it’s a step up from having the entire app crash whenever one field was wrong.

 

And there you have it! First pet project of the semester. Check it out, play around with it and let me know what you think. More to come soon.