Blogs

By Gregory Gerhardt 25th October 2012

José del R. Millan: Mind controlled Machines
Machines, again! José Millan brought us closer to the brain-controlled ones. How do they work? - People deliver mental commands. The machine decodes it. However, both sides are learning agents. They need to get couple in order to cooperate. In a live demo his colleague remote-controlled a robot in their EPFL offices wearing an electrode hoodie. And tang, it worked!

Jacques Neirynck: The Swiss confederate model applied to Europe
We have to stop asking what Europe can do for Switzerland, but ask what we can do for Europe. The most valuable contribution would be the Swiss federal model: A sound amount of basic democracy (a popular vote can be right or wrong, but people identify themselves with the decision), local autonomy and a federal council, not a government. Furthermore we should become what California is to the United States - THE breeding ground for European invention and innovation. Switzerland is at the top of immigration countries. Every second baby born in Switzerland holds two passports. We are a multi-nation already.

Eleanor Tabi Haller-Jorden: Gender Biases
Women earn less for the same degree. One 10 men in a board of directors come 1.5 women only. What's the reason? Very often perceptions and stereotypes. We hear "leader", we think men. We hear "diversity", we think women. Eleanor tackles these stereotypes that are propagated day by day and hamper the career opportunities of women. What is a very practical intervention? Leverage the differences, ignore the gender.

Enrique Steiger: Swisscross, protecting health care in war times
Enrique Steiger is a plastic surgeon by day, by mission he operates in war zones. Staff casualties in areas of conflict have doubled over the last 2.5 years. The point he makes is simple: War surgeons have to be protected by force of weapon. The project that could enable the lightly weaponed shield for hospitals and medical supplies is Swisscross. A strong cause that still needs a mandate. 

Jan Henrik Hansen: Musical Sculptures
This is mind-boggling. Jan Henrik and his colleague materialize music or "audiolize" architectural structures. Live jam with digital visualization included. Refreshing!
 
Wow, that was another great day, thanks to the TEDx team and sponsors!
 
By Gregory Gerhardt 25th October 2012 Events

Charles Eugster: Combatting Ageing Problems
This man is 93 years old and he is amazing. He held a firework of a speech and earned a hurricane of an applause. Eugster, a dentist by background, rowed and bodybuilded internationally at ages of 80 years and more. The English gentleman's mission is to prevent the world from obesity and a phlegmatic old age. Obesity has doubled since 1980. 12% of the world's population is obese. In other words a world pandemic. By 2030 a forecasted 50% of the US population will be obese. Regarding the continuous ageing of human population there will soon be more people over sixty than children under 15. 92.2% of the 65+ have one or more chronic diseases. Three factors contribute to successful ageing: Work, Diet and Exercise. "Retirement is voluntary or unvoluntary unemployment for up to 30 years!". Inactivity kills. If somebody can kill the Grim Reaper it's Charles Eugster.   

Stelian Coros: Researching Human Locomotion
More than 200 muscles are activated and in complex interplay when humans walk. Stelian researches into the theory of locomotion. Applications range from Disney's animated movies to supportive devices for disabled people. 
 
 
Jorge Vinuales: A tax on bottled water
150 times the price that water companies pay for the water at the spring the client pays when buying bottled water in the store. Water is scarce: Only 2.5% of water is freshwater. Water is still an unfulfilled need: About a billion of the world's population have no access to running water. The environmental impact of the water industry is significant. Citing an honest statement from a senior corporate officer "When we're done, tap water will be relegated to showers and washing dishes". Not for Jorge. The idea he suggests: Add a tax of 3% tax on every bottle which would make a 1.5 billion for building infrastructure in the developing world. I'm interested to see if TEDx Zurich is going to provide tap or bottled water next year.
 
 
Thomas and Christian took us on an extreme journey through their double success at the Red Bull Xalps. They explained how they shared their responsibilities and how they prepared to go to the limit of their paraglider, body and mind. Sounds like fun? Stay tuned. They are one of the teams selected for the 2013 edition of the Red Bull Xalps.
 
 
Jurczok 1001: Music Act
More cool music. This time a looped remix. 
 
 
By Gregory Gerhardt 25th October 2012 Events

Davide Scaramuzza: Flying robots
From swimming robots to flying robots! Davide was the man for us boys in the audience. Unlike our toystore helicopters, Davide's robots can fly without motion capture system or remote control. In order to navigate autonomously they need to know where they are, however, GPS is not used since it's not a reliable system. While it flies the helicopter constructs its own map of the environment. Several helicopters can fuse their maps. Besides all play, what's the real interest in autonomous flying robots? -They can be taken to environments where human beings cannot fly or flights would not be economic, e.g. search for survivors after an earth quake or do environmental monitoring using helicopter swarms. The great presentation was crowned by a live show (behind safety net).

Ellen't Hoen: Medicine Patent Pool
After Roger de Weck's address, Ellen't Hoen took the stake with a pledge to establish medicine patent pools to tackle epidemics in developing countries. Unprecedented in pharma it was applied while battling HIV/Aids. The model has proven to work for all sides - the innovators and the people in need. By establishing publicly funded patent pools, the patent holders can hand their patents over - against compensation. The patent pool hands the production rights to generic manufacturers. From conflict to collaboration.
 
 
Domi Chansorn: Music Act
Spheric flows and a smoky voice. Our Victor would have loved this one!
 
 
Hugo, the talented technical director gave us a brief overview of the waves the last TDXs have caused. TEDx inspires action.
 
 
Christoph von Toggenburg: Humanity in Action
Christoph's mantra is: Feel - Like - Act. Having grown up in a picture perfect Swiss village he was inspired by his parents to see the world with the eyes of the others (feel). In 1988 he launched his first project "Run for Help" (270 km across the alps) to fund a children's home in Romania (ending up with money that fed 300 children for one year). Then he launched "Bike for Help" and rode his bike "Chaschper" from India to Switzerland to fight leprosy. In 2010 he cycled across the Himalayas. At that time he was cycling for mentally destitute women. Leaving the comfort zone has no doubt inspired this man's life. And helped thousand of people all over the world. Be the change you wish to see in the world.
 
 
By Gregory Gerhardt 25th October 2012 Events

TEDx Zurich, the intellectual antidote to the daily grind is back in town! Here is what we got to see in an amazing first two hours.

Mikael Colville-Andersen: Bicycle Culture by design
Liveable cities! That is Mikael's mission and job. Referred to as Denmark’s Bicycle Ambassador he's firm on getting our cities back in the hand of pedestrians and cyclists. His solution? Design instead of engineer! Develop cities according to human needs, not mathematical models. Observe human activity right in place - then start paving the natural paths. He left us with a quote that I only caught half but might best visualize Mikael's guiding spirit: "Cities are erectoned on spiritual columns. Like giant mirrors, they reflect the hearts of their citizens...". Who wants to be reflected by a car city? If you want to find out how bicycle (un-)friendly Zurich is, check their Copenhagenize index.
 
 
James B. Glattfelder: Complex Financial Systems
Complex systems are hard to map, however, they are only the result of few simple rules of interaction. Every complex system is understood as a network of nodes. For example ownership networks. Physicist Glattfelder's scientific interest: Who are the key players in the world economy? Who controls the world? In his studies 13 million ownership relations were analyzed. The finding: In the center there's a core of highly connected companies with 36 of the transnational companies owning 95% of the world's revenues. These 36 TNCs again are held by 737 top players that control 80% of their equity. Mostly institutional investors in the US and the UK. No doubt, an economic eye opener.
 
 
Stephen Malinowski: Video Animation & Music Performance
I saw music!
 
 
Istvan Görgényi: Hunting Territories
We are territorial animals. We don't like our neighbors to interfere because it might conflict with our interests. However, since we live in a highly complex, interconnected world we don't have the luxury to isolate ourselves anymore. We have to cooperate and share problems and solutions. Deepwater Horizon platform was the example he used to visualize the territory theory including the four core companies BP, Mineral Management service, Halliburton and Transocean. According to Istvan, Transocean and BP's territorial overlap basically triggered the blast. The conclusion. The top management of BP didn't realize that they had a responsibility on the territorial overlap. Top management doesn't like to hear bad news and if there's no feedback system (including overlapping areas) management is blinded.
 
 
Bradley Nelson: Micro and Nano Robots
How do bacteria move? They swim. If you remember the movie Fantastic Voyage or would like to get a robot swimming in your blood stream, then mechanical engineer Bradley Nelson is your man. Bacteria swim by rotating their flagellar filaments (discovered in 1973). Based on this finding, Bradley is working on propelling his little things with an artificial bacterial flagella (10 microns only!). A use case could be to deliver drugs into specific areas of the body. The scientist describes, the engineer builds what never was!
 
 
By Vasi Chindris 24th October 2012 Drupal

If you are a developer it is almost certain that you had to refactor code at some point. Refactoring is no joy, especially if it is not your code and badly written.

In the bigger picture refactoring is ever-present. Just take a look at the Drupal ecosystem. You could refactor content types, display suite fields or views.
 
In this blog post I will give you an insight in how we deal with code refactoring at Amazee Labs.
 

The three code states

I like to think that the code we write can have three states:

  • stable code: code that is subject to almost no changes, and at the same time permits to easily add new functionality.
  • code to be refactored: this is the code that we are working on, or it is marked with @todo and a comment regarding why and what should be refactored.
  • bad code: code that should be refactored, but nobody is aware of it - at least not yet... You will only notice when the client reports a bug or a feature request that cannot be implemented without changes in that portion of code.

Managing @todos

One of the though lessons learned is that when you set a @todo, unless you reserve exclusive time for code refactoring, you will not refactor that code until it is subject of a bug. Since, our first rule regarding code refactoring is actually to try to avoid it, or to make it really early in the development stage, and not let too many @todos go into production. But in the real world, this rarely happens, there always will be @todo in the code.
 
The next thing is how you report a @todo. A bad example is:
 
// @todo: This code has to be refactored.
 
This does not give a clue what the code does now or why the code should be changed. You should always point out the reason why the code needs to be refactored.
 
 

Refactoring

Then, when the time comes to actually refactor the code, the question is: How do you refactor? It depends on the code that has to be refactored, but most of the time it involves moving code into a separate function, changing the structure of a classes tree or moving the implementation from a function oriented to an object oriented approach.

Finally, you have to check if your refactored code really works. Because you refactored the code, this does not mean that you fixed the bugs. You could even have introduced new ones. So to ensure this didn't happen, the best thing is  to have automated tests that you run on your code, which is not always a trivial task to do.
 

The five conclusions

  1. If possible, try to avoid having many @todos in your code, especially in the one that goes to production.
  2. Always write good documentation for what you have to refactor. It would be good to specify why the code has to be refactored, the priority and optionally why you've chosen not to refactor yet. 
  3. Refactor the code as soon as possible. Ideally is in the development stage.
  4. Always test the new code. If you refactor it, it does not mean that that code is correct.
  5. Avoid writing code you know that you will have refactore it in the future.

If you are looking for a more general blog post on code refactoring you should take a look at SourceMaking's "Introduction to Refactoring".

This web week started with an epic event: The Red Bull Stratos jump. We hope you enjoy the selection!

Food for thought

Econsultancy: Five content marketing lessons from the Red Bull Stratos jump
This blog post looks the jump though the glasses of a marketer. If you are looking for lighter content regarding Red Bull Stratos, you might like t3n's blog post.

Technology

Wired: Google Throws Open Doors to Its Top-Secret Data Center

Ever wondered how a Google data center looks like? Now you can find out for yourself. You can even explore it on you own with Google Street View.

Naked Security: India spews more spam than ever before, report finds
Sophos' Naked Security blog published some findings regarding the source of spam in the last three months. More surprising than the main culprit is that three of Switzerland's five neighbor countries made the top 12.

Drupal

Erdfisch: Email and link module landed in core
Great news for all Drupal site builders: It appears that the Link and the Email module will be part of Drupal 8.

Tweets that cut through the noise.

We love to see framed copies of our periodic table of Drupal modules. :)

By Michael Schmid 18th October 2012 Drupal

A few hours ago, the Drupal Security Team informed about a highly critical Drupal 7 core issue: http://drupal.org/node/1815912

The vulnerability allows an attacker to reinstall an existing Drupal site with an external database server and then execute custom PHP code on the web server.

As usual, to mitigate a highly critical vulnerability, a new Drupal 7 version (7.16) was released which fixes this issue. Since it is not always possible to update or patch every customer website immediately there is an accepted workaround for this: Deny access to install.php.

Add this to .htaccess the file:

# Deny access to install.php because of SA-CORE-2012-003 http://drupal.org/node/1815912
<Files install.php>
  Order allow,deny
  ErrorDocument 403 "Sorry, no access to install.php. If you need access you will have to change .htaccess"
</Files>

This will prevent everybody from accessing install.php and rule out that an attacker can use it for an attack.

But overall it is best to update Drupal as fast as possible and also deny write access for settings.php as described in the Drupal security best practices.

You can deny the access to install.php by using this patch and applying it with: "patch < SA-CORE-2012-003_deny_access_install_php.patch"

By Sascha Eggenberger 17th October 2012

For a web designer the most obvious place for inspiration is the web, especially with so many amazing resources like The Best Designs, Mediaqueries or CSS Mania. But how organize all the inspirational nuggets? Not long ago I collected them as bookmarks in my browser but my library grew out of hand.

Say hello to LittleSnapper

Then I came across the LittleSnapper app, a screenshot collecting tool for Mac OS X, which changed the way I collect and organize my inspirations.
 
With LittleSnapper you can easily snap entire websites, webpage elements, your entire desktop or just add jpg or png files to your collection. You can also tag your snapshots, add notes, create folders and add them to collections. But the real benefit is that you actually have a visual preview of all your inspirational designs.
 
 

LittleSnapper + Dropbox = Inspiration in the cloud

 
The only thing that I really miss is a syncing feature. But I found a workaround for this: Dropbox.
 
In the advanced settings of LittleSnapper (Preferences -> Advanced) you can change the path to your LittleSnapper Library. Set the path to a folder on your Dropbox. Do this for every Mac you would love to have your Library on. It's that easy and has proven to be an excellent solution.
 

Here comes the traditional collection of stories that caught our weekly attention. Enjoy!

Drupal

Drupal Association: Election Results
This week the results for the community election to choose two at-large Directors for the board of the Drupal Association were announced. Congratulations to Morten Birch Heide-Jørgensen and Pedro Cambra!

Social Media

Beevolve: An Exhaustive Study of Twitter Users Across the World
Beevolve, a provider of a Social Media Monitoring platform shares some statistics of its mined data.

AllThingsD: Very Pinteresting! Facebook Cranks Up Another (Potential) Revenue Stream With “Collections.”
Remember the times when every Facebook update included many Twitteresque features? Now the world largest social network turns its attention to Pinterest.

Food for thought

Wired: Fend Off Trolls, Bots and Jerks With ‘Empathy’ Test
CAPTCHAs can be annoying. Why not use that opportunity to stand up for human rights.

Tweets that cut through the noise

By Boris Baldinger 10th October 2012 Drupal

After a few weeks of using Sublime Text 2 (ST2) it is time to draw a conclusion. Did Sublime Text 2 manage to be a good replacement for a fully integrated development environment like NetBeans or PhpStorm?

Yes, ST2 is good, but skip the hype.

I joined the flock when ST2 was released and was really into it. Now, after the party, ST2 has just become another working tool. A very comprehensive text editor. That's all. And still, at certain points I miss the quick access to features I get in an integrated development environment. My modest advice: Only switch if you are not happy with your current setup, or have enough time to play around and google your plugins. ST2 is a very modular and highly configurable tool and this makes it fun, - no doubt.

Do I sound a bit hung over? If you are looking for more comprehensive arguments to switch to Sublime Text then you should look at Stuart Herbert's blog posts. He gives 10 reasons why you should switch to ST2 and made a YouTube series on how to setup your ST2 for PHP development. I included the playlist below.

Any final tips for Sublime Text 2?

I recently ran into an issue, where my Git configuration was overwritten by a plugin update. If you are having the same issue, just copy the Git.sublime-settings from the Git package folder to the User folder.

And if you wonder how to check for plugin-updates manually. Just hit CMD+SHIFT+P and type upgrade.

Pages

Subscribe to Amazee Labs Blog

Latest comments

  • Adam Hummell's picture

    Hop on one foot for 1 minute or Gimmie 20. Starting now....GO

    Adam Hummell
  • infojunkie's picture

    Thanks for using Views Auto-Refresh and glad it's working out for you! The new version at http://drupal.org/project/views_autorefresh now uses an area handler to allow site builders to set it up. It should be functionally equivalent to the Views Hacks version, in addition to the bug fixes that went into it since it moved.

    infojunkie
  • daniel truninger's picture

    @Gurpreet

    Not sure I understand your question fully.

    If you try run this on your local without a web server you might get a bunch of errors or no unicorn at all. Vectron uses Ajax requests to get the SVG file, for this you need to have a local web server or run it on a real environment. More about this issue can be found here.

    If your question is of a different nature why not ask it over on Stack Overflow, where you can ask your question to a broader audience. I'm sure somebody there will have had the same challenge as you.

    Daniel Truninger