Category: Uncategorized
-
Blog migration and self-hosting retrospective
Avid readers of my blog (which I like to pretend are out there somewhere) will notice that the theme has changed. This is because I migrated my blog from self-hosted WordPress to the hosted wordpress.com service and the theme was not available. The process left me with some thoughts about WordPress and self-hosting. Background I…
-
Amazon disallows pointing out paid reviews
I recently bought a webcam from Amazon (late to the party, I know), and when it came it was fine but not amazing. When I went through the packaging I saw a little card saying “send us a screenshot of your 5-star review and we’ll give you a $10 Amazon gift card”: I thought that…
-
Update on NumPy acceleration
I’ve been looking into accelerating NumPy using TensorFlow, and the results have been pretty interesting. Here’s a quick update. tldr: TensorFlow adds a lot of overhead and doesn’t speed up CPU execution, making converting NumPy->TensorFlow less promising. TensorFlow’s ability to target GPUs, though, makes up for the overheads, but not all NumPy programs are GPU-friendly.…
-
Monitor crashes
I’ve gotten a new problem in my life: my monitor has started crashing. To be fair, the steps that cause it are fairly esoteric (using the USB ports, then switch the video input), but the failure mode is pretty remarkable: the monitor becomes completely unresponsive. As in, I can’t switch the video mode again. And…
-
Persuasiveness and selection bias
I happened to be watching the Oscars last night, and I was pretty shocked to see the mistake with the Best Picture award. Thinking back on it, this is a bit surprising to me: many things are happening that should be more “shocking” (all the craziness in Washington) but don’t seem to affect me the…
-
NumPy to Theano / TensorFlow: Yea or Nay?
Hey all, I’m investigating an idea and it’s gotten to the point that I’d like to solicit feedback. The idea is to use Theano or TensorFlow to accelerate existing NumPy programs. The technical challenges here are pretty daunting, but I feel like I have a decent understanding of its feasibility (I have a prototype that…
-
Amazon-Walmart arbitrage
I recently ordered some junk food from Amazon, despite my wife’s objections. I ordered it from an Amazon Market (aka third party) seller since that was the choice picked by Amazon for one-click ordering. The food arrived, and the interesting thing is that it arrived in a Walmart box, with a Walmart packing slip. Evidently,…
-
What does this print, #2
I meant to post more of these, but here’s one for fun: class A(object): def __eq__(self, rhs): return True class B(object): def __eq__(self, rhs): return False print A() in [B()] print B() in [A()] Maybe not quite as surprising once you see the results and think about it, but getting this wrong was the source…
-
Stack vs Register bytecodes for Python
There seems to be a consensus that register bytecodes are superior to stack bytecodes. I don’t quite know how to cite “common knowledge”, but doing a google search for “Python register VM” or “stack vs register vm” supports the fact that many people believe this. There was a comment on this blog to this effect as well.…
-
Benchmarking: minimum vs average
I’ve seen this question come up a couple times, most recently on the python-dev mailing list. When you want to benchmark something, you naturally want to run the workload multiple times. But what is the best way to aggregate the multiple measurements? The two common ways are to take the minimum of them, and to…