Archive for the ‘computer science’ Category

SVG library for Actionscript 3.0

Friday, October 19th, 2007

Big news. The runtime SVG parser and renderer for Actionscript 3.0 is working, sort of. The newest version of the library is available here. For the path mircosyntax, I used the lexer and parser from the Batik project, which is released under the Apache Version 2.0 license. The path is drawn correctly but the colors are not being rendered properly. Right now there is just code; I’ll be posting a swf and some test svg’s later.

Literature, computer science, art

Tuesday, May 8th, 2007

I have in the back of my head that it would be really interesting to combine writing and computer science, especially literature. I finally got around to thinking hard about this, and why it’s easy to combine art and computer science. Computer science can be used in art as a tool; most of the current art that uses computer science either generates visuals or is used to make a custom interface (e.g. motion sensors etc). Computer science can also be used in the understanding of art, as it has been used in the understanding of music.

I’ve been told that this is a good time to get into digital art — there’s just not a lot of artists who are skilled in computer science.

So that brings me to literature. There have been programs to generate literature, in which words are combined with some attention paid to grammar and the compatibility of the words. But this approach takes the artistry away — all that’s left to do is for the artist to look through the output and select interesting texts. On the other hand, there are ways to use computers to enhance the study of literature — researchers claim to have a program that can distinguish male and female writing. There’s the innovation of hyperlinking and easy text chatting. There are helpers — word processors, grammar checkers, word processors, etc.

I could imagine being able to input plots, themes and emotions into a computer and have it output a story, but this seems a long way off and how much fun, and how much a personal expression, would it be anyway. Perhaps such things already exist.

I think I will give up on the idea of a connection between literature and computer science.

Ajax version of segmentation and false coloring app posted

Friday, March 30th, 2007

I have posted an ajax version of the segmentation and false coloring application here.

This application produces an artistic rendering of an image. The options are to have the image rendered in a patchwork of random colors, or to have similar areas of the image colored in the average color of that image. Looks sort of like the image has been smoothed out.

Reimplementation of average coloring algorithm for segmentation code

Thursday, March 29th, 2007

I reimplemented the average color algorithm that was originally in the F&H image segmentation code. Creates neat results.

Example output

Conferences of interest

Wednesday, March 28th, 2007

I am not quite sure what to make of the European interest in my website. Is it just spambots? At any rate, I have heard that digital arts are more popular in Europe than they are here. In particular I think that Ars Electronica is an interesting conference. I am tentatively going to present my research there this fall.

The other conference that interests me is SxSW, which just ended. I am interested in how the web is making inroads into mainstream media and art, and this seems to be a good place to see this happen.

Hierarchical Agglomerative Clustering in n dimensions

Thursday, March 1st, 2007

I am really happy about the blogging thing. Anyhow somebody named Kokila Dhamodharan from India got in touch with me last month about hierarchical agglomerative clustering of images. It happens I know a thing or two about that. Basically you have an n-dimensional, metric space where the dimensions are properties of the image that you are interested in (color, variation, etc). When I did this I was comparing the partitions of a segmented image so I had color, size, shape, major axis etc.

I realize that the asymptotic complexity analysis of my paper was a bit slapdash. But who cares when you have run times of a second. I know that everything is less than O(n^3) anyway.

So here’s the naive approach: You calculate pairwise distances O(n^2). You have n^2 edges, and run an MST algorithm, which takes, with m=n^2, O(m log m) = O(n^2 log n).

Of course a really asymptotically efficient MST algorithm is essentially O(n). And you can approximate the set of pairwise distances — somehow or other…

Anyway, my code relied heavily on Pedro F. Felzenszwalb and Daniel P. Huttenlocher’s code, available here. I even reused their MST implementation. My project also used some code for an image format called ppm.

I sent my code over to the guy in India, but I am too lazy to really figure out what the license is, so I’m not posting it. It looks like it is MIT license compatible. Pedro’s new repackaging is GPL.

It would be fun to put either Pedro’s app and/or my app online.

Here are the results from my code:
Flowerbed showing results of finding repeated shapes