Author: ThatWhinyBoi

What is YUV?

YUV is a format used to describe colour inside a pixel. Most of the times, that answer should be enough. But this post is for those rare times when that answer isn’t enough and needs a lot more than a single sentence.

Although, be warned that I cannot do justice to YUV by starting at YUV. I need to explain the story behind it. The story is as fascinating as the theory. So if you’re one of those guys who need a to-the-point explanation of YUV, I apologise right now. Since no human is perfect, and this is my first time writing a technical post, there will be errors. I would be glad to have them pointed out to me.

The Beginning

Let’s go hop on a time machine and go to when we were kids (assuming the ones who read this are actually adults). Do you remember those colouring books which you used to spend hours colouring and admiring? In those books, there used to be an exercise which contained a number of small squares arranged to form a large square or a rectangle. Each of those small squares would contain a number and there was a legend at the bottom where each number would be assigned a colour. Something like this:

I’m sorry, I couldn’t get a good quality pic.

Your task was to follow those colour code and colour each of the squares with their corresponding colour. In the end you’d be greeted with something cute (most of the time) like this:

Still sorry.

Funnily enough, this is exactly how a display works. Any display, be it your smartphone, TV, laptops, desktops or even those huge billboards that play advertisements, uses this same principle for showing the video or an image. They use tiny squares and colour them to show you an image. String along a number of images one after the other and you now have a video. Just like a flip-book. The underlying principle is that easy. Anyway, those small coloured squares are known as pixels and they are the fundamental building block in an image (technically it’s atoms (technically-technically it’s quarks but let’s not go there shall we?) but let’s not go there shall we?).

A more formal definition would be: A pixel is the smallest discrete component of an image or a picture. (Where did I get this? Of course from Wikipedia. It’s not like I have a teacher standing right next to me saying he won’t accept my work because it’s been taken from Wikipedia.)
These pixels are also known as picture element or pel. You can make out these pixels on a large screen (like a monitor or TV) if you peer closely enough.

The pixels are those grid-like things if you peer in a bit.

So let’s go to the next question: how are the colours stored and shown to us? There are many ways, but we’ll look at the two major ones: RGB and YUV.

RGB

RGB stands for Red Green Blue. This is used by almost every digital image in the world. The theory is simple: Each pixel is described by 3 values (or numbers), which correspond to the value of red, green and blue respectively. Normally, the values range between 0 to 1.

For example, if a pixel contained the colour red, then there is no presence of blue or green components. So the values will be:

R = 1, G = 0, B = 0  or  (R, G, B) = (1, 0, 0)

Similarly, for green, the values will be:

R = 0, G = 1, B = 0  or  (R, G, B) = (0, 1, 0)

But what if the pixel contained black? Since black means the absence of any colour, all the values will be zero:

R = 0, G = 0, B = 0  or  (R, G, B) = (0, 0, 0)

What about white? White means presence of all the colours, so all the values will be maximum:

R = 1, G = 1, B = 1  or  (R, G, B) = (1, 1, 1)

Any composite colour? Let’s take purple for example. It contains some part of red and some part of blue, but no green. So the values are:

R = 0.5, G = 0, B = 0.5  or  (R, G, B) = (0.5, 0, 0.5)

But since computers suck at decimal points (I can personally vouch for that), they usually map the values to [0, 255], i.e, 0 becomes 0 and 1 becomes 255 and any value in-between are mapped proportionally. From this mapping, we can get a total of 256 x 256 x 256 colours.

Using these values, we can start filling colours on the screen. In a typical LED screen, each pixel contains 3 LEDs (yeah those LED bulbs you use them at home, but these are way smaller). Those three LEDs are special: each of them can emit only one colour. They are red, green and blue respectively. Each of the values say to how bright the corresponding LED must be, i.e., a value of 0 means no brightness (turned off) and a value of 255 means maximum brightness. By using this, we can display all the colours required on the screen.

Infact, you can see these LEDs with a camera and a screen. Take a picture of your screen (monitor or laptop) with your smartphone with the camera as near as possible to the screen without losing clarity. If you zoom in on the image, you can easily make out the three LEDs, placed neatly in order.

A normal image of the screen on the left and the zoomed image on the right. You can clearly see the three individual colours present side by side.

Let’s try to calculate the space required to store a single image using RGB format. We need 1 byte of data to store values upto 255. Since we have 3 values per pixel, we’re gonna need 3 bytes of data per pixel. If we use a standard HD image, that is 1920×1080 pixels. So the total data for a HD image would be 1920*1080*3 = 6220800 bytes, or a little over 6MB. If we make it into a formula (the only formula in this post, promise), it’ll be:

Size of image = Number of pixels * Bytes per pixel
                      or
Size of image = Width * Height * Bytes per pixel

That covers on the basic aspect of RGB. It is widely used in digital image processing (basically photoshop). I’m pretty sure you’d have heard about RGB at some point in your life. No? So it’s only me then? Damn.

Now then, onwards to uncharted waters:

YUV

YUV has three channels (like RGB) which are: one luminance (Y) channel and two chrominance (UV) channels. They don’t have abbreviations like RGB (don’t ask me why). While technically it should be Y’UV, we’ll use YUV in this post. While both RGB and YUV represent the colours, the values they have might be different. It’s like the difference between kilometers and miles: although both of them may have different values, they are just representing the same thing, which is distance.

YUV is slightly tricky to understand. Slightly. The value of Y can vary from 0 to 1. with 0 being no brightness and 1 being maximum brightness. But the values for U and V range from -0.5 to +0.5 with 0 being the center.

So for black, since Y denotes the brightness, it’s value will be 0 and the values of U and V will be zero:

Y = 0, U = 0, V = 0 or (Y, U, V) = (0, 0, 0)

For white, the value of Y will be maximum (1) but the values of U and V will be:

Y = 1, U = 0, V = 0 or (Y, U, V) = (1, 0, 0)

Yeah, it is weird. Until you get to know how it works. Let’s take another example. Let’s try red. For red, the values are:

Y = 0.3, U = 0.5, V = -0.17 or (Y, U, V) = (0.3, 0.5, -0.17)

The values are, pretty confusing to understand. Here’s how I made sense of this madness. The U and V channels together specify what colour you want and the Y specifies how bright the colour is going to be. I mean, it pretty much is the definition of YUV (duh), but imagining a slider that varies the brightness of the colour made much more sense to me than just thinking of them as soulless channels. This link does a pretty good job of visualizing the colours in different formats (the one we’re interested are RGB and YPbPr which is same as YUV in our case).

If we are to transform from decimal to integers for use in computers, the Y would be similar to RGB, i.e., [0, 1] is mapped to [0, 255]. But for UV, [-0.5, 0.5] is mapped to [0, 255]. That means a value of 0 corresponds to a value of 128, a value of -0.5 corresponds to 0 and a value of 0.5 corresponds to 255.

I could not do justice to U and V on a slider (like RGB), so it is left as black. But it does contain colours.

Why use YUV if it is so confusing? Because there is one major advantage with YUV. YUV has separate channels for brightness (Y) and colour (UV), which is remarkably similar to our eyes. Human eyes have different cells for perceiving brightness and colour called rods and cones, respectively (high school biology anyone?). And our eyes contain around 120 million rods and 5 million cones. That means, we are more sensitive to changes in brightness than colour. That is why it we can make out shapes of objects but not their colours during night or in dark areas. Using that same principle, we can do some amazing optimizations to how we store the pixel information. It’ll be easier with an example:

Let’s say I have a YUV image of 8×8 pixels. It will look like this.

This took waay too long to create.

Here each pixel is defined by 3 values, Y, U and V. Each pixel is named with a number for easier reference (P0, P1 and so on). So Y0, U0, V0 are the YUV values for P0, and so on. Now, for the magic. I can remove U and V values of alternate pixels and the image will still look the same to us. Mostly same.

The YUV 422 format

This means I don’t have to store every value of U and V. This format is known as YUV 4:2:2 (referred as YUV422). There are multiple ways to reduce the U and V samples, taking alternate values, averaging the two values and so on. We are considering only the alternate values because it’s simpler to understand. This process of reducing the UV samples is called chroma subsampling.

Now for one more magic trick: I can remove U and V values of alternate pixels along the columns it still wouldn’t have a huge difference on how the image looks. This format is called YUV 4:2:0 (YUV420). Pretty neat eh?

The YUV 420 format

This basically means all the U and V values that are present in YUV422 and YUV420 are shared by the neighboring pixels. So in YUV422, U0 and V0 are shared by P0 and P1 and so on. Similarly in YUV420, U0 and V0 are shared by P0, P1, P8 and P9 and so on. This sharing is done as part of displaying and not as part of storing the image.

How the neighboring pixels share the UV samples in YUV422 (left) and YVU420 (right)

How much does this save us in memory? The original YUV, with all the U and V values intact, also known as YUV444, is same as that of RGB. So a HD image will cost us 6MB.
YUV422, on the other hand, has 2 Ys, 1U and 1V for every 2 pixels. That means 1Y, 0.5U and 0.5V for one pixel. So if each of them take 1 byte, then in total they’ll take 1 + 0.5 + 0.5 = 2 bytes per pixel. Plugging this value into our size formula, we get 1920*1080*2 = 4147200 bytes or a little over 4MB. This gives us a 33% reduction in size over YUV444.
YUV420, on the other other hand, has 4Ys, 1U and 1V for every 4 pixels. That means 1Y, 0.25U and 0.25V for one pixel. So the size if 1 + 0.25 + 0.25 =1.5 bytes per pixel. For this, we’ll get 1920*1080*1.5 = 3110400 bytes or a little over 3MB. Comparing them, we can see that there is a 50% reduction in size (conversely bandwidth) requirements when using YUV420 over YUV444 (and RGB). The only downside being loss of colours but even that is not very apparent visually.

Initially the TVs supported only black and white videos. So they had two channels of information: one for the video which contained only the brightness information (since black and white meant you only needed the brightness values), and one for audio. When they invented the colour TV later, they had two choices: create a new format for sending colour signals or build upon the existing standards to support colour signals. So they added two more channels for the colours. Those 3 channels (one brightness and two colour channels) are basically the YUV format. Using this format meant the existing infrastructure for video broadcasting wouldn’t have to be drastically changed. Since you’d just be adding some extra channels to handle colour, if it was sent to a black and white TV, the TV would just ignore the colours and show the video in black and white. So with minimal changes (compared to something like RGB) you can show colours in colour TV and black and white in existing TVs. And using YUV420 meant reduction in size by half. Couple this with the fact that bandwidth was ridiculously expensive (due to Jio not being present), the answer was obvious. Go with YUV. And thus, we still use YUV even now. Nearly video you watch uses YUV format. Yeah. It’s that popular.

YUV is not constrained to these two subsampled formats only. There are YUV 4:1:1, UYVY, NV12, NV21 and lots more. But we will stop here to reduce the possibility of a information overload (and also because I am not familiar with most of them).

Also, when I talk about YUV, it is actually YCbCr. YUV is for analog signals, used in older TVs (those heavy boxes, also known as Mjölnir’s older brother). YCbCr is for digital signals. But they are used interchangeably, so most of the time, the difference in names do not matter.

That, hopefully, should help you get started with the YUV (YCbCr) format.


References:

  1. Wikipedia on YUV
  2. This helpful video

Work From Home

Covid-19 has forced me and most of the world into staying at home. Since most of my work does not require my physical body to be present at the company office, we are all working from home. I was pretty skeptical about the amount of work I’d get done considering I will be working from Mysore and I have too many distractions over there (TV and PC mostly) and the past couple of weeks have just confirmed my beliefs.

I had read tens of articles on Hacker News and hundreds of answers on Quora describing how amazing it is to work from home. No set timings, no nagging manager looking over your shoulder all the time (disclaimer: my manager doesn’t do it, yeah he’s amazing), no colleagues disturbing you every 5 minutes (not that anyone disturbs me), no meetings unless absolutely necessary and even those meetings are on calls. It’s a dream come true for any guy who wants to get their work done without any distractions.

Or so I thought.

When I was working from the office, there was a working environment that forced me to stop daydreaming or any other unproductive tasks, and work. That was actually a good thing for me. The work would start at 11-ish and I would toil till 7-8 in the evening. When I returned home, unless the work was high priority, I would stop thinking about anything related to it until the next day. This gave my mind a chance to rest and relax before tackling it again.

But ever since I’ve started working from home, my life is becoming messier by the minute. Although I like my work (it’s fucking awesome) and am motivated enough to get it done, my disorganized and unfocused ass, for the life of me, will not let me sit still for more than 20 minutes. This means every 10-20 minutes I’ll end up on Instagram or YouTube or Hacker News (I still can’t believe that I can get distracted by a website that focuses on latest trends in tech world, which includes most of the geeky stuffs). Not to mention, now that I have no set timings, I wake up at 10AM. 10 FREAKING AM! I mean, I’m not a stranger to that routine, but this results in me starting work at 11.30-12AM. Compared to my office timings, that is not so bad, but you need to understand that to actually get into the flow, I’ll need at-least 30-45 minutes. Couple that with my distractions, I end up doing far less work than I would for the same amount of time in the office. This leads me to my greatest problem: the guilt.

Now that I work less at my home due to . . . me, I feel guilty. In order to feel less guilty, I start working more. But I don’t start focusing more while I work, nor do I stop the distractions, because those are too tough to do. Instead, I increase my work hours. Now, my end time goes from 7-8PM to 9-10PM. Why you ask? Because I’m an idiot.

So due to working from home, I am now working more than I used to, I have no human interaction apart from my family (not that I interacted too much before), I have lost all sense of time (I’m thinking of announcing a reward for any information regarding this, last seen before lockdown), I don’t even want to think what happened to my biological clock and I’M STILL NOT GETTING ENOUGH WORK DONE!!

I hate work from home.

How I Fixed My PC’s Blue Screen of Death

Ever since I got my PC (unless and until specified, “my PC” specifically refers to my latest desktop), I had this strange issue where it used to randomly hang up and restart. You know, that dreaded . . .
*looks around*
Blue Screen of Death (BSoD) [1]
*screams echo in the background*

I’d be playing my favourite game of the week and all of a sudden, I’d get the damn BSoD and my whole fictional world would come crashing down. To say that I was angry, would be a prime contender for the understatement of the year. It was with superhuman willpower, effort and patience that I would calmly wait for it to restart again, which took around 2-3 minutes, and then continue my digital adventure where I left off. Sometimes though, the crash would occur when I let my PC run overnight to download a huge game. I’d feel like I plugged in the mobile to the charger overnight and realize that I forgot to turn it on in the morning. Although most of the times I would lose around 15 minutes of gameplay, that wasn’t the reason for my outburst. It had more to do with my fear of the PC breaking down. If these crashes continued, then it would ultimately lead to some hardware failure. That meant I had to get it repaired, if that doesn’t work, then I’d have to get a replacement part from the shop, which meant half a day gone in getting it, or worst-case scenario: I’d have to buy a new PC. Yeah I overthink, a lot (over-overthink?). So yes, I was obviously concerned and angry whenever those BSoDs paid a visit to my PC.

It’s not like I haven’t tried to find the root of the problem. But it increases the difficulty when the message BSoD gives changes every time it crashes. So I had to go one layer above and search for multiple BSoD failures. And after hours and hours of probing the deep recess of the web and even exhausting the Google search (yes, I went to the second page of search results, that’s how far I’m willing to go for my PC), I confirmed only one thing: one or more of my hardware has failed. That too was not guaranteed, since it could still be a Windows issue. So I had two options in front of me right now:

  1. Reinstall Windows
  2. Remove the faulty hardware and plug in a new one

Reinstalling Windows meant I had to get the repair guy and ask him to install it, and I could only call him on weekends because, well, I am not available any other time. But as the week crawls by over to the weekend my laziness takes over and I postpone it to next week.
I could try the second option, but it is easier said than done. First of all, there is no way to know which hardware is faulty and I don’t have any spares. And according to the Gods of the Web, it can be either the PSU, or the motherboard, or the CPU, or the RAM, or the fan, or the HDD (throw in video card and you have all the components required for a CPU). So I did what any rational person would do: ignore it. Since it works most of the time and only crashes once or twice in a fortnight, I figured I could live with it until I found a way to nab that faulty hardware.

Until that fateful day.

I was playing on the PC as usual when it crashed once again. So I calmly waited for it to restart but before I could even play, it crashed again. Now this was something new. No worries, I’ll just wait until it rest . . . crash. It crashed while it was recovering from the crash (crash-ception?). And after that it was all downhill. It was never able to run for more than 10 minutes and anything I do would cause it to crash. Trying to start a game? Crash. Trying to open the settings? Crash. Trying to open the Start Menu? Crash. Looking at the monitor at a slightly weird angle? Crash. After half an hour of agonizingly trying to find what was wrong, I gave up and realized that it was time to call the repair guy. The guy comes over, turns it on and waits for it to crash. Well whaddaya know, the damn thing didn’t crash even once. And so after waiting for half an hour for it to crash he left asking me to call him the next time it crashed. But before parting, he gave me one last piece of advice: this is most likely caused by the RAM or the HDD. And that actually narrowed it down to a more manageable list of things I could check. So I kept that in the back of my mind to use it the next time my PC crashed, which was two minutes after the guy left. It’s almost like the PC wanted to see me suffer.

But this time I was desperate and prepared. A deadly combination.

I mentally prepared myself to get my hands dirty. Although I didn’t have a spare HDD, I did have 2 RAM sticks that were presently within the CPU. I could remove one of them and check whether the crashes continue or not. I can then do the same with the other RAM stick. If they stop, then the one outside is the culprit, if they don’t stop for both the RAMs then it must be some other hardware. So I started my foray into the land of the silicon. After ~4 hours of back breaking work (what? turning off, swapping RAM sticks, trying out all combinations is hard work), I found that while there were still crashes, one of the RAMs had 3-4x times the crashes compared to the other. Bingo! That meant one the RAMs had gone rogue. But the crashes were still infrequent; I didn’t know how to reliably get it to crash so that I can confirm my diagnosis. That’s when my friend pointed me in the direction of prime95[2]. Started it up on my faulty RAM and waited for it to throw an error. I didn’t even have to wait for 5 minutes before it complained about multiple “hardware failure detected, “, which, did not occur for the other RAM stick. So I threw the faulty one out and magically, all the crashes went away. Not magically exactly, since I went through hell to find that faulty hardware, but I still felt pretty awesome for debugging a hardware issue for once.

The reason the working RAM crashed once or twice might have something to do with my constantly swapping in the good one and the bad one every 5 minutes. I’m still not sure as to why it crashed at all, because after that, the PC hasn’t crashed once till now (~3-4 months as of the time of writing).

All in all, I wasted the complete second half of my Sunday to find the issue. This is a reminder to myself that out of those thousands of working RAM sticks, only I got the faulty one. But that led to having one of the most fulfilling afternoons I’ve ever had in a long time, so maybe, should I even consider myself as unlucky? Or lucky enough to get the faulty piece and get new knowledge in the process of finding it?


Final Notes

How Not to Make Pizza Bread: Part 2

After my fiasco the last time I tried to bake bread in my kitchen, the only sensible thing left to do was to try to learn cooking properly before dipping my toes into the deep waters. But due to unforeseen circumstances, I was not able to cook as often as I wished. My companion in these trying times was, ironically, bread. I would come home from work late in the night, exhausted, and my trusty bread would always be present for a light toast. The toast was the only thing I could prepare at that time of the night which was fast and easy. I had a newfound respect for the versatility of this simple yet amazing piece of culinary invention that was sitting on my kitchen counter nearly everyday. This, is apparently the third or fourth time I’m rediscovering bread’s potential, even though I’ve been eating it for more than two decades. The problem was, that bread sitting on top the kitchen counter was a sign of my poor bread-making skills (read: non-existent). I could imagine it sneering at me whenever I pulled out some slices for a much needed dinner (“Look at you, what a fucking peasant. Can’t even bake some bread. I can’t believe I’m helping you in your hunger. What happened to being like Gordon? Where is your lamb sauce, loser?”). After being humiliated by this for a fortnight (two weeks for the uninitiated), I finally gave in.

Just because I messed up last time, doesn’t mean I should always mess up. I decided to research it properly and do it correctly this time. As I analyzed my previous attempt at creating bread, I found some glaring mistakes in it. First, I had not dissolved the yeast in the water properly before making the dough. This was because I had a different than the ones shown in the recipes and videos. Mine was more of a bead-like shaped than the usual powdery ones. So not dissolving them meant they weren’t activated as much as I hoped. Second, I used atta for the dough since I wanted a more healthy bread than the usual maida ones. So I decided to use the maida this time, health be damned. Third, the dough itself was too dry. I think that if the dough is too dry, it might not rise too much since it isn’t so loose or flexible (just my reasoning, which kind of made sense). Fourth, I had not let it rise properly before making the bread. This was because I did not have time to wait for it. I had left it for around an hour and half. Fifth and the last, I had used a tawa instead of an oven. This, I believe to be the most important one, since I could make those other mistakes and still end up with a bread albeit, a bad one but if I had no oven, then I wouldn’t even be able to make a bread. Now that the analysis is out of the way, I finally got ready to earn me some bread.

I came home early that fateful day to start the process early. Grabbing a spoonful of yeast in a small cup, I added warm water and stirred it until all the yeast dissolved and went from small beads to a colloidal solution. I let it rest for five minutes before taking two cups of maida in a large bowl and adding the yeast mixture to it. I could have taken a mix of atta and maida but I didn’t want to risk some shitty product again. I added couple of spoons of oil (I don’t know if its teaspoon or tablespoon, it’s just a spoon okay? I just eyeball it anyway) and started kneading the dough. I made sure to keep it a bit sticky and hydrated compared to last time. After kneading for 10-15 minutes I smeared the insides of the bowl with oil, kept the dough inside and covered it. Since I had not given time for the dough to rise the last time, I decided to let this one rise for 24 hours (that’s right, it’s either 0 or 100 with me, no in-between). Next morning, I checked the dough once before leaving for work. Well what do you know, the dough had risen beautifully. I . . . had not expected that. It was double the size of original. Not having anymore time to work on it, I left for the office. I had now taken care of mistakes #1 to #4 in one fell swoop. I was ecstatic. Maybe I can do this. Maybe I can show that piece of bread on the kitchen counter who’s the boss.

Side-note: 12 hours seems to be good enough time for letting the dough rise. Although you can let it for upto a week, you must keep it refrigerated during the whole duration. As I still hadn’t procured a fridge, 12-24 hours is ideal.

Now there was only one thing left to do: bake it. But, I still didn’t have an oven. So I thought of using the tawa again. My brain, at the last moment, stopped me from committing the same mistake again (Sometimes, I wonder what would happen if I listen to my brain more often). I decided to not use the tawa. But what else to use for baking apart from buying an actual oven? Time for some jugaad. You can use the pressure cooker itself as an oven using some salt. You spread half to one inch thick layer of salt inside the cooker and place a ring-type utensil on the bottom inside the cooker. You can now place whatever you need baked on a plate and place it on the ring. The theory is that the salt is an insulator of heat so it will create this uniform layer of heat at the bottom. The ring is there so that the plate will not get hot quickly and burn the underside of the dough. Pretty neat if you ask me. I set this up, placed it on the stove and let it heat to remove any moisture inside. I still hadn’t placed the plate with the dough yet. Also the cooker must be covered when heating with the gasket and the weight on top removed. The gasket will be ruined if it’s there when heating. The weight is removed so that you are not arrested for starting fireworks in the house. I now concentrated on the dough while I let it heat. I removed the dough from the bowl and kneaded it for a few minutes. It was soft, airy and felt so good in my hands (oh yeah, I am sooo gonna get this bread). I halved it and put one of the halves on a plate and started flattening it. I wanted to make it a bit thin so that it can bake faster. I was pressing it down with my hand an . . .

SNAP!!!

Beep . . . Beep . . . Beep . .

I looked over to the only other piece of electronics present in the kitchen (apart from my mobile): the stove. I use an induction stove. The led display was showing “ES” and beeping every five seconds. It stopped heating the cooker and none of the buttons worked, except the power button. I did the next sane thing: I kept the plate with the dough inside the cooker to bake with whatever heat there was left. Efficient use of heat? Nonetheless, while I waited for the bread, I started contemplating my future course of action. My most immediate concern was that I hadn’t prepared dinner yet and I was feeling hungry and it was already late. So I resigned myself to eating Hide and Seek for dinner and moved to the core issue. Well, from whatever I understood, the stove was pretty much done for. I needed a new stove. Although it was a shitty stove, I had grown to like it. Sad. By now I could see the heat from the cooker was not as intense as before so I opened it to check up on my pièce de résistance.

This time there were two thuds in my dustbin.

One was the half baked bread.

The other was the second half of the dough which couldn’t be used even if I wanted to.

The most disappointing part was that the bread, although half baked, seemed like it would actually turn out fine if the jugaad oven worked as it was supposed to. Woe is me.

I turned off the stove and left to check my mobile for any late-night delivery. After half an hour of fruitless searching for food and wasting time on Insta because I couldn’t find any food, I came to the kitchen to get the pack of biscuits. I looked at the stove and just felt like trying to turn it on one last time. I switched it on and pressed the power button and . . . it worked! It was up and running. I could not believe my eyes. What is happening? How did it work? Why is it even working? And then I realized, the display was not showing “ES” when it snapped, it was showing “E5”, Error 5. It had probably tripped some internal circuit when I was heating the cooker and displayed that message. Maybe it could not handle the high heat from the cooker because of the salt inside. Maybe I should start reading manuals when I buy something.

Anyway I then chanced upon the half finished packet of bread lying at the side on the counter and hungrily grabbed it for my late-night toast, even as the bread just flat out gave up on my journey to become a good cook.

Hope Dooms Eternal

The first thing I did when I got a job was to save up my money and buy a decent PC. I fought with my mom for that one. Who wouldn’t? But compared to our fights before, this was a lot less intense and my mom had probably given up all hopes on me being a functioning adult at that point. So I happily started researching for a PC that was within my budget (around 80k, in Rupees). Although I could have gone for a higher budget PC, my upbringing, courtesy of mom, somehow got hold of my decision making machine (sometimes referred to as a brain) and refused to allocate more resources. I searched high and low for the parts online. Finally when I decided on what kind of PC I wanted, I visited Chikpete in Bangalore and searched all the shops once more for the cheapest option for my spec. After hours of agony and dilemma, chose a shop and got everything I required and came back to Mysore with me grinning like an idiot the whole trip back. I got it assembled at my home and just . . . fell in love with it.

I decided that since I am earning, I will now buy games like a normal person. But, I hear you say, a normal person does not buy games, he torrents it like the rest of us. To you, I say, . . . ah shit you win, I will now buy games like an abnormal person. And that is how I ended up installing Steam (like Amazon but for games). Even before I had bought my latest computer, I had a list of all the games I wanted to play when I got a good PC. And now I referred to that list and starting adding all those games to my wishlist on Steam. And among those entries, there was this one game I had been dying to play for more than a year: Doom (2016).

Doom was a reboot of the original series, whose first entry was released waaaaaay back in 1993 by a company called Id Software. You may not know it but these guys were the creators of one of the most famous genre in the history of gaming: The First Person Shooters or FPS. Doom 1993 became a classic. You controlled a marine (known as Doomguy) who fought off demons from hell using your trusty guns. I haven’t played Doom 1 (yet) but I played a lot of Doom 2 (1994) and Quake 2, another one of their masterpieces. In fact, I have fun playing Quake 2 even now. But what actually hyped me up for the latest Doom (2016, which is the 4th game in the series) was Doom 3. I can already hear Doom fans picking up their chainsaws in the background, but I am not changing my opinion (but I am getting ready to escape). I loved Doom 3. While the first 2 games focused purely on shooting, Doom 3 was more of a horror game. I loved the atmosphere, loved the guns, loved its tight corridor shooting and sense of tension and dread it created throughout its 10 or so hours of gameplay. And it was the first horror game I had ever played and finished in my life.

When I saw the latest Doom on the Steam page, I immediately added it to my wishlist and waited for the day it was offered in a sale. Just because I stated I’ll buy games doesn’t mean I’ll splurge 2-3k on a single game. By the time I had got my PC Id had announced the next installment of Doom. So I was hopeful that they will reduce the price of Doom 2016. So I waited.

And waited.

And waited.

Seems like people still bought the game even after 2 years. And Bethesda (the publisher of the game) had no intention of offering the game up on a sale. WTF. I can’t pay 2k for my most anticipated game. I had some other games to play so I could afford to wait. But I’ll admit, I was on the verge of snapping.
“It’s just 2k, just buy it”,
“Spend your money just this once, you can save later”,
“You’re saving it for yourself, so why not spend it for yourself”,
“You don’t know when they’ll offer a sale, just do it now”.
You kind of feel sorry for Smeagol once you experience such thoughts day by day. So when they finally offered a discount of 20%, I finally gave in and bought the game. Then I had to download the game and it was around, *drum rolls please*, 70GB. My monthly internet plan was 100GB. I had to use up 70% of it just to download this single game. But I was unfazed. I was on a mission, to play that game no matter what. I was ready to even face the wrath of my mom if it meant I could achieve my dream. I kept it to download on a Sunday night, which was a huge mistake on my part because the game would be downloaded on the next day but I had to go to Bangalore for work. This meant I had to wait a whole week before I could play the game. A WHOLE WEEK. That week was one of the longest weeks I had ever had in my life. Never had I been so sad to be a Weekend Mysurian. But it was finally over and I rushed back to Mysore as fast as possible. I sat down, fired up my PC and started the game.

I was not prepared for what came next.

The Doom Slayer, ripped and teared my expectations and put a super-shotgun-sized hole in it using his super shotgun. Whatever I had hoped for, they did it better. You wanted good gameplay? We’ll give you better gameplay. You wanted simple story? We’ll give you minimal story. You want to rip and tear those demons? YOU WILL RIP AND TEAR THOSE MOTHERFUCKING DEMONS. For 17 hours (I am a slow player) I shredded and blasted those demons like never before and I loved every second of it. Oh the buttery smooth movement, the fast paced combat, the addictive gameplay loop, the soundtrack, the enemies, there are so many things to talk about that I don’t even know where to start. The very first thing you notice when you start the game is how to-the-point the game is. You wake up in a room chained to an altar and there are demons around you. So you do what any rational person would do, break off from the chains, smash a demon’s head that stumbled towards you, grab a gun and start blasting. There are no 15 minutes cutscenes, there are no lengthy expositions explaining why the protagonist (referred from now as Doom Slayer) was chained, where he was before he woke up and so on. You aren’t even told what to do to those demons surrounding. And you realize you have only one objective within 45 seconds of starting the game: Shoot anything that moves. One of its “tips” says this exact same thing in a very Doom-like way: If the enemy has a head, its a weakpoint. And this simplicity is what made me root for the game just within a minute into it. But that is not the only thing it has going for it. The gameplay is fast, smooth and polished. The movement feels so good that you don’t feel like staying at one place and shooting the demons. And that is what the developers also want you to do. You cannot survive if you stay at a single place. The guns are awesome and each feel unique. For a First Person Shooter game to have good guns? Colour me impressed. And the protagonist himself is something you tend to like two minutes into the game. There is a scene at the start where a computer screen starts explaining what is happening around him and what he should and how he should go about doing it . . . and Doom Slayer just slams the screen to a wall. He doesn’t want to know all those. He just wants to kill some damn demons. The man is literally too angry to die. Doom Slayer’s badassery charms you in a way very few games do. It’s like you are in control of a god that is dishing out punishment to the demons (“Be blessed, ye lowly being. Thou shall soon face my wrath and be ripped and teared”). Lastly, the soundtrack. Oh the soundtrack. I have an eargasm just thinking about it. I never realized how a good soundtrack can elevate the status of an excellent game to a legendary one. Doom’s music is mainly metal. I don’t listen to metal but by the end of my playthrough, I had all the songs in-game on my playlist. The music complements the gameplay and the gameplay complements the music. The symbiosis is perfect. You feel that Mick Gordon (the composer) deserves a standing ovation by the time you finish the game. You come to a realization that the game is basically a love letter to the FPS genre and the original Doom (1 and 2) games.

I had read some reviews when the game came out which did not give as much positive reviews as I was hoping for. I had also heard the gameplay is repetitive: go into a large room, kill all demons, repeat. And somewhere in the back of my mind, I was afraid that I might not like the game. But I am glad that I still felt like buying the game and checking it out. Infact I had so much fun playing that I completed it once more at a higher difficulty last month. That means Doom has the distinction of being the only game in my life that I have completed twice on different difficulty levels. Doom by far, is the most expensive game I’ve bought (at 1.1k) and I am so glad that I did splurge on it.

The next game in the series (Doom Eternal), is releasing next month and I cannot wait to play it. I hope that it will live up to the hype and be better than what Doom 2016 was. Although I dunno how they can possibly top it.

Even if Doom Eternal is releasing next month, I have to wait for the next sale (August or December) because I still cannot spend 4k on the game. But maybe, just maybe, I might buy the game at its full price this time.

The Weekend Mysurian

“Hey guys, let’s go out somewhere tomorrow evening!”

“Where?”

“We’ll decide tomorrow. Hopefully some movie and a dinner.”

“Okay sure.”

“Count me in!”

“Me too!”

“Sorry but I cannot come.”

“What?! Why not? It’s Friday!”

“That’s why I cannot come. I need to go to Mysore.”

“Again? Dude you went there last week too. Can’t you skip this week?”

“No.”

“Oh come on. Just once. You go there every week.”

” And I will continue to do so as long as I can.”

“Why?”

“You know why.”


When a city booms, it leads to a loop that somewhat follows this order: influx of talents -> influx of companies -> more development -> influx of more talents and so on. Although this is a near perpetual cycle, it requires a high up-front cost. So when Bangalore (No, I don’t want to call it Bengaluru) exploded into popularity as the go-to destination for all your IT needs, there was a humongous migration of people and companies from all over the country and sometimes, even from different countries. That led to Bangalore being the IT capital of India. Of course when a city advances at such a pace, there is bound to be crazy changes in the lifestyle and culture of its inhabitants. Gone were the days where you could see the whole city in different shades of green (Green City of India, anyone?). Now they were replaced by this drab concrete jungles. Gone were the days when you could go from one end of the city to other end within an hour. Now you have to pack food worth for two days to even go to Majestic from Kengeri. But our economy boomed, so it was a precariously balanced trade-off. With these new generation of techies, the city adopted a more lenient and modern lifestyle compared to its surrounding cities. When a city becomes more modernized it leads to a weekly lifestyle: slog your ass throughout the week, so that you can do something in the weekend (Please don’t quote me on this or ask which studies I referred. I just told what I observed). But for a techie, the “something” boiled down to one of the three things:

  1. Stay at home and make a piss poor attempt at getting back his sleep and thus, his sanity.
  2. Roam the city. Bangalore provides so many things to do its not even a joke at this point.
  3. Go on a trip for the weekend.

And it was all well and good.

Until the Fire Nation attacked.


Mysore (I definitely refuse to call it Mysuru. It’s an abomination and must be destroyed at all costs) is one of the closest and most important city near Bangalore. It’s a 2.5 hour drive from Bangalore, 5 if you consider the traffic. It was the capital of Karnataka before independence so it is quite influential and it is one of the most important historic cities of India. Due to its proximity, these people started traveling to Bangalore for jobs and other things (I’m joking, Mysore wasn’t this late into the party. Its inhabitants were one of the first to be captured by Bangalore’s beauty). And Bangalore accepted them because its motto is: We will accept anyone no matter what. We may not have space left to walk but hey we’ll just haphazardly expand and build some buildings at the outskirts. What about dealing with proper organization and well structured city? Like a great programmer once said when asked about documentation and commenting the code: We’ll do it later.

Coming back to point, Bangalore happily accepted the Mysurians into her Majestic arms. But these were of a different species from the rest of the immigrants. You see, although these guys (and gals) came here for the jobs, they were still madly in love with Mysore. And most of the Mysurians had never traveled for more than 200kms in their life. The ones who did, found nothing could compare to Mysore. This led to them having this wild urge to go back to Mysore at every chance they got. Every. Damn. Chance. So they would go back to Mysore every weekend, holiday or even for remote work (Nothing says Work From Home like actually traveling to home and working). These legendary creatures crossed the minimum threshold to be called a separate group and were started to be referred to as:

The Weekend Mysurian.


A study was conducted to note down the behaviour and the life of The Weekend Mysurians’ (hereby called as TWM). The behaviour of the subject is similar to a typical Bangaloreans on weekdays. But the difference is found as the we approach the weekend. As the week crawls over to its end, the subject experiences uncontrollable bouts of homesickness where it feels as if it hasn’t been to its home in a very long time. The subject starts experiencing withdrawal symptoms as the week draws to a close. On a Friday, the subject finally succumbs, packs its bags and goes to work along with the bags. It was found that a typical TWM usually leaves at 4.30PM on a Friday evening in hopes of catching the train to Mysore. The train is also the most important one in the life of a TWM. It is called Chamundi Express and it is the train it finds even remotely suited to its taste. Although there are many who take up other means of transportation, bus from satellite bus stand being the next most popular mode, this train makes up for a huge chunk of it. If by any chance you have a friend in Bangalore who is from Mysore, you can expect 3 out of 5 times that he/she will be in this train. The Chamundi Express gets around 50-60% of its revenue from this single ride (6.15PM from Bangalore). The subject then returns to Bangalore late Sunday evening or early Monday morning.

There are subspecies in these too. There are many TWMs which go back to Mysore on a fortnightly basis rather than a weekly one. But when they do, they still go in the Chamundi Express most of the time.

The reasons for this behaviour are numerous. We discovered a few of these reasons in our studies. The subject might be homesick; it doesn’t want to spend time with its friends or it doesn’t like doing its laundry. It was also found that the ones doing their own laundry usually left every fortnight. The study also found that the subject will schedule its life in such a way as to not disturb the weekly ride back to Mysore. The author also made an startling discovery that the reason it might go back to Mysore every weekend might be its feeble attempt at clinging on to its golden memories for as long as physically possible.

Although these creatures are magnificent, they have a very short lifespan. The lifespan averages to 2-3 years after which, they morph into a typical Bangalorean. Whatever the case may be, enough can’t be said about their determination to go home week after week no matter what is happening around them.

The author of this study also wishes to convey that he is in fact, one of them.

How Not to Make Pizza Bread

You realize (damn you American auto-correct) how much shit your mom put up with you when you start cooking food for yourself. All those amazing dishes prepared lovingly by her and you act like a moron and say “No, I want something else”. It takes way too long to prepare even something simple from getting the ingredients, chopping the veggies to cooking it and finally eating your creation. Funnily though, I like it. That was so un-lazy of me that I kept pinching myself the first few times thinking it was a dream. I like every part of the process except washing the dishes.

Anyway, when I started to learn to cook, I got this irresistible urge to scour the net for some recipes. As usual, Google told YouTube about my newfound hobby and YouTube got into action. Before long, I was watching Gordon Ramsay bash on chefs and restaurant owners like it was nothing. Once you start watching Gordon, there is no going back. YouTube starts recommending food channels as if it hasn’t eaten for days. In these outstanding list of food related videos, I was particularly amazed at how easy it was to prepare pizza. I always thought the base, the sauce, the toppings and the cheese were all too complex. Turns out, the pizza base is pretty easy to prepare. In this video, the guy showed how ridiculously easy it is to make pizza. And I decided I wanted to at-least try out making the bread. I mean, what could go wrong?

I got the yeast from the supermarket, I already had flour (atta), oil and salt. Getting ingredients, done. Took a spoonful of yeast in a medium sized bowl, added warm water and left it for 5 minutes. Then I added 1.5 cups of flour to the bowl (small sized cup, fortunately I had enough sense to limit the damage as much as possible), two spoons of vegetable oil and some more water and kneaded the dough for around 10 minutes. I covered the bowl and then left it for the dough to rise. According to the video, I was supposed to keep it in the refrigerator overnight, but then I don’t have one yet. Well, I figured, for the second time in the evening, what could possibly go wrong?

I kept checking every half an hour whether the dough had risen to double its height. Unfortunately, the dough rose to around 20-25% of its height and refused to rise any more. After 1.5 hours and praying for a good dough, I finally succumbed to my hunger and took it out. I kneaded it a bit more and flattened it out like a pizza base. In case the bread turned out better than I expected, I wanted it to be tasty, and so I added few cloves of chopped garlic and some salt on top.

Here I encountered my first major obstacle: I did not have an oven (I know, I know, I am an idiot. That is not gonna change in the foreseeable future). But, this was one of those rare moments in my life where I was prepared for a change. You see, in my extensive research on creating pizza (which amounts to 5 videos), I also searched for making the pizza without an oven. I thought, I could mix them up a little, i.e., I’ll use the recipe for the pizza base from one video and the way to bake it without oven from another. That is what cooking is, right? What the hell could go wrong?

I heated a pan at max heat for a few minutes, applied some oil and dropped the flattened dough on top. Closed the lid and let it cook in low heat. After a few minutes, came back and saw it had risen a little like a typical pizza base. I waited a few more minutes so that the top-side of the dough would be heated. My reasoning was, since I closed the lid, the heat inside would be sufficient to bake the top side properly too. When I saw that it didn’t, I did what any sane person would do and flipped the base. The underside was slightly overcooked and since I left it in low heat and cooked it for too long, it had become hard. But now the topside was uneven and did not cook properly. After a few minutes of looking at it hopelessly, I took the bread out. I call it bread because I knew what I was trying to cook. But to any of the uninitiated, it looked like a flying disc having a bad day. Nevertheless, I cut a small piece and plopped it in my mouth.

I then promptly threw that sorry excuse of a bread into the trash and went on to prepare some Maggi.

It seems asking “What could go wrong?” too many times can actually make something go horribly wrong. Probably Murphy has go to do something with it, as usual. Or I don’t know a damn thing about cooking. You may not agree but I am certain it is the former.

Considering everything, it’s okay I guess. There were moments where it looked like it would work out fine. Even if all hope is lost, there is always the saying: “Once you’ve hit rock bottom, the only place to go is up”.

But then I remembered, I belong to this category: