Margaret Thatcher Passes Away at 87

Personally, I don’t know that much about who she is.  But in my memory, as a child, she was the only lady who would keep on appearing in the news.

The one name she would be known as is “鐵娘子” or “Iron-lady” leaves a deep impression in me.  Some may use it in jest or contempt, but to me, it speaks of inner strength, determination and courage in Margaret Thatcher.

Wherever she is now, may she find peace and happiness.
May she be Guided and Protected by the Buddha, Dharma and the Sangha!

Sabbe Satta Sukhita hontu!

The Kind of Student I Was … and the Wonderful Teachers I Had!

Back in secondary school, there was one time we had art class and the first assignment was to make our own art folder.  We were given a large A3 vanguard sheet and the assignment was to cut out a template, fold it into a folder and decorate the exterior with a designs of shapes.

One possible design would be

Not Van Gogh or Picasso, but it’s good enough.

Below is the folder design I submitted.  My teacher rejected my folder initially dismissing it as stripes and not shapes.  I reasoned that my folder design consist of blue rectangles.

I carried the only art folder with stripes for the year … … I mean blue rectangles! :p

Thank you dear teachers, for not forcing your students to conform into model answers. ^.^

Simulations by Scientists Suggests Waste Heat Warms Up Climate

In one microprocessor class back in university, a professor once declared “A cpu is a heater that happens to calculate”.  The cpu in the computer or handphone you are using is a super duper transistor.  Most cpus today consist of billions of transistors and is built around the same fundamental design of logic gates using transistors.

Transistors in an analogue circuit amplify input signals while transistors in a digital circuits make use of the cut-off behaviour of a transistor to act as a switch.  In both cases, heat is unwittingly
produced.

Newer cpus are more “efficient” in that lesser heat is produced, i.e. lesser energy is required to compute while lesser energy is expended as heat.

All the appliances and devices we use, including the screen you are reading this on, dissipates heat.  The heat must go somewhere and it does go somewhere.  The environment.

Air-conditioning

The funny thing is that even the air-conditioners that cools down our rooms also generates heat.  Back in August 2006, I wrote about how air-conditioners do not really produce ‘cold’ or that it is really a displacement of heat [1].  This heat from the air-conditioners and all the other appliances must go some where as well.  It dissipates to the air around, i.e. the atmosphere.

Now consider earth, with its atmosphere as the ‘Room’. The rooms we are cooling are akin to tiny little fridges in this big Room. Owing to heat loss to space, the whole earth cools off at night. But in the day itself, the reverse is true. Heat from sunlight is warming up the surfaces of earth and air, while these little fridges are doing their part to displace heat, and inevitably adding on ambient heat to the environment. Simply put, air-cons do not just ‘cool’ the rooms, it also heats up the environment.

In recent studies by scientists, simulations are pointing to a similar conclusion.

Human-made waste heat warms climate [2]

Energy dissipated as heat in cities can cause regional temperature changes, simulations suggest

The waste heat generated by car engines, power plants, home furnaces and other fossil fuel-burning machinery plays an unappreciated role in influencing regional climates, new computer simulations suggest. By altering atmospheric circulation, human-made heat may raise temperatures by as much as 1 degree Celsius during winter in the northernmost parts of the world.

From the air-conditioning to the pc or mobile, from the television in your living room to the car on the street and the plane in the sky, all appliances, equipments and machineries produce heat, and it is adding up.

Proposing to remove all these modern creature comforts (or to some, necessities) is impractical.  Energy efficient appliances and cars can definitely help to reduce the amount of energy wasted, in most cases as heat.

Earth Day raises awareness by having people around the world turn off the lights for an hour at 8pm once a year.  Perhaps it may be more effective to turn off the air-conditioner as well.  After all, air-conditioners consumes much more energy than than lighting and merely displaces heat while producing heat at the same time!

Are we ready to live without or with lesser air-conditioning?

References

Back From a Retreat

Hi everyone,

Just got back from a retreat and found that the daily verses on facebook also went into a ‘retreat’!

The verses and images are back online.  Read on if you want to know the gritty details.

There were three main failures leading to the ‘retreat’ of the verses.

1. New web hosting environment
2. Change in imgur apis for public albums
3. Automatic suspension of monitoring services

1. New web hosting environment
I switched to a new web hosting company a few days before going for my retreat.

Mistake #1.

Never make major changes before going on a retreat.  (I also uploaded an update of the Android app back then … leading to app settings not saved etc … another story!)

The old web hoster was demanding an increase of hosting fees (200% ~ 300%) and it was due in Oct.  With the new hosting company, the hosting fees are ‘locked’ in perpetually.  What this means is that it will honour those prices and promise not to hike the prices but allow existing customers to renew at their signon rates.

A part of me secretly thinks that it means they will honour it until they go bust.

Another reason for switching, a technical one, is the numerous and frequent unscheduled downtime of the web server.  I am perfectly fine with scheduled maintainence / upgrade server downtime.  But when the server just goes up and down and have poor response time, it means that this company is signing on more sheeps than their barn can hold.

Time to go to another farm.  If I’m going to get fleeced, I want to make sure I get adequate leg-room and good chomp to boot.

Effectively, a hosting company just have to email me before they power down their servers for maintenance, and I’m a happy camper.  I don’t care if it is because they want to upgrade to a new shiny SSD drive or just to watch customers’ sites go down.  If you keep me posted, that’s good enough.

The catch is that, you cannot do that for failures or traffic load.  Not easily anyway.  So decent web hosting companies should do just fine, not the shady run by night ones.

With the new hoster, all is shiny and good.  At some point, they decided to enforce a php safe_mode lock down.  Good practice.  Except it breaks many other legitimate apps.

This led to multiple warnings and errors logged in the server and disabled the tweeter code.

Failure #1.

2. Change in imgur apis for public albums

Imgur is a very useful image hosting service company.   It is mostly free to users to upload and to view the images online, with the option to go pro (read: cough up the silver!).

Like most online services, it has an api (Application Programming Interface) for other mobile, web or desktop apps to talk to it and consume the image hosting service.  So instead of having a human being go to its site, copy and paste the image link etc, you get an app to do it.

Effectly, your app talks to the imgur server app.  But there need a way for them to understand each other.  Apps are pretty dumb, in that you cannot simply get two apps
to talk without first establishing how they should talk.  They need a way to Interface, hence Application Programming Interface.  It’s like trade lingo, except it’s for apps, and in this case, specifically for apps to talk to imgur.

Imgur decides how other apps talk to its server apps.  All went well until I think mid or late August or so.  Imgur decided to speak French.  Ok, maybe not French, but a slight change in the URL format.

The bane of consuming web services.  Until apps that you find in your CDROM (anyone still use that??) and install into your pc, web services / apps can, will and do change.  Sometimes without notice.  Sometimes with notice when you are away on a retreat!!

So, that broke the interface for the image retrieval code.

This error also led to time outs, leading to the next problem.

Failure #2.


3. Automatic suspension of monitoring services

The facebook app that I wrote used to run on a cron service to send out daily verses to users according to their timezone location in the world.  One of the previous web hosting company decided that cron jobs are dangerous and routinely disabled the cron jobs without notice.  (I was running the cron jobs 24 x 2 times a day.  Once per hour and another as backup to complete the job if the earlier one failed somehow).

This was switched to an external monitoring service.  I piggy back onto the site monitoring and get it to monitor my server app and effectively call it 24 x 2 times a day!

So far so good.

When the above two failures persisted over a few hours, the monitoring service would suspend that monitor request.  The good thing about this service is that it keeps you notified through email notifications.

The bad thing is that after receiving thousands of notifications, I set a gmail filter to mark it as read and archive them.

Also, once a request is suspended, it no longer update you further.

Oh, and did I mention that I was on a retreat?

 

So, now everything is back online.

Hmmm … I think there is some Dharma learning to glean from the above … but I’m heading for lunch now.  Why don’t you post your learning below? 🙂

Worldly Tips: Ubuntu App Building Tools: Quickly & Illumination

Want to write apps on Ubuntu?  Check out the link [1] below on two great tools for writing apps on it.

Quickly [2]

There are a ton of great tools out there for Linux software developers. But it has been only recently that the level of difficulty has been greatly reduced.

The idea is to attract newbie and advanced developers into building worthwhile applications for the various distributions out there. Most successful in this space has been Ubuntu, with a new development tool called Quickly. The Quickly software builder provides Ubuntu users with access to a development tool that can easily build out software based on Python and GTK.


Illumination
[3]

Illumination Software Creator is without question easier to use than Quickly for people who have never created software. Unlike veteran software developers, newbies to the developer space haven’t the slightest idea how to lay things out so they work in a usable manner. Therefore using Illumination to “connect the dots” can do wonders to steer newbie developers away from first-time development frustrations.

I tried Quickly yesterday afternoon on my Ubuntu notebook.  Followed the video in the Ubuntu Get Started site [2] and everything went super smoothly, except for one glitch.

I hit the following error when I tried to package the app.

bzr: ERROR: Unable to determine your name.

but thanks to the askubuntu.com [4], I was able to resolve it quickly (pun intended!) with the following command.

bzr whoami "MY NAME <myemail@gmail.com>"

Replace ‘MY NAME’ with your name and ‘myemail@gmail.com’ with your email and you are good to go.

All in, it’s one of the easiest coding experience, and that includes writing GUI for a simple web browser (!)  and packaging everything into a debian package (.deb) that you can share with your friends or upload to Ubuntu Software Centre for the whole world to download!

Now all we need is for PC makers to start shipping with Ubuntu

Happy coding!

 

References