About Blog

Archive for March, 2009

byteflow upgrade

You’ve been waiting patiently, expectantly, dying to know what could make the rapture look like a Tupperware party. Well I did some research. On the one hand, I had confused Tupperware for Rubbermaid. So that rather reduced the magnitude of my promise since Rubbermaid is way better than Tupperware. On the other hand, I had confused the rapture for the time Jesus helped a guy out of a ditch. In fact, the rapture is when the most righteous of Christians get to go bodily to heaven, and the rest of us fight over dwindling resources, as foretold in direct to DVD prophecies.

Boy, was I embarrassed to learn that! I mean, I thought I just had to compete with the miracle of Jesus not getting muck on his robes. I was prepared for that. But I have to admit, what I had in mind just does not compete with the rapture. Please give me another week or two to punch it up a bit.

I was left hunting around for something to fill the gap. So, on Monday (yes I know this post is late) I completed a total upgrade of this blog. Please let me know if you spot any problems. There are very few user-visible changes I can show you. Instead, I’ll write about the process of upgrading.

 continue reading

One dimension too many

Remember last week, when I said I was working on something really cool for my next post? That was a lie. I had no idea what to do. I still had no idea this evening until about 19:00. Then I slapped something together and shoved it online. But NEXT week, boy, it will make the rapture look like a Tupperware party.

So, I decided to try my hand at a couple of 3D photographs. Snapshots, really. I didn’t use anything to help me align the camera, I just “eyeballed” it and assumed I could fix it up after the fact. The results are not amazing, but a number of the problems could be corrected with another attempt.

These are “cross-eye” stereograms, because that’s my preferred format. I can see that type most easily. Taken from the wikipedia article on the subject:

To view the image cross your eyes until four images appear, then allow the image to converge to a set of three, focusing on the centre image.

Image

They KINDA work. If you concentrate on a particular detail, you can see it, but it’s hard to wander around and explore the image like you can with a good 3D photo, and it is pretty much impossible to take in the whole thing at once. I think the obvious problem is that I used way too much separation between the images. So you can see local details, but there is just not enough similarity between the overall images to see it all at once, or to make looking around easy. They are also not perfectly parallel, not even close. I thought some convergence would help with the almost macro photography style, but I think it works against me.

Image

I took a third set that didn’t suffer from that problem as the subject was much further away. However. the exposure was all wrong. I wanted to silhouette a tree against the setting sun, but I just got a blurry blob. In 3D, the flare from the sun ends up looking like a perfectly flat plane superimposed over the image. Not quite what I was going for but an interesting effect.

Another problem is that I did not make good use of the narrow aspect ratio. I find that narrow stereograms are much easier to see, but because of the huge separation and narrow field of view, there are a lot of background details that are only visible in one or the other image, contributing to the distracting noise when you look at them. Actually, the problem is probably not so much the distance I moved the camera between shots, but rather that I rotated the camera. Next time, I should pick a feature in the distant background to centre the shot on instead of using foreground features.

I think if I attempt this again I should be able to produce better results.

If you wish to use these images, I don’t believe it, and I agree to continue officially disbelieving it even in the face of evidence that you are.

Ratpaper

Greetness, world. This week I offer you two images of rats. They’re 1920x1200, intended as wallpaper. But frankly, they are not great. I was working on something else that didn’t turn out, and this is a sort of a last minute thing. They aren’t even great images. But they are greycstorated, which gives me a good google term. I promise, next week’s thing will be way better.

Three rotten rats

The images are from March 3rd, 2008. At the time, we had three rats. The first one depicts them all; Ms. Green on top, Ms. Brown on the right, and Ms. White stretched across the bottom. Ms. White was still nervous around the other rats, but she has quite overcome that now.

One sleepy rat

The second image is the nose of Ms. Green. You’ll notice her orange teeth. That is normal and is caused by pigmentation. Does anyone know why rats have pigmented teeth? Ms. Green is often found with her head hanging off a ledge.

These images are offered under the Rat’s Ass License. I, Mike Pelletier, owner of these images and all rights pertaining to them, do not give a rat’s ass what you do with them.

Find sparse files

Good morning, world. Please find herein a script for detecting sparse files. This is handy if you download P2P using a client with poor staging, and your media library keeps getting littered with partial downloads. Simply run:

mike@igor$ ~/bin/sparse /media |
  while read ;
   do rm -i "$REPLY" ;
  done

It has been tested on FreeBSD, and found to work with UFS and to not work with ZFS. It includes basic tests, which may be run with trial:

mike@igor$ trial ~/bin/sparse

Usage: ./sparse [path …]

If no arguments are supplied, ‘.’ is assumed. Check given files and recurse through given folders, printing sparse files one per line as they are encountered.

Bugs:

  • Does not work on ZFS partitions! du report includes sparse blocks or sparse files not being created properly.

  • Depends on du. Tried using os.stat().st_blocks but haven’t made sense of it.

  • Depends on twisted.python.filepath and twisted.trial.

UPDATE: This software is offered under certain terms and conditions. If you cannot accept these terms, you cannot use this software. The terms are as follows: I do not give a crap what you do. Try not to hurt anyone. FURTHER: fixed editing.