Colin's Journal: A place for thoughts about politics, software, and daily life.

ExpenseClam
Easy-to-use business expense tracker for Android.

ExpenseClam for Android

April 28th, 2004

SimpleTAL 3.9 Released

I’ve just uploaded SimpleTAL 3.9. This release brings the large performance improvements that I’ve mentioned in earlier posts.

Applications that utilise the inner workings of SimpleTAL, such as JOTWeb, will need to be updated before they can use this new release. Most applications (such as PubTal) should work fine, and much faster, with this new version.

April 27th, 2004

Computer Woes

As I was coming home on Friday evening I had a plan for the weekend. I was going to enjoy the nice weather we’d been forecast, and take lots of photos.

Chilies for sale at a Venetian market.Within half an hour of arriving home my plan was confounded by a dying hard drive. At first I wasn’t sure where the sound was coming from, but the stream of I/O errors to the console confirmed that my hard drive was on its way out.

I decided to take advantage of the new hard drive, which I had to buy, and upgrade from Debian to Fedora. The installation of Fedora went very smoothly, detecting all of my hardware even down the make and model of monitor.

Restoring all of the software services that I run, and recovering my data off the old drive, took most of the weekend. I’m still not finished, but the essentials are working (Subversion, TALAggregator, CUPS, NFS, MySQL, etc).

I’ve since attempted (and so far failed) to upgrade my machine to 100MB ethernet on the internal network, and added a 2nd 120GB to act as backup.

The good side of this upgrade is that my machine now has a new lease of life. Fedora is much faster than Debian, probably due to a combination of kernel tweaks and a newer version of Gnome.

(Photo is of some chilies for sale at a Venetian market.)

April 19th, 2004

Constitution Referendum?

It looks, despite earlier assurances to the contrary, that the UK will be holding a referendum on the adoption of the EU Constitution. I’m a little surprised that the government has chosen to go this way, but I can understand their reasoning.

Boat on Venetian canal against wall of ivy.The hope is that the constitution question will be removed from people’s decision making in the European Parliamentary elections. This reduces the size of the protest vote, meaning better results for Labour, and less chance of the opposition successfully claiming legitimacy with their calls to renegotiate the constitution.

Unlike votes cast in the European elections, votes cast in a referendum will have a definite effect on the adoption of the constitution. In my opinion the middle ground on this issue is very large, with most voters not starkly for or against the constitution. Persuading them to vote in favour should be a manageable task, not just because the arguments in favour are fairly strong, but because those against are very weak.

Those campaigning against ratification of the constitution are going to have a hard sell. The consequences of a No vote is hard to predict, and is mostly out of the hands of UK citizens and politicians.

If two or more countries failed to ratify the constitution then we would probably see the constitutional project put on the back burner for a long time, possibly forever. The current complex interwoven treaties would stay in effect, with select countries continuing deeper cooperation to the exclusion of others.

If the UK was the only country not to ratify the constitution then things would be very difficult. We could try to negotiate minor face saving changes to the constitution, and then ratify it through parliament. If this didn’t happen then we would probably have to leave the EU and participate in the single market through the EEA.

(The weekend had lousy weather, so I’m resorting to older photos like this one from our Christmas in Venice).

April 12th, 2004

SimpleTAL performance.

Top of a stone tower on the beaches.I’m pleased with the performance improvements that are going to be in the next version of SimpleTAL. The performance of the template parsing is unchanged, but the performance of the template expansion is significantly better. Exactly how much better depends on what you are doing, but I’ve seen improvements in the 45-70% range using the simple tests that I have.

The first version of SimpleTAL that I did any benchmarking on was version 1.1. On my “Basic” template test it managed to do 5.38 expansions/sec on my lowly P3-450. Version 2.0 brought a massive improvement, getting 69.32 expansions/sec, with version 3.2 bringing the peak performance to date of 74.88. Following 3.2 performance slipped as new features and code to handle edge cases was added.

Today’s development version achieves 101.59 expansions/sec under Python 2.1, and a little more under 2.3. I think that I’ve now reached the upper limit of what I can easily tune the code to achieve. To go faster would require a significant change in approach (for example compiling to Python byte code).

Another topic: I’ve had to make another correction to my RSS feed, this time caused by a bug in my weblog plugin code. The problem was due to my code using the file extension of the current template (rss.xml), rather than the “day” template (day.html) when generating the links to posts. Thanks to Heather for pointing it out!

April 11th, 2004

LJ Syndication Feed Problem

When I switched my weblog over to a PubTal based plugin I also switched the character set used by my RSS feed. Unfortunately the LiveJournal Syndication system doesn’t support ISO-8859-15, and so it hasn’t been syndicating my site for the last three weeks.

I’ve now switched it back to UTF-8 which should hopefully solve the problem for LJ users, and given universal support for UTF-8 in XML it should also work for anyone else aggregating the feed.

April 9th, 2004

Profiling Python

Profiling Python code is difficult. Python comes with two different profilers, called “Profile” and “hotshot”. The hotshot profiler is written in C and is meant to introduce little overhead into the running of your application. Unfortunately it also produces extremely variable output, with the timings determined for a particular function call differing by as much as 400%. This means you can’t make an optimisation and then check with hotshot to determine whether the effect was good, bad, or indifferent. The older “Profile” profiler has a similar problem, but seems to record smaller variations in the times it records for function execution.

Running these profilers was still useful however, because I’ve managed to improve SimpleTAL performance by ~35%. The single biggest performance gain was also the easiest to implement, and involved removing two debug statements. Much to my surprise Python’s logging library introduces a heavy overhead, even when debug is turned off. SimpleTAL used to make a call to a Logger’s debug function for every TAL path evaluated, and despite the significant amount of work performed during the rest of the path evaluation, this debug call took most of the execution time.

The other changes I’ve made were also fairly small, and have improved things by another 10% or so. To make any further improvements I suspect that large scale changes to the TAL/TALES interaction would have to be made.

April 7th, 2004

Passover

Red berries hidden by leaves.Part of my distant past includes having to take religious studies up to, and including, GCSE level. This compulsion may be explained by the school being sponsored by the church, or it may just have been someone’s whimsy. Regardless of the reason, I had to study religion, composed of two parts: Judaism and Ethics.

In many respects I can probably claim to have failed the Ethics part, because there wasn’t any structure to it. Judaism, while being completely irrelevant to me, did at least include lots of things to remember. Having passed the GCSE exam I promptly forgot almost all that I had learnt on Judaism, apart from a few random facts and half-correct ideas.

Last night I had a chance to revive some of this knowledge by attending a wonderful passover meal hosted by a friend. The ceremony part was remarkable for its flexibility and lack of prescribed ritual. There was a very strong structure in place, but the actions performed and words spoken within that structure were extremely open. The written guide we were following originated from California, and in places it showed. It also strongly resembled a work in progress; in need of editing and in some parts completion.

The food and wine involved throughout the ceremony was excellent, although extremely filling. As ceremonies go it certainly has much to recommend it over the usual Christian ones that I’ve been exposed to (discounting Christmas and Easter meals – which in my mind are so far removed from religion that they don’t count).

April 5th, 2004

New website design

I’ve finally had time to redesign my website. The content hasn’t changed, just the styling of the pages. Getting the CSS to work correctly took far longer than I had hoped, but it is mostly there now. If anyone knows why there are a couple of pixels of white space underneath the side image in Mozilla (on pages with little content), and some more above it in IE (on most pages), I would gladly like to know.

I don’t know how long this design will last. I had something else in mind, but as I started prototyping I found myself working towards this more minimalist design instead. If anyone has any problems in their preferred browser please let me know. Testing done so far includes:

  • Mozilla FireFox 0.8 – occasional strange gap at bottom of side image.
  • Galeon – same as Mozilla.
  • IE 6.0 – strange gap at top of side image.
  • Safari – same as Mozilla.
  • Lynx – works perfectly.

April 3rd, 2004

Bits and Bobs

Swan on Lake Ontario.Last weekend we were travelling to Arkansas, so I needed to purchase a book to keep me entertained on the flights. I chose an author new to me, Alastair Reynolds, and a book called Chasm City.

The book is far-future science fiction incorporating many tried and tested space travel ideas. The writing was generally good, but the relationships between the characters often felt false. Characters interacted in peculiar ways; conversations lacked emotion and actions seemed driven only by plot requirements. Even at 616 pages the book felt rushed, as though the plot fit but the story didn’t.

At some point I’ll try his earlier book, Revelation Space, which is selected as being the superior of the two in the Amazon reviews.

The news that the US will be fingerprinting and photographing all visa-waiver country citizens from September is marginally better than the previous plan, making us obtain a US visa, but it still disappointing. The introduction of biometric passports next year will make this a moot issue anyway.

The UK passport service is currently saying that they will place digitised photos into the new-style passports, but leave space for one other biometric identifier. Depending on what this second identifier is, and the most logical is a fingerprint, then all countries that you enter and leave will be able to record this information anyway.

Treating people as criminals isn’t just a policy for people crossing international borders; the UK is also planning to introduce biometric identify cards for the entire population. State interference in everyday lives seems to be the direction we are heading in.

%nbsp;

Copyright 2009 Colin Stewart

Email: colin@owlfish.com