Search Results: "nion"

20 January 2008

Jacobo Tarrío Barreiro: Flags and languages

Many languages are spoken in more than one country, and many countries have more than one language. When you forget this you do stuff like language selection menus that use flags to represent languages. This is problematic for several reasons, starting with having to ask yourself what flag you are going to use to represent English, and how to deal with the angry letters you’ll receive when you use the national flag to represent a regional language. So, using flags to represent languages is definitely discouraged. This said, have a look at this small piece of the KDE l10n stats page: Galician language with flag of Greenland The funny thing is that the flag you see next to Galician is the flag of Greenland. And Galician is not spoken at all in Greenland! So, what happened? Why did they use so wrong a flag? The problem is that the ISO 639-1 code for the Galician language is gl , which is the same as the ISO 3166-1 code for Greenland. So, when choosing the flag for Galician they confused the language code with the country code and selected the flag for gl : that is, for Greenland. (I’m surprised that they used the Ukrainian flag ( ua ) for the Ukrainian language ( uk ), and not the Union Flag. Perhaps that would have been too obvious an error :) – although I have been told by email that the ISO 3166-1 code for the UK is GB , not UK ) So, my takeaway message is: don’t use flags to represent languages and if you do, make sure you use a flag of a place where the language is actually spoken! Addendum: I have just seen that Basque is accompanied by the flag of the European Union! That’s because the language’s code is eu . Ah, and there are three variants of the Chinese language (Hong-Kong, Simplified and Traditional), all with the flag of the People’s Republic of China. Someone is bound to receive angry email – Taiwan is a political hot potato. I have sent email to the maintainer of the page.

19 January 2008

Theodore Ts'o: Why I purchased the Sony PRS-505 Reader

Although I lot of people have been lauding the Kindle, I recently decided to go with the Sony PRS-505 instead. Yes, the Kindle has built-in EVDO access, and the ability to buy books without a computer, or even browse the web; and yes, the Sony has once again demonstrated it can’t create a compelling 21st century computer application to save its life. However, it had a few things that at least for me, made a better choice for me than the Kindle:
  1. The Sony is thinner — I want to be able to slip it into my laptop case and have it take the absolute minimum amount of space.
  2. The Sony simply looks much more elegant than the Kindle; steel with a leather cover simply looks a lot better than white, cheasy plastic.
  3. I’m not interested in buying a lot of DRM’ed ebooks; ergo, I won’t be buying may books from either Sony or Amazon’s web sites. It is highly likely that within 2 years I will be buying a more advanced eBook reader, possibly one with color, and I don’t want to be locked into a single format where I have to go and repurchase all of my books just because some the latest and greatest eBook reader uses an incompatible DRM technology from whatever Sony or Amazon has used.
  4. The Sony is $100 cheaper. Given that something better will be available within 2-3 years at the very most, and possibly sooner, I’m just not interested in spending $400 on a first generation prototype.
  5. Perhaps the most important, the Sony has the really, really good open source support. Kovid Goyal’s libprs500 project supports the Sony PRS-500 and PRS-505, and has very good version tools, allowing people to convert eBooks previously stored in HTML, PDF, TXT, Microsoft Reader (.lit), IDPF/Open eBook (.epub) into Sony’s format. And with a little bit of work, it does a very, very good job with the conversion. Better yet, its ability to convert multiple HTML pages into a single eBook, with credible table of contents, means that libprs500 can pull down the New York Times, the Economist, etc., automatically format it into a single eBook which you can save onto your Sony Reader, and then read it while you are on the airplane. No muss, no fuss. I can also take various books that are available on the web as HTML and also convert them into an eBook which can be used by the Sony Reader very easily.
This last point is I believe one of the best reasons why the Sony Reader will be able to compete very successfully with the Kindle. The libprs500 software is written as a python application, and it will work on Windows, Linux, and MacOS — and its GUI user interface is far better than the truly pathetic Sony Connect software. Score one for Open Source! In my opinion, Sony should send a very nice gift certificate to Kovid as a thank you; his open source project has added an immeasurable amount of value to their product. The only thing that you can’t do using the libprs500 software is buy DRM’ed books which are locked to the Sony Reader — but that isn’t something that many people will be particularly interested in, I suspect. OK, I did buy Pillars of the Earth, which was available on the Sony site for $6 dollars — hmm, cheaper than Amazon’s $9.99 — but that was an investment I was willing to flush down the toilet when the PRS-505 becomes obsolete, mainly so I could test what buying a DRM’ed book would be like from the Sony web site. But I probably won’t be buying many books with DRM that way. On the other hand, I am quite willing to spend quite a bit more money on non-DRM’ed books from publishes such as Baen Books. Here’s to the hope to the publishing industry figures things out faster than RIAA’s member companies. In the meantime, I will be mostly pretending that the both the Sony and Amazon eBook stores with their proprietary DRM’ed books don’t exist…

Jacobo Tarrío Barreiro

Many languages are spoken in more than one country, and many countries have more than one language. When you forget this you do stuff like language selection menus that use flags to represent languages. This is problematic for several reasons, starting with having to ask yourself what flag you are going to use to represent English, and how to deal with the angry letters you’ll receive when you use the national flag to represent a regional language. So, using flags to represent languages is definitely discouraged. This said, have a look at this small piece of the KDE l10n stats page: Galician language with flag of Greenland The funny thing is that the flag you see next to Galician is the flag of Greenland. And Galician is not spoken at all in Greenland! So, what happened? Why did they use so wrong a flag? The problem is that the ISO 639-1 code for the Galician language is gl , which is the same as the ISO 3166-1 code for Greenland. So, when choosing the flag for Galician they confused the language code with the country code and selected the flag for gl : that is, for Greenland. (I’m surprised that they used the Ukrainian flag ( ua ) for the Ukrainian language ( uk ), and not the Union Flag ( uk ). Perhaps that would have been too obvious an error :)) So, my takeaway message is: don’t use flags to represent languages and if you do, make sure you use a flag of a place where the language is actually spoken!

Jacobo Tarrío Barreiro: Flags and languages

Many languages are spoken in more than one country, and many countries have more than one language. When you forget this you do stuff like language selection menus that use flags to represent languages. This is problematic for several reasons, starting with having to ask yourself what flag you are going to use to represent English, and how to deal with the angry letters you’ll receive when you use the national flag to represent a regional language. So, using flags to represent languages is definitely discouraged. This said, have a look at this small piece of the KDE l10n stats page: Galician language with flag of Greenland The funny thing is that the flag you see next to Galician is the flag of Greenland. And Galician is not spoken at all in Greenland! So, what happened? Why did they use so wrong a flag? The problem is that the ISO 639-1 code for the Galician language is gl , which is the same as the ISO 3166-1 code for Greenland. So, when choosing the flag for Galician they confused the language code with the country code and selected the flag for gl : that is, for Greenland. (I’m surprised that they used the Ukrainian flag ( ua ) for the Ukrainian language ( uk ), and not the Union Flag. Perhaps that would have been too obvious an error :) – although I have been told by email that the ISO 3166-1 code for the UK is GB , not UK ) So, my takeaway message is: don’t use flags to represent languages and if you do, make sure you use a flag of a place where the language is actually spoken!

16 January 2008

Aigars Mahinovs

AJ, if some blogs would support comments, I would leave my opinion there and not add noise to the planet. 1) Censorship does not stop being censorship just because the people doing the censoring don’t have the absolute power to censor the information everywhere and only block the information or opinion from the channels they can control. It can be called otherwise - editorial control, policy of political correctness, libel liability protection policy, Children-Safe Talk Initiative or Women Friendly Environment Collective. But at its heart it is still censorship of all official Debian-related channels of communication as the aim is to remove the objectionable content from all such channels. 2 and 3) Discriminating against jerks is also a discrimination against people or groups. Please do not get all DFSG-bendy on me here. DFSG is about use and distribution license of the software and not about the communication channels used to facilitate this process. I could actually counter you with a quote from the Social Contract that says that we will not hide problems. The discussion as such admits that some people consider sexism to be a problem in Debian (for example). Excluding sexist comments from Debian official channels will not make sexism magically disappear, it will be just hidden, swiped under the rag and said to sit quiet. The only problem is that the community that is tired of such hushing is much larger then anticipated. There are people that think that men and women are different. We checked. I can’t see anything bad in the example quoted on the planet so far. Yes, the depth of the discussion is weak - we can’t be genius all the time, but I really fail to see who is insulted in there. Lesbians? Don’t think so, they are compared to a threesome quite favorably. That is not a technical discussion about interrupt timings, but that’s why it is in offtopic. Doh! Relaxed chit-chat like this is typical in all healthy and tight-knit communities. Is it offensive to women to talk about sex??? Grow up and have a good 3 hour chit-chat with some real women. Women talk about sex even more than men. Especially on-line. Can someone really show what is the “OFFENDING BEHAVIOR” so obscene and dangerous that people want to censor out of Debian and explain what exactly they see as being so horribly bad to Debian that they see total censorship of all Debian communication channels as an acceptable countermeasure?

15 January 2008

David Watson: Faulty cats

Daniel, mine seem to like cheese and onion crisps. So maybe the whole batch is faulty.

11 January 2008

Anthony Towns: LCA Sponsors

An article by Sam Varghese appeared on ITwire today, entitled linux.conf.au: What is Novell doing here?:
A GNU/Linux system does not normally load modules that are not released under an approved licence. So why should Australia’s national Linux conference take on board a sponsor who engages in practices that are at odds with the community? What am I talking about? A company which should not be in the picture has poked its nose in as a sponsor. Novell, which indicated the level of its commitment to FOSS by signing a deal with Microsoft in November 2006, will be one of the supporting sponsors for the conference.
Novell was also a minor sponsor of the 2007 conference, and Sam wrote an article in January expressing similar thoughts, which included this quote from Bruce Perens:
“I’d rather they hadn’t accepted a Novell sponsorship. It wasn’t very clueful of them, given Novell’s recent collaboration with Microsoft in spreading fear and doubt about Linux and software patents,” Perens said.
Ultimately, I think that’s a mistaken view. Linux.conf.au is what it is thanks to the contributions of four groups:
the organisers
who create the conference, get a venue, organise a schedule of events, help the speakers and attendees to get there, and generally make it easy for everyone to just get immersed in cool Linux stuff
the speakers
who provide the core of the schedule, the reason for attendees to go, and a core depth of awesome technical knowledge and ideas
the attendees
who fill in the organisational/content gaps that the organisers and speakers miss, who make for fascinating corridor and dinner conversations, who make side events like the miniconfs, the hackfest or open day interesting, and who pay the rego fees that lets the conference happen
the sponsors
who provide a chunk of money to fill out the conference budget letting us commit to venues and events earlier (when we might otherwise have to wait to see how many people come), and let us do extra things that registration fees alone wouldn’t cover
Obviously sometimes you have to exclude people from participating, but that’s mostly only if they’re actually causing trouble for the event. For sponsors, that pretty much means trying to interfere in the conference itself, or not paying on time. Otherwise, if you’re contributing to the conference, and not causing problems, you certainly should be recognised for that, as far as I can see. For me, the same thing would apply if Microsoft was offering to sponsor the conference – if they’re willing to contribute, and not cause problems, I’m all for it. If they happen to not be doing anything constructive in Linux-space anywhere else, well, it seems perfectly fine to me to start contributing by helping make linux.conf.au awesome. In Microsoft’s case that would be hard, because all the people going “oh my gosh, Microsoft, Linux! Wolves, sheeps! Hell, snow!” along with possible mixed messages from Microsoft and our long-term major sponsors HP and IBM about the future of Linux and whatnot could really distract us from all the cool technical stuff the conference is fundamentally about. I don’t think there’s anything Microsoft could offer to justify that much disruption, but having more of the world’s software companies involved in free software would probably be worth a bit of hassle, if the disruption could be minimised. Ultimately, I guess my disagreement comes down to these couple of comments from Sam’s article:
Asked whether it was right that Novell should be allowed to be a sponsor for a conference such as this - which, in my view, is a privilege - […] […] Novell, obviously, is hoping that, as public memory is woefully short, it will be able to wriggle its way back into the community. Providing such leeway is, in my opinion, a big mistake.
In my opinion, the ability to contribute to open source isn’t a privelege, it’s something that should be open to everyone, including people who’ve made mistakes in the past: and that’s precisely what the “free” in free software is all about. OTOH, if you want to see who’s been participating most in the Linux world lately, you’re much better off looking at the list of speakers than sponsors. Novell (or at least SuSE) folks giving talks in the main conference this year seem to include John Johansen and Nick Piggin. Interestingly, the count of HP folks seems a bit low this year, with only two that I can see, which leaves them not only merely equalling Novell/SuSE, but beaten by both Intel and Catalyst. Tsk! I guess we’ll have to wait and see if that changes when we can see the list of attendees’ companies in the booklet this year…

10 January 2008

Christine Spang: MIT Athena: Not Dead Yet

(Disclaimer: I work for MIT Information Services & Technology blah blah blah I am a student blah blah these are only my words and do not represent the opinion(s) of my employer.) Way back in the day in 1983, MIT started something it called Project Athena, which had the goal of investigating how computers could be used to enhance education at MIT. This project became the origin of such pieces of software as the X Window System and Kerberos, as well as a campus-wide network of workstations all running similar software. In 1991, Project Athena ended, but the Athena system continued on, taken over by MIT Information Systems. It’s 2008, and Athena still exists at MIT—walk into a computing cluster, and chances are all the machines will be running Athena software. (Unless that particular cluster has been taken over be Athena’s evil sibling, often referenced as “WinAthena”, which often seems to be maintained by no one, and whose existence is sometimes denied by those who maintain and support Real Athena. Not many machines have suffered this agonizing fate, luckily.) Unfortunately, as the years have progressed recently, fewer and fewer resources have been put into the development of Athena. In many ways it is no longer on the cutting edge of things as it has been in the past, though it is certainly still useful. Some students these days, however, even think of Athena as only “their MIT email” or maybe use it occasionally to print something in a cluster on the way to class. I’ve seen people grow frustrated and storm out of a cluster due to things like instructions for using a flash drive that involve more steps than just plugging it in. While on the one hand it’s easy to laugh at people for a lack of patience or being open to a computing system that is not either Windows or Mac and perhaps a bit more complicated on the surface, on the other hand, some of these things really should just work by now, and on other UNIX-based systems they do—but Athena has lagged behind. When you log into an Athena workstation for the first time, you are confronted with what looks like this: Clean MIT Athena login That’s GNOME 2.8, and it looks kind of like the GNOME 2.8 default but uglier. When you look under the hood, there are pieces of the system that obviously originated in a time where nothing better existed and so something new had to be created—the “xlogin” login system doesn’t support PAM, and the login path involves a hairy maze of scripts that perform various tasks. Under the hood, the base OS is currently RHEL 4 or Solaris 10. I still can’t remember what the right options are to feed RPM whenever I need some information that I think I should be able to get from it. These things were once necessary but today just look crufty. Some people have tossed around the idea that everyone has a laptop these days and thus clusters are uselessly expensive, but it’s been met with a lot of resistance. I’m all for progress, but I use clusters all the time! They’re one thing that makes it an easy choice for me to have a really portable laptop, because when I really need computing power or screen space on campus away from my room, there is always a cluster nearby. They’re also nice isolated places that can be associated with “work mode”, which is good for productivity. Beyond all this, Athena provides a common platform that all technical classes can depend on, from providing standard and specialized academic software to standing as a baseline of “make sure your code works on this before handing it in because that is how it will be graded”. At any rate, things are finally happening on this front. Athena can’t stay RHEL 4 forever—while AFS allows non-system software to be easily updated for all machines without requiring any OS release, hardware moves on and compatibility is lost, and the rest of the world is coming up with new awesome things that Athena machines are missing out on. A student group that I am vaguely involved with, SIPB, took the early initiative with this and created DebAthena, which takes stock Debian and Ubuntu and allows it to closely resemble an Athena environment. We even run a campus Linux dialup using the packages. (I won’t claim to have done much work on DebAthena myself because, well, I didn’t.) Amazingly, the Athena release team has decided to work with the SIPB on the next release of Athena. So, what I really just wasted over 600 words prepping for is to say that Athena 10 will be based on Ubuntu. This is only relatively new news, but I am lame about finishing blog posts. There are a variety of reasons why Ubuntu was chosen over Debian. Some of them are lame and some of them are not. Even so, I am excited about this prospect—and it should be possible to peripherally support Debian in such a way that was not possible with Athena 9.4. I really like Athena. Even coming to MIT with a background in Linux there has been a steep learning curve, though, and I think that things could be better. Lots of people here have their first encounter with a ‘nix system in the form of Athena, and we should strive to make that experience as good as possible. I’m kind of skeptical on the expected release date of this upcoming summer, but as long as it happens soon it will be a big step forward. In some ways it’s kind of sad that I’m excited about a big part of a research institution catching up with others—but inertia is a strong force, and dealing with thousands of workstations is no trivial task. I kind of long for the exciting days of creating new big pieces of free software like X. I bet I imagine those days as being better than they actually were.

9 January 2008

Eddy Petrișor: my laptop is back

Yesterday I got my laptop back. It was in service since the 6th of December.

They replaced the battery, and although it looked like the built-in charge indicator was defect, actually the button on this battery is buried deeper than it was on the previous one and I have to press really hard on it to trigger it.

According to the tests made yesterday night, this battery holds for about 2.5-3 hours when playing music. Also it has 96% of its designed capacity. I guess is OK enough since I don't want to be spared from my laptop anymore.

Next on the agenda:
BTW, I still hold to my opinion that Dell and Emag suck, although I might buy desktops from Dell, laptops are a no-no until they fix their broken batteries and their broken "1-year warranty for batteries" policy.

[1] I bought a new NSLU2 after I left my laptop in service and it has been waiting since then to run the Debian Arm EABI (armel) port

6 January 2008

Wouter Verhelst: Broken C code: followup

I received a number of comments on my previous blog post, with people stating that my example code wasn't right, either. For reference, here's my code snippet again:
#include <stdio.h>
void* f();
int main()  
	long* a;
	a=(long*)f();
	printf("%Ld\n", *a);
	return 0;
 
void* f()  
	static long a=84;
	printf("%Ld\n", a);
	return &a;
 
First, let me make one thing perfectly clear: the "a" variable is not on the stack. It is a locally-scoped variable, but it is also declared as static, meaning that it's valid for the entire run of the process; if it were on the stack, then this variable would vanish when the function would end. Yes, it's wrong to return a pointer to a variable on the stack, since there's no guarantee that the stack value will still be valid; but I'm not doing that. Alternative implementations could've used a global variable, or could've malloc()'ed a pointer; but the compiled assembly code for my C code will only differ from a version with a global variable in the used label for the variable's location, and in the lack of an extra function call from a version that uses malloc(). Second, no, using A0 as a return value for pointers is not a bug in the compiler, and has not been since 1990, when this interesting book entitled "System V ABI Motorola 68000 Processor Family Supplement" was written. Allow me to quote a snippet from page 3-14 of that book:
%a0Pointer return values appear in %a0. When calling a function that returns a structure or union, the caller allocates space for the return value and sets %a0 to its address. A function that returns a structure or union value places the same address in %a0 before it returns.
To this day, ELF-conforming implementations do it this way. Really. Go look it up, if you wish; the ISBN is 0-13-877663-6.

5 January 2008

Simon Richter: Christmas cooking

The general idea on the 25th was to relax, watch some , and generally do not care too much about anything. Right, only after 13 episodes of ("Crest of the Stars") hunger set in, and it being late at night on a holiday, we scrounged the kitchen for things that might fit together. Idea 1: Let's make Spaghetti Alio e Olio. — Well, no Spaghetti in the house. So replace them with Farfalle. Idea 2: We could also add some onion. — Splendid. Idea 3: We could add sugar to the onion. — Yay, caramel. Unforeseen Circumstance 1: Whoops, not that much sugar. Idea 4: It being Christmas, and the food being awfully sweet now anyway, let's add apples and cinnamon. So, I present the ultimate Christmas dinner, featuring: And it tasted quite good, actually. I shall remember to buy more food before the holidays next year though.

3 January 2008

Ond&#345;ej &#268;ert&iacute;k: SymPy/sympycore (pure Python) up to 5x faster than Maxima (future of Sage.calculus?)

According to this test, sympycore is from 2.5x to 5x faster than Maxima. This is an absolutely fantastic result and also a perfect certificate for Python in scientific computing. Considering that we compare pure Python to LISP.

Ok, this made us excited, so we dugg deeper and ran more benchmarks. But first, let me say a few general remarks. I want a fast CAS (Computer Algebra System) in Python. General CAS, that people use, that is useful, that is easily extensible (!), that is not missing anything, that is comparable to Mathematica and Maple -- and most importantly -- I want it now and I don't care about 30 years horizons (I won't be able to do any serious programming in 30 years anyway). All right. How to do that? Well, many people tried... And failed. The only opensource CAS system, that has any chance of becoming the opensource CAS, in my own opinion, is Sage. You can read more about my impressions form Sage here. I am actually only interested in mathematical physics, so basically Sage.calculus. Currently Sage uses Maxima, because Maxima is old, proven, working system and it's reasonably fast and quite reliable, but written in LISP. Some people like LISP. I don't and I find it extremely difficult to extend Maxima. Also even though Maxima is in LISP, it uses it's own language for interacting with the user (well, that's not the way). I like python, so I want to use Python. Sage has written Python wrappers to Maxima, so Sage can do almost everything that Maxima can, plus many other things. Now. But the Sage.calculus has issues.

First, I don't know how to extend the wrappers with some new things, see my post in the sage-devel for details, it's almost 2 months old with no reaction, which shows that it's a difficult issue (or nonsense:)).

And second, it's slow. For some examples that Sage users have found out, even SymPy, as it is now, is 7x faster than Sage and sympycore 23x faster and with the recent speed improvements 40x faster than Sage.

So let's improve Sage.calculus. How? Well, no one knows for sure, but
I believe in my original idea of pure Python CAS (SymPy), possibly with some parts rewritten in C. Fortunately, quite a lot of us believe that this is the way.

What is this sympycore thing? In sympy, we wanted to have something now, instead of tomorrow, so we were adding a lot of features, not looking too much on speed. But then Pearu Peterson came and said, guys, we need speed too. So he rewrote the core (resulting in 10x to 100x speedup) and we moved to the new core. But first, the speed isn't sufficient, and second it destabilized SymPy a lot (there are still some problems with caching and assumptions half a year later). So with the next package of speed improvements, we decided to either port them to the current sympy, or wait until the new core stabilizes enough. So the new new core is called sympycore now, currently it only has the very basic arithmetics (and derivatives and simple integrals), but it's very fast. It's mainly done by Pearu. But for example the latest speed improvement using sexpressions was invented by Fredrik Johansson, another SymPy developer and the author of mpmath.

OK, let's go back to the benchmarks. First thing we realized is that Pearu was using CLISP 2.41 (2006-10-13) and compiled Maxima by hand in the above timings, but when I tried Maxima in Debian (which is compiled with GNU Common Lisp (GCL) GCL 2.6.8), I got different results, Maxima did beat sympycore.

SymPyCore:

In [5]: %time e=((x+y+z)**100).expand()
CPU times: user 0.57 s, sys: 0.00 s, total: 0.57 s
Wall time: 0.57

In [6]: %time e=((x+y+z)**20 * (y+x)**19).expand()
CPU times: user 0.25 s, sys: 0.00 s, total: 0.25 s
Wall time: 0.25

Maxima:

(%i7) t0:elapsed_real_time ()$ expand ((x+y+z)^100)$ elapsed_real_time ()-t0;
(%o9) 0.41
(%i16) t0:elapsed_real_time ()$ expand ((x + y+z)^20*(x+z)^19)$ elapsed_real_time ()-t0;
(%o18) 0.080000000000005


So when expanding, Maxima is comparable to sympycore (0.41 vs 0.57), but for general arithmetics, Maxima is 3.5x faster. We also compared GiNaC (resp. swiginac):

>>> %time e=((x+y+z)**20 * (y+x)**19).expand()
CPU times: user 0.03 s, sys: 0.00 s, total: 0.03 s
Wall time: 0.03


Then we compared just the (x+y+z)**200:

sympycore:
>>> %time e=((x+y+z)**200).expand()
CPU times: user 1.80 s, sys: 0.06 s, total: 1.86 s
Wall time: 1.92
swiginac:
>>> %time e=((x+y+z)**200).expand()
CPU times: user 0.52 s, sys: 0.02 s, total: 0.53 s
maxima:
(%i41) t0:elapsed_real_time ()$ expand ((x + y+z)^200)$ elapsed_real_time ()-t0;
(%o43) 2.220000000000027


Where GiNaC still wins, but sympycore beats Maxima, but the timings really depend on the algorithm used, sympycore uses Millers algorithm which is the most efficient.

So then we tried a fair comparison: compare expanding x * y where x and y are expanded powers (to make more terms):

sympycore:
>>> from sympy import *
>>> x,y,z=map(Symbol,'xyz')
>>> xx=((x+y+z)**20).expand()
>>> yy=((x+y+z)**21).expand()
>>> %time e=(xx*yy).expand()
CPU times: user 2.21 s, sys: 0.10 s, total: 2.32 s
Wall time: 2.31
swiginac:
>>> xx=((x+y+z)**20).expand()
>>> yy=((x+y+z)**21).expand()
>>> %time e=(xx*yy).expand()
CPU times: user 0.30 s, sys: 0.00 s, total: 0.30 s
Wall time: 0.30
maxima:
(%i44) xx:expand((x+y+z)^20)$
(%i45) yy:expand((x+y+z)^21)$
(%i46) t0:elapsed_real_time ()$ expand (xx*yy)$ elapsed_real_time ()-t0;
(%o48) 0.57999999999993

So, sympycore is 7x slower than swiginac and 3x slower than maxima. We are still using pure Python, so that's very promising.

When using sexpr functions directly then 3*(a*x+..) is 4-5x faster than Maxima in Debian/Ubuntu. So, the headline of this post is justified. :)

Conclusion

Let's build the car. Sage has the most features and it is the most complete car. It has issues, some wheels need to be improved (Sage.calculus). Let's change them then. Maybe SymPy could be the new wheel, maybe not, we'll see. SymPy is quite a reasonable car for calculus (it has plotting, it has exports to latex, nice, simple but powerfull command line with ipython and all those bells and whistles and it can also be used as a regular python library). But it also has issues, one wheel should be improved. That's the sympycore project.

All those smaller and smaller wheels show, that this is indeed the way to go, but very important thing is to put them back in the car. I.e. sympycore back to sympy and sympy back to Sage and integrate them well. While also leaving them as separate modules, so that users, that only need one particular wheel, can use them.

2 January 2008

David Welton: Tcl and Tk 8.5 out

Actually, they were out a few weeks ago, but I've been on vacation at the in-laws' near Monselice, Italy. The release announcement is here: http://www.tcl.tk/software/tcltk/8.5.tml It's worth writing about, because it's been a long time in the making, and contains a number of improvements. Particularly noteworthy in my opinion are 'real' hash tables (dicts), an even better sandbox model (Tcl and Java have the best sandboxes that I know of), and a theme engine for Tk that, in the right hands, significantly improves how it looks. In the fickle world of language fads, Tcl doesn't get the respect that it should these days. Like anything, it has problems, but what doesn't, when examined up close? It's ironic that for years it has gotten things right like Unicode support, and OS-level threading, that are currently being worked on in Ruby. Hecl obviously owes a great deal to Tcl, but since it's a new language (more or less necessitated by cell phone limitations), we're free to take a stab at improving things that Tcl doesn't get right. In any case, Tcl is worth a look if you want to play with something that's fundamentally different from a lot of popular languages, and the core team has put a lot of work into the latest release, so give it a whirl (perhaps using tkcon instead of the readline-less tclsh executable) with an open mind, and see if you don't learn something new.

28 December 2007

Lior Kaplan: conffiles, newer packages and purging


Earlier this month Kumar Appaiah opened a bug against the culmus package as part of the stable -> unstable piuparts upgrade tests. First, I’m proud in Debian to have these tests. Thanks for the people involved with running them, parsing the log files and reporting the bugs. I really feel the lake of such checks in commercial distributions I work with. After finding the time to get to the bottom of the bug, and talking with Kumar, it seems most of the bugs found in the test are similar. I think this might indicate something wrong in a more basic level of the package handling. The source of these bugs is how to handle files which were conffile in version x, but aren’t included in version x+1 (as a regular file). In the common situation, the conffiles are removed only during the purge process and not during upgrade or removal. But if a conffile doesn’t exist in the x+1 package, no one will “own” it after the upgrade, and no will purge it in due time. This is why changing conffiles can result in extra files on our system, which is the problem discovered by the recent piuparts test. One solution will be that each package maintainer will add the necessary code to the maintainer scripts to remove the file on upgrade. A second solution is to decide the wanted behavior in such a case and to have dpkg handle it for all packages. The behavior can be to remove the old conffile during the upgrade (postinst script) or to dynamically add it to the list of files owned by the package. Although technically possible, I’m not sure if the second method is “legal” with the debian policy. I thought it would be better to hear others’ opinions before submitting a wishlist bug about this.

23 December 2007

Wouter Verhelst: They managed!

It took them half a year, but the Belgian federal politicians finally managed to come up with some form of government. I can't say I'm impressed. Well. In a way I am impressed. After trying for 6 months, Leterme still failed to produce some form of government. Since the situation was becoming quite dire, the King gave Verhofstadt the initiative, who then promptly produced a government in only two weeks. Granted, Verhofstadt's mission was not as hard as Leterme's. Verhofstadt was told to form a government only to handle the most urgent matters, and which will be disbanded at Easter; Leterme was asked to form a government to last for four years, which is how long a Belgian federal government usually holds office. And yes, Leterme's mission has most likely been one of the hardest one in the history of Belgian formation talks. But even if all that is true, I'm baffled at the fact that the intention now still is to make Leterme the prime minister at or around Easter. In my opinion, he's had his chance and blew it. Then again, maybe I'm biased. I've never liked Leterme; and when his party CD&V decided to ally themselves with a separatist party, I decided to gracefully extend my antipathy to his entire party.

18 December 2007

Martin F. Krafft: Taxes and wars

I was considering importing my car to Switzerland. When I moved in 2002, I asked the customs office about the process and was told that I'd need to pay taxes and fees, so I postponed the import until Day Unknown. Today, a very friendly customs official told me that this is not true and that I could have imported my car duty-free if I had done so as part of my move. Slightly annoyed, I went on to discover what those duties would be today. I found out that there are seven different types of fees I'll have to pay, and tried to understand the reason for these fees:
  1. To import a car, you need a form 11.010, downloadable from the Swiss Customs Office. Because each download causes extra work for the administrator, they charge a nominal fee of CHF 0.70 to get the PDF file.

  2. I take that form to the customs office. There, the officials will assemble around the car and attempt to lift it. I don't know why they do that, but they charge you between CHF 12 and CHF 15 per 100kg of weight. I think it must be recompensation for the hard physical labour. Also, each customs official can lift 100kg, which explains those figures they seemed a bit arbitrary at first.

  3. Next, they'll ask 4% of the estimated value of the car as a car tax. They do this because the value of a car is directly related to the area it covers, and since Switzerland is so small, you effectively have to buy a couple of square metres for the car. It's not quite as easy as that though: once I bought the area under my car, I have to move the car away, because I cannot park my car on the area I just bought. I have to buy parking space for that. If I don't want to buy a parking space, I have to keep the car moving. In order to keep the car moving I need to fork over CHF 40 per year for a permit to drive the car on Swiss highways.

  4. Now, I pay 7.6% value-added tax. It makes no difference that the car isn't new, that I am not selling or buying it, nor that I have already paid 16% VAT in Germany when I bought it. Since I am about to "consume" the car in Switzerland, I have to pay consumer tax. Since I also consume the physical labour the officials put into the car lifting exercise, as well as the area under the car I bought, I pay VAT for (car value + lifting tax + area under car). Unfortunately, the European Union will not pay back the consumer tax I previously paid as part of the export, since I already consumed the car there.

  5. I then get a report about the import. This costs CHF 20. I don't need this report, but I have to buy it. The reason is that the computer admins are so overworked serving PDF files to future importers that they have not had time to stop the computers from printing this report, and the special paper and toner used by all administrative offices in Switzerland costs about CHF 20 per page. An alternative explanation is that CHF 20 is the smallest bit of "money" in Switzerland, everything else is "change".

  6. I will also have to pay annual taxes for possession of a car, the value to be determined by the custom officials. Since I already paid for the area under the car while moving and while stationary, I think the annual car tax is levied for environmental reasons. A lot of people drive through Switzerland to get from Germany to Italy or from Austria to France, pumping a lot of exhaust gas into the Swiss air. This makes them guilty, just like inhabitants of Switzerland who own a car are guilty. Due to legal reasons, the Swiss government can only punish Swiss people for those sins, so the annual car tax is a little higher to cover for all environmental damage. It is doubtful where the money goes, though. I also have to continue paying taxes in Germany, because I still have a residence with my parents.

  7. Finally, I have to purchase a car insurance. That insurance does not insure the car, it insures the others on the road. Actually, it is a driver-car-dependent insurance, meaning that the others are insured only if I am the driver of my car. If I drive another car, or someone else drives my car, the others will not be insured. unless I pay higher insurance fees. Because cars with a larger area under them and those that require more people to lift them are more dangerous, the insurance fee is proportional to the car density. At least I can give up my German insurance and be covered by the Swiss insurance. However, I cannot keep my German insurance and be covered in Switzerland. I think this is because the head of customs department and the CEO of the insurance company have sex with each other.

It's been a great day, given how much I learnt. I finally understand why people have fought wars over taxes. I think I may leave the car in Germany. PS: Yes, this post may be considered hyperbole. NP: The Pineapple Thief: 8 Days Later

11 December 2007

Nico Golde: grml-paste

Today mika mentioned in the #grml channel that it would be nice to have a command line tool to paste to the online paste bot.

I wrote a small ruby script for this today. Since it is pretty easy to adapt it for other paste bots like the Debian paste bot on paste.debian.net and mika reads this weblog as far as I know, the result is:
http://nion.modprobe.de/grml-paste

Wouter Verhelst: Hardware sucks, but their manufacturers too.

A while back, I needed to do something with a mainboard made by Intel. The mainboard doesn't have a PS/2 connector; so I had to use a USB keyboard. In itself, this is horrible; USB is an incredibly bad interface to connect a keyboard to, IMO. But, well, sometimes the decision isn't yours, you know. Bad Intel. Given my above-stated opinion on USB, I guess it's not surprising that I don't have a USB keyboard; I don't believe in them. But, well, a mainboard without a PS/2 connector doesn't suddenly get one because I look at it, so I went to a nearby computer shop with the intention to buy me a keyboard. While it's bad enough that I had to get me a USB keyboard, they managed to make things worse. The particular model that I'd bought is broken in ... well, let me count the ways.
  1. Blue LEDs are annoying. Yes, a keyboard needs LEDs to show that num lock (etc) are enabled, but a yellow LED works too, and is far less flashy or distracting.
  2. A "Fn" key is nice if you want to overload keys on your keyboard. However, if there is not a single key on your keyboard that is overloaded using the Fn key, then you're silly.
  3. The particular model used a "condensed" layout, rather than the standard 105-key be azerty layout. I'm used to the standard 105-key keyboard layout, and having to type on one that is different is no fun. When I mentioned this to the salesguy, he told me that I'd "get used to this pretty quickly". Well, perhaps if that were my only keyboard. But I also have my home desktop (standard 105-key layout), my laptop (apple azerty laptop layout), some m68k macs (mac azerty 105-key layout), and some more; then, it doesn't get so easy.
  4. They keys on the keyboard were flat as on a laptop keyboard, rather than thick as on a desktop. This makes it harder to disassemble when it gets dirty, with the risk of breaking it (I've had to have my laptop's keyboard replaced when I broke it by disassembling it because the keys started to get stuck and I wanted to clean it...)
Now obviously it's possible to fix most of these issues by simply buying a decent keyboard—except that the shops that I went to simply don't have a decent keyboard anymore these days. At least this one still had 105 keys; for reasons that totally escape me, some keyboard manufacturers today seem to think it's a good idea to drop the insert key on their keyboards. WTF? People just don't make decent quality keyboards anymore these days... Bad hardware manufacturers. Bad, bad, bad!

10 December 2007

Lior Kaplan: Load Balancing Jboss with Apache and mod_jk

Apache’s mod_jk has nice load balancing features. They work quite well for me with Jboss. The basic configuration is to install Jboss on several machines and have an Apache to load balance them. But while the load balancing is good, the Apache machine becomes a single point of failure. I was asked how to overcome that. The main principle I want keep is the “keep it simple, stupid” principle. Doing a round robin DNS between two machines is nice, but doesn’t really provides real the load balancing (as it always does 50/50). It also doesn’t check for the the load before it does the balancing. Other options like using mod_backhand and mod_proxy_balancer all leave me with the same single point of failure problem. That’s why I prefer to use an active/passive cluster to make sure Apache can move to another server in case of a failure. The IP address the users get is a virtual (or floating) IP, which can “jump” between the cluster nodes. There are several ways to create that cluster, but that’s probably for another more general post. I’ll be happy to hear other opinions…

5 December 2007

Biella Coleman: Rethinking Blogs: The importance of fewer posts and preaching to the choir

It is hard to believe that I have been blogging for over five years. And what is clear is that being an assistant professor is not all that conducive for blogging and this is materially evident in my sparse posting pattern over the last few months. It has been particularly bad in the last month thanks to a week long international trip, back-to-back sickness over Thanksgiving week, and finally going to Washington D.C. for the AAAs. But this retreat from blogging as well as teaching on so-called Web 2.0 software, like blogs, has made me rethink the value and limits of the craft of blogging and so I am going to take some time (that I feel like I don t really have, but oh-well..) to write them down as I am preparing a short piece for on the politics of Web 2.0 and I hope I can transfer some of these ideas there. So as I have already mentioned, I am an now infrequent blogger. Prior to the era of RSS, this could have meant the death of my blog because if people went to visit my page and there was no new post and then this happened a few more times, they would just stop visiting. The magic of RSS is that it brings the blog post to you and this alters the landscape of possibilities within the context of what has been nothing short of a seismic explosion of blogs. What I am finding and this will be no surprise to anyone is that it is just too difficult to keep up too many of a certain class of blogger the prolific poster who posts medium to long posts and worse, nearly everyday! To make a point about the effects of this, allow me to tell a story: Two blogs I really like are Joe Reagle’s blog on Open Communities as well as Tenured Radical. Both provide captivating posts but I recently unsubscribed to Radical Tenure and not Joe Reagle s. Why? My decision was purely pragmatic. Because she posts way too much, I just can t keep up. If I stop reading her blog for 2 weeks, and then pay a visit via bloglines, I am faced with a blogolanche and I am trying to avoid, at all costs, overwhelming situations. On the other hand, if I stop reading Joe s blog for 2 weeks, there may be one or two posts so I feel like I can spare the time to continue reading. Ironically, I will now visit Tenured Radical every month, much as I did prior to the RSS era, just to take a quick scan and see if there is anything I must read. There is another class of blogs, such as Sivacracy, that update their site frequently but the posts are tidy and short and so I can usually keep up and they provide important news for my projects. But the type of blog that provides longer ruminations has proliferated (and I really like reading those) but I suspect that as the blogosphere has expanded, less people can commit to those types of blogs. In other words, today, you may hang on to more readers, if you only blog 1 to 2 times a week instead of 3-5 weekly posts that are medium to long in length. Now I may be completely OFF the mark with this by generalizing my own experience so I would be interested in hearing people s experiences or better, if anyone could point me to someone who studies these types of pattern, I would really appreciate it. On a related note, last week I taught a now famous piece by Cass Sunstein on political balkanization on the Internet that is in part secured by blogging. His core argument, which I think stands to some degree, is that the blogosphere is less an arena where people with different inclinations and views meet to debate, and thus change their views, but is an arena where your pre-existing ideas are reinforced because you are simply reading and debating with people who hold your worldview. As I mentioned, I think this is true in so far as you don t see people on the left and right engaging in some debate that substantially transforms their ideas. But the argument is faulty or missing something crucial about the nature of politics, in so far as that the so called left or right or so called liberal and conservative positions are truly not unitary so that if different types of liberals/lefties are engaging with each other to change positions and ideas within that group, well then, the critical function of blogging is in fact well and alive. To state using an example, there are plenty of liberals who, in my opinion, could use a little radicalization and perhaps this is happening in the blogosphere because people come across a spectrum of ideas and positions from within their political pole. Finally and this point really is not mine but I am poaching it from Jeff Juris who made it last weekend at the AAA meeting during his presentation on activist videos. One of his findings was that activists were the only ones watching video s documenting protests when hosted on radical political sites like Indymedia. When they were placed on Youtube, the audience expanded considerably: conservatives were also watching them, but they effect was not to make their more sympathetic toward the left and their political points, but simply to reinforce their position, which is evident in the archived comments expressing their great distaste of the left. This is a perfect example of the Balkanization that Sunstein talks about but with an important reversal: it comes from confronting difference not avoiding it! But Jeff made the excellent point that there is a critical function in preaching to the choir: it ensures that the choir will not stop singing! That is, your political passions are not simply ensured, they must be renewed and given the massive amounts of apathy peppering our population, renewal by confronting what you believe in, is vital. So my advice is keep producing posts, keep reading even if it tends to be stuff you already believe in BUT please, post less. Less, I think, is really becoming the new more….

Next.

Previous.