Thursday, November 17, 2011

The social graph is...

"...neither social nor a graph..."

...provided you redefine the words "social" and "graph" to mean something other than what they mean to everyone else.

M. Ceglowski is just being deliberately obtuse, or more precisely he is taking a wild excess of rhetorical license in order to make his statements seem more profound and unconventional. For example, he writes:

We nerds love graphs because they are easy to represent in a computer and there is a vast literature on how to do useful things with them. . . . In order to model something as a graph, you have to have a clear definition of what its nodes and edges represent.

Well, that's actually bullshit. In a dynamic Bayesian network, you don't have a complete definition a priori of what nodes and edges represent. Well, you do, in that the nodes represent variables and the edges represent relationships between those variables, but the weights on the edges are learned statistically from data. An edge may represent a meaningful connection, or it may mean nothing at all. The graph precedes semantics, not vice versa. Likewise with the social graph. People are connected, and you don't necessarily know what each connection means. But it's still a graph.

The labels on the social graph's edges may be subtler and more multidimensional than the simple weights you put on Bayesian network edges. And we don't have a good handle on how to learn those labels, or even what the labels should be. However, calling for the abandonment of a useful mathematical construction in an emerging field of science because it's incomplete is something that you do when you want to convince people that you're smarter than the people working in that field. It's not something you do when you want people to become better-informed.

Ceglowski also writes that the social graph is "not social" because... well, actually, I have trouble even locating a coherent argument in that part of the essay. He seems to be confusing "social" with "sociable". The social graph is social, since it describes relationships between people. Perhaps some activity involved in digitally reifying the social graph is anti-social (Note that anti-social is not the opposite of social — anti-social behaviors are social behaviors!). But that doesn't make the social graph "not social". By that standard, sociology is not a social science because sociologists spend a lot of time by themselves in libraries.

Incidentally social scientists have been modeling social connections as graphs for decades.

Here is a short list of the valid points Ceglowski makes:

  1. FOAF relationship labels are kind of dumb and embarrassing.
  2. Manually maintaining anything other than a very coarse-grained digital reification of a social graph is a tedious chore.
  3. Making your social network and behavior the property of a company whose revenue model is not aligned with your long-term interests is a bad idea.

And here is a short list of other, non-terminological points that Ceglowski just gets wrong:

  1. Social networks do "[g]ive people something cool to do and a way to talk to each other". It turns out that sharing photos, videos, and links is one of the most broadly appealing online activities, and social networking sites seem to do this better (along some dimensions) than dedicated photo-, video-, and link-sharing sites.
  2. Judging communities by the outward-facing cultural artifacts they produce is a radically inadequate measure of value. The vast majority of communication is point-to-point, not broadcast, and the vast majority of interpersonal interactions are social grooming. Social grooming is a deep-seated primate instinct which nerds devalue at their peril. Social networks have made online social grooming far easier than their predecessors did.
  3. People on WoW, Eve Online, and 4chan have healthier social lives than people on Facebook? Really?

Note that I write all the above as someone who dislikes Facebook and is skeptical of reductive approaches to modeling social relationships. And I've been advocating* an end to proprietary social networks for years — long before I started working at Google, and in fact before Facebook was even the predominant social network. So I'm broadly sympathetic to Ceglowski's aims. But I don't like at all the way that he goes about explaining them.


*Incidentally, rereading this old post, I realize that I completely missed the possibility that the dominant social network site would simply become a huge platform for third-party applications. I guess it never occurred to me that serious companies would bet their livelihoods on being sharecroppers in the walled garden. Go figure. I could speculate that this willingness can be traced directly to the Valley vogue for building companies to flip rather than to create sustainable, decades-long sources of enduring value — if you're just holding on until your "liquidity event" then it doesn't matter that your business is built on the fickle forbearance of your platform landlord — but I'm not sure how right that is.

Monday, October 31, 2011

Occupy .* and the Iraq War

Then, as now, conservative opinion and elite bipartisan opinion was mostly contemptuous of the protesters. Well-fed, well-educated, well-salaried pundits looked on the shaggy protesters and remarked: how unsophisticated were the protesters' opinions, how disorganized their complaints! Fortunately, the nation was run by a select few who understood the harsh realities of a world where some suffering was necessary (for other people) so that the existing order could be maintained. And the march to war rolled on.

In all likelihood, the protests today will be as futile as those were. It's taken a couple hundred years, but the system of governance by elected representatives has evolved an immune system with nearly impervious defenses against street protests. Nevertheless in a society supported by the many and operated for the few, it is perhaps useful, for aesthetic reasons if nothing else, to have some people calling attention to that fact. If you, as a critic, imagine yourself on the side of the angels in damning the protesters, then you should perhaps reconsider.

Thursday, October 13, 2011

Cynicism and libertarian ends (again)

Why M. Yglesias is a nationally acclaimed writer and I am not, exhibit #7572: a couple of years ago I wrote a somewhat convoluted post about cynicism and libertarianism, whereas today Yglesias wrote this which is elegant, readable, and much more worth your time.

Wednesday, August 03, 2011

g++ unordered_multimap: an exercise

I discovered this randomly several weeks ago while debugging something else at work, and I thought it was worth sharing since the g++ STL is widely used.

Step 1: Save the following file as mapdemo.cpp:

#include <iostream>
#include <unordered_map>

int main() {
    typedef std::unordered_multimap<int, int> int_multimap;
    int_multimap map;
    for (int i = 0; i < 10000; ++i) {
        map.insert(int_multimap::value_type(17, i));
    }
    std::cerr << *static_cast<int*>(0);
    return 0;
}

Step 2: Compile the file:

g++ --std=c++0x -g mapdemo.cpp

Step 3: Load the file in gdb and examine the buckets:

$ gdb -silent ./a.out
Reading symbols from xxx/a.out...done.
(gdb) run
Starting program: xxx/a.out 

Program received signal SIGSEGV, Segmentation fault.
0x0000000000400b4d in main () at mapdemo.cpp:10
10     std::cerr << *static_cast<int*>(0);
(gdb) p map._M_bucket_count
$1 = 15173
(gdb) p map._M_buckets[0]
$2 = (std::__detail::_Hash_node<std::pair<int const, int>, false> *) 0x0
(gdb) p map._M_buckets[15172]
$3 = (std::__detail::_Hash_node<std::pair<int const, int>, false> *) 0x0
(gdb) p map._M_buckets[17]
$4 = (std::__detail::_Hash_node<std::pair<int const, int>, false> *) 0x605080
(gdb) p *map._M_buckets[17]
$5 = {_M_v = {first = 17, second = 0}, _M_next = 0x670c90}

Yes, g++'s implementation of unordered_multimap (known as hash_multimap in pre-C++0x versions of C++) uses bucket hashing, but the size of the backing array is proportional to the count of elements in the multimap, not the count of distinct keys.

Exercise for the reader: Explain what I just did; explain why the result of step 3 is curious; and then explain why the authors might have chosen to do it this way anyway.

It occurs to me that this would have made a decent interview question if I hadn't written it up here. Oh well, I have others.

Monday, August 01, 2011

Acer Aspire TimelineX 1830T semi-review

Attention conservation notice: Google-food for a gadget you will probably never need to know about.

I recently bought an Acer 1830T ultra-compact notebook (11.6" screen, 3.1 lbs, Core i5 470UM, ~$540 street price). I have neither the time nor (yet) the data to review it comprehensively, but here are a few observations that I didn't find in other online reviews, with a focus on the physical design. This review is intended to complement other information online, not replace it, and is offered in the hope that it's useful to other people who may be in the market for a very small laptop.

Size

You can read on the spec sheet that the laptop is 285 x 204 x 28 mm (11.22 x 8.03 x 1.1 inches) at its widest point, but that doesn't give you a visceral feel for its size. Here it is next to a few objects with which you may be familiar.

Counterclockwise from upper left: Kindle 2G, 12oz. Diet Coke, Nexus S, $1 Federal Reserve Note, 15" Macbook Pro (unibody), and TimelineX 1830T. You can see that it's quite small. It feels qualitatively similar in the hand to other ultra-compact notebooks I've handled, such as smaller Lenovo X series laptops, although it's not nearly as blade-thin as a Macbook Air. Below are a couple of detail on-edge shots to illustrate the device thickness.

The top shot is the same 15" Macbook Pro and Kindle stacked next to the TimelineX 1830T, with the other props on the edges. The bottom shot is the Macbook Pro alone next to the 1830T. Subjectively, I will say that its small size and light weight make it feel thinner than it is. I'll toss this in my bag as a second laptop without hesitation.

Input devices

The keyboard is OK but not stellar. Here it is, compared to the Macbook Pro keyboard, using my left hand as a reference object:

You'll notice that it's marginally smaller — and for me, this is enough that it does subjectively feel more cramped — but it's much closer than I would have expected, and about as good as I'd expect from a machine this size. It's not a Lenovo keyboard but then nothing is.

The trackpad is quite small and almost invisible, marked only by three fine raised lines on the palmrest's metal surface:

Overall the small size of the palmrest and trackpad are the biggest ergonomic shortcomings of this device. I've concluded that they shrunk the palmrest to make room for the (huge) battery on the top side of the keyboard. After a brief acclimation period, I find the trackpad acceptable for casual use, but I expect I'll still carry around a mouse when I want to do serious work.

Power adapter

The TimelineX has an interesting power adapter. First, here is a size illustration.

Counterclockwise from upper left: Nexus S, Macbook Pro power adapter, TimelineX 1830T power adapter, 12oz. Diet Coke, and $1 bill. Note that the adapter is closer in size and weight to a cell phone power adapter than a traditional laptop power adapter. Furthermore the plug prongs are detachable:

Cleverly, the prongs can be attached in either orientation:

Obviously this is useful for power strips or other situations where the area around the cord might be crowded. Most laptops deal with this problem by attaching the plug head via a separate cord, but I would like to see this design become more widespread for cell-phone-style power adapters. Rotating the prongs is a simple 10-second operation:

video

Miscellany

A few other brief observations:

  • 1080p video plays perfectly fine, either downsampled on the native 1366x768 screen or at full resolution on an external 1080p television via HDMI.
  • 64-bit Ubuntu Maverick (10.10) under VMWare Player works adequately for casual coding. I have not yet set up dual-boot and perhaps I won't need to.
  • Suspend from resume is quite quick in Windows; a full boot is slow but rare.
  • The battery is huge; the screen is small; the CPU is an ultra-low-voltage Core i5. The net result is that battery life goes all day for practical purposes, and this is the rare laptop that I will not bother to plug in during use most of the time.

Finally, here's a close-up shot of the laptop cover, which has a nice, grippy embossed cross-hatched texture.


p.s. Incidentally, having shopped for a laptop recently, I have to say that typical review sites do not pay nearly enough attention to laptops as physical objects. The physical reality of the laptop is one of its most crucial characteristics; it's not like a workstation which you just leave under your desk and hook up to the keyboard, mouse, and monitor of your choice. People who do this for a living should be able to provide more useful and objective information than "it feels light". Also, laptop review sites overall strike me as quite lazy. Why would you show useless white-background product shots from the PR kit, when digital cameras are so ubiquitous, and it's trivial to take your own much more useful photos, as this blog post shows? Grrr.

Saturday, July 02, 2011

Two white dresses

Striking juxtaposition (intentional?) on the CNN International home page just now:

One woman is the subject of the photo, and you see her eyes looking fearlessly at her vanquished opponent. Furthermore, she is important for having excelled in a worldwide competition of objective achievement. The other is a secondary subject, her eyes invisible but her gaze clearly directed at the primary subject of the photo, a man — whom, I suppose, she has also conquered, in a sense, although her fellow competitors for the prize are (as in the first photo) outside the frame. Furthermore she is newsworthy only because her new husband happens to be of royal birth. Wittstock is of course more conventionally beautiful than Kvitova as well.

I won't claim that sports are categorically more important than weddings of ceremonial heads of state, but someday I'd hope that the positions of these images would be reversed.

(Posted from lounge in BGI airport while waiting for a flight.)

Sunday, April 03, 2011

Tree structure and comment threads (a brief observation)

It has been claimed that flat, linear presentation of comments appears to work better for humans than tree-structured comment threads. Without getting too deeply into whether this is true (and if so, why), I would like to offer an observation.

Conversation is never a tree; it is a general directed acyclic graph. In reality, in the commenter's mind, every comment potentially implicitly responds to an arbitrary subset of preceding comments, not to a unique parent and its chain of unique transitive ancestors.

Tree-structured threading — sometimes (erroneously!) called "true threading" — artificially imposes a tree structure on this graph. Flat, linear comment systems do not: each comment appears after all those that precede it topologically in the DAG, and it is up to the reader to reassemble the DAG based on the comments' contents.

It is true, of course, that flat comment systems fail to reify all DAG edges as explicit metadata. However, the nature of these edges is quite subtle and capturing them all explicitly is intractable. Often a comment "responds" to previous comments in indirect ways — for example, simply by omitting some aspect of the argument that has been covered by a previous comment.

(Prompted by a TC article linked off HN.)

Sunday, March 27, 2011

Ubuntu has not solved the agency problem in community software development for the Linux desktop

Four and a half years ago, I wrote:

In an open source project with a dictatorial or committee-led governance structure, somebody would long ago have cracked some heads and gotten this feature implemented. In a commercial software project, open source or non-, some engineer would be assigned ownership of this feature; and goddammit, if that feature didn't get implemented and maintained, that engineer would be fired and the feature would be assigned to someone else. But KDE's headless. It's less like a mammal with a central nervous system than an enormous amoeba whose various pseudopodia ooze tropically in the direction of "developer itches" and "coolest implementation hacks" (hence the recent proliferation of "hugely ambitious infrastructure refactoring" subprojects like Plasma or Solid) rather than unsexy, annoying-to-implement features that merely provide value to end users.

I genuinely thought Ubuntu had a fighting chance of resolving this agency problem. Surely with a dictator taking responsibility for the entire desktop stack, there would be progress. When there's a bad corner of usability for a common user task, somebody will crack some heads and get it fixed.

Today, I tried to share a file over my local network between my Ubuntu desktop and my Ubuntu laptop. And I ran into this defect which has been open for a year. In the year 2011, the easiest way to copy a file from one Linux computer on your local network to another Linux computer on your local network is still either (a) copy it onto a USB stick or (b) upload it to the Internet (e.g. by attaching it to a draft Gmail message).

Meanwhile, Ubuntu's burning huge numbers of developer and UI designer cycles on stuff like Unity ("We're too impatient to fix the rough edges in our existing desktop which has a decade of developer investment behind it; therefore we will design a brand new desktop, because there definitely won't be any rough edges in that.").

It turns out that, in fact, Ubuntu has not solved the agency problem in Linux desktop software development. Sigh.