Archive for February, 2003

House Invaders

Thursday, February 27th, 2003

Little pests have invaded our house. No, not the presenters of “House Invaders (BBC - Homes - House Invaders)”:http://www.bbc.co.uk/homes/houseinvaders/, not that bad. No, in one of our cupboards last night we discovered Flour Moths. I think they are the Mediterranean variety to be precise.

For the past week, I noticed a small moth fly past in the kitchen. “Oh look, a moth,” I’d idly think. Then a couple of days ago, I though, “Oh look, two moths”, and then yesterday, “Oh look, five moths; that is more than normal”. Checking in the cupboard we found grubs and coccoons of about 30 of the little pests. All removed, all food near the moths removed (it was cooking stuff like flour, suger and baking powder rather than tins of baked beans), shelves and surfaces cleaned violiently, all the while my itchiness increased.

I hope I’ve got rid of them all. This morning we found one moth on the wall, but I’m hoping that had been out having fun whilst its home had been demolished. The poor homeless creature was sent on moth heaven with a prayer and a rolled up newspaper.

Threaded Comments

Tuesday, February 25th, 2003

Looks like I’ve got threaded comments

Let’s see what can go wrong. I’ve got a number of problems with the design and layout again, but seen as I never finished the design this is not a problem.

Looks to integrate with SimpleComments well, as Phil has proved.

Coffee

Tuesday, February 25th, 2003

I’ve given up coffee and coke since Friday now. So far, I’ve had no physical effect except for being able to get up in the morning feeling rather refreshed. Of course, no children have woken up at 1am during this time, and I slept the entirety of Saturday, so this feature may not be connected.

For years, I’ve known I’ve drunk too much coke, ever since I cut down on the booze and fags, I’ve had to have another vice, so I cut down to one can a day. My coffee intake seems to have risen alarmingly. At one point last week, I was getting a coffee every half an hour. I think it was only the fact that my children are so tiring that I was able to sleep at night. I’d still wake during the night; I’ve always been a light sleeper.

When my first child was born, I was working in an office with a _super-coffee_ machine. I don’t know what sort of coffee was in there except for the fact it was *strong*. During the first couple of weeks after the birth, I was naturally tired, not getting the sleep in the night that would take me through the day. My wife found it easy to sleep when the baby slept and endured. I had a cubicle, a computer screen and not much to do. So, the _super-coffee_ machine came to the rescue. By the afternoon, I’d be buzzing. By the second week, I was shaking. I stopped drinking the _super-coffee_ and stopped shaking, eventually.

Caffeine isn’t good for you, really, but it does feel nice to drink. I say there has been no physically reaction, but water is no substitute, and there is a real craving feeling setting in. I don’t trust drinking tea; slippery slope.

Maybe I can get a patch.

Deep Junior

Tuesday, February 25th, 2003

An interesting article by Garry Kasparov about his recent bout with Deep Junior

Deep Junior is a different sort of computer to its predecessor, Deep Blue :-

==

In game five of my match with Deep Junior it played an imaginative sacrifice of the type generally considered impossible for a computer player. It was a landmark moment for computer chess and the science and programmers behind it.

==

When Deep Blue did, it did it with raw speed; or did it? As Kasparov points out
“Sheer power means little in chess because it is a mathematically near-infinite game.” IBM terminated the Deep Blue program after the 1997 victory, thus denying mathematicians the chance to analyse how it worked, and the records never made public. Why was this? On IBM’s “Deep Blue”:http://www.research.ibm.com/deepblue/learn/html/e.html website, they explain that the underlying RS/6000 technology is being used for

* Cleaning up toxic waste sites
* Forecasting the weather
* Modeling financial data
* Designing cars
* Developing innovative drug therapies

But that is the server technology, not the actual chess program, not Deep Blue itself? On a “page about Deep Blue”:http://www.research.ibm.com/deepblue/learn/html/e.8.3.html IBM say:

==

For proof of RS/6000 capabilities, look no further than this web site. You may recall what happened the first day Deep Blue and Garry Kasparov battled last year. The web site crashed. Frankly, we weren’t prepared for the worldwide interest the match would generate. The web site couldn’t handle all the “hits” of chess fans trying to follow the action. But literally overnight, we scaled up the RS/6000 server — adding nodes. The result? The site was able to handle three million “hits” in three hours.”

==

This time, the match was more scientific with both Deep Junior and Kasparov under scientific scrutiny. The actual result of the match was less important this time than the results of the scientific analysis. With Deep Junior supposedly _simulating human behavior_ the results should be interesting.

The article starts with a mention to one of my minor obsessions, Alan Turing. When I see an article on the internet written my the computer opponent then I’ll start to believe. It does have a “bio though”:http://www.x3dworld.com/Entertainment/CI_X3DEvnt_DeepJunior_Big_Frameset.html

Safe HTML Comment checker

Tuesday, February 25th, 2003

??Simon Willison?? has enabled a subset of HTML in his comments by writing his own XML parser to check validity

bq. The system I have implemented works by running submitted posts through an XML parser, which checks that each element is in my list of allowed elements, is nested correctly (you can’t put a blockquote inside a p for example) and doesn’t have any illegal attributes.

This post was brought to you by the numbers 2, 6 and 3 and the plugin “Textile (Brad Choate: MT-Textile)”:http://www.bradchoate.com/past/mttextile.php

RecentTrackbacks

Monday, February 24th, 2003

Recent Trackback template using just MovableType and the MTSQL plugin. (Did I tell you how much I liked the MTSQL plugin? Oh, I did, didn’t I.)

<ul>

<MTSQLPings query="select p.tbping_id
from mt_entry e, mt_trackback t, mt_tbping p
where e.entry_id = t.trackback_entry_id
and t.trackback_id = p.tbping_tb_id order by p.tbping_created_on limit 5">

<MTSQLEntries query="select DISTINCT e.entry_id
from mt_entry e, mt_trackback t, mt_tbping p
where e.entry_id = t.trackback_entry_id
and t.trackback_id = p.tbping_tb_id
and p.tbping_id = [MTPingID]">

<li><a href="<MTPingURL>"><MTPingTitle></a>
 on <a href="<MTEntryPermalink>"><MTEntryTitle></a>
</li>

</MTSQLEntries>
</MTSQLPings>
</ul>

Change the value after limit to however many trackbacks you want. In theory, you can use any MTEntries or MTPings tags you want in there

So, for inclusion with SimpleComments, this is my template.

<h4>Recent Comments</h4>
<ul class="recentcomments">
<MTSimpleComments lastn="15" sort_order="descend">
<MTSimpleCommentIfComment>
<li><$MTCommentAuthorLink show_email="0"$>
on <a href="<MTCommentEntry>
<$MTEntryPermalink$>
</MTCommentEntry>#comment<$MTCommentID$>"><MTCommentEntry><$MTEntryTitle$></MTCommentEntry>
</a></li>
</MTSimpleCommentIfComment>
<MTSimpleCommentIfTrackback>
<MTSQLEntries query="select DISTINCT e.entry_id
from mt_entry e, mt_trackback t, mt_tbping p
where e.entry_id = t.trackback_entry_id
and t.trackback_id = p.tbping_tb_id
and p.tbping_id = [MTPingID]">

<li>[Trackback] <a href="<MTPingURL>"><MTPingTitle></a>
 on <a href="<MTEntryPermalink>"><MTEntryTitle></a>
</li>

</MTSQLEntries>
</MTSimpleCommentIfTrackback>
</MTSimpleComments>
</ul>