An experiment in Obamamania

Okay, I’m running out of cash. I admit it. I’ve been spending like a crazy person since my purchase of a house here in the slums of Redwood City. My bank accounts are on the verge of depletion and I’ve been paying 10% APR on my credit cards for several months now.

Why I Spend so Much?
It’s kind of surprising how you expect to spend no money on the house other than the closing cost on the Good Faith Estimate, but then later, once the house closes, the moving costs, the blinders… ugh, where did all that money go? all I can recall is buying some blinders for the house, and yet my monthly expenditure, aside from the mortgage payments and utilities, has gone up by at least $1000/month.

The Blog Entry
Anyway, I decided to try to take advantage of President Barack Obama’s Credit Card reform. According to this article on creditcards.com, when the credit cards will receive your monthly payment, it will take the “minimum payment” and do as it please with it, and the remaining money in the payment will be required to go towards paying off the portion of the debt that has the highest interest!!

Let’s say that I have a credit card that I’ve used to make “auto-payment” of about $500/month to utilities, phones, tv, and the likes. These auto-payments occur every month, and I have arranged for the credit card company to withdraw that exact amount from my bank account monthly. If I do not pay this amount on time, my interest rate is something like 12% APR charged monthly at 1% a month.

Now, I have also received an offer of $5000 12-months 0% APR Promo-check from the same credit card company.

Prior to this legislation, my monthly auto-payment to this credit card will go towards paying off the $5000 0% APR debt, and the $500 I spend every month will accumulate and charge interest until the $5000 is paid off. So the payment/balance looks like this for the first few months

Month 0% APR balance 12% APR balance Payment Total Balance Interest Charged this Month
1 $4500 $500 $500 $5000 0
2 $4000 $1000 $500 $5000 $500 *.01=$5
3 $3500 $1500 $500 $5000 $1000 *.01=$10
4 $3000 $2000 $500 $5000 $1500 *.01=$15

Today, under the new rule, the same charge/payment that I make monthly would produce a table like this:

Month 0% APR balance 12% APR balance Payment Total Balance Interest Charged this Month
1 $5000 $500 $500 $5000 0
2 $5000 $500 $500 $5000 0
3 $5000 $500 $500 $5000 0
4 $5000 $500 $500 $5000 0

So that 0% apr promotional charge is a real 0% APR.

Now, I don’t believe my eyes when I read this “policy update” from the bank. So I found the legislation. Here’s a snippet of the relevant portion:

And here are some links to the text of the bill passed:here, here, and here. 111th Congress, H.R.627;

I guess even after researching into the bill and reading the text of it, I am still sceptical. Why has the Obama administration not spend any marketing money on the passage of this bill? It would surely stimulate the economy by making more people take advantage of the true 0% APR? There must be a catch that I haven’t seen yet. I’ll probably get slammed by a loss of job, bodily injuries, numerous car accidents and traffic tickets, tree falling on my house, etc, for taking advantage of this 0% APR. I mean it’s happened before that some thing random and rare happens every single time I used one of these 0% APR checks to interrupt my monthly payment. It’s almost like the efficient market is efficient in taking my money in super-natural ways.

But despite my misgivings about the free market, the whole credit card industry and Obama brand of hopus-believous, I have taken one of those checks on the credit card I describe above and cashed it.

Call me stupid.

Call me gullible.

But having hope is right? I hope it’s right…

12% interest is worth the price for even 1% chance of discovering a change that we’ve hoped for and can believe in.

The Greatest Magic Show on Earth

According to the Christian Science Monitor, “The Chinese traffic jam that has lasted for over two weeks has vanished overnight.” The article cites both MSNBC and French press AFP as source.

More supprisingly than the magic of 60 miles of traffic disappearing is the fact that western media did not make a glib remark about how it’s another communist PR ploy, and how they mobilized local farmers and burried the 60 miles of cars to fool the western media into believe the incredible powers of the Chinese communist party.

I mean, the article does go into detail about how bad the traffic is in China, which is completely fair. I just cannot get used to the neutral tone of this report.

The Mechanisms of the Hack

I am attempting to demonstrate to every person who has basic knowledge of the computer that it is fairly easy for another employee at my company to accomplish these acts remotely:

  • Screen shot of my computer at work.
  • Take a video recording of my screen at work.
  • Take a video of me or anything else that is currently in front of my laptop with the built-in camera.
  • Make an audio recording from my laptop’s microphone.
  • Send timed key-stroke sequences to my computer as if I pressed those keys.
  • Send mouse movements to my computer as if I moved the mouse.
  • Interact with application on my screen as if they are sitting in front of my computer.

There are many over the counter software that facilitate this on a modern computer. If you do not believe me, go ahead and download these software and try them for free. You will need two computers on the same network to see how you can manipulate a remote computer.

  • On the Mac, Viola is an application that allow for recording of the screen.
  • On the Mac, Command-Shift-3, and Command-Shift-3 will result in a picture of the entire screen or a selected window, respectively to be saved to a file on the desktop. 
  • On Window machines, the [Print Screen] key and [Alt]-[Print Screen] will result in a picture of the the entire screen or a selected window, respectively, to be saved to a file.
  • On most OS’s VNC is a program that allows you to see and control a computer remotely.
  • On most OS’s Synergy is a program that allows you to control mouse or keyboard from a remote computer system.
  • On XWindow systems, XTEST from XAutomation package has a command called xte which produces key stroke and mouse movement ad specified time without a person actually moving the mouse or keyboard
All I wish to demonstrate in this blog entry is that you, any of you who knows how to open a browser window and read a blog entry, can go to these websites, download a program, and read another person’s email, send email as another person, or fake typo’s while he is typing.
Next time I or anybody else speak to you and say: “hey, you know? I think xyz at work has been spying on my email.” or “My work has been sabotaged by my cube-mate.” That you do not dismiss him as an escapee from an insane asylum.
This issue must be dealt with openly and rationally.

re-repigged

So, here’s the solution to the question in my previous post.

The most obvious way is to perform a partial aggregate and then merge the results.

A = group TABLE by (f1,f2,f3, ((long)(random()*100));
B = foreach A generate FLATTEN(group), SUM(f4) as sf4, MIN(f5) as mf5, MAX(f6) as mf6;
C = group B by (group::f1, group::f2, group::f3);
D = foreach C generate FLATTEN(group), SUM(f4) as sum_of_f4, MIN(mf5) as min_of_f5, MAX(mf6) as max_of_f6;

simple and effective. Does not require extra programming in java at all. This algorithm can be applied to all associative reducing functions. But associativity is not a necessary condition. The Algebraic functions in Pig actually allows for more general implementation where by an operation is divided into two stages. The first stage is required to produce tuples, which the second stage then processes.

You will probably never meet a problem that produces a bag larger than one compute node can handle. I mean I work for one of the fastest growing internet eCommerce servicing companies and our processing never even come close to seeing this problem.

But, in case in some distant future, when you encounter bags in computation that overflow one or even two compute nodes, and even at that time Pig/Hadoop still does not have a built in mechanism to deal with this automatically. So the above is an workaround.

Hope this helps you in your work or play when I’m long gone and dead.

Artificial Errors

Errors

Errors during human computer interface can take many forms. The most common one is the “typo”. A “typo” or typographic error is one where the intended word, phrase, expression, or command is issued into the computer with minor error such that it is not exactly what the user wanted to enter.

Most of the time, these errors are do not have grammatical meaning. But other times, the changing of one character could cause the entire sentence or program to change in meaning.

Typos can occur in many places. The names of files for instance often may be mistyped or miscapitalized.

Missing punctuations is another type of typo that causes a great deal of headache for programmers and writers alike.

Other changes include altering file structure within the folder hierarchy that is now the norm on computers.

The errors can roughly be categorized by size and effect.

1.) Deletion of a punctuation.

2.) Errors that are less than 3 character edits away from the original input.

3.) Whole word replacements. two words adjacent to each other being swapped.

4.) Scrambling meaning of entire sentence or programming blocks.

5.) Systematic changes: renaming a variable will make it difficult to detect other changes because it will have changed many lines and spacing.

6.) Rewrites: Rewriting an existing system that has the exact same requirements facilitates the introduction of malicious code. Since it is a rewrite, it will be difficult to detect subtle changes.

Effects include:

a.) Completely useless error: Does not cause any misunderstanding or program compilation or run time error.

b.) Immediately detectable: Compilation errors. Spelling mistakes detected by spell checkers. detection by inspection.

c.) Eventually detectable: Changing a “>” to “>=” will be detected during unit testing, for example. Changing “will” to “will not” in a feature spec.

d.) Malicious and difficult to detect. These are bugs that cannot be caught by normal unit testing, integration testing, code review, or editorial process.

e.) Malicious and impossible to detect. These are bugs that are introduced publicly as features. The reason behind its introduction is explained and may be widely scrutinized. However, the true intent of the feature is eventually materialized causing massive or specific systematic failure. After failure, the original person or group that caused this feature to be implemented will not be faulted for introducing the bug.

These forms of sabotage occur everyday. More often than not, they are detected and then dismissed as a true error, and silently corrected so that the fact of a natural error is hidden when in fact the error is not nature and the concealment of its existence has conceals its true cause and prevents true remedy.

Respond to my blog entry if you feel that you have been the target of an artificial bug insemination.

Let the truth out so that humanity can move on!!

Why do high tech companies employ internal facing hackers?

Why is it that American high tech companies intentionally employ and tolerate employees who’s job is to alter other employee’s work on the computer?
To be explicit, the effect of the employees who directly or indirectly through insertion of viruses on other employee’s computers so that their output into the computer, including emails, documents, programs, and any other production that theoretically belong to the company since it is produced and stored on company computer. The corruption range from simple typos to very serious bugs and errors introduced in vital files stored on the computers.
Mechanism:
Monitoring real time over the network and deliberately making changes to documents on the fly.
Changing data at the end of the day or during lunch hours or during mandatory company wide meetings
Changing data stored on servers.

Effect and Intent and Cause:
(inhibition of some people to work may lead to better overall success)

(producing paranoia in the workforce may lead to better overall productivity)
(giving a few people “god” power improves their productivity to “god” level)
(complete random errors/surprises promotes/stimulates the human brain to be more creative and less bored of really stupid shit)(cite paper about it)
(frustration, fatigue, desperation, paranoia, lethargy, hoplessness, indifference extended concern for self and family, hatred, and other psychological conditions produced by random errors causes, on average, better performance.)
/s/on average/best
…..
Systematic or individual racial discrimination
to maintain political control
to create reason to fire people. (one time… we had an employ who’s employment followed by files being removed from everyone’s computers. then he was let go with “not the skill set we were looking for.” What are the chances an african american who talks about playing beer pong at lunch has “the skill set” to wipe files off of my desktop???
 I’ve been wondering about this for a long time. I’ve hypothesized that
only management does this.
only people who can do this are part of management
This is done to preserve company secrecy
Personal gains: there are lots of unethical americans out there.
wide spread of psychological disorder: There may be a large number of computer employees who have developed psychological disorders from working on computers and highly competitive  environment. It may very well be that half of the people that I work with are psychopaths and would be deemed clinically insane. These people also exhibit signs of obsessive compulsive disorder. Their obsession with what other people are typing, and their compulsion to mess with it.
It could also be because the employers themselves are 
Maintaining control over the technical progress of the company: For one reason or another, it might be advantageous to executives of the company for some products to fail and others to be delayed. (set short development cycles, fail often, so they don’t have to give bonus. Greed is the virtue of Capitalism)
Why do high tech companies employ (or does not fire) people who spend their day introducing typos and intelligent errors into other peoples’ work?
Initially, I had thought that this is done with prejudice  (link), also I had once thought it was for personal gains (link), and I also hypothesized that it is a psychological problem developed from working in high tech companies (link) or a developmental problem in some people who grew up in environments that I cannot fathom (link). However, recently, I am beginning to realize that perhaps there is great wisdom behind the way these companies in the United States operate.
The United States is not a world dominant power house for no reason. There must be many things that are done intentionally on a macroscopic scale (through the setting of policies, directives, and guidelines), and also many microscopic actions that work in unison to create the synergy that is America.
Types of artificial error and intent
To be concrete, I am discussing two specific types of artificial errors that are created:
A.) typos. I type with very high rate of error at work. In important documents, this is especially problematic.
B.) Bugs. My programs will often contain a very difficult to find bug that results from a one-line change. one-liners are bigger than typo’s but small enough to evade a casual scan of the diff.
A.)
The frequent introduction of typos forces the writer to read what he wrote. My CEO here has once commented to us that he writes Emails without recipients so as to force himself to re-read the email before sending it. My problem with this explanation is that often the typo’s are introduced later on. For instance a wiki/confluence page at work will change, and there would bee obvious potatoes like this. Let us name these different typos for discussion sake.
A1) Typos introduced in realtime. These typos are introduced as I type so that if I send email immediately it would be sent out to servers that the typo-introducing-mechanism(man, software) will not have control over.
A2) Typos introduced during the development process, but maybe while the author is sleeping between multi-day writing projects.
A3) Typos introduced after the completion of a piece of writing. This is possibly why we find some really obvious typos in printed books. The editorial process is very thorough but still we often seen typos in large captions of graphs.
Typos are further categorizable into effects of the typo (without respect to the original intent)
T1) Completely random: if a z is added to wordz at random, its impact is minimal and largely forgettable. It does not affect the ability of the original writing to communicate.
T2) Not random, but not misleading: If a changes is made that may cause the reader to suspect the specific meaning of the sentence, then it belongs to this type
T3) Random or not, definitely misleading: This type of typo happens never. (obviously the word ‘never’ has replaced a word that conotes higher frequency)
My ultimate goal here is not to completely solve the mystery of America’s irrational success, however I hope to shed light on my lack of success and hopefully lead to increased quality of my own life.
A1T1-> probably a real mistake
A1T2-> malicious
A1T3-> malicious
A2T1-> possibly because a temporary episode author’s hallucination, but if it happens too often then definitely see a doctor. Also, regular backups and md5 hashes with comments might help to alleviate the author’s paranoia.
A2T2 -> Serious personality disorder, possibly multiple personality disorder (cite America Psychiatry Diagnostic Manual)
A2T3 -> If you have hashed prove and alibis (like an editor or code-reviewer), then investigate into computer security, otherwise call it A1 and shut up about it before you ruin your reputation.
A3T1 -> whatever
A3T2 -> Whoever did it, it could have been made worse, thank god he’s not experienced  and invest in more security systems.
A3T3 -> recall book/software; issue errata/point release, invest in more security system.
B.)…….
Ultimately, America continues to operate and recover from economic crisis, and companies IPO and life goes on–More so than many European and Asian countries…. How does these typos contribute to that?

What if you worked for Madoff

What would you do, if suddenly one day you stumble upon that extra floor in your office building where your company has been faking data all these years to create the appearance of profitability ?

The better question is, I suppose, how do I maintain my personal safety, my professional integrity, and my networth all at the same time?

Personal safety is important because often, your co-workers WILL HURT YOU if they think you are about to expose the company!

Professional integrity is important. This actually will give this whole blog it’s meaning. Because without professional integrity, it’s actually pretty easy to just keep an eye closed.

And finally maintaining networth will make this whole endeavour challenging. Because it’s very easy to just quit and not get the payoff. It is also easy to expose the company and not get any payoff.

So, what can a person do???

For my self, I want to actually start taking lawyer classes to learn the laws governing corporations and fraud. The Ponzi scheme apparently is illegal for reasons in addition to it’s structure: Fraud, Money laundaring, perjury, etc.

Each of these have specific meaning and is associated with actions. So by learning about the punishments for each count of illegality, I would be able to assess my risk and weighing the trade-offs.

For instance, would I be willing to trade 5% chance of 20 years in prison for a payoff of $10,000,000 in 5 years ?

Read that carefully: Ten Million Dollars for an expected prison time of 1 year (expected value)

For most people, the answer is no. But for some people, the answer might be yes…

map reduce is so repigged

okay, so here’s a problem I ran into today. In PigLatin, I needed to calculate the following:

A = group TABLE by (f1,f2,f3);
B = foreach A generate group, SUM(f4), MIN(f5), MAX(f6), (f7 is null)?1:0;

My problem is that for the data that I have (about 100gb) there are actually only about a dozzen combinations of (f1,f2,f3), so the consequence is that the execution crashes with the reducer running out of memory.

The question is, is it possible to make this calculation even with sparse keys?