Showing posts with label fun. Show all posts
Showing posts with label fun. Show all posts

A pretty sweet band: Lowen and Navarro

No comments:
This band was introduced to my by a neighbor - who is the niece of Navarro. They have a mature, soulful vibe with some pretty tight song writing ability. They sound like they'd be a good live show.

What bands are appropriate for live music?

No comments:
  1. Sigur Ros. NO!
  2. Yeah Yeah Yeahs. YES!
  3. Postal Service. Probably not.
  4. Tom Petty. YES!
  5. Jesca Hoop. Yes.

I have a crush on Grace Kelly

No comments:
Of all the classic movie stars, Grace Kelly is by far my favorite: beautiful, intelligent, sophisticated - and possessing of that rare femininity that isn't displaced by a strong personality. A kind soul has collected a bunch of Grace Kelly and placed it online. Her voice sounds amazing! Oh, to have known her as a young woman, or at all.

People are Strange

No comments:
I'm working at my favorite coffee shop, near the beach, and once again wonder at the strangeness of people. A group of young people on my side of the street see a friend, a young girl, on the other side of the street. They yell joyfully, incoherently. The girl sees them, and responds with that wordless, surprisingly high-pitched sound that either means "I'm in severe danger" or "hi", depending on context. I have to wonder, what ever happened to using words?

Another observation sitting here: it's remarkable how few people seem to know how to parallel park. Yesterday I watched a guy try to park for about 10 minutes. That may not sound like a long time, but it's an eternity when parking. I found the dramatic triangle between him, his girlfriend, and the parking spot strangely compelling.

Tonight, I won

No comments:
Tonight, I won, and yet there is little joy in the victory. For some reason on this night of all nights, it hit me that poker is a game that rewards aggression, and is indeed not a wholesome game. This particular reason for decrying the game are substantially different from the other reasons that I've heard - that it is a sin against God, etc. No, I object to the game for the simple reason that it rewards and reinforces bullying and dominating behavior. In essence it reenforces the opposite behaivors that are generally desirable in a human being.

Now, there is something to be said for differentiating between a "game" and "real life", and some poker apologists might very well claim that I am failing to make the distinction here. But I wonder, if real money is on the line (hundreds, thousands of dollars), and if money is only obtained through the expenditure of effort in real life, then is not the game leveraged against "real life" and so becomes a part of it? I'd argue yes: once non-trivial sums are involved, one is risking (sizable) chunks of a real life.

This is different than other games in which one might be quite cut-throat (for example, Monopoly or Chess), but because there is no money riding on the match there is no moral difficulty. There is only a pleasant sort of competition and a match of intellect, and perhaps a somewhat frivolous waste of time, but there is no true conflict.

To be more specific, poker rewards aggression in that, once you have the "big stack" it is the "correct" play to become very aggressive and attempt to "steal" blinds and such. The theory is sound: the big stack is risking the same amount on an absolute scale, but much less on a relative scale than his opponents. On average it is better for the big stack to overbet his hand (under certain conditions) knowing that, on average, his opponents will not be able to take the proportionally greater risk.

And this is all find and dandy, until real money is on the line. Then all of a sudden the big stack is simply using his greater sum of money to make even more money, a concept which seems, on it's face, quite abhorrent. (I can't help but wonder where in real life does this financial dynamic exist? Are there places where simply having lots of cash allows you to make a lot of cash? I'm absolutely positive that there are.)

Anyway, I won a bunch of money based on these principles, and I don't feel very good about it. I played "correctly", having a big stack and generally being very agressive. I was caught once or twice, but on average I continued to build my lead, and finally won the game.

And the victory is as ash in my mouth.

Flavors of Entanglement Review

No comments:
Alanis Morissette
Release: June 10, 2008

Alanis and I go way back, and I was very curious about her latest when I heard that she was going to try more electronic arrangements. She's never been afraid of technology - word was that she recorded "Jagged Little Pill" on home-studio ADAT recorders, state-of-the art for the time. Regardless, it was a revelation to the music world - here was a singer/songwriter who was bold, sexual, and angry. Her second album, "Supposed Former Infatuation Junkie" filled with interesting music and the insightful, if self-absorbed, lyrics of a young woman finding herself through repeated glotteral stops. My respect for her only went up when she released a hilarious Fergie/Humps parody, and when she revealed in an interview a fondness for Triumph motorcycles. Alanis' music is often about herself, or close observations of others, but is a record of her growing up.

"Flavors of Entanglement" is the 3rd album of hers that I own - it's the first album I've ever pre-ordered off of the iTunes store. I got a few bonus track and a special pre-order track (and those tracks are very important, as they eclipse the quality of the rest of the album!). But I also only get 128kb tracks, and no art. Not too sure about this iTunes business yet.

The first two tracks, "Citizen of the Planet" and "Underneath", are forgettable. They simply did not hold my interest. The third tack, Straitjacket, made me raise my eyebrows. A dance track? Dropping the f-bomb? The instrumentation is all saw-lead synthesizer, run through a limiter. The vocal track is heavily harmonized. Very strange. "Versions of Violence" is more of the same, although less dancable.

"Not as we", the 5th track, is more Alanis back in the "Joni Mitchell" confessional mode.

"In Praise of the Vulnerable Man" is Alanis back in "singing a letter" mode, similar to "Unsent" or "Head over Feet". But then a minute into it a saccharin backing synth that puts it more into Donna Lewis territory. I couldn't finish listening to this one.

"Moratorium" has the lyric which contains the albums name, and is a kind of eerie-sounding self-excoriation. Not bad. "I declare a moratorium on things relationship. I declare a respite from the toils of liaison." I know the feeling!

(OK, honestly I'm listening to this album as I write the review, and I'm on "Torch" and growing impatient. "Torch" is a down-tempo melancoly break-up song. I find myself wishing she would stop moaning about "missing his warmth" and start taunting him about whether or not she'd go down on him in a theater.)

"Giggling again for no reason" is a song about getting away from your life, driving down PCH without telling anyone where you're going, or even that you've gone. The content resonates with me deeply, but the music is not engaging. It's a great subject for a song, though.

I quickly skipped to the "Bonus Tracks". I'm glad I did! The 5 tracks here are uniformly better than the rest of the album. I was concerned for a bit that I'd wasted my money, but these tracks save the day! I really like "Orchid", "Madness", and "Limb No More". I could do without "On the Tequila" but it's a fun song!

Because I pre-ordered, I got a "Bonus Bonus Track", called "It's a Bitch to Grow Up". Musically, it's a good track, and the lyrics particularly resonate with me, so I'll wrap up this review with some of those lyrics:

...
It's been 33 years of restraining,
of trying to control this tumult.
...

[chorus]
I feel done.
I feel raked over coals.
All that remains is the case: that it's a bitch to grow up.

I've repeated this dance
There's still something to learn that I've not
I'm told to see that this is divine perfection
But my bones don't feel this perfection

...
I've known through the kicking and screaming
that there was no other direction to go
[chorus]

Microsoft Yahoo Google in Pictures

No comments:


Yes, yes indeed.

The Google Command-Line: Goosh

No comments:
This little web2.0 application "Goosh" is a command line for Google. I'm not sure if it will make it's way into my day-to-day toolset, but it does make keyboard-only navigation of google and it's search results quite painless, especially combined with tabbed browsing and the CTRL+W shortcut.

I like the CLI UI, but goosh is lacking some important features of ordinary CLIs, first and foremost piping. One important feature that would make goosh more useful would be to introduce the notion of context - in it's simplest form, to build up a search one term at a time. "Command history" would also make a lot of sense.

I'm glad to see that people are thinking outside the box, and look forward to seeing how goosh, and the inevitable copy-cats, turn out.

A work of true genius

No comments:
Genius pops up when you least expect it. In this case, a game of Counter-Strike:Source spray:


Coffee shop recommendation: Qatsi Trilogy

No comments:
Thanks to Nick from the coffee shop for recommending the Qatsi Trilogy, a series of movies related to Baraka.

Movie Night!

1 comment:
Ok, so we saw Iron Man (Toan, Alex B, Robert, Marc and Me). Marc posed with his date:


A couple of great videos

No comments:
Ran across this seemingly at random on YouTube. It's a wonderful series of videos done in a pleasing, unique style of simple sketches and voiceovers. It's called Tales of Mere Existence and chronicles the experience of a creative, quiet man with extraordinary candor. His insights are not terribly deep, and there is a quiet pain to most of the stories, but he is so honest that one can't help but be drawn to these remarkable videos:



Another video was recommended to me by a good yoga friend, and chronicles the misadventures of Ogden, the inappropriate yoga guy.

Public Domain Movies

No comments:
The upcoming Will Smith movie "I Am Legend" is based on Richard Matheson's science fiction novel of the same name, but there are other movie versions. The Last Man on Earth (1964) was the first, with Vincent Price. It is in the public domain, and can be viewed for free. This movie influenced another famous movie, George Romero's The Night of the Living Dead (1968), which is also in the public domain.

Alas, The Omega Man (1971) with Charlton Heston is not available in this way. I actually rather liked that version (although to be fair, it's the only version I've seen).

Thinkpad Accelerometer with Java JNI

2 comments:
Man I have a lot of things to do. But I can't help thinking about my aunt tilting the laptop for Crayon physics. It turns out that the accelerometer on the Thinkpad can actually be accessed:
  1. C# code [fritjers.net] and a very nice version from bsuter.[stanford.edu]
  2. Perl code [thinkwiki.org]
  3. More C# code with a writeup.
Shocking that IBM doesn't have a Java library for it! Well, I got a bit excited that I might be the first to write the code...of course, I've never written JNI code before in my life. I've heard its tricky, and I know it complicates deployment (I've had to package and deploy JNI code before). So it seems that Sun's JNI programmers guide is the place to go. I skimmed it and came to this section on wrapping existing native libraries. It's pretty hairy, especially compared to the perl code, but hey this is Java right?

Undaunted I downloaded the example code from the book, thinking I could just compile the CFuntion, etc classes and be on my way. I fire up Cygwin, discover I don't have gcc or make installed - which was easily corrected. (And I noticed that an ocaml compiler was available, so I installed it too for giggles.)

I run into my first roadblock - make goes into infinite recursion and I have to kill the process. I read the makefile. It appears that the win32 makefiles provided with the distro are written for nmake - Microsoft's rewrite of gnu make. I'd never heard of it before. (Good heavens, how many make clones does the world really need?)

Probably the easiest thing to do would be to just install Visual Studio, if I had the disk space (I have a bigger drive on order, actually). If I knew make better I could edit the makefile for compatibility. But I suspect there may be other things in the codebase that require VS. Or I could scrap my original plan and write custom "one-to-one mapping" code, and hope that gcc will cut the mustard. That might be worth a shot (and more educational) while I wait for my new hard drive.

So I gave HelloWorld a shot. Alas, it didn't work (using the command line "gcc -I$JAVA_HOME/include -I$JAVA_HOME/include/win32 HelloWorld.c") - the parser didn't like the header files. What I really need is a version of this book for Cygwin, as I don't have the expertise to figure it out myself. The internet to the rescue! (Hmm and he mentions SWIG. Interesting.)

Well I was damn close. "gcc -mno-cygwin -I$JAVA_HOME/include -I$JAVA_HOME/include/win32 -Wl,--add-stdcall-alias -shared -o HelloWorld.dll HelloWorld.c" did the trick.

(Note that when I first tried to run I got a "java.lang.UnsupportedClassVersionError: Bad version number in .class file". A "which java" in cygwin showed that I was running a JRE in "/cygdrive/c/WINDOWS/system32/java" while compiling with a different one. So I just ran it with the right JRE and it worked! "$JAVA_HOME/bin/java HelloWorld". There are lots of ways to fix cygwin systematically - I'll probably make the change globally to the PATH in /etc/.bashrc)

I don't hold JNI itself responsible for this learning curve of mine - I don't do C/C++ development in Cygwin (or out of it), and that's caused the majority of the trouble. It's true that I think it *should* be possible to drag a DLL into a tool and have it's functions exposed in whatever language you like, automatically.

After reading the mindprod JNI article (which I should have done first - Roedy Green really gets into this stuff and is generous with his knowledge) I think the biggest thing holding me back is not having the source to sensor.dll source code. There are several "SharedStub" pre-compiled libraries out there (JNative, JNIWrapper - commercial) which claim to avoid writing and compiling any C (at least under Windows and Linux). SWIG claims to avoid writing any C - but you have to compile it (and it's not clear how you compile for Windows vs. Linux). The super cool thing about SWIG is once you write the ".i" file you can generate bindings for 13 different languages, not just Java. I might even get inspiration from how Eclipse generates JNI for SWT (something called JNIGeneratorAppUI). I discovered that the Shared Stub C code from the Sun book is on the site repackaged and distrubuted with a normal make file! Perhaps that's the code that JNative is based on?

One problem I cannot solve is figuring out which functions "sensors.dll" exposes. Static or dynamic, all of these JNI methods basically require a header file to work with. Seems to me a library would be pretty up-front about the functions it exposes. A tool to generate SWIG .i files from a dll would be pretty cool - if overkill. If that's not available, then a tool that generates .h files from a .dll.



If only this data was available via a port or a file handle! Oddly, the file handle method is the one used in C# and Perl. I don't really understand it though. Ironically, Mark Smith at IBM started a project to make accelerometer data available in Linux and is now open source. (This is ironic for two reasons: first, that the Linux form would be easier to use with Java, and second that Mark had to reverse-engineer his own companies software - but come to think of it that happens all the time.)

[Update: According to MSDN, that strange path-like structure is a "communication resource handle" on which there are several possible operations. These operations are fully documented (for example the CreateFile function).

Oddly, I noticed similar path strings in Windows Services. Take this executable path: "C:\bin\Tomcat 5.5\bin\tomcat5.exe" //RS//Tomcat5. My guess is this is an internal attempt to avoid running tomcat twice, similar to using a PID file. But that's probably not what it is since tomcat won't start again because of port conflicts - a sort of port PID.

Here's another - "C:\bin\Tomcat 5.5\bin\tomcat5w.exe" //MS//Tomcat5 (for monitoring tomcat)