10
Jun 07

Deranged One Hit Wonders

Path: mv.asterisco.pt!mvalente
From: mvale…@ruido-visual.pt (Mario Valente)
Newsgroups: mv
Subject: Deranged One Hit Wonders
Date: Sun, 10 Jun 07 16:18:21 GMT

OK, OK, these 5 videos are neither “heavy” nor
“mental”. I guess that they fall into the “mentally
deranged” category: stuff so off and geeky that it
appeals to your “heavy mental” look for quirkyness.
These videos always put me in a good mood and make
me laugh my ass off…

Stakka Bo – Here We Go
http://www.youtube.com/watch?v=IQR9bw-4R08

Dee Lite – Groove Is In The Heart
http://www.youtube.com/watch?v=mKTCW4oxS6I

MC Hammer – Can’t Touch This
http://www.youtube.com/watch?v=EMzoBkaFxh4

B52s – Love Shack
http://www.youtube.com/watch?v=T8NhJNpQlsY

Right Said Fred – I’m Too Sexy
http://www.youtube.com/watch?v=ipZDG6__Zfc

— MV


10
Jun 07

Heavy One Hit Wonders

Path: mv.asterisco.pt!mvalente
From: mvale…@ruido-visual.pt (Mario Valente)
Newsgroups: mv
Subject: Heavy One Hit Wonders
Date: Sun, 10 Jun 07 15:18:21 GMT

Just thought I’d share with you 5 one-hit wonders
from the “heavy” side of the “heavy mental” personality
disorder. Basic, sleazy rock at its best, from bands
that have been forgotten after grunge, Nirvana and
Cobain destroyed the music industry leaving only hip hop
in its wake.

Danzig – Mother
http://www.youtube.com/watch?v=vgSn0SbQJQI

White Zombie – Thunder Kiss ’65
http://www.youtube.com/watch?v=0VELvq-faGk

Zodiac Mindwarp + The Love Reaction – Prime Mover
http://www.youtube.com/watch?v=mtnCcWOS7y8

Freak Of Nature – Rescue Me
http://www.youtube.com/watch?v=GaknfXHGYTQ

Terrorvision – Oblivion
http://www.youtube.com/watch?v=5RIlRhXXQjg

— MV


10
Jun 07

Mental One Hit Wonders

Path: mv.asterisco.pt!mvalente
From: mvale…@ruido-visual.pt (Mario Valente)
Newsgroups: mv
Subject: Mental One Hit Wonders
Date: Sun, 10 Jun 07 15:18:21 GMT

As counterpoint to the previous post, here’s
a sample of 5 one-hit wonders from the “mental”
side. I wouldnt call the videos themselves “mental”;
they’re basic early 80s stuff; nonetheless I still
find them great fun to listen to (not that I would
have or buy the albums… OK, I do have the Chess
musical CD and the ELO Time concept album….)

Murray Head – One Night In Bangkok
http://www.youtube.com/watch?v=NcCamcx_q3c

Pop Muzik – M
http://www.youtube.com/watch?v=1Lul7YCkrAQ

Patrick Hernandez – Born to be alive
http://www.youtube.com/watch?v=a-aI1Ch39ZU

Nick Straker Band – “A Walk In The Park”
http://www.youtube.com/watch?v=-wJMAg6jc1s

Electric Light Orchestra – Twilight
http://www.youtube.com/watch?v=hVkEHBbv4Fg

— MV


10
Jun 07

PHP2Py

Path: mv.asterisco.pt!mvalente
From: mvale…@ruido-visual.pt (Mario Valente)
Newsgroups: mv
Subject: PHP2Py
Date: Sun, 10 Jun 07 01:04:21 GMT

If I had the time and patience of days gone by, I would
get my photocopied Aho compiler book [1] from some closet or
box laying about (I dont know which), get my skills up on
XSLT (which I hate from back experience [2]) and use the
PHC [3] PHP compiler option of outputting AST trees [4]
in XML format to create PHP2PY, a PHP-to-Python translator,
using XSLT to transform the PHC-created AST XML tree
into Python source code.

[1]
http://en.wikipedia.org/wiki/Principles_of_Compiler_Design
http://en.wikipedia.org/wiki/Compilers:_Principles%2C_Techniques%2C_and_Tools

[2]
http://www.gildot.org/articles/04/05/21/1654202.shtml#10

[3]
http://www.phpcompiler.org/doc/runningphc.html#xml

[4]
http://en.wikipedia.org/wiki/Abstract_syntax_tree

As it is, downloading, installing and running PHC to
look at the generated XML for a simple “Hello World” and
putting together a proof-of-concept translator will have
to do to satisfy my hacking thirst…

— MV

PS – If you want to try it out, go get PHC, use it to
generate an XML AST of <? echo “Hello world!”; ?> into
a file called hello.xml. Processing it with the following
Python script should get you this:

#PHP2PY generated
print ‘Hello world!’

8<—————————————————<8
import xml.parsers.expat

InMethod=0
InString=0
MethodCall=0
StringValue=0

def start_element(name, attrs):
global InMethod, InString, MethodCall, StringValue

#print 'Start element:', name, attrs
if name == 'Token_method_name':
InMethod=1
if name == 'Token_string':
InString=1

if name == 'value' and InMethod:
MethodCall=1
if name == 'value' and InString:
StringValue=1

def end_element(name):
global InMethod, InString, MethodCall, StringValue

#print 'End element:', name
if name == 'Token_method_name':
InMethod=0
if name == 'Token_string':
InString=0

def char_data(data):
global InMethod, InString, MethodCall, StringValue

if MethodCall:
if data == "%run%": print "#PHP2PY generated"
if data == "echo": print "print",
MethodCall=0
if StringValue:
print "'"+data+"'"
StringValue=0

p = xml.parsers.expat.ParserCreate()

p.StartElementHandler = start_element
p.EndElementHandler = end_element
p.CharacterDataHandler = char_data

hellofile = open("hello.xml")
p.ParseFile(hellofile)
hellofile.close()


10
Jun 07

Heavy Mental IV

Path: mv.asterisco.pt!mvalente
From: mvale…@ruido-visual.pt (Mario Valente)
Newsgroups: mv
Subject: Heavy Mental IV
Date: Sat, 07 Jun 07 23:49:21 GMT

And another music example with favorite bands of mine.
And once again opposites do seem to attract.

Heavy: Sigue Sigue Sputnik

http://www.youtube.com/watch?v=pk30a0qsVIk
http://www.youtube.com/watch?v=28hFIxgtv0o
http://www.youtube.com/watch?v=pS71DJUTDU8

Mental: Kraftwerk

http://www.youtube.com/watch?v=9YCZVeIJ8xk
http://www.youtube.com/watch?v=qDde1es7aoU
http://www.youtube.com/watch?v=HieIpE-Q19c

— MV