Friday, September 5, 2008

Wanted: Suggestions for Superheroine Moniker

(I know I've said before that I'd post all baby fluff in the other blog, but she's just too cute for words and I really want more people to see her, even if it's really just one more...)

Needing the service of a superheroine? Look no further than me, the... er... ah.... hmmm. I need a superheroine moniker. Any suggestions?




Hush. I just sneaked into the enemy's secret hideout and trying to find out where they're keeping the hostages.




I hear a scream! Hang on, I'm coming!




You ain't getting away, you baddie!




Take that! *POW* *SMASH*




Another day, another baddie in the garbage can. I'm off!

Sunday, August 17, 2008

Aging Laptop

(Just to remind anyone who wants news of Hui Ning, my new daughter — head on to my other blog. And if you decide to venture there do be aware that there might be TMI at times...)

My Fujitsu laptop's showing symptoms of age, even though I've only had it for about a bit over two years. Then again I showed it no mercy, using it for >16 hours per day frequently, coupled with the temperature in M'sia...

Bottomline is, the fan refused to work, even at startup, about 2 months back. I get a loud beep at boot-up and an erroring declaring that the fan system is off. I was trying to knock off some projects before the baby arrived, so I continued using the laptop anyway. It probably wasn't a good idea. A few days back I found that after about 30 minutes of usage (without air-conditioning), the graphics card seems to go all wonky: in Windows, the screen just froze. I restarted the machine, and I see vertical stripes interspersed with the usual BIOS startup splash. In Debian though, X.org seemed to work OK, but come shutting down time, the console messages are a bunch of garbled text.

Uh-oh. Sounds like some stuff are getting fried. Back-up time. And only use the machine with air-conditioning on when it's absolutely necessary (like uploading Hui Ning's photos and videos, heheh.)

Then today, immediately on startup, the vertical stripes were already there in the BIOS startup. Windows is rendered unusable as even the login screen can't be displayed. Debian though... ok so the startup console messages look like some pig-latin encrypted code, but in due time X.org starts up fine and I'm here writing this blog post while backing up whatever else I should be backing up. (Why do I feel like writing "We cannot get out. They are coming. We cannot get out."??)

This laptop goes to the service centre tomorrow — hopefully we're not too late.

Monday, August 4, 2008

Welcome, Baby Hui Ning!

Baby Hui Ning 慧宁 arrived roughly a week earlier, at 12:58pm on 30 July 2008. My water broke around 6a.m., so I guess my labour wasn't too long for a first child...



I'm still pretty exhausted (and time-constrained!) to blog much -- you know the drill ;-D In the meantime, here are some photos.

Tuesday, July 29, 2008

38 weeks



Until I saw myself on film I had no clear idea how big I've actually become....

1.5 weeks to go (assuming we're following strict due dates) :D !

Sunday, June 22, 2008

Double Yolk



I was making a quick snack and out popped this twin of a egg into the saucepan. (Sure, call me kampung to even want to blog about this.)

Tuesday, June 10, 2008

iMac in the house

After the desktop PC conked out yet again (the power supply this time), we've had it with PCs and Windows.

Result: We went out to Sunway carnival and got a spanking new iMac.



We love it. Lotsa things to explore.

Now we've got three OS'es in the house. BTW the wallpaper there is Semicolon from Vladstudio.com. (Also, the panda didn't come with the Mac...)

Sunday, May 25, 2008

Here in My Home



Nice song. Fun video (and I don't just mean identifying the personalities without looking at the credits). Soppy and too-good-to-be-true dream, though. Yes, I know I sound cynical. But I can't help the warm fuzzy feeling (and the sour cynical feeling) after listening/watching this.

The MP3 and QuickTime video can be downloaded for free at MalaysianArtistesForUnity. So go on, watch the video, download the mp3, embed the banner/video in your website/blog, spread the word. If only because it's a nice song.

free download

Update: I badly needed a LaTeX fix, so I re-typeset the guitar chords (original .DOC version available at the site above). The LaTeX-ed guitar chord + lyrics sheet can be downloaded here.

Update 2: This is weird. My baby kicks whenever I play the song. HARD. Yes sweetie, mommy hopes that this'll be a good home for you too. A better one than now anyway.

Thursday, May 22, 2008

Attack of the Sudden Visiting Researchers

(This is the last in a series of ranty posts, about the events of a particularly... "exciting" week. Yeah, I hear many sighs of reliefs — or is it just one since I really only have a readership of one? )

'Twas the morning before the ScienceFund project presentation, and I was waiting for CC to come to the lab so that I could set up the demo system on his laptop.

When suddenly...

Mr T appeared and told me to quickly come to the office, 'cos the main office just made a surprise call saying that a team of visiting researchers from a Thai university are coming down to each of the labs, so, yeah, get ready to receive them and show them around.

"When's that happening?"

"In, uh, like, 5 minutes' time."

Well thank you Main Office for the short notice. Though I guess everyone forgot everything else with the ScienceFund projects for the last one and a half weeks, so it's probably unfair to blame them.

Receive the visitors, eh. (And then what?) Mr Tan the word was to brief them about the research we do. Sure, get someone to talk, but we were in a bit of a fix: Dr T wasn't around. Dr R wasn't around. I was the only RO around in the lab at the ungodly hour of 11am (hey everyone was exhausted the whole week scrambling for the presentations and reports). Mr T had already dragged out Dr S, but she's into linguistics and not really crazy about the "computational" part — and on seeing me she said "Oh good, you're here. You can do the talking then."

Ack.

Then I remembered about the brochures for last year's open day, and luckily we still have a few copies lying around in the office. And then it's scurrying back to the lab to hopefully find a big enough space for 7–8 people to huddle around a computer monitor (Dr S' suggestion) and to hopefully locate some online demos that we can show (Dr C from next door's suggestion).

They came.

I gabbed. Tried to gab. Then showed them the online machine translation prototype, the multilingual lexicontology (yeah it's a mouthful, but the real project name is even worse) and the (not quite reliable) sense tagger.

Surprisingly the visitors were deeply interested (and even impressed with the sense tagger)! The questions they asked showed that they were no strangers to NLP. They even left name cards (which I yet again embarrassingly told them I didn't have one since I'm a mere down-trodden RO. ) En A who escorted them around said that of all the labs visited thus far, this lab was the longest time they spent.

On a side note — En A (sorta cluelessly) remarked that this was also the most run-down/unimpressive (something to that effect, dunno the exact word used 'cos this was re-told to me later by Mr T) lab they've seen that day. To which Dr S retorted "Well this is the lab where the people do real work!"

Microsoft Office 2007 to support ODF?

If what's reported in this PC World article is true, I'd be so happy. I can then happily work away on OpenOffice and e-mail them to all the other Microsoft Office users without converting them and getting a bunch of tables and bulleted lists wrangled in a the process!

Sunday, May 11, 2008

Attack of the LaTeX Typesetting Job Windfall

Well since it was a windfall I probably shouldn't call it an "attack" – but as we raced towards the end and with other stuff happening, it felt like it.

It was nearing mid-afternoon on Sunday and I was in the middle of downloading the latest versions of Apache Tomcat and PostgreSQL so that I could install my project system on Windoze, when I received an SMS from a USM PhD candidate. His conference paper was selected to be published in a Springer journal, but the catch was that it must be in LaTeX. He tried to learn it that morning (I greatly admire his courage), but gave up by afternoon. As it was a tight deadline he decided to offer me a bounty to do the job.

I'm always up for a LaTeX fix (it's the high I'm after not the $$, get that straight! ) so I said Yes. When's the deadline though? I was hoping that I could finish dealing with the ScienceFund project presentations first.

Tuesday, came the reply.

Yikes.

I decided that I still needed my LaTeX fix. Besides, this was my first paid LaTeX assignment! (Did I mention that it's the high I'm after and not the $$?)

The LaTeXing itself wasn't too difficult, although the conference organiser's failure to post the correct version of style files to be used made it a bit frustrating. We were told to go hunt the correct version down at the Springer website instead. Also a couple of not-so-trivial table formatting, but luckily the trusty LaTeX Companion book was ever helpful. In the end what proved to be my downfall were typos. With the deadline fast approaching we went absolutely frantic with the to-and-fro e-mailing and SMS-ing. These keep turning up till 11.59pm on Monday night, when I just couldn't hold my eyes open nor my head up anymore, and had to call it a night. Luckily my client didn't come across any more typos after that, and he submitted the paper in the morning.

(I'm really sorry about all those typos, J!)

In hindsight I probably charged a bit too low for so much effort, especially with my tight deadline and packed schedule at the time. I guess I should consider it as a First Client Discount though.

So if you have any LaTeX typesetting job (for a fee), why not try dropping me a line? It'd help a lot if you also attach existing text in soft copy (Word etc) if any, as well as information about the formatting or style guidelines required. A link to the conference organiser's or journal publisher's web page providing such info should do. A comfortable timeline for both you and me would be one week at least, so that we'd have time to review the outputs. Anything shorter than that and I'd either have to turn down the job or charge extra.

Please note that I will not typeset your thesis for you, though. I'd be happy to offer advice and answer questions on how to use the USM thesis template, or even design your university's template for you (price negotiable), but not typesetting your thesis itself.

And remember – I do things like this for the fun of LaTeXing, not for the money! Me, crazy? Sure, why'd you think I name this blog what it is now?

Well cheers, folks!

Saturday, May 10, 2008

Attack of the Sudden Nation-wide ScienceFund Project Evaluations

This, dear reader, is going to be the first in a continuous series of ranty posts. It's been an... exciting week for me.

Here's the chronology:

Apr 29, 11am:
The first inkling I had, was a fleeting comment from C.C. about his having to go down to Putrajaya on 7 May to present a ScienceFund project he's involved in. I thought his project was picked on by random, because that's what happened to another researcher before. Then he told me it's actually because MOSTI is requesting all the 1st cycle projects (ending May '08) to this evaluation/presentation workshop, so that they can decide whether they'll release the last payment.

O_O

What about my project on the multilingual dictionary then? Haven't heard anything. But I suppose all correspondences would've gone to Dr C's mailbox and she's on extended medical leave...

C.C. checked against the list of projects he had and told me my project wasn't listed. So it doesn't concern me then...

Apr 29, 1.15pm:
Back from lunch, and found a note on my table from Mr T. Well well weeeeell, whaddaya know. There's a second list of projects circulated just this morning and my project's slotted for 7 May, too. Talk about short notice.

It's all a bit spooky though, since I just finished all the programming and put the servlets online last week, and was actually going to update Dr T and Mr T via e-mail anyway.

After a quick discussion with Mr T, he went into doc compilation overdrive mode (harrassing Bendahari and RCMO for the respective docs, photocopying whatever docs and receipts he has on hand etc), and I went into PowerPoint overdrive mode. The best part is that many academics are on leave one day or another this week, since Labour Day is this Thursday, and – wait for it – almost all USM clerical staff are attending a seminar this week!

At least we didn't have to rush up on the technical development stuff. Also, Dr T will be around Cyberjaya/Putrajaya on 7 May (he'll be at a seminar in Port Dickson until 6 May) to present the project, so I won't have to travel down. Although Sara commented that if I went down nobody'd dare ask too many questions on seeing my bump...

Apr 29, 6pm:
MOSTI just won't disappoint – Dr T e-mailed to say that there's been a THIRD list and now one of his projects (in 2nd cycle) is also slotted for presentation, also on 7 May!

Apr 30:
Got most of the slides in order by last night, so today it was mainly checking over them and help brief H.H. and C.K. for Dr T's project.

Holiday tomorrow – don't care, am going to kick back and relax.

May 2:
It wasn't until late evening when the financial details came in, so I incorporated those at night. Also got together a bunch of documents to be printed out in hard copy first thing on Monday. Apparently there was also some RSVP slip (e-mailed out today) that had to be returned to MOSTI by... today. Eugh. Hopefully Dr T saw it; anyway I SMS'ed him to check his inbox in case he didn't.

May 3, around noon:
Dr T called in the morning – apparently he's already in Port Dickson since yesterday! Quickly called Mr T who's back at the office to continue all the photocopying. We'd have to send the RSVP on Dr C and Dr T's behalf; and hopefully it'd land in the right inbox since apparently we need to RSVP to different people for different panels...

Suddenly remembered that I'd better check with C.C. that he's sticking around in Putrajaya long enough to be in time to pass the projects to Dr T! More SMS frenzy. Turns out that they have the first slot 9.00–9.30am and plans to fly back to Penang by noon! More SMS frenzy to Dr T to see if he can make it to Putrajaya in the early morning.

Then decided to forget all about it as Dr T couldn't respond just yet (he's at the seminar remember?). Went to RedBox to semi-celebrate husband's birthday, semi-release stress (both of us needed a break), before heading to the World Music Festival (will blog that later! ) in the evening...

May 3, 7pm:
Was at the Botanical Gardens for the World Music Festival when C.C. sent an SMS saying that Dr T has arranged for him and H.H. to stay overnight at Dr T's place on 7 May – so no problem for him to hand over the docs to Dr T then!

Ah bliss.

But little was I to know...

May 4, 11am:
Got a call from Dr T asking me to install my system on C.C. or H.H.'s laptop, just in case there's no internet connection at the workshop venue. And we all know how very true that can be.

Yikes. I've never tried installing it, especially PostgreSQL with all that huge amount of data, on Windoze before!

May 5:
Stupid. Windoze. Wouldn't. Print. To the lab printer! Eventually I had to delete the printer, restart Windoze, add the printer again, for it to work. Bah. Well by noon I finally managed to print whatever docs I needed. Finalised the presentation slides and docs with Mr T in the afternoon, and he carried off the docs for binding/compilation.

I had to switch tracks a while and get rushing on a LaTeX typesetting job due the next morning, or today midnight... (more on that in another post.) Then spent the whole evening trying to work out the system installation/config/setup details on Windoze, till midnight. I'm getting worried. Them conceptual vectors data are really huge and seem to take a looooong while to load into the database.

May 6:
Sudden Attack of Visiting Researchers (more about that in a later post) in the mid-morning rather threw all of us off-balance. It was after lunch when I could start trying to set up the system on C.C.'s laptop. To my surprise it took less time than I expected – a bit over 2 hours. However PostgreSQL just managed to start up once: it refused to start again after I shut it down, so that I could show C.C. how to launch everything. As we were all damned tired I told C.C. and Dr T to use the demo video I created with CamStudio. The sense tagger can't run locally off the laptop anyway if the internet's inaccessible since it relies on our FDG server.

I hit home after burning the presentation slides and video onto a CD and passed everything to H.H. and C.C. I'm beat.

May 7:
So this is the day – but I slept in late anyway. Too, too tired. But I still made it to the lab relatively early (10am) to make sure that the server was still running. In the meantime Dr T called to confirm a few points in the slides; then C.C. called to tell me that while they do have Internet access there, the firewall blocks all requests to ports other than 80 (HTTP), both ingoing and outgoing.

Huh?! How stupid can that be?? They've probably just voided out all Apache Tomcat-based applications, and then some.

C.C. also appeared to have found what's wrong with the PostgreSQL installation; apparently I made a typo in postgres.conf! Once that's corrected, everything's running as expected – well except for the sense tagger, since it sends requests to port 8080 on the FDG server – and that's blocked. Meh. Luckily we still have the video.

In the afternoon C.C. SMS-ed back to say that they've finished all the presentations and the panels seemed satisfied. What a relief! (Although for some reason, the MOSTI people requested to bring back all the docs for my project with them.)

And now to bed! And now to bed!!!

Wednesday, April 30, 2008

iGoogle Artist Themes

You can now customize your iGoogle page with themes by contemporary artists. They're all interesting, but some are definitely acquired tastes. :-D




Monday, April 28, 2008

A website of colours

I'm really lousy when it comes to picking colours, especially if it's fiddling with RGB code to produce anything that looks remotely interesting. Luckily for me though there's COLOURlovers. Community users (called "lovers") post their concocted colour palettes, and can be downloaded as GIMP, Photoshop or HTML etc format. The blog posts are interesting reads, too. It's all really very nice.

delicious citrusCapuccino
Bibi of the snowStapelia Flavopurpur

Tuesday, April 22, 2008

More kitty fluff

Awwwwwwwww me want!!! Me want!!!





Saturday, April 19, 2008

Fractal Google Gadget

Mmmmmm. More eye candy...

Monday, April 14, 2008

Wow. Hibernate worked!

On my Fujitsu laptop. Running on Debian. Wooow.

Debian yammered about starting the snapshot process (checkpointing, Hussein sez) and proceeded to write n number of pages. Once that's done, the laptop powered down, and I went out to dinner. When I powered on the computer again, what greeted me was the GRUB menu. And I was thiking "well so much for false hopes..."

Once I booted into Debian though, it started to yammer about resuming from n pages of image (checkpoint-restore, Hussein sez) and voila! It's back to exactly where I left off!

Both the checkpointing and restoring took longer than in Windows, though.


ps: Apparently Hibernate is not expected to work usually:

<obiwan> hey guys
<obiwan> 'Hibernate' actually worked for my colleague.
<ahu> .. once
<ijuz> probably some new drug
<obiwan> No, it really worked

Hahahahahahaaaahahaha! :D

Saturday, April 12, 2008

Viruses never looked so good


MIT grad student Alex Dragulescu was asked to turn viruses, spams and spywares into graphics with visualisation algorithms -- and the eye candies that emerged are simply c00l. (The thing at the top is MyDoom.)

Saturday, April 5, 2008

The other blog -- on Fluffy Baby Stuff

My friend Hussein was expressing his trepidation of me spouting fluffy baby rants on this blog once it comes into this world come August. (I suspect he's also rather apprehensive of having cases of TMI.)

Fear not, friend. I promise that all baby fluff stuff will be posted at this blog -- since such fluff doesn't really "fit" here anyway (think baby talk, brand comparisons of baby cribs etc). So you don't have to read all about it if you don't want to, simply don't subscribe to the other blog feed. ;-)

One thing, though: kitty fluff do belong here! Any questions?

Lost Li'l Bird

This little guy got lost and made his way into our house the other night.


It was getting quite a bit confused, chirping, hopping and flying around the house in frustration for not being able to find its way out of the house again. Eventually we had to turn off all the house lights except the porch light to guide it out again.


Monday, March 31, 2008

HAL's Legacy

Quite a while back, while I was surfing for "fun" bits of information to be included in some course notes, I came across this e-book version of Hal's Legacy.


Hal (or more formally, Hal-9000), as you might recall, is the supercomputer in the science fiction book/movie classic 2001: A Space Odyssey who (yes, I insist, who) eventually committed murder in an endeavor of self-preservation. Hal's Legacy is a great book for students interested in artificial intelligence, natural language processing, robotics, or just geeks in general. And it's online in its entirety for free!

Enjoy!

Thursday, March 6, 2008

牛奶+柠檬+蜜糖+薄荷牙膏

肚子里的小瓜总在我进食后呱呱叫,胃又好胀好胀气,心烧了又烧……

四处搜索,多番尝试下,竟然发现以下几个方法可行:
  1. 蜜糖泡水,再加一片柠檬。(冷热随喜)
  2. 牛奶!反正牛奶是最容易汲取钙质等营养的饮品。
  3. 饭后勤刷牙,尤其用薄荷牙膏——据说口腔清爽可以减少胃酸分泌。

Thursday, January 17, 2008

iGoogle Theme Fest!

Good news to "personalisation" fans out there - Google just released the iGoogle Themes API so that you can create (and post) your own themes!

A slew of new themes have been posted, and expect more as people start to pounce on the Themes API. Here are a few to whet your appetites:

"Earth-Light"


"Adventures in Lollipop-Land"

"Countryside"

Thursday, December 13, 2007

New USM Thesis LaTeX Class Files

I just uploaded the new USM Thesis LaTeX class files (usmthesis 1.2) at http://liantze.googlepages.com/latextypesetting#usmthesis, to be compatible with the new thesis guidelines effective from Dec 16 2007 onwards.

Major changes:
  • Body font is now Times Roman for serif type, Helvetica for sans serif type, and TX Typewriter for typewriter font.
  • Bottom page margin increased to 4.0cm.
  • Page number now placed 1.0cm from bottom edge of paper.
  • All text on title page are now in bold.
  • Title of bibliography/references is now "REFERENCES".
  • Introduced new "plate" float and "List of Plates".
  • List of Publications is now moved to after appendices.
  • Re-formatting of the table of contents:
    • all text are unformatted (chapter headings are neither in bold nor using larger font size
    • otted leader between titles and page number
    • larger separation between (sub)section numbers and titles to resemble the sample in the guidelines more closely
  • Fixed bug in definition of \chapter to honour short title in \chapter[short title]{full title}
Enjoy!

(p/s I've yet to blog about our recent participation in the 11th International Conference on Translation in KL... I wonder if I'll ever get round to it?)

Tuesday, November 27, 2007

New Google Themes

You now have another 5 new delicious themes for your Google personalised page! Here I'm using the Hong Kong theme. Enjoy!


Friday, November 2, 2007

Drunken Kitten

Still under effect of a sedation after visiting a vet. (S)he's such a cuuuuute lil' kitty... nak cubit...

Tuesday, October 16, 2007

LocoRoco: Yellow Rolly Ball of (Weird) Cuteness

I can't possibly find the appropriate words to adequately describe this game. It'd be best if you watch the promotional trailer and experience the demo yourself instead:



Wednesday, October 10, 2007

That's... creative, dear



I might consider having kids if I could get away with this >:-D

Although, my husband and our parents are unlikely to concur...

Monday, October 1, 2007

天野喜孝 Yoshitaka Amano and Sandman






I've always been fascinated with Yoshitaka Amano's(天野喜孝) artwork, especially his illustrative work. He's greatly known for his character design for the Final Fantasy series, and also (perhaps not so greatly known) for the Gatchaman anime series (a.k.a. G-Force, soon to be a motion picture... erk. I'm not sure if I'm looking forward to that, though.)

To the joy of fantasy fans everywhere, Amano collaborated with Neil Gaiman to produce a Sandman graphic novel, "Dream Hunters" (1999). The story is actually a re-telling of a Japanese legend/story, set in Heian-era Japan (or so I think, since Onmyouji 阴阳师 and "classical" Japanese supernatural beings figures largely in the plot) -- which makes Amano's flowing style rather relevant. There's something Klimt-ish about his work in "Dream Hunters".

Gaiman's clever style here could've fooled me into thinking that this was something translated directly from a Japanese source! (Well, it is a re-telling of a Japanese story but still, I'm really happy that he took this approach instead of "Westernising" it. :p)

Monday, September 17, 2007

歌神降临

歌神降临,雨神助威!(还是来搞局的?一开场灯光一暗下就马上下雨……)

两个字,过瘾!(虽然学友的感冒还是有少许影响……)经典歌还是占了大部分啊。快歌也不少。招牌的兰花指全场没少过。“发癫”又如何?我们陪你癫过!比起新加坡人来,大马人还是比较癫的。(不然也不会有敢死队胆粗粗跑去关仔角等看海啸,真是服了。这个我就不敢陪各位敢死英雄癫。)

还要再来哦!(但算我怕了 KL 的神经交通……)

Friday, August 24, 2007

Ladybirds Red and Bamboo Leaves Green






(Well, I'm sorry that my garden is so boring, I'm sure...)

Wednesday, August 1, 2007

English-Malay Translation Google Gadget

So I was bored (or having a writer/researcher's block, depressed to tears, too busy P-ing, no research inspirations, whatever). So I decided to try writing a Google Gadget for UTMK's EBMT solution:



Basically, it's a "lite" version of our research group's example-based machine translation solution (read: a Universal Translator in the making). For the moment it supports English-Malay (both directions) translation, and we still have whole tons of ideas for improving its speed, accuracy, coverage etc.

I tried submitting the Google Gadget to the public searchable Directory, but apparently there's an approval process, so it doesn't show up yet. Meanwhile if you'd like to add it to your personalised Google homepage, you'll have to add the gadget by its URL: http://liantze.googlepages.com/utmk-ebmt.xml

Stay tuned!

Sunday, July 29, 2007

UTMK Open Day + Didier's Farewell Party

Goooood I'm still feeling dead tired after our mini-expo and Didier's farewell party on Thursday...

I don't think I can write anything about it yet, too physically/emotionally draining, so hop along to Hussein's take on it, or take a look at the photo slideshow:



All pics were taken by either Hussein or Kak Azimah, which are also on my Picasa Web Album:
UTMK Open Day + Didier's Farewell Party




Come back again soon and often if you can, Didier!

Wednesday, July 4, 2007

Generating JPGs and PNGs from Tikz/PGF

Gem of a post found at Nabble.com:

Re: Generating PNG or JPG ?

by Kjell Magne Fauske Mar 23, 2007; 02:47am

On 3/22/07, Hari Sundar wrote:
> Hi,
>
> Is it possible to generate images from tikz code ? I would like to put these
> images on a webpage and was wondering if there is an automatic way of
> generating the images rather than taking screenshots.
>

Sure, I do it every time I update the gallery I maintain at
http://www.fauskes.net/pgftikzexamples/

My approach is to use Ghostscript. Lets say I have a tex file named
figure.tex The work flow is approximately like this:

> pdflatex figure.tex

I then run ghostscript on the generated file figure.pdf to generate a PNG:

> gs -dNOPAUSE -r400 -dGraphicsAlphaBits=4 -dTextAlphaBits=4 -sDEVICE=png16m -sOutputFile=figure.png -dBATCH figure.pdf

(On Windows the command is gswin32c. )

>From the resulting PNG file I generate a jpg thumbnail.

To crop the figures I use a package called preview[1]. The package
provides several ways of previewing parts of your document. For
example, adding this to your document preamble:

\usepackage[active,tightpage]{preview}
\PreviewEnvironment{tikzpicture}

will extract every tikzpicture environment. If you use pdflatex, every
tikzpicture will be put on a separate page in the resulting pdf
document. To add a margin around the figure add:

\setlength\PreviewBorder{10pt}%

[1] http://www.ctan.org/tex-archive/help/Catalogue/entries/preview.html


Regards,
Kjell Magne Fauske

Monday, July 2, 2007

People are downloading my stuff!

OMIGOSH, people are actually starting to download my LaTeX scribblings! *tears of joy*

That people wanted the workshop slides are expected; anyway the colloquium committee put up a copy at their website too. Surprisingly the LaTeX installation walkthrough for Windows is the most sought-after file now! And the Absolute Beginner short guide! And the USMthesis style files!!

w00t!!

Friday, June 29, 2007

LaTeX Workshop Delivered

I'm still catching my breath after giving the LaTeX workshop on Tuesday (26th June). Talked non-stop for 1 hour 20 minutes and I still had several things I couldn't cover in time, especially demonstrating on-the-spot how an ACM conference paper can be produced from a default article document class, and show a few pages from the USMthesis package, etc.

The audience (20~30 people including both lecturers and postgrad students) seems to have liked the talk, and although I don't have any proper feedback data, here are some comments passed to me after the talk:
  • people have heard of LaTeX before, but have no idea how it's used.
  • people have heard of the wonderful "beautiful" outputs of LaTeX, but until I showed them a side-by-side comparison of output from LaTeX and Word, they had no idea what kind of "beautiful" output people meant.
  • people wanted to try LaTeX before, but didn't know what to install.
  • although I told them that some features like auto-generation of table of contents are also available in Word, people actually told me that they know about the feature in Word but "it's too hard to use", whereas in LaTeX one line of code will definitely get it done.
The fact that the Colloquium programme book was created with LaTeX (I helped the committee to do it within 2 days) helped convinced the audience with physical proof of what LaTeX can do...

Maybe within the next week or two, I'll get more comments and feedback via e-mail, or something. But at least now I've managed to raise some interest here...

Thursday, June 28, 2007

Vector Graphics Application with LaTeX PGF/Tikz

I simply must blog this before I go off for a meeting. Nicola Talbot has written a vector graphics program, JpgfDrawing, that can export to LaTeX code that renders the graphics using the Tikz/PGF package. PGF is used in the Beamer package, and I played with Tikz while preparing for the LaTeX workshop. It's the best drawing package for use with pdflatex I've encountered so far. (I'm not a fan of PS files, so I don't use PSTricks much, sorry.)

Sunday, June 24, 2007

Making booklets

So I was asked to help produce the program/abstract book for the CSPC'07 (Postgrad Colloquium) with LaTeX. I said Yes since here's a legitimate opportunity to get my LaTeX fix. ;-)

The end result was to be an A5-sized booklet, i.e. 2-up pages on an A4 sheet, folded. I tried the LaTeX booklet package, but it wouldn't play nice with the geometry package, not without me twiddling explicitly with the page sizes and margins. Dear, dear./>
Thank goodness for GNU/Linux though, since we can always use psutils for producing booklets, and we want PDF outputs anyway. And so, once the full-sized A4 abstractbook.pdf is done, these commands spring into action:

$ pdftops -paper A4 abstractbook.pdf abstractbook.ps
$ psbook -s40 abstractbook.ps absbook-sig.ps
$ psnup -n2 -pa4 absbook-sig.ps abstractbooklet.ps
$ ps2pdf -sPAPERSIZE=a4 abstractbooklet.ps


where the -s40 parameter to psbook signifies there should be 40 pages in the booklet. The number must be a multiple of 4. It doesn't matter if your full-size doc doesn't have the right number of pages; psbook will add blank pages as necessary, so just round up your actual page number to the next multiple of 4 to pass to psbook.

TA-DAAAAA!!!!




It was a learning experience especially the following points:
  • Do not be a smart-aleck and try to reset page numberings when making twoside documents. Let \frontmatter and \bodymatter do the job. Otherwise the odd/even page margins get all messed up.
  • Use the ltxtable package for longtable + tabularx. But then each longtable (with tabularx column specs) needs to be in its own individual file.
  • On the whole, LaTeX is relatively easier than
    • coaxing printers to co-operate.
    • proof-reading.
    • proof-reading.
    • ESPECIALLY the proof-reading.

Friday, June 15, 2007

Wednesday, June 13, 2007

秀萍当妈妈了!


Cynthia's a very close friend from my A-level and Warwick days. She's the kind of person that takes on life's challenges head-on, and I admire her greatly for that. So when she and Andrew (another Warwick coursemate!) got married, I was no end happy for them, and especially for Cyn.

Now they're proud parents of little Joelle Chow! She was born 9th June, 2007 at Royal Free Hospital, London. O joyous day, congratulations Andrew and Cynthia and little Joelle!

Friday, June 8, 2007

tex4ht

曾经好玩地尝试了 latex2html, HeVeA, TtH 等等。简单的 LaTeX 文件是没问题啦,都可以生成不错的 HTML,但若有特别的宏包、自己定义的指令,那就非常对不起了。(其中 TtH 的速度还真不是普通的快!)

最近发现了 tex4ht,似乎还没有什么可以难倒它的!皆因它会先生成一个 .dvi 文件,再从这个文件生成 HTML, OpenDocument 等其他格式。默认的 HTML 是有点丑啦,但可以自己定义 CSS 或其他设置来改善。最重要的是,啥宏包(或是自己定义)的指令都可以处理哦。

起初是有个小疑问:我已习惯了 \includegraphics{file} (即不写明 file extension),结果 tex4ht 就老是要找 .eps 文件……而我又不想改动成 file.eps 那么累赘,还真花了不少时间在网上搜索。最后终于找到解决方法。先要一个 myconfig.cfg 文件:
\Preamble{html}
\DeclareGraphicsExtensions{.jpg,.png,.eps,.pdf}
\begin{document}
\EndPreamble
然后运行(基本指令,当然还可以加上其他配置值)

htlatex myfile "myconfig"

就可以了。

Friday, June 1, 2007

The Rage with Patents

Why this obsession with patents? Why? Patents for industrial and engineering designs, I understand. But patents for algorithms and software procedures and computer applications?

Maybe I should have become a lawyer like my dad secretly wished (before he realised-- happily, I think -- I had a bigger knack for maths and such).

Well here's what Computer Science's Yoda (that's what he is to me) has to say about software patents: Prof Donald Knuth's 1994 Letter to the Patent Office.