All Things Techie With Huge, Unstructured, Intuitive Leaps

Digital Energy Drink for the Brain -- Opposite of Digital Marijuana


Most people get brain storms. I just get a little drizzle now and again, and I am lucky if it doesn't leave a brain stain in the nether regions. However, since we only use about 3 percent of our brains, I figured that I could experiment with some of the other 97 percent, so I went and filled my brain with binaural beats, which turned out to be a form of digital marijuana.  You can read about it here or scroll down a couple of blog posts: http://coderzen.blogspot.com/2015/01/how-to-stop-thinking-and-clear-your.html

Essentially binaural beats are sound processing artifacts created in the brain when you feed a different frequency in each ear, and the brain synthesizes a third which is the difference between the two, and then you get entrainment or synchronization between the brainwaves and the effect is like meditation.  It turns off compulsive thinking, or initially any kind of critical thinking and just lets you be.  That is why I called it digital marijuana.  If you want to read the full account, click the link above.

So the upshot of all of these experiments on my brain, is that today I wanted to see if classical music would have the same effect as the binaural beats.  If you recall, I went for a 4.5 mile walk when I was playing the binaural beats on my iPod.  So today, I went for the same walk, and instead of binaural beats, I had a classical music play list.

Well, the effect was absolutely just the opposite.  First of all, my walk takes me along a scenic road, and I experienced first hand, the digital enhancement of reality with classical music.  As my eyes took in the scenery, it was augmented by the beautiful music playing in my head.  I had seen people exercising, jogging, running, or skateboarding with earbuds, but never tried it myself before.  It is a natural high to be stimulated by music while being stimulated by enchanting scenery,

And when it came to thinking, particularly to creative thinking and idea generation, it was like an energy drink for my mind. As I walked, looked at the scenery and listened to the music, creative ideas surged through my brain in one wave after another.  It was like wow man. I got the idea of having a transistor for a silicon based artificial neuron (instead of a software multilayer perceptron), and the transistor bias would be the weight that determined if the logic fired.  I got an idea for a new app, that I can't disclose.  I hearkened back to my hardware engineering days, and I created mental schematics of how voltage multipliers would control transistor based logic circuits mixing analog and digital for discrete machine-learning functions.  It was wild.  I just let my mind gallop on, and it did.

After a couple of miles of walking, I decided to analyze the music that I was listening to.  It was mostly piano and violin with some energy to it.  A lot of classic music is polyphonic and stretches into "I am bummed" music that is a perfect for accompanying a suicide. Whereas when you get a guy like Mozart, he does have a light air and a playfulness about his melodies that is rich in genius.

So it was quite illuminating today.  For the curious, following is a fragment of the playlist that I heard today:


  • Vivaldi - 4th symphony in G major
  • Chopin - Etude 3 in E major
  • Cinema Paradiso - Yoyo Ma and Chris Botti
  • Mozart K622 Clarinet concerts - Adagio
  • Zipoli - Adagio for Oboe, Cello, Organ Strings
  • Mozart - Eine Kleine Nachtmusik
  • Mozart - K284 Piano Sonata in D major III Andante
  • Mozart - K330 Piano Sonata in C major II Andante
  • Mozart - Piano Sonata 11 in A major K331
  • Mozart - Piano Concerto 17 Part 1
  • Boccherini Cello Concerto
  • Boccherini Minuetto
  • Mozart - Concerto for Piano and Orchestra 4 in Gmajor
  • Mozart - Elvira Madigan Piano Concerto 21
  • Mozart - Wiengenlied
  • Toselli - Serenata Rimpianto
  • Mozart - Violin Sonata D major KV7
  • Schumann - Träumerei


So there you have it -- my Digital Energy Drink for the Brain. Head Bull if you will.  I will let you know what head techniques create fabulous revenue streams -- or maybe I won't.

However, the above works for me in a superb kind of way!

Big Data Retro Art


You don't see much Big Data art, so I decided to create some out of retro comic art. I then tweeted the above pic on my Twitter account and immediately it was favorited and re-tweeted even though it was in the middle of the Patriots/Ravens post-season play.  Enjoy!

How To Stop Thinking And Clear Your Mind - Is this digital marijuana?


I used to think the brain was the most important organ. Then I thought, look what’s telling me that.  However, I recently have been giving a lot of thought to brain health. My significant other is on a journey of quelling anxiety and finding peace of mind as well as enlightenment.  She is a creative type (taking pottery) as well as yoga, and that brought her to meditation.  Through her efforts, I have been introduced to mindfulness, meditation and quelling the constant flow of thoughts, ideas, compulsive and recurring themes, and worry.  (You should google mindfulness and meditation if you haven't already).

The yoga folks came up with the idea of meditation where you clear your head of all thoughts to give your brain a rest and rejuvenate yourself.  This is a lot tougher than you think.  I tried it, and let me tell you, the idea of thinking nothing or just one thing, is the toughest thing possible, although I hear that quitting heroin is really tough as well.  I have no intention of trying that drug to see if it is true or not.  However, I have read that meditation and mindfulness meditation has been certified by the medical profession as extremely good for brain health and balanced living.

I am not a good meditator. I was first introduced to it in the tropics.  When you live on an island for more than a few months, you have seen pretty much everything that there is to see and do.  So after reading the book "Eat, Pray, Love" and reading about ashram life, we decided to attend the ashram on the island across the harbor. Saffron-robed monks driving a boat, come to fetch you off a rat-infested dock with rotting hulks of ships moored to the wharf. Then they take you to an oasis of peace on a tropical isle.

When we arrived at the ashram, we took our shoes off, and went into the temple. It began to fill with the most beautiful women in flowing yoga prayer robes with lithe bodies and exquisite tans.  A yoga ashram tends to collect the most beautiful, lithe, nubile, athletic young women imaginable.  It is an array of feminine pulchritude of the finest kind.  My meditation lessons didn't go well, but I got a PhD in surreptitious gawking.

All this to say is that there is benefit to giving your mind a good cleansing. It pays to shut off the stream of consciousness, stifle the worry, and suppress the thoughts of strangling your loved ones.  I have tried meditating on a small bridge over a tinkling stream in the middle of the woods, or at the side of the ocean as the surf gently laps the beach. However I found that just being in those places obviates the need for mediation.  The real trick is to be able to do it in your basement.

So last week, I had a technical problem and I was getting nowhere with it.  After a day of struggling with the code, I decided to go for a walk to clear my mind.  I decided to do an experiment on myself. I was going to find a mechanism to clear my mind, and then as I was walking, I was going to concentrate on the problem and let the unconscious computer in my head come up with a solution while exercising.

I had been reading about entrainment and binaural beats, and how they were an aid to meditation by slowing down the brainstorms and constant barrage of thoughts in your head.  Binaural beats are auditory processing artifacts in your brain.  One frequency is fed into one ear, and a second frequency, a few cycles per second different from the first is fed into the other ear.  The brain clearly and distinctly manufactures a third frequency in your brain, that is the difference between the two.  It is a low frequency synthesis that causes entrainment.  What entrainment means, is that everything lines up with the third low frequency -- meaning all of the brain waves slow down.  At least that is the theory.

For my birthday, I got a massage as a gift at the local luxury hotel, and the therapist was exceptionally good.  I like getting the rub while naked with young women, because I am a man pig,  even though it is chaste and therapeutic. My therapist is right into all of the woo-woo stuff, and she told me that binaural beats are at first annoying but then your brain makes layers and layers of soothing stuff around the base frequency difference.  She hears rain and heartbeat and all sorts of harmonics.

So I put a binaural beats app onto my Android device, and off I went for a long walk to solve my problems.  This is the splash pic for the binaural beat app, and the URL from Amazon is:    http://www.amazon.com/gp/product/B00JLJFXNU



This particular binaural beat app is made for jogging. There are others for meditation, etc, etc. This one is over an hour long, so I figured that it would suit the long walk scenario.

Well, with the earbuds on and me walking down the road, I decided to go into the shtick of clearing my mind, purposefully stating the problem, and automagically coming up with the solution.  It didn't work out that way.

The stuff start playing in the earbuds, and as the massage therapist stated, soon I started hearing the complexities in my head. It wasn't exactly relaxing, but it wasn't anxious making.  It just was!  I walked a bit, and then decided that I better get down to the business of why I was on this walk -- to solve my problem.

Well Jumping Jimminy, the upshot of the whole deal, was that I was unable to think at all.  I could hold a thought for two seconds. I couldn't concentrate on my problem, and I didn't care.  I just couldn't think any sustained thoughts with this stuff playing in my ears.  And the good news was that I didn't care, because I couldn't generate the worry thoughts about not being able to think.

I suddenly realized that I was basically in a thoughtless state of just being. It was what meditation was supposed to be.  But that thought went away too.  I just walked.  I could hear my footsteps, but I soon lost interest in that sound. Shiny objects no longer had the same appeal and eye magnetism.  The constant diarrhea of thought in my head stopped.  I call it diarrhea, because I have a fertile imagination and farmers and others know what makes fields fertile.

I walked for about 4 and half miles.  About three quarters of the way in, I got used to the binaural beats, and I could start thinking coherent thoughts strung together, but still I wasn't emotionally reacting to them one way or another. And I simply couldn't think of my problem that I wanted to solve, because I didn't care anymore.

After I stopped feeding the binaural beats in my ears, the thought struck me that this would be a perfect way to stop worry.  This would be a great tool for those who didn't know how to stop thinking bad thoughts or negative thoughts. It was a great way to stop thinking too much.  Anxiety and worry disappeared.

I still used this for my walks.  However by and large, I enjoy my thoughts and where they take me, so I don't use it as a therapeutic tool.  Where it helps me, is to pass the time while exercising on my rowing machine.  But playing heavy metal music in my ear buds does the same thing.

Basically, what I think that I have discovered is digital marijuana.  Have a listen and stop thinking! When I looked at other binaural beat offerings on Amazon, there was one that caused brain orgasms or Autonomous Meridian Sensory Responses through Binaural Beats ( http://www.amazon.com/gp/product/B00IMGWMJQ ).  So not only do you have digital marijuana, but digital brain orgasms as well.  That takes care of sex and drugs -- and my iPod takes care of Rock 'n Roll!  I'm happy!

Synaptic Pruning in Artificial Neural Networks and Multilayer Perceptrons

What happens in a baby's mind is fascinating.  While the baby is sleeping, it processes all of the information that its senses took in, and puts in through a huge Mixmaster creating all sorts of connections to memory, storage, logic and emotions.  I love the way that Mother Nature plays dice.  The baby's brain makes synaptic connections between bits of data that are also inappropriate. This is hugely beneficial because once these connections are made, then the logic circuits can evaluate if they are sound and reflect the outside world.  A baby's brain multiplies in size 5 times until it reaches adulthood, largely from creation of synapses or links to neurons (plus other biological infrastructure functions).  This is why a child's imagination is so fertile.

Then we have synaptic pruning near the onset of puberty. ( http://en.wikipedia.org/wiki/Synaptic_pruning ). Once we start thinking about sex, we start pruning the synapses that we think are inappropriate.  The cartoon below gives a very simplistic diagram of pruning inappropriate synapses.  I use the word inappropriate in the sense of what is considered inappropriate by adults and keen rationalists or fairy-tale dogmatics.



How did I get onto this?  I saw a tweet by a hard-core religion fundamentalist who stated that neuroplasticity was the deity's way of fixing a brain.  (In that context, I think that he was implying neural re-wiring to fix apostasy, homosexuality, atheism, and everything else that he didn't approve of.)  I had heard of neuroplasticity but I googled it to ascertain the current scientific thinking of it.  Simply, neuroplasticity is the rewiring or creation of synapsis to take over functions of the brain that have been destroyed by trauma, injury and/or accident.  For example, it has been reported that brain function controlling say motor activity has been discovered in a portion of the brain not known for that activity in an accident victim.  The term synaptic pruning was in this article, and I had to investigate the term.

Once I googled it, it reminded me of the works of Dr. Stephen L. Thaler, PhD.  He has a raft of scientific discovery and patents, and he was an early adopter of artificial neural networks. ( http://imagination-engines.com/iei_founder.php ). In a nutshell, he did some work in Cognition, Consciousness and Creativity in artificial neural networks for which he holds patents.  He discovered that if you randomly destroyed neurons in a massive array of artificial neural networks, as the network was expiring, it came up with creative outputs or solutions.  As a result, he added another layer of neurals nets to observe this.  In essence by killing off neurons randomly, he was doing synaptic pruning of a sort.

Let me quote from Dr. Thaler's website:

After witnessing some really great ideas emerge from the near-death experience of artificial neural networks, Thaler decided to add additional nets to automatically observe and filter for any emerging brainstorms. From this network architecture was born the Creativity Machine (US Patent 5,659,666). Thaler has proposed such neural cascade as a canonical model of consciousness in which the former net manifests what can only be called a stream of consciousness while the second net develops an attitude about the cognitive turnover within the first net (i.e., the subjective feel of consciousness). In this theory, all aspects of both human and animal cognition are modeled in terms of confabulation generation. Thaler is therefore both the founder and architect of confabulation theory and the patent holder for all neural systems that contemplate, invent, and discover via such confabulations.


The idea then struck me, that perhaps it wasn't necessary to destroy the neuron in the network to achieve what Dr. Thaler saw, but rather just do the synaptic pruning, by randomly destroying inputs (and as a result their weights) in the hidden layers of multilayer perceptrons.

After the connection was destroyed, you would still run the AI machine including back propagation and see what comes out.  What a fascinating concept, and I am itching to try this once I find the time.

I am sure that all sorts of people might think that Dr. Thaler is a nutbar, but those were the same people who thought that Benoit Mandelbrot's ideas on fractal geometry were child's play with no practical applications.  Or we see how the works of the Rev. Thomas Bayes who is a relative unknown, publishing only two papers in his lifetime, and dying in 1761 postulated the important Bayesian inference used in Machine Learning.

So Artificial Neural Networks come and go in popularity in the computing field.  I am sure that Dr. Thaler is onto something, and for some strange reason, his theories may pan out to be seminal in the field of machine consciousness that way that Alan Turing's ideas became pivotal in this modern age of technology.  And somewhere in there, synaptic pruning will take place, and it just may not be a footnote in the development of artificial consciousness.

If you are looking for ideas for a master or doctoral thesis, you are welcome.





Chrome Canary - Wonderful but flawed - Just like me


(click on pic for larger image)

"He's dead, Jim!".  That's what Chrome Canary tells me every time I try to play a youtube video. Chrome Canary and Windows 7 doesn't let youtube work. You always get the purple screen of death saying that Chrome ran out of memory.

When you download Chrome ( from here: https://www.google.com/chrome/browser/canary.html ), the splash page warns you.  It says" Get the Bleeding Edge of the Web".  It says that this browser is not for the faint-hearted and it crashes regularly.

The splash page also says: "Google Chrome Canary has the newest of the new Chrome features.
Be forewarned: it's designed for developers and early adopters, and can sometimes break down completely."

So why did I get it? I am a developer among other things. When I develop Android, and I have an app with a web widget, often things like javascript breaks down.  These kind of web errors are often not reported in the Software Development Kit.  Only Java errors that throw exceptions are regularly recorded.  So when your app goes Islamic Terrorist Irrational on you, you can connect the USB cord to the Android device, type in chrome://inspect and click on devices, and you can get an idea of why you app has gone ape-crap or bat-crap crazy. A javascript console can be a very helpful thing.

Other features is that Chrome Canary is blazing fast.  In fact the only negative so far, is that it craps out with youtube and win7.  I am willing to bet though, that it doesn't crap out in a Chromebook.

Spam And Eggs, or .... Green Eggs and Spam


I get a lot of spam, because I publish my email address in various places. I get requests asking for money. I get a lot of requests from Africa, Nigeria, Burkino Faso, etc asking me for my banking information so they can transfer millions of dollars into my account. A whole bunch of Russians send me emails telling me that my penis is too small, and they have the pills to fix it. I get spam asking for money. I get spam asking me to support right wing and weird causes.  However, my latest bit of spam is a new one for me.  It is perhaps a sign of our brave new world.  I got spam asking me for eggs -- human, frozen eggs. Read it and weep:


I’m touching base as I consider my next steps in this journey to motherhood.  I have always wanted to be a mom.  I’ve had five pregnancy losses in the past 9 years, most recently through the failed IVF (in vitro fertilization) attempt in November.  I still carry this longing to be a mother and would like to try again. Statistically, my chances of carrying a pregnancy to term at my age, with my eggs, are virtually nil.  Roger and I are beginning to explore the possibility of donor eggs from someone under 35 as younger eggs greatly improve chances of pregnancy.

We are reaching out to people we know who may know someone with eggs or embryos already frozen and no longer needed or who may be interested in egg donation.  There is, unfortunately, no one we know in this position.  I’m wondering if there’s anyone you might know who might consider donating?

Roger and I are being supported by a wonderful fertility clinic in Montreal and feel confident in the caring and competent staff; donors will be well taken care of.

I recognize that this is a big request about personal matters.  Please let me know if any other information would be helpful.

Thank you

Just idly wondering if this could be considered human trafficking? There is a new Dr. Zeuss book on the horizon, "Green Eggs and Spam"?

The Worst Possible, Lamest Button To Have On Your Website


Back in the good old daze of the internet, when things were actually quite rotten, most users had slow-as-molasses dial-up connections. This is going back to the 1990's.  The brightest and best designs of the day optimized this with a splash page that told you what the internet site that you were visiting was all about.  If you still wanted to proceed to a content-rich site, you pressed the "Enter Site" button and waited ... and waited .... and waited. There was good reason why WWW stood for World Wide Wait.

Flash ahead to the present. We have tremendous internet speeds, even on mobile devices. The "Enter Site" button made its debut before phones had browsers.

So what does the "Enter Site" button tell you about a website? It tells you that the content manager or the chief web designer is a 50-something old fart who remembers that the coolest thing on the internet was a picture of a coffee pot in a UK university that refreshed every 15 minutes, and took forever to load.

Having an "Enter Site" button is the worst possible, lamest button to have on your site. It screams "Welcome to Fogeyville. Site last updated in 1998".

So, who still has this lame UIX button? I blurred the pic to make it unidentifiable, but I have changed my mind. It is the site for the Aviva Premiership Rugby and can be found at this URL:

http://www.premiershiprugby.com/

Maybe someday the Scrooges who run the joint will be able to attract some young interns who will refresh the site for free.

Alan Turing, Success & Failure, Truths Gleaned From The Film.


While watching the movie, "The Imitation Game"( http://www.imdb.com/title/tt2084970/ )  about Alan Turing and solving Enigma, breaking the German World War II codes, I became acutely aware of something.


  • Failure is an integral part of success!
  • Only by failing can we succeed.
  • Success requires a feedback loop from failure, and a learning step.
  • Success is a process.


And finally, success brings satisfaction, but rarely does it bring universal happiness.

What I learned from playing with Artificial Neural Nets and Multilayer Perceptrons


Anecdotal Observations about Artificial Neural Networks and Multilayer Perceptrons

I like experimenting. I have had a lot of fun of trying to embed knowledge in the thresholds of a massively parallel Artificial Neural Networks, specifically multi-layer perceptrons.  The field of artificial intelligence is a space where one can create magnificent experiments without the physical ramifications of things going very wrong very quickly, say in other experiments using high energy explosives, raw high voltage electricity or caustic, extremely fast exothermic reactions. Everything happens in the five pounds of laptop sitting on your knees without smoke, or blowing fuses or having to call the fire department.

  I created my own Java framework with each perceptron being its own object.  I am told that object oriented programming is the most advanced form of programming, and in my quest for a possible Nobel Prize, I have to use the most advanced tools available to me.  My perceptrons were connected by axon objects which held the outputs and fed them into the next hidden layer. It was intended to be a fine example of silicon mimicry of noggin topography.

I didn't do anything fancy with the activation function. Rather than a Heaviside function, even though I rather admire the works of the very eccentric Oliver Heaviside ( http://en.wikipedia.org/wiki/Oliver_Heaviside ).  He showed that the math involved in understanding Einstein's theories is less than complex in the mathematics of describing what happens inside an electric power cable.  But je digress.   I chose a sigmoid activation function and there are two common ones:



I chose tanh because for the back propagation, I knew that the differential of tanh was 1 - tanh^2 , and that would save me some time for coding the weight adjustments for back propagation.  I used the standard formula for corrections to the weight on the nodes which minimizes the error of the output given by the fancy schmancy looking equation that merely states the sum of all of the inputs multiplied by their weights, including a bias and bias weight:



The back propagation uses gradient descent and is given by, (hence the need to know the differential of the sigmoid function):

which again is a very smart-looking, complicated-looking equation that adds some real provenance of superior intelligence to this blog entry. Any kindergarten prodigy could understand the concept of the relationship of the local gradient to the differential of the activation or squashing function to get an approximation of the correct weights when the perceptron gives an answer as dumb as a doorpost, or an NFL player hit on the head one too many times.

So having said all of that, these are my observations about multi-layer perceptrons:

1) Bigger is not better

It takes a hell of a lot of training epochs to get a large number of hidden layers to move significantly to a more correct output. I start getting better approximations to the training set more quickly with less layers. I naively thought that the more, the merrier and much smarter.  Less layers get smarter quicker. There is a proviso though. Deep Layers, like Deep Throat does eventually give more satisfying results.  It gives a measure of accuracy in very complex inputs. However it takes a hell of a lot of training and spinning of silicon gears to get there. Moi - I am the impatient type who likes results quickly even though, like the smoked bloaters that I bought yesterday -- they are a bit off.

2) It pays to be explicit.  Since I was using a Sigmoid activation function, I figured that the hidden layers would act as some huge flip-flop or boolean gate array to magically come up with an answer with a minimum amount of neurons. By this I mean, suppose that you had a problem with three inputs and the hypothesis value of the outputs was also three. two, one or zero. Since the output neurons can be activated or not, the binary equivalent of a three possible output scenario can be represented by only two neurons (counting to three in binary goes like:  00,01, 10, 11).  I soon learned to be explicit. If you have three hypothetical output values, you should have three output neurons in the output layer to minimize training epochs.

3) It pays to be a wild and crazy guy. With eager anticipation, I fired up my newly made artificial intelligence machine, expecting a Frankenstein equivalent of Einstein to machine learn and do my tasks for me, and generally make me look brilliant.  I figured that I was on the verge of artificial genius to enhance my brain capacity, which I already figured to be roughly the size of a small planet. So when it came to setting weights and biases, I either went with the integer 1 or a random integer, and figured that the back propagation would clean up and get me to the appropriate figure.  Again, that would be the case if I had the patience to sit through a few million training epochs.  When my perceptrons had the intellectually ability of Popeye the Sailor Man, I was sorely tempted to give up, until I started doing crazy things with the initial weights. In one case, I got satisfaction by starting with a value of 10^-3.

4) It pays to initially log everything. I was getting fabulous results in early testing with minimal training. I figured that I was well on the way to creating my own silicon-based Watson that would reside on my laptop at my beck and call. However as the number of training epochs climbed, the weight correction stalled and the logs reported that the local gradient was NaN or not a number. Several WTF sessions resulted, and it took me through the travail of logging everything to discover that the phi equation where I was supposed to calculate the local gradient, had a mistake. I was squaring Math.tan instead of Math.tanh. It was disappointing to learn that a programming error initially added a lot of accuracy and amazement to my artificial intelligence machine, but as it progressed, it got dumber and dumber. I suppose that it's a good model for the intellectual capacity of a human being's Life journey, but that wasn't what I was aiming for.

5) One of the most difficult things using multi-layer perceptrons is framing the tool such that the functioning maps clearly to a hypothesis value with a minimal amount of jumping through loops and hoops and a pile of remedial programming. In other words, to make the thing do real life work (instead of constructing a piece of software that autonomously mimics an exclusive OR gate, as most tutorials in this field do) you have to design it such that real world inputs can be mapped into the morphology, topology and operating methodology of an artificial neural net, and the outputs can be mapped to significant hypothesis values.

In other words, a high school girl can code a functional multi-layer perceptron machine (and she has -- if you watch TED talks, she diagnoses cancer with it), however it takes a bit of real work to make it solve real life problems. But when you do, machine learning is one of the most sublime achievements of the human race. The machines achieve a level of logic that their carbon-based creators cannot.  And that is why Dr. Stephen Hawking says that Artificial Intelligence poses a threat to mankind.  I am not worried about the threat of artificial intelligence. I am more worried about the threat of a fanatic, with a bunch of explosives strapped to his chest. It is only logical, and it doesn't take very many training epochs to figure that one out.

Java java.io.NotSerializableException


I decided to get fancy with my multilayer perceptron, Artificial Intelligence machine that I build over the Christmas season. It was a classical design of artificial neurons, arranged in a layered perceptron pattern with weights and firing thresholds.  Instead of loading a bunch of arrays that were the nodes in the perceptron, I created objects. There were the neurons themselves, and the axons feeding the neurons.  I had the problem of saving the weights, and instead of writing all of it to a file, and having a massive IO operation, I decided to serialize the whole machine.  That way, I could resurrect the whole machine by de-serializing it.

I also thought that I was being smart by having a property change listener on the last input of each layer.  When the final input changed state, I would use the property change listener to fire the neuron.  It all worked like a charm, except when it came time to save the machine.  I kept getting a

java.io.NotSerializableException

It turned out that the PropertyChangeListener is not serializable.  I marked it transient, which means that it wasn't serialized, but I wasn't crazy about the whole machine not being serialized.

So, I coded out the property change listener.  All this to say, is that if you get this exception, you can mark the field transient, to not serialize it, or you can code out the parts that won't serialize.

Hope this helps someone.

Winston Churchill's Secrets And Lessons In Leadership


The internet is full of memes of how to be a leader.  Leadership is the new Eckankar, management philosophy, buzzword, transient movement, vehicle for consulting success, etc.  Stephen Covey started it, and people are milking it to this day.  I just got the entire lesson in leadership by looking at one photo.

I saw this candid picture of Winston Churchill emerging from bathing in the sea, and instantly I learned the secret and lessons of being a great leader. It can be summed up in one sentence:

"You don't need a big dick to be a great leader, you just have to be one!"

Event Logs, Process Mining and Artificial Intelligence


In my course on process mining from the Eindoven University of Technology in the Netherlands, on the course forum, a person asked about where to get events logs for process mining.  This was the question posted:

Anyhow, as I was watching the lecture on Guidelines for Event Logging, I was struck by the question that usually occurs to me in such courses: But how to do it in practice?

I'm assuming that logging for the Internet of Things is part of the Things that Make Up that Internet. But otherwise? I absolutely abhor having to program, never struck me as that interesting. So how is it done in practice? Do you guys have preset functions/libraries? In case a human needs to log their behaviour, how do you ensure compliance - that they don't forget etc. etc.?

I'd love to hear more on that!

I took it upon myself to reply, and this is what I said:

I am a technical architect (and Chief Technology Officer !) for an eCommerce platform that deals with high-dollar value goods marketed in exclusive circles. We have had the benefit of creating the technology so we created event logs for everything.  Here is an example:

1) When you log in, we record the time, the username, the IP address of where the login came and whether the user was using a desk computer or a mobile platform.

2) When you check your messages on our system, they are marked as read with a timestamp. That creates another event log.

3) When you go to view offerings, what you look at is recorded, so we can gather data on what the user likes to buy.

4) If the user is a seller, we record what he uploads into a database table, and every entry has a timestamp column to detect when the data was added.
5) Each sale is recorded along with a timestamp.

6) Each log out is recorded, along with a timestamp.  All of this is very easy to do, because when we create a database to store data, we construct it such that each entry (called a row) has a column labeled timestamp where the computer puts the NOW() date/time when the data is recorded.  This automagically creates the event logs for us, for all tasks, even tasks that are consided non-process related (which really add value to our processes).

When you are online, every time data is recorded, a timestamp goes along with it. We have event logs for everything.

But you can paper-based event logs that can be transcribed.  For example, we looked at an auto repair shop  and did a very rudimentary process mining when we were constructing a business app for the company. They took appointments and recorded the time of the call and the time the customer was going to bring the car into the shop. Then the service writer recorded the details on an invoice, service sheet when the customer arrived, and pushed the invoice into a time clock, stamping the arrival time. We then looked at the mechanic's time sheet to see what hours that he billed for the job. Then we know when the customer picked it up, because the payment invoice was timestamped (usually with the cash register receipt).  They had a complete event log on various bits of paper floating around the business, and once the business was computerized, they could determine the bottlenecks. (Which turned out to be waiting for ordered parts),  This was my first experience of events logs in a non-computerized fashion.  Since then, I timestamp every database table that I construct -- even the ones which store metadata and mined data such as standard deviation of an aggregate of characteristics of our top buyers and sellers.

There is now a burgeoning field of using non-sql graph databases (we like neo4j) which can map semantic and/or fuzzy relationships very easily, and this course has taught me to timestamp graphs and edges to monitor significant but transient process relationships in the business milieu.

Hopes this helps,

Most people do not realize how many internet tracks they leave that are event logs when they do ordinary things online. The Germans have a word for this. It is not a nice word. It translates to "digital slime".

Event logs are ubiquitous, and it is my contention that all of these digital tracks and Big Data will lead to a plethora of training data for artificial intelligence. Artificial neural nets need concrete examples to learn from and iterate and re-iterate to "get smart.  Process mining will be huge in that respect. Process mining is the first step for computers to learn human behavior. Neural net machines and multilayer perceptrons will pore over process maps gleaned from human behavior and learn to mimic and reproduce expert behavior in a very more and more repeatable fashion that humans can.

Impressed with Microsoft -- finally -- Azure




I, like a lot of other geeks, have become greatly disillusioned with Microsoft in the past several years. I saw them as anti-innovative, fat-cats protected a revenue stream that did not favors for its users, and becoming a stodgy, quaint grandparent in a tech world, where it thought that it was still the same sex object that it was in its early daze.

Microsoft, in my opinion has hung on too long to its archaic operating system which is essentially one big kludge onto top of a stack of turtles of kludges all the way down to the bare silicon. All of their innovations in almost every endeavor from tablets to phones, to music services,  have been market failures because they stubbornly resisted changes to their bloated, digital-cholesterol clogged operating system.  If they truly want to be innovative, they would ditch it in favor of a brand of QNX or Linux for a sleek, less vulnerable system.  Back in the early daze of the 8086 microprocessor, I saw a QNX system being able to boot from one floppy disk, and in its day, that was amazing.

Now that I got that off my chest, I must grudgingly admit that Microsoft has lit a spark that impresses me with their Azure big data suite.  If they are going to re-invent themselves and breathe new life back into the corporation and become innovative again, then Azure might be the vehicle.

Big Data is where it is at, and where it is going to be if we want to manage and monetize the Internet of Everything. And Microsoft Azure is trying to create and promulgate products to that end with Azure.  I only became aware of Azure when several members of the Azure team followed me on Twitter, and when I checked them out, I realized that it wasn't Bill Gates' Microsoft. I really liked what I saw.

Azure offers data analysis as a service, and they have a free component. It is done in a quasi-cloud environment, and from what I see, once you graduate from the newbie class, the prices is okay.  The good news is that there is a link to some pretty nifty free tools.  Here is the link:

https://datamarket.azure.com/browse?query=machine%20learning&price=free

The tools are varied, useful and intriguing.

Microsoft just may have a chance to dominate the market.  Their thin edge of the wedge with azure is great, but they must follow the template of Microsoft Word when it started to dominate the marketplace.  Back in the day, personal computers were useful, but not that useful when it came to creating documents electronically.  The IBM Selectric typewriter was the weapon of choice to use up reams of paper.  Then along came the word processor.  Dr. An Wang made a fortune from inventing computer memory, and then sunk his money into Wang Labs headquartered in Lowell Massachusetts. The Wang word processor became ubiquitous for several years. It was a dedicated piece of hardware, and tightly coupled software that didn't do anything else except create formatted documents.  Prior to that, electronic documents were printed on a dot matrix or impact printer without stylings.  (The Wang OS was the first OS that I successfully hacked).

Microsoft Word came out and essentially destroyed the word processor.  It was order of magnitude cheaper, easier to use and a mere fraction of the cost.  It is still the dominant document creator to this day.  Microsoft needs to do the same thing with Azure.

Right now, a lot of the Azure products use the statistical language R. Other plugins calculate linear regression, and all sorts of stuff like standard deviation, blah blah blah.  Microsoft needs to hide that under a big layer of abstraction and make all of that invisible to the end user. Picture the end user who runs a niche cafe in a hip town. Their Point-Of-Sale and computer system collects metrics, meta-data and machine data.  The owners of this data has no idea what this data can tell them or how they can increase their revenue streams.  They don't know Bayesian inference from degree of confidence.

Microsoft needs to build data analysis for the common person, like they built word processing for the common person.  If they do that, they will take their company into the next century. If not, they will be the biggest Edsel of the tech industry.  However, for the first time in a long time, I like what I am seeing come out of Microsoft.


I Love ACID


I love ACID.  In the database sense. To remind you what ACID means, here is an excerpt from Wikipedia:

ACID (Atomicity, Consistency, Isolation, Durability) is a set of properties that guarantee that database transactions are processed reliably.

Atomicity

Main article: Atomicity (database systems)
Atomicity requires that each transaction be "all or nothing": if one part of the transaction fails, the entire transaction fails, and the database state is left unchanged. An atomic system must guarantee atomicity in each and every situation, including power failures, errors, and crashes. To the outside world, a committed transaction appears (by its effects on the database) to be indivisible ("atomic"), and an aborted transaction does not happen.

Consistency

The consistency property ensures that any transaction will bring the database from one valid state to another. Any data written to the database must be valid according to all defined rules, including constraints, cascades, triggers, and any combination thereof. This does not guarantee correctness of the transaction in all ways the application programmer might have wanted (that is the responsibility of application-level code) but merely that any programming errors cannot result in the violation of any defined rules.

Isolation

The isolation property ensures that the concurrent execution of transactions result in a system state that would be obtained if transactions were executed serially, i.e. one after the other. Providing isolation is the main goal of concurrency control. Depending on concurrency control method, the effects of an incomplete transaction might not even be visible to another transaction.

Durability

Durability means that once a transaction has been committed, it will remain so, even in the event of power loss, crashes, or errors. In a relational database, for instance, once a group of SQL statements execute, the results need to be stored permanently (even if the database crashes immediately thereafter). To defend against power loss, transactions (or their effects) must be recorded in a non-volatile memory.

Why bring this up?  Recently I was playing with some feed-forward, backwards propagating Multi-Layer Perceptrons.  I love them because they allow machines to make decisions.  However the decision-making process is not ACID in the context above, if your artificial neural network composed of multi-layer perceptrons is in the continuous learn mode (each successive new bit of information is back propagated with a learning rate).

This may be good or bad, depending on the state of the fuzziness of what had to be decided by the machine, but wouldn't it be nice to have ACID in an artificial neural network?

Get your thinking caps on, and leave me some comments to inspire my imagination and perhaps create a whole new breed of technology.

The Death of the On / Off Switch


I was talking to a colleague of mine and we were discussing, of all things, Bugs Bunny cartoons. In a couple of cartoons, Bugs is in a cabin with Yosemite Sam, and in one instance, there is an old style nickel plated wood stove and in another instance, there is a pot belly stove.  If you don't know what a pot belly stove looks like, here is one:

The conversation revolved around how Bugs Bunny is still popular with today's kids, and yet it was first created in 1940.  My colleague idly wondered if the kids of today know what a pot belly stove was, how it was used and what it was for.  If you are a certain age, and are a grandparent, you may remember them from cabins or cottages, but I doubt that anyone younger than 40 years old has seen one.  So the question is, can the kids of today relate to the cultural load of the concept of a pot belly stove?

The reason that I bring this up, is because the On / Off switch is going the way of the pot belly stove.  Back in the good old, primitive days, an On / Off switch was fairly mechanical. It consisted of a toggle and two contacts separated by a space. When you flipped the switch, the juice flowed and when you turned it off, the contact was broken and the current stopped flowing.

This concept carried on for a long time.  But the On / Off switch is going the way of the dodo bird. Back in the day BR (before remote), you walked over to a TV and pulled a switch to turn it on. The earliest desktop computers had a toggle switch somewhere on the side. A switch was a simple  concept to learn.  Not so any more.

Televisions for example, do not go dead when you switch them off. They have a quiescent circuit just listening for a remote signal. To turn on my iPad, you press a button and to make it work, you do a swipe on the face of it.  On my car, I no longer have to turn on headlights. When it gets dark, they turn on themselves.

With Moore's Law, where transistors are getting smaller and smaller, and smarts are built into everything, the On / Off switch is dying.  Devices will have sensors that will detect when power is needed to the main circuits and they will switch them from solid state switches or transistors. Vacuum cleaners will have motion sensors, and they will know when to turn on the sucking mechanism.  The list goes on and on. New cars detect when a key is in the pocket of the driver and you push a button. No more mechanical linkages.  I am reminded of an 80-some year old man who won an iPod at a church bazaar and didn't know what it was.  He had no inkling that it could be turned on and something so small could play music.

So one day in the future, a child will see some sort of image on an On /Off switch and wonder what it is for and why it was needed.  They will be flummoxed by it.  It's a Brave New World that is coming.  Me -- I say "Bring it on!"