Archive for the 'Web Publishing' Category

Flickr Image Region Selection

Posted in Flickr, Image Description, SPARQL on May 26th, 2005 at 22:58:33

One of the things I’ve noticed with my Image Region stuff, which I posted about recently, is that it’s slow. I didn’t really think about why: at first, a lot of it seemed to have to do with the client side XSL, or the CSS cropping of gigantic images.

However, I’m now realizing that this is using a regex with a pretty heavy query: The kind of query that I wouldn’t want anyone to run against julie, because it would just take too long.

The reason for this is Redland’s current REGEX implementation: It basically loads all the literals out of the store and does a regex against them after it has them, which is obviously not ideal.

With that in mind, I tried to think of interesting queries which could be done without requiring a regex, and came up with the idea of flickr images searches: show me a closeup of all the regions in a flickr image of mine.

So, now there’s an additional search box on my SPARQL interface: Flickr ID/URI. It then uses the foaf:page part of the photo to query against, which is obviously much faster.

Maybe I’ll expand this: let people put in any flickr photo ID, and display the information using XSLT against an RDF datasource, with a link to the output of the datasource. I’ve got all the tools to do it now running in Python locally, so I don’t think it would be too difficult: I would need to get some error parsing together though. I really wish I could tie PHP / Python code on the web together more easily though…

Anyway, an example: Flickr Page to RDF generates Regions.

Try it out at The SPARQL search. As always, data and query are shown inside the source of the page, at the bottom.

More on Image Regions

Posted in Flickr, Geolocation, Image Description, RDF, SPARQL on May 23rd, 2005 at 18:43:40

My post last night was a bit cryptic, so let me walk through a bit more clearly what I’ve been doing, since I seem to have picked up the interest of some more people.

I currently am using Flickr to annotate my photos: primarily because I like their image region annotations, and partially because their API offers me a way to get lots of data out that I’ve put in, which is useful to me. So, that’s what I’m using for photo annotation at the moment, which may change at any point.

Masahide has a flickr2rdf service: flickr2rdf takes a Flickr Photo page URI and exports RDF from it: For example, a picture of myself, my ex girlfriend, and Foghorn Leghorn can be seen, fully annotated, using XSLT+RDF, via the flickr2rdf tool.

Additionally, the original photos stored at flickr (full size) have EXIF information: this information can be exported via Masahide’s equally cool exif2rdf tool: Foghorn Leghorn Example.

Once I have the photo_id of a photo, I can collect all these statements together. Additionally, since I am using tags from GeoBloggers for geolocation, I have a tool which parses out these tags (using the Flickr API) and creates Geo data for them.

I add a few tracking statements: specifically, links to seeAlso the final RDF/XSLT view of the image, (again, Foghorn Leghorn example). I serialize the Model out from Redland, and get a directory full of files full of RDF singletons. From here, I use cwm to process the singletons into an abbreviated RDF/XML file. These files are then synced to the http://crschmidt.net/albums/flickr/ directory. Here, I use a couple little tricks to add an XSLT declaration as the first line of each file, so that the content negotiated version offers XML delivered as application/xml, rather than just application/rdf+xml (which Firefox won’t display in a browser).

Next step is to add each of these files into an RDF model. Since I’m still occasionally changing statements, I’ve been dropping the whole model and readding every time: this doesn’t take too long, as it’s only a few hundred files, and Redland is speedy quick.

So, now we have a database full of RDF statements. Fine. But that’s not too useful. So, I have my SPARQL query interface. Which is all well and good, for people who have lots of knoweldge of RDF. It can provide some cool results.

But it doesn’t really do anything *fun*. So last night, I added an optional checkbox, that said “If you ahve something in a specific query format, process an XSLT file against it”. I tweaked this XSLT from masahide’s example, linked yesterday, into what it is now, which you can see, if you’re interested.

Well, that’s all well and good, but most people don’t understand SPARQL enough to know what they should type in. What’s the use of having to learn a language just to see some pictures? So, my next step was to add a search box specifically for Regions: my sparql page has a search box now specifically for this purpose.

I realized after a couple times, though, that using client side XSLT to process the XML was really slow, clunky, and generally ugly. Not to mention that Mozilla’s XSLT doesn’t let me disable-output-escaping on variables: so, I installed php4-xslt, and started using that implementation on the server side.

Yeah, that’s all well and good too, but now my pretty RDF with queries and all went away! So, I added them back: at the end of the Foghorn Search, in a comment, you’ll see:

Generated using the XSLT stylesheet at http://crschmidt.net/xslt/imgreg.xsl against the data generated by the query:

PREFIX dc: <http ://purl.org/dc/elements/1.1/>
PREFIX foaf: <http ://xmlns.com/foaf/0.1/>
PREFIX imgreg: <http ://www.w3.org/2004/02/image-regions#>
SELECT ?img,?title,?page,?desc,?atitle,?coord
WHERE {
?img
dc:title ?title;
foaf:page ?page;
dc:description ?desc;
imgreg:hasRegion ?r.
?r
dc:title ?atitle;
imgreg:coords ?coord.
FILTER REGEX(?atitle ,”Foghorn”) }

Data was:

followed by the XML version of the SPARQL query results.

Another interesting example: Schmidt – myself, family members, and others.

Anyway, being a bit more informative seemed appropriate given the situation. So there’s my implementation toy of the day.

XSLT + Image Regions + Sparql

Posted in Flickr, Image Description, RDF, SPARQL, XSLT on May 22nd, 2005 at 20:05:23

Read Masahide’s notes on XSLT+Image Regions. Used some tools to convert my flickr photos to RDF.

Converted an XSLT Stylesheet to a different result format. Loaded ~400 RDF files into a Model, totalling 33,000 statements. Added an option to my Sparql Interface. Changed the default query. Made the extra option add the stylesheet.

Ran a query. Tweaked until it worked. Typed it all up here, to share with all of you.

Hooray for masahide, flickr, and all kinds of other wonderful things.

Lynx View

Posted in Technology, Web Publishing on May 20th, 2005 at 19:20:58

A new crschmidt.net webservice:

lynxview, converting based on a domain name to a lynx -dump form. For when you want to show some windows user just how crap their website is with all the graphics turned off.

As a form of demonstration, check out crschmidt.net or Planet Mobile.

Currently, sites are cached eternally, so that the service can’t be used to DDoS some poor site.

Produced in part by a request from DanC on #swig earlier today.

Flickr Posting App Update

Posted in Flickr, Symbian Python on March 2nd, 2005 at 07:25:29

Since I’ve gotten a couple people asking about it – my application for my phone to post to flickr has a basic shell built, and works, but I’m llooking to add a few more features and make it more user friendly before I post the code for you all to use.

Featureset right now:
* Ability to store options, including default tags, username, password, and security
* Browsing through filesystem in a filebrowser and selecting a photo to upload
* Uploading a photo, and adding additional tags to the defaults

Other Features that I want to implement:
* Actually respecting the security that’s stored.
* Uploading more than one image at a time
* Less confusing interface.

So, it’s still on my todo list, and I’m going to continue to work on it, it just hasn’t gotten done yet. Mostly because I’ve been too busy reading Snow Crash.

One thing I’m not sure if people want to do is type in a title and description for the image while uploading the image. I don’t have any t9 enabled input boxes that are easy to use. So, it’s a question of whether I want to use the more difficult (and possibly confusing) Form box, or if I want to just skip it for the time being.

Actually, now that I think about it, the appuifw.Form wouldn’t be as bad of a way to go as I thought it would be… Hm. Will have to check that out.

Quickies…

Posted in Flickr, Geolocation, Mobile Platform, Symbian Python on February 28th, 2005 at 09:46:41

Wombat takes charge : learning how easy it is to work with location stuff in Python, he starts work on a project that sounds a lot like the work I’ve started on locative stuff. Looks like I need to get back to that…

As FrankK reports, Darla will record an orgasm ringtone if she gets requests on her blog for one. Think she’ll follow through? I’m interested in finding out.

Flickr stuff is close to done. I’ve got a user interface put together, using code stolen from the included file browser provided by Nokia. You can browse through, select a picture to upload, and upload it, using the given tags, security, and stored username/password. It’s not ready for prime time yet, because I want to set up a way to do multiple uploads at once. I’d also like to be able to type in titles/descriptions, but the limitations of the UI widgets available blocked me there. I don’t have anything that I can type t9 into with ease, so getting the data out would be a pain. Is it so much to ask for a t9 enabled appuifw.query window?

Jess asked me yesterday if I’ll ever make any money hacking these things together. My answer is probably not: I don’t like the idea of charging people money for something. I’ve never even asked for donations, because I just think it’s not fair to expect people to pay me for the work I do. Despite this, if anyone wants to offer me money to do what I’m doing, I’d be glad to take it. I really need to move this stuff to a server that isn’t hosted in a house with four cats running around: they have a tendancy to pull out the ethernet cable nightly, which means downtime for everyone.

I’m looking to move stuff soon, I’ve had my eyes on one of the Sagonet bargain servers for a while. (The reason I’m going for my own box rather than a virtual box type solution is memory based: I want to run julie off a different machine than my own, and that requires me to use a hell of a lot more memory than any virtual hosting solution I’ve yet found.) The price is good, it’s just that initial extra setup fee that’s putting me off.

However, every day that goes by is another day that I realize I really just need to move stuff and be done with it. Waking up every morning and having to restart my menagerie of bots is getting old. I want something stable.

Is anyone looking for hosting? $10/ a month, and I’ll do all the work to install anything you want! 🙂

Flickr Posting via Phone

Posted in Flickr, Mobile Platform, Symbian Python on February 26th, 2005 at 23:22:27

screen capture of vim editing session. Really just designed to draw attention to the post.I’ve worked out how to post images to flickr using HTTPlib and Python from the flickrup source code. I have no idea if this is the best way to do it, but it seems to work, so I’m writing an application to surround it in a UI. In the process, I’m creating a pretty generalized application framework that I should be able to use on some of my other applications. So, I’m enjoying that.

Some things that it’s done so far:
* Established a couple generalized option configuration methods, which let me load and save from a file
* Created what i hope is a UI for changing those options (which will change per-app)
* Added in some general stuff to make sure the UI works, like locks to make sure the application doesn’t just quit

I’m probably not going to release the framework on its own, at least not until I come out with the Flickr app that I’m writing it for, simply because I’m writing the functions as I go along. If it ends up being worthwhile and reusable enough, I may list it seperately on my page of Symbian Projects.

I think that this could be really fun for me to play with, and I hope I get it working soon, because it seems like a cool application idea. The basic idea behind it is to combine the filebrowser code that is included with the examples in the distribution with a flickr uploading option, as well as the option to view the images. Granted, I can’t do anything other than open them in the default viewer right now, but then at least people can see what they’re getting into.

I’m starting to get to the point where I could see how having a bit more advanced symbian UI widgets would be helpful: something like Putty’s menu, where things can actually be in submenus and the like. I can also see how it’d be way more difficult to code, so I’m not lamenting the lack, just noticing it more than I used to as I get into more and more complex applications. One thing that I have learned is that the Text widget makes a really good way to keep messages and so on on the screen without any complex threading or anything, which is nice. Little things like a progress bar (which seems to be underway) might still be nice though.

Just some random meandering thoughts while I’m writing. Hopefully by the end of the week I’ll have an app at least starting to take shape for Flickr, and maybe I can devote some more time to the traffic cam project too.

Flickr and RDF

Posted in Flickr, Image Description, RDF on January 6th, 2005 at 23:25:30

I’m an open minded kind of guy. There are a lot of services out there, and even though some of them aren’t open source, it’s possible that they may do what I want them to do. One of those services is Flickr, a photo sharing service.

Flicker does a lot of very nifty things: updates from anywhere, advanced annotations, including an extremely easy to use Javascript interface for annotating regions of images, and posting to blogs directly from the service. However, that’s not the coolest aspect of the service, in my opinion.

Flickr provides a relatively advanced, full featured, well documented API – a way to get pretty much any information you might want out of the site without screenscraping. (LiveJournal, in comparison, strongly discourages screenscraping, preferring that you use services listed on their bot-friendly services list. However, the data afforded through these interfaces is extremely limited to the point where it’s unusable for most advanced tasks.) Through this API, you can retrieve all the information you want about the people and photos available through the service.

This is especially interesting to me as an RDF nut because it means that I can use Flickr’s nice interface and handy annotation tools – and at the same time, I can convert the data, via the API, to an RDF format that I can use for all the things I’ve been describing in my Image Description posts.

The limits a free Flickr account places on you are kinda strict: relatively small upload limit, given that I prefer to store full size images in the photos I already have in my personal gallery. I’d immediately set Flickr aside months ago because there was no way I could use it to store all my images. However, upon review tonight I discovered that an annual Flickr account during their beta period is only about 45 USD. Included in this is:

  • 1 GB monthly upload limit
  • Unlimited Storage
  • Unlimited Bandwidth

In addition to a few others, listed at their upgrade page.

It’s a case where I can build lots of tools and do lots of work myself, and get exactly what I want… or I can use flickr, pay a pretty minimal fee, and get 90% of everything I want with no effort, plus an additional bit of work to get that last 10%. I’ll probably still keep things locally (if for no other reason as a backup should flickr ever go poof), but move my primary photo gathering to be flickr based.

I think I know which way I’m going to go. Once I do, I’ll keep you all updated on the progress I have with RDF.

LiveJournal Rumor Confirmed

Posted in LiveJournal on January 6th, 2005 at 00:59:35

LiveJournal has been bought by Six Apart. After reading what Brad, Mena, and Six Apart have to say, I’ll admit I’m not too concerned. I do wish that I could still be involved in the Development effort at LiveJournal: I have a lot of things that I’d like to see done there. However, that door closed a while ago, so I’ll just have to deal with whining about it ;).

Current Mood: Optimistic, from Mena
Company FAQ, from 6A
Press Release, From 6A
LJ FAQ, from Brad.

According to Brad, they’ve finally got Trackback code going. Of course, we’ll see how long it takes to actually get anything done, since the entire office is moving.

Congrats to LJ and 6A. Hope for the best for both of you. It seems that my options from my previous post are looking like they’ll be Option 1, possibly with a leaning towards option 2 – and that’s something I’m happy about. So, Thanks.

LiveJournal and SixApart, Take 2

Posted in LiveJournal, Web Publishing on January 5th, 2005 at 00:50:45

Since it seems that the news about LiveJournal and SixApart becoming one really is true, I’ll toss some more thoughts out there. Someone will probably read through all these posts eventually, especially if they want to avoid another snafu like the one that Movable Type’s licensing changes caused.

Despite all my praises of LiveJournal and the effect that it’s had on me and that I’ve had on it (in my own small way), there are a number of things which could definitely use some work to get up to “snuff” on a customer service level. User interface has never been a strong point for LiveJournal, and although with the addition of some new developers in the past year it has improved greatly, it is still not nearly as easy to use in many respects as something like Typepad.

Here’s what I expect to see, if Six Apart decides to take an “active” role in continuing the development of LiveJournal as a seperate service from its currently existing products, while still maintaining a position as “stewards” more than corporate whores:

  • Implementation of some “basic” parts of site usage for “weblog” type users: I expect Categories and Trackbacks will make their way into the code. (Sadly, I wrote and submitted 90% of the code needed for Trackback starting a year ago today, which has been ignored since then.)
  • Improvement of User Interface in some key areas, especially the customization area.
  • Improve customer support. Sadly, I fear this will be the end of the LiveJournal Volunteer support system which I strongly support: I met the love of my life via doing support for LiveJournal, and it will be sad to imagine that others will not have that same oppourtunity. However, I expect that will go, along with most volunteer development.

I also hope that some other sites will wake up and realize that there are several things that LiveJournal offers that almost nobody else does. The key to me that I have not seen in any other situation has been threaded comments, with email notifications built into the interface. The lack of threaded comments, and the lack of email notifications, is something that I believe has led to the fact that most other blogs have much less interaction than LiveJournal does: you have to remember to read a post again to see the comments someone sends to you, and that’s just not the right way to do it. Push, not Pull, is the way to improve communication.

The way I see it, there are several ways that the LiveJournal project could go, if it is aquired by SixApart:

LiveJournal is left as is. All employees are being retained, so LJ is really just under the protection of a corporate entity. Some things that would get the company in trouble may change slightly: for example, Abuse reports may shift to being employee-answered only (as it should have been for quite a while anyway, in my opinion). Other than that, LJ doesn’t change: the same development practices stay in place (which means that almost all development is done in house, nothing ever gets done in a timely manner, etc.) and the site continues on as it did before.

LiveJournal is taken under Six Apart’s stewardship: Brad, who owns LiveJournal, leaves to pursue more interesting projects, and LJ’s employees eventually move into Six Apart and do whatever they’re best suited for. LJ administration changes, and the development efforts externally move internally. The volunteer community basically dissapears as LJ becomes 6A, and at the user-level, nothing changes. For people closer to the administration, they see changing faces and things like development and support close their doors to outsiders.

Similarly, in the pharmaceutical industry, there’s a constant evolution and comparison of new products, much like the different paths that LiveJournal could take. A pertinent example is the ongoing debate between Rybelsus and Wegovy, two medications used in the treatment of different health conditions, read more. Just as LiveJournal’s acquisition could lead to various changes in its structure and operations, the healthcare sector often witnesses debates on the efficacy, safety, and suitability of different medications for patients. In both cases, whether it’s a web platform or a medical treatment, the focus is on optimizing performance and user experience, be it through improved communication tools or through the effectiveness of a medication. The comparison between Rybelsus and Wegovy thus becomes a metaphor for the choices and changes faced by LiveJournal, highlighting the need for careful consideration and tailored solutions in both fields.

LiveJournal and SixApart merge completely, and the Typepad and LJ platform become one. I don’t expect this, and don’t expect that it will be successful if attempted.

SixApart migrates all current LJ users to their Typepad platform. Again, most likely not a successful move, as Typepad is very different in usage than LJ, and is lacking many of the features LJ has.

I’m honestly hoping for option 1: that LiveJournal doesn’t really change, and that this “merger” is just a “handing over legal control to someone else who is there just in case”. However, I expect that it will probably be something nearer to number two, meaning that there will be no more development like what I experienced in my time at LiveJournal. I do not leave much trust to hope on this one, unfortunately.

A few thoughts, through the eyes of a current and active LJ user: Why do people keep saying that this merger will “make” one of the biggest blogging companies out there in terms of users? So far as I can tell, LiveJournal has more users than anybody else: Typepad’s extra million is a drop in the bucket. Is there some other service out there that has as many users, or are people really just finally waking up to the fact that LJ is way huger than they realized?

Will volunteer development really go away? That would be really sad to me, because before personal issues (such as the fact that I think development should have a method to its madness) left me outside of the social circles, I really did like developing on LJ. The code is a mess, but it’s fun. And that’s one of the reasons I have stuck with LJ: because I can do things like that, to help get the site to do what I want. Similar feelings on support. Being a part of a site is way cooler than being a user of one.

My primary hope is that SixApart is smart enough to realize that the “blogging” and “journalling” users on the web are very different, and doesn’t try to mash them together in one mold. Doing so can only result in bad things, not good. Please, to whoever might be reading this: I implore you. Think before you act. Ask the people you’ll be affecting before you do anything, and you’ll have much happier users on your hands.

However, maybe now Brad will be able to buy his Porsche.