January 18, 2016

AccessViolationException when using Font from PrivateFontCollection


You have used a PrivateFontCollection to get access to a Font and are using it when suddenly you get an AccessViolationException while using the font.


The PrivateFontCollection object has gone out of scope and has been disposed.  When the object goes out of scope, it seems to destroy any Font object that came from it.


Move the declaration of the PrivateFontCollection so that it stays in scope until you are done with all fonts that you are using from it.

December 10, 2015

Still Alive

I'm still alive.  The last six weeks have been an ordeal, but I'm still around.

I went back to work last Monday and have been working on finishing up Electric Eye since then.

I finally got Yvonne's certificate of death on Monday and am going through all the paperwork that has been waiting for that document to arrive, like her life insurance policy and some dealings with her attorney.

My granddaughter is coming out to visit on December 17 and will be here through Christmas.

Right now, I'm planning on starting posting and updating things again after the first of the year.

November 3, 2015

Yvonne Russell, 1952-2015

While I was at the office on Thursday, October 30, I got a panicked call from my wife telling me that she had lost her balance outside while putting up Halloween decorations, had fallen, had broken her wrist and that she was heading to the emergency room at Good Samaritan Hospital in Los Gatos.  I managed to get there quickly and spent six hours with her in the ER while a doctor reset an impacted radial fracture and applied a splint.

I had a rehearsal at work Friday for a tech talk I was going to be giving on November 5 and was going to be able to duck out afterwards to take care of my wife, so I made sure my wife was comfortable and went into the office.  My last words to her were, "Love you.  See you soon.  Rest."  It was the last time I saw her awake.

Shortly after my meeting, I got a call from my neighbor telling me to get home as quickly as possible.  She had found my wife collapsed on the front porch, and the fire department was there trying to revive her.  Nobody knows how long she was down for.  When I got home, two policemen met me and told me that she had been taken to El Camino Hospital in Los Gatos.

When I got to El Camino, it was a flurry of paperwork and disclosures before I was able to get back to the ER.  Everyone briefly panicked when I mentioned she was allergic to latex.  Turns out she had collapsed at home due to a heart attack, had been resuscitated at home, was rushed to the emergency room, and she had three more heart attacks in the ER.  I was escorted to the "meditation room" to wait for news, which was a small room with a box of tissue, no trash can, and a ton of religious pamphlets about prayers for loved ones you are going to lose in a variety of religions.  Hardly an optimistic moment.

They took my wife for a CT scan, then wheeled her over to the ICU.  They finally let me in around eight hours later.  They were sending her through hypothermia protocol, which has been shown to help people recover after a heart attack.

Once she completed the protocol, her heartrate was a bit high and slightly unstable, but she was holding her own blood pressure.  A respirator was helping her breathe.  There was hope that she'd be okay.  I was told to go home and get some sleep.  I needed to take care of myself.

On Sunday, I was told that the neurologist was holding off on an examination until Monday to give my wife a chance to wake on her own.  My wife looked like she was sleeping restfully for the first time in a long time.  Most nights, she woke up with horrible nightmares, or kicked me in her sleep in a desperate attempt to get away from the monsters that haunted her in her restless dreams, but she looked calm.

I work three blocks away from the hospital, so I told the doctors to call me if there was any change in her status since I could be there in fifteen minutes.  I went into work on Monday so I could work on Electric Eye since in my (less-than-restful) night's sleep the previous night, I had an insight about how to solve the last major roadblock in development.

I got a call at 11:30am from the neurologist.  I was told that my wife was still in a coma and fully reliant on the respirator for breathing.  They had tried to turn down the respirator, but her body wasn't responding or helping her breathe anymore.  Her eyes showed no response to light stimuli.  In the doctor's opinion, she suffered severe brain damage due to hypoxia.  An EEG was going to be scheduled for the same day to confirm the diagnosis.  My boss at Netflix was nice enough to let me go on leave through November to take care of what I needed to do.  I went over and waited by her side, but even though she wasn't under sedation, I didn't see REM sleep.  I didn't see nightmares.  I didn't see dreams, either.  I saw nothing.

During all of this, I was trying to keep friends and family updated via Facebook.  My son-in-law was covering for me on phones to give me some distance, which I appreciated.  It was hard enough to keep it together without dozens of family members bombarding my phone day in and day out.  I can talk to people I know about this kind of stuff easily enough, but every time Yvonne had dealt with her family, it usually ended in her getting upset and fighting over something trivial, so I never bothered trying to get close.

I was told to be at the hospital at 11am on Tuesday to meet with the neurologist.  I spent the remainder of the evening trying to keep it together by finding small projects around the house and working on them.  Fill the trash can.  Sort and start a load of laundry.  Click on this boss for 30 seconds in "Clicker Heroes."  Fold and put away the laundry.

Overnight, I kept flashing back to end-of-life discussions that I had with my wife.  Back during the Terry Schiavo debacle, we'd had a fairly lengthy discussion about her fears.  She told me that she didn't want to be kept alive by a machine.  To her, the thought of being dead but having her body remain around scared her beyond words.

In the end, both her EEG and a follow-up CT scan showed absolutely no brain activity.  Due to how organ donation works here, I won't have an official time of death for a bit, but she is gone.

So now I'm a widower.  It's an odd word.  It almost seems inappropriate.  A widow is a woman who has lost her husband.  A "widower" sounds like someone who creates widows...not someone who has lost their wife.  It's not exactly easy to say without sounding like you're butchering your pronunciation of "littler."  Regardless of my opinion of the word, it's the appropriate label at the moment.  It's a new label in my life, and it will take some time before it seems like it fits.

I may not have always gotten along with my wife.  I've lost track of the number of times when I told her that I loved her, but I hated the things that she did.  The past several years have been increasingly hard as her health regressed and her mood went with it, but even so, I loved her.  Now she's gone, and there's a twenty-year-plus void in my life that will never be filled or forgotten, but will hopefully, eventually, and mercifully be adapted to.

Farewell, Yvonne.  For someone who loved living life as if it was a roar, I'm sorry you had to go out with a whimper.

In lieu of cards or flowers, please make a donation to Doctors Without Borders.  Yvonne lived a full life due to excellent medical care by well-trained caregivers, and this is the surest way to ensure that others are able to do so as well who wouldn't be able to do so otherwise.

[Update 11/14: A Redditor pointed out that I typed 2013 instead of 2015 in the title of this post.  The title has been updated, but the old year remains in the permalink.]

October 5, 2015

No Internet At Home Makes Rom Something Something...

I just finished a weekend suffering from not only a bad case of food poisoning, but also little to no internet connectivity.  My internet connection went down Saturday afternoon, came back for a little bit Sunday evening, and it went down again this morning at around 12:20am.

It's very difficult to work at a streaming movie service and also suffer from an unstable internet connection.

Competition can't come to this area soon enough...

[Update: 10/5, 6:48pm] After a total of five hours of being on hold and being hung up on seven times, I finally got through to a customer service rep who had things fixed in a few minutes.  She proceeded to blame the modem that they assigned me for the problem.


September 22, 2015

Electric Eye - The Post Postmortem

If you haven't read the Netflix tech blog yet today, you might want to wander over there before reading this post.  Yep, the project I created and am acting as lead on at Netflix is called Electric Eye.

The project started ~6 months ago as a one-off experiment and has exploded beyond anything I thought could happen because the damned thing kept working even when I thought it wouldn't.  It has repeatedly triggered my Impostor Syndrome, making it ramp up to 11 from time to time, because while I had to test computer vision projects before, and had even written a few, I felt that I was at sub-novice level for most of what I've been doing.

I don't want to talk about the project in this post, though.  I would like to talk about why this post was written the way that it was.

First, you may be asking why there isn't any code yet.  Well, we've been working with legal on the code release.  Almost all of the code is going to be open sourced except perhaps one item that I can't talk about yet and some code to hook this into our backend for test reporting.  However, that will include my highly optimized frame transformation system, all of the CV and audio DSP helpers I've developed, and possibly ~25 full CV test cases.  There's still some refactoring and code cleanup to be done, but I'd expect a code release either late next spring or summer.

Second, you may be wondering why I link to libraries and, specifically, certain functions in the libraries.  This is actually a direct result of interactions with a former employer.  No, they didn't make me not release code.  They showed me that not every employer will let their test teams use open source unless the code is released under a BSD license or something even more lenient.  I intentionally wrote the post so that a tester in a restricted environment could find the information necessary to implement a variation on what I'm doing on their own.  After all, if I can tell you how to detect a pattern and transform the image to get you a testable frame, that's most of the challenge right there and if you do it on your own, your legal department will have no issues outside of vetting your library licenses.  If I give you the code to do it at the same time, then your legal department may freak out.

Finally, you may be wondering why the blog post is out before the code.  We're trying to hire some great SDETs and every candidate we've spoken with has been extremely excited by this project.  Showing off some cool testing tech is a great way to grow awareness of QA inside Netflix and does wonders to raise interest levels.  The sooner we get some great SDETs in here, the better.

We got the final logo (the blue eye) yesterday morning, but I've been pulling screenshots all through the development process.  The screenshots in the article range from 1-4 months old.

Well, back to work.  Who knows...we might end up doing an AMA somewhere about it.