Archive for the ‘Uncategorized’ Category

Get kiva.org credit from MTV

February 1, 2009

MTV gives away $25 gift certificates for lending on kiva.org (you’ll need to register)

Advertisements

Panoramic photos revisited

April 21, 2008

Every some time there’s a place that would look great on a panoramic picture but I only have a plain touristic camera with me and decide to take a series of photos in all directions from one point with a plan to later glue them together to get something real. Then I forget it completely or sometimes I load Gimp and glue the pictures together. This can take an hour or two and gets boring, but the result is often ok (digital example, analog camera example). This time I decided to try to get my PC to do the gluing for me and use one of the tools that appeared in gentoo’s portage tree. This didn’t go faster than I would have done it manually (perhaps five x longer) but knowing about all the quirks, it may actually go faster next time, and the result is comparable with manual stitching. So let me just write down the things I wish I had known when I started. The package that is now in most distro’s repositories and that I used, is libpano12 and various tools associated with it.

First part is selecting the individual pictures and telling the computer how they are oriented in relation to each other so it knows how to glue them. Hugin (a GUI frontend for libpano) lets you select the shots and input the data necessary for libpano to make sense of the individual pictures, which is a list of common points on the overlapping parts of the photos. This part quite intuitive. Remember to build the latest hugin and latest wxGTK or hugin will segfault. Before loading pictures into hugin rotate them in Gimp to be at least more or less straight (if they aren’t). Have 2GB of free disc space. Choose one of the rectangular projection types because the fancy ones are not supported by the other tools we’ll need to use. The picking of common points can be done automatically by autopano-sift but this has mono and other heavy packages as dependencies so I avoided it. When you’re done placing the points and playing with all the other parameters in hugin, hugin will want to generate a script for the stitching program that will do the heavy work. Hugin knows about two such programs: PTstitcher (part of panotools) which sucks because it’s closed-source and only works on one arch. The second one is nona which sucks because it doesn’t support most of the format, projections, blending, auto adjusting. So we will choose “multiple TIFF” as the output format, set all the other parameters, save the project, tell hugin to generate the script to a text file and quit hugin. Now we have one other program to do the stitching: PTmender, an opensource replacement for PTstitcher, also part of panotools – this one supports the formats we want and some automatic colour balance / exposure correction but if you choose any of the plain bitmap output formats, it won’t blend them nicely together because it’s not supported yet. If you in turn want a format with the individual pieces on separate layers (XCF not supported yet, so PSD) to do the merging in Gimp, PTmender will segfault in some doubly-linked-list code. So we choose the “multiple TIFF” output format and get TIFFs that are ready to merge except they don’t have any transparency mask set. We could now use Gimp’s “alpha to selection” and “feather selection”, but there’s a program, enblend, that will do just this merging, and does it really well (using multi-resolution splines). It only operates on TIFFs, and seems to get all the parameters right if you don’t give any.

You may need to repeat some part of the process if you see something really bad in the enblend output, and if not then you just need to load it in Gimp and rotate / crop / scale the picture. To load TIFFs in Gimp you may need to rebuild with USE=”tiff” if you’re on Gentoo.

I could’ve written a novel with all the keystrokes

April 18, 2008

In other words if you printed all the vim commands I typed, on Earth’s equator in 15pt font, you would get a very repetitive string printed on Earth’s equator line (which could no way be seen from outer space).

$ history | awk '{a[$2]++ } END{for(i in a){print a[i] " " i}}' | sort -rn | head
2673 vim
1475 cd
694 screen
632 make
475 man
329 ls
261 grep
231 cg-diff
161 aoss
149 cg-patch

The numbers sum to > 1000 because I use HISTSIZE=”10000″ and HISTCONTROL=”ignoredups” in my bashrc.

Need more freedom, more freedom!

March 25, 2008

After some discussion it was agreed that the freedoms guaranteed by free / open-source software were no freedom at all and that we need to add more freedoms.  The proposed fifth freedom is the freedom of choosing the implementation you want to use.  To spread the idea the Multi-source Software Foundation is hereby established, MSS being the proposed short-hand for the body of software that comes with more than one source representations of the program, letting you choose the source you wanna compile.  Among our flagship projects are such fundamental programs as hello world, pacman, tetris, netcat.

Nomadic C162

February 11, 2008

…is a regular smartphone (don’t confuse with Nomadik). I’m only posting about it because I found completely no information about it on the intarwebs when trying to answer the simple question of whether Linux could be ported to it, so that if anybody else wants its specs they don’t have to take the device apart anymore. I got one such phone this week and today disassembled it and collected the list of chips it features, complete with pictures. All chips on the PCB have metal covers on them, some of the covers have to be ripped out by force. There’s nothing special about the phone except that it’s a CDMA phone (uses the CDMA2000 standard in the 850MHz range) and that local calls are free, but the network only exists in Warsaw, outside this area it becomes an mp3 player/camera with four hours running time (in constant use, so not terribly bad). The manufacturer of the C162 is a Chinese company called TechFaith. They have several similar models on their website but no mention of C162 or C161c in particular. The Polish operator Sferia seems to be the only operator using these models. Here’s the obligatory generic diagram of the OS structure of TechFaith devices.

The specs I collected are in this text file. I uploaded some pictures of the C162 intestines here, together with some pics of my new GTA02.

GTA02 WLAN card from AtherosThe answer to my original question seems to be that the C162 can’t run Linux because the CPU is from the MSM6k series by Qualcomm which features ARM7TDMI cores (i.e. no mmu), so the best you can get is uClinux, but then it seems Qualcomm doesn’t make the documentation accessible. There exists a working kernel tree for the MSM7k series maintained by the Google Android project, probably some drivers would be reusable.

At OH-plex

December 22, 2007

The Christmas arrived at OpenedHand a week ago, in form of a Millenium Falcon, and on that occasion we had some (traditional British) fun together. This was my first chance to see the famous OH-plex live, the place where the ideas hatch for the near and far future of open-source mobile computing. The interior is full of things you’ve never seen and the reindeers help the elves with some of the heavier tasks we have to complete for our super-secret but top of the market corporate customers. There are surprisingly few actual PCs (I think I counted 2 or 3 desktops). Some pictures here.

The said traditional British Xmas goes like this: first thing in the morning you ride quad bikes, then do some archery and this is followed by laser-modded full-size shotgun shooting. Then, to top off the Christmas spirit you jump into a 4×4 jeep for some blindfolded driving in winter mud on a farm in Kent. Basically a day full of crazy fun and joy of celebrating a globe-wide cross-religion holiday.

To get to the place I landed at the London City Airport which is like a normal international airport except it’s squeezed in a space ten times smaller than a usual airport. That allows it to function relatively close to the city centre so you don’t have to travel far. The single runway is practically built *on* the Thames, surrounded by water from all sides and looks quite impressive.

It was very cool to see London after perhaps some ten years since my last visit, and the Thames river had a new feel after my (not so) recent lecture of “Two and a Half Men in a Boat” by Nigel Williams (great read, btw., and how the book got in my hands in the middle of wild wild south of France is a weird story).

Category theory

August 3, 2007

Ah, also of note was a category theory (CT) exam because it was very difficult and I suck at CT so I was surprised to have passed it and bragged about it around. But the response I was getting was always “what the hell is category theory?”. Here again wikipedia comes to rescue by allowing me to just say that the Abstract nonsense article refers to CT and then everyone decides that they don’t really need to know what the hell is category theory.

What is qemu

August 3, 2007

Last month I had a couple of semester end exams and presentations at the uni and for one course I had to choose the presentation topic myself so I took qemu. Since qemu has no logo or anything it was hard to come up with any graphics, and there’s also no UI so no screenshots. In the end I had only one image in the slides and it’s this one:

What is QEMU?

It’s a painfully obvious rip-off of angryflower.com‘s What is Peggle but I just couldn’t resist it, the image just cracks me :-( I suspect the copyright belongs to Stephen Notley, it was only slightly modified under Gimp with my trackball. BTW I discourage anyone editing pictures using a trackball, there’s nothing worse than a trackball for pictures.