Archive for the ‘sci-tech’ Category.

Human Brain vs. Computers

When I was young, maybe in my early teens, I used to think that what gave the human brain its advantage (over synthetic computation machines) was its speed. I used to think that the brain processed information with a throughput and latency that was far superior to machines and that was why computers couldn’t duplicate the more complex tasks that every human does every second. But of course this was completely false. In terms of sheer speed of processing and signal transmission, human nervous system and brain fall much short of any computer.

Later on, I arrived at the concept that it was the inherent parallelism and emergent mechanisms that are going on in our brain that give it its superiority. The billions of neurons on our brains all are working in parallel (well, not all obviously, but each subsystem seems to be massively parallel) and many of them are actively selecting and routing and inhibiting and amplifying the signals that come their way so new, probably non-deterministic and previously untried, methods are emerging and falling all the time. As an interesting side note, it seems to me that our brain is quite good at data parallelism, and really bad at task parallelism! A corollary of this concept could be the idea that human brain is also very small for the computational power it has (I don’t think it is.) Anyways, while this parallelism might very well be a great feature of human brain, it’s probably not the most important or amazing. After all, the whole Internet is a parallel machine (for some loose definition of the phrase) that probably has more computational power than the whole human population combined by several orders of magnitude (haven’t done the math; don’t bug me about it!)

In the first years of college, I was introduced (a tiny bit more properly) to the fact that human brain reconfigures itself on the fly. Through a process and under rules that might very well be quite simple and even trivial to understand, it reinforces some paths and connects and creates others. This still counts (for me) as an important feature.

Very recently, I’ve started to realize the most amazing feature of the human brain is its energy consumption! There’s all this stuff going on in there, with all these capabilities, and it consumes, what, 100 watts? 200? (again, haven’t done any research or calculations – please illuminate me if you know.) That’s not even enough to power a half decent GPU these days. Am I too wrong?

VN:F [1.9.13_1145]
Rating: 8.4/10 (7 votes cast)
VN:F [1.9.13_1145]
Rating: +4 (from 8 votes)

No More Souls To Sell

As you may know, I have sold my soul to the Prince of Darkness and got a Kindle. Now I want a Samsung Galaxy Tab, but I have no soul(s) left to bargain. Any suggestions?

VN:F [1.9.13_1145]
Rating: 5.7/10 (3 votes cast)
VN:F [1.9.13_1145]
Rating: +3 (from 7 votes)

Akindled

Well, it’s obvious, is it not? I got a Kindle (latest generation, i.e. three, 6″, graphite and no 3G) and the huge thanks for it goes to my brother Ehsan, because I absolutely love it!
Oh, and I named it “Rand.” What else was I going to name it, “Kevin”?! The reason for this name should be obvious to anyone who has read the first few books of the Wheel of Time. Also, I thought after a few female names for my gadgets and toys (Fenchurch for my iPod, Metis for my phone, Eros for my PSP, Jane for one of my portable disks) it was time for a male character to be in this dramatis personae.

Now to the Kindle itself. It’s clean, cool and chic. It’s very light and thin too. There are some things to be desired, like a more controllable music playback or generic notes, but in my opinion they just distract from this device’s one true raison d’etre: to read books on. And it does that splendidly! The built-in browser is surprisingly capable. It is based on Webkit, but the size and nature of the device and the keyboard make it less usable than one might hope. Did I mention that the display of text is practically like real print?!

By the way, it should be obvious that I’m writing these on Rand.

VN:F [1.9.13_1145]
Rating: 8.2/10 (5 votes cast)
VN:F [1.9.13_1145]
Rating: +1 (from 3 votes)

Sorrrrrrrrrrry State of Video?

I don’t know if I’ve written about the sorry status of digital video (in web sites and other places) before or not (I think I have, but it’s almost 11AM and I haven’t slept yet, so forgive me if I’m misremembering!)
Anyways, the state of things up to a few months back was that we had quite good standards for WORM media distribution (Blurays and whatnot) but who actually uses those anymore?! If you wanted to rip video and archive them, you had a few choices.
You could go with MPEG4 (Xvid) and MP3 or AC3 inside AVI, to get the best compatibility (noob-owned PCs, standalone video players, etc.) but Xvid is not the most advanced technology these days and AVI is plain obsolete; not to mention the fact that support for AVI and said codecs is very limited on handheld and portable devices.
You could pick stupid and unwieldy containers like MP4, which might or might not be playable on this or that device. You could throw all your data down a bottomless well of Microsoft’s (or another corporation’s) fancy sounding but virtually unusable formats (codecs and containers) which I won’t even mention here.
You could go with cool and quite free containers like MKV (or OGG) which are (currently) only playable on PCs (with non-noob owners!) This fact is really sad, because and MKV file with x264 and AC3 is a mighty force to be reckoned with, for storing all kinds of video, from small to UD (Ultra Definition, whenever that in invented and becomes trendy!)

On the web, the situation is quite simpler and more equal. Everybody were being fucked by Adobe Flash (and still are.) With occasional fingers thrust in by Windows Media and Apple Quicktime. All these have their own codecs (or variations of codecs) and all are proprietary. (If I had gods, I would thank them for making RealMedia defunct!)

But HTML5 has its own audio and video support, and HTML5 is being picked up by virtually every browser maker (yes, even Microsoft, but I can’t imagine why anybody still uses their piece of shit, except to download Firefox or Opera or Chrome or SeaMonkey or Safari. The really cool guys don’t even do that and FTP down the usable browsers directly!) The problem with HTML5 standard is that it doesn’t (didn’t?) mandate the container format and codecs (video or audio) that should be used! Obviously, this is not good for anybody. Of course, the situation could have been worse if the standard had specified a patent-laden or proprietary format, but still this under-specification means Morphy’s Law applies and web-developers and web site administrators get fucked even more than usual. Not to mention lusers.

A viable option for free audio and video was (and always is) of course Vorbis and Theora, and I quite like them, but people might argue that they (specially Theora) are not state-of-the-art codecs (not out-dated though, just not quite on the bleeding edge.)

Anyways, a few months back Google bought a company named On2 which held (presumably and hopefully) all the patents for a video codec (format) named VP8. At the time many people (including me) speculated and hoped that Google would put the patents in public domain (or whatever the term is that means make the use of the technology available to everyone, everywhere without charge and limitations for all time.) A couple of months back Google did the exact same thing and the WebM project was born. It’s defines a container format that hosts VP8 video and Vorbis audio, with no applicable patents in private control and liberal opensource-compatible licenses on all the software and libraries. Already most relevant browser makers have declared support for WebM (Mozilla, Opera, Google (obviously) and I think even Microsoft (but these days they just have to do anything the leaders of industry do, because they are not part of them anymore!)) and there are 3rd-party implementations of it. In short, I think the state of video on the web is starting to look good.

(This post has no links and it needs 100. I apologize for the inconvenience of having to copy+paste.)

VN:F [1.9.13_1145]
Rating: 7.8/10 (4 votes cast)
VN:F [1.9.13_1145]
Rating: +1 (from 3 votes)

An ABSOLUTELY Unmissable Talk on Modern Hardware

Iff[sic] you are a programmer, if you don’t do anything else even if you don’t eat and even if you don’t shower, please please please please please watch this presentation.

The presenter is Dr. Cliff Click, and the topic is an in-depth view of modern code execution architecture. The talk is from 2009, and it has been on my to{do} list for almost 6 months. It is the best thing I have seen in the last year (and I played God of War III!) if not in many years. The guy is obviously very knowledgeable and he talks extremely fast, which just means that he packs an incredible amount of invaluable information into this 50+ minute talk.

I can’t stress this enough. Take an hour to watch this. Please! If you are a game developer, or any programmer with a conscience, you have to watch it right now! I’m not kidding here. Watch this through.

On an ego-boosting note, I just watched this talk and I already knew almost all of it (I have to brush up on the newer cache-coherency protocols though; those have also been on my to{do} list for some time now!) It did have some eye-opening “Aha!” moments for me. I may write about them later.

What are you doing still reading my shithead rant?! GO WATCH THIS!Cliff Click’s Crash Course in Modern Hardware (hosted locally.)

VN:F [1.9.13_1145]
Rating: 10.0/10 (5 votes cast)
VN:F [1.9.13_1145]
Rating: +4 (from 4 votes)

“Planning for Debugging Day” Presentation

Here are my presentation slides from the talk I gave this past March in Sharif University, at the first Iranian computer game developer’s mini-conference.

Here I talk (mostly out of personal experience) about things that we should pay attention to, at the beginning of a game development project, so our debugging and issue tracking and solving experience becomes less irritating and more effective. I’d be happy to hear any suggestions, corrections and discussions.

Oh, and I have expanded the talk a bit, from what I actually presented! Also I’d be happy to explain my views on any of the particular points if anyone actually bothers to read through the thing.

VN:F [1.9.13_1145]
Rating: 8.2/10 (5 votes cast)
VN:F [1.9.13_1145]
Rating: +4 (from 6 votes)

There Is No AI, Stupid!

My outspoken (and certainly prejudiced and groundless) stance on AI is very well known where I am known myself. I hate the current trends and implementations of what is called Artificial Intelligence.
And what’s with the “artificial” prefix anyway? What is “real intelligence”? Why we call human (organic? carbon-based?) intelligence “real” and silicon-based (germanium-based?!) intelligence “artificial”? Because we where here first? Because we are currently more complex and have the upper hand? Wait for the “Singularity” (definitely STFW) and see who gets the last laugh, folks! I guarantee that it will be soon and it won’t be us (almost by definition!)
It can’t be because our intelligence is emergent and evolution-based and computer intelligence is designed and creation-based, because it is not! As far as I know (which is admittedly not far) most successful and state-of-the-art “intelligent” software are evolution-based these days. (They are based on that singly most unique and most elegant idea Darwin had one summer evening (or one winter morning, or whatever) which so beautifully explains a significant portion of the mess that we call “life”.)
And to attack the issue from another angle, “What is real? How do you define real?” What makes you think that we are any more real than the data structures and code run everyday on our own computers?
And don’t even get me started on the “gods-created-us-therefore-we-are-super-special” bullshit.

In any case, my point is that whatever this intelligence is, it’s no more artificial than our own, and we are probably no more real than it.
Maybe we should call it Third Intelligence? Obviously, calling machine intelligence Second Intelligence would be wrong, because they are third after mice and dolphins. We are fourth at best! “So long and thanks for all the fish” anyone?

Let me quote a great quote from a (supposedly) great person:

The question of whether computers can think is no more relevant than the question of whether submarines can swim.

Obviously, there must be a reason that I’m writing philosophically about AI at 6:28 in the morning. I have just started reading “The Metamorphosis of Prime Intellect” (a seemingly great sci-fi book, available freely online) which apparently deals with the Singularity and the post-Singularity world. I’m in the middle of chapter two (out of eight) and I must say that the opening chapter was refreshingly original for me and sweetly violent. I recommend it even if the remaining 6.5 chapters are total crap.

VN:F [1.9.13_1145]
Rating: 10.0/10 (2 votes cast)
VN:F [1.9.13_1145]
Rating: 0 (from 0 votes)

Chipmate!

There’s hardly anything sexier than a multicore CPU that I actually know how to program! Better yet, make that a “manycore” CPU.
Dual-core CPUs were cool, and quad-cores even cooler. But they were hardly enough to enable writing real fine-grained parallel programs. Recently Intel released “Core i7″ architecture CPUs, with four cores minimum and they all support HyperThreading, which is at best a hack and not a particularly beautiful one, but it gets the count of available hardware threads to 8, which I’m willing to settle for! (Note that semi-8-core CPUs have been available for some time, but not on desktops, and not in practical price ranges.)
When I think of all the execution units, the 64-bit wide registers, the cache hierarchy… Oooh!

VN:F [1.9.13_1145]
Rating: 8.0/10 (6 votes cast)
VN:F [1.9.13_1145]
Rating: 0 (from 0 votes)

Better Soshiant Videos

Here are two higher-resolution in-game videos from Soshiant: one (~90MiB) and two (~86MiB).
Here’s another video (~71MiB) showing some characters from concept, through modeling, to animations.

Note that our engine is not even in alpha. There are many bugs present, most of with are level design bugs due to our rush for the exhibition (camera placements and transitions, characters occasionally going through walls, Soshiant’s hand not being aligned with the ledges he is hanging from, etc.) But there are some engine bugs too, like the character’s hair getting stuck in a wall or ground, or the character jumping from one position to another, or the shadows poping here and there. All you see is subject to improvement, change or both.
Also, these videos are compressed with the irreplaceable Xvid codec. The third video, which is the only one with sound, features one of our original sound-tracks, composed and played by our multi-talented concept artist Soheil Danesh.
I would be very happy to hear your feed back on any and every aspect of these videos.

VN:F [1.9.13_1145]
Rating: 8.5/10 (6 votes cast)
VN:F [1.9.13_1145]
Rating: 0 (from 0 votes)

Managing Your Life Online – Part 1

(Should I have titled these series “Managing Your Online Life”? But there’s almost no distinction between my online life and my life, so I don’t feel the need.)

Some general notes first. When it comes to online life (or even life in general,) the most important thing you have is data, period. So you have to think about data accessibility, portability and protection.
Let me give you an example. If you use Yahoo! mail as your primary email, you are not OK. Your email is held hostage on Yahoo! servers. You have no way of reaching it. Even if you pay for premium services, you only get lousy POP3 service and the ability to download all your email as an archive. The keyword here is “all”. You can’t chop it up and the download is not restartable or resumable. Imagine downloading a 3GiB file in those situations! If you forward your email to another account, you won’t get a local copy anymore and you can’t forward the mail already in your inbox. It doesn’t support IMAP so you can’t remotely manage and move your email around in your mailbox. Both the web-based interfaces are so brain-dead that any form of bulk operation is tremendously hard or virtually impossible. So you tell me whether my almost 90000 email messages in my Yahoo! mailbox are accessible or not? Can I get a backup copy of my email so that if someone malevolently accessed my account and deleted all my email, I won’t be left high and dry? Can I be sure that Yahoo! will not start enforcing its own brand of sanctions against Iran and blocking my access to my email from tonight? Can I be sure that my email is not read by Yahoo itself, or not forwarded to Michael Chertoff’s or Jack Valenti’s desks as a result of something similar to the Patriot Act?
So, accessibility, portability and security are important!

Don’t trust anyone! Don’t trust corporations. Don’t trust governments. However, keep in mind that both keeping security and breaking security cost money and time (usually.) Weigh the trade offs and then make decisions. If your data is not worth anything to you, then it may not be cost-effective for you to protect it. If it’s not worth anything to anybody, then it may not be cost-effective for an adversary to try and gain access to you data.

Also remember that I live in Iran. My whole life I’ve been struggling with unreliable and lacking technological infrastructure, services and options. The situation is unlikely to improve in near or even far future. Therefore, I cannot download 3GiB from a webserver in a single connection. My connection will get interrupted. I cannot be sure that I’ll have Internet connectivity in my home for 12 hours straight without disruption because I have no grounds to sue my ISP when I get disconnected for 1 to 5 minutes every 2 to 3 hours (or 5 hours of no connectivity every once in a while.) Actually, I can’t even trust my cellphone, hard-line phone or even electricity to be available all the time (they almost always are, but I can’t expect them to, and no one will be accountable if they are not, and there are few or no alternatives to switch to in that case, and the providers know that.)

Unfortunately, I have to use Windows for all my current work and therefor I use it most of the time (who am I kidding? I use Windows almost exclusively.) But I hate Windows. Although I have to admit it was getting better and better with Windows XP and Windows 2000. It sucked a lot less than it used to. But then Microsoft went and just did it; yo and behold a beast straight from the Dungeon Dimensions: (Do I really have to name it? I’m afraid that there might be a “Taboo” on it so they can track me if I use the name!) It starts with a ‘V’ and ends with an ‘ista’! I’m not hopeless though. It’s not the OS you use, it’s how you use it and what you use it for! I count myself a proponent of free software and opensource software, and crossplatformity is a real concern for me.

One more piece of advice. Sam (no last name) never walks into a place he doesn’t know how to walk out of. You should never ever put your data somewhere you don’t know how to take it out of. This point is more important that anything else to remember and utilize. Avoid vendor lock-ins like the black plague and tomato juice mixed together! If your email or hosting provider can’t secure your data, or your day-to-day access is hard, but you can export your data in a usable manner, then you have no problems. You can pack up and move anytime you want. So, always devise an escape route before you put your data in. (Hey, that’s good “Hitman” and “Commandos” advice too!)

The above factors affect the choices I make and opinions I have.

*Expect the next parts at a time indeterminately far away.*

VN:F [1.9.13_1145]
Rating: 8.2/10 (5 votes cast)
VN:F [1.9.13_1145]
Rating: 0 (from 0 votes)

Mass Produced Input Device That Uses Brain Activity

OMG!
OMFG!
(Note the plural!)
Read this news article on Slashdot. Wow! I don’t care if it works, or is it even practical. The idea of having an input device such as this is sooo appealing to me…
A while back I read about an Australian who had put an RFID tag into his arm, and it acted as his identity for everything in his home, where he obviously had rigged everything to be controlled via software. I wish I was tech savvy enough to do such a thing. But over here, it’s all just Make-It-Yourself, not Connect-It-Yourself.

I wish I could put an 802.11 interface in my brain.

VN:F [1.9.13_1145]
Rating: 8.2/10 (5 votes cast)
VN:F [1.9.13_1145]
Rating: 0 (from 0 votes)

Sun Microsystems Bought MySQL AB!

I just saw it on slashdot! here‘s the announcement. That’s the biggest acquisition news since AMD bought ATI!
Man, what is the world coming to? At least Sun is tolerable. What if Oracle had bought them out?! What would have happened to my favorite DBMS?

VN:F [1.9.13_1145]
Rating: 7.8/10 (4 votes cast)
VN:F [1.9.13_1145]
Rating: 0 (from 0 votes)

The Good, the OOXML and the OOXML!

I hate Microsoft. No, let me rephrase that. I hate everything that insults my intelligence, and Microsoft is very high on the list of them. Another thing that I hate is a bad standard. Put these two together, like the case of Microsoft pushing for ISO standardization of OOXML, and I’ll be entering a “Two Minute Hate” period!
I could bore you with all the reasons that I think OOXML is bad, but you can find all those and a few more over here. Specially interesting and possibly beneficial is a petition they’re seeking to prevent the standardization of OOXML.

You can also get these cool banners there!



(Sorry for the GIF. Still waiting for MNG adoption!)
VN:F [1.9.13_1145]
Rating: 7.0/10 (3 votes cast)
VN:F [1.9.13_1145]
Rating: 0 (from 0 votes)