Stories
Slash Boxes
Comments

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

scrottie (4167)

scrottie
  scott@slowass.net
http://slowass.net/

My email address is scott@slowass.net. Spam me harder! *moan*

Journal of scrottie (4167)

Saturday August 30, 2008
02:52 AM

On Inexact is Good Enough

Original article here: http://www.ekinoderm.com/wordpress/2008/08/inexact-is-good-enough

My reply, slightly edited:

Good thought, good article.

I want to comment on comp sci a bit though. This is a field that's been badly watered down lately in all but a few schools. The way I was thought, everything is a trade-off. The trade-off between time and space is the most discussed. Programming something like the Atari 2600 is interesting, where you have very little CPU power but even less space -- 128 bytes of RAM -- and so are forced to optimize for space. Good comp sci curriculums teach about NP-complete problems and algorithms, where a perfect solution for even a normal set of data in unfeasible, and the approximate ("pretty good") solutions that are workable. Students learn -- or should learn -- that various constraints are wins. The more you know about your data or the problem space, the more you can optimize. Closed polygons versus open ones; directed versus undirected graphs; and so on. These are approximations in that a less generalized algorithm is an approximation of the more generalized algorithm. Kind of.

Just looking at the history of computer gaming, the break throughs usually came about when someone was able to do something in an approximate fashion. Flight sims started on 8 bit machines with cos/sin tables with 256 entries of 8 bits each, which is terrible precision, but some clever chap at Sublogic thought it might just be good enough to make something kind of fly. And he was right. 8 bits isn't many, but most 8 bit games somewhere have tables where the bytes are broken down further, assigning 4 bits to the whole part and 4 bits to the fractal part of a number, and similar things. The programmers spend a lot of time thinking about how much precision they really need to eek by. Early interesting enemy AIs were finite state machines. The ghosts in Pac Man have simple personalities. I've been playing a bit of Blaster Master on the NES lately and the little routines the various types of baddies go through is quite impressive. Doom used a terrible simplification of the 3D model called "raycasting" which is piled full of constraints and trade-offs. But people had been dabbling with 3D first person long before the PC, and probably before the C=64, where I first saw it.

If you're a smart guy playing, trying to see if something unlikely is in fact feasible, you're coming at all of this very different from a work-a-day grunt. The smart guy playing is going after what's barely possible; the grunt uses inherent difficulty in problems to excuse himself from being expected to exceed, or even take the assignment seriously.

To say that people used to use slide rules to do amazing things is a bit of a simplification. The interesting things that were done were done with slide rules. But most people were using mechanical adding machines which required less imagination to use and had even less precision, besides nothing resembling logs. Most people were doing very mundane things with tried and true technologies that were simple to operate and quite limited in potential. And that hasn't changed. I don't expect it will.

Cheers,
-scott

P.S.: Sorry about the off-topic spam that has made it from me onto the front page in the past. The "Post: Pay no attention to my musings" option doesn't seem to do what I expected it to. So I'll try to keep stuff here at least somehow related to Perl.

Wednesday August 13, 2008
07:10 AM

Losing weight, work, and what I've been up to

Hi everyone. Been a while. I've been busy with day-job-work but not doing anything really worth blogging about. This is good and bad. I haven't been solving hard problems, just cleaning up, testing, writing tests, nailing down the dangley corner case specs, fixing bugs, integrating, and so on, and moving towards pushing a version two out the door. I have some ambitions of, once this is out the door, doing some stuff that's blog worthy.

I moved out on my own a while back, hence the necessity and ability to log more hours. Photos and stuff about the world is getting posted on http://scrottie.livejournal.com. Between there, here, and Twitter -- http://twitter.com/scrottie -- I'm kind of straddling three blogs.

A few things have been on my mind lately. One of them is losing weight... not thinking about doing, but reflecting back on having done it, and observing my habits. I guess I'm still not quite done. A few things participated this. I'm back in the dating pool, so I want to be marketable meat. Also, I fucked my shoulder up in Jujitsu, so I can't do rock climbing or martial arts. I thought that if I was ever going to be able to climb again, I was going to have to lose a lot of weight first. I eeked out a 5.11- once in a gym that tends to be technical and intentionally slightly harder, but at 180 plus pounds, my fat ass was really keeping me down. Okay, so I wasn't huge. I was reasonably active, but pretty porky for my activity level. I guess I had the attitutde of I can eat whatever I want and I'll just work it off because I enjoy being active anyway.

Cooking my own meals now, I have control over what I eat. When half the time someone else was cooking, we were going through a pound of butter a week. We'd shop every week, and we always needed butter. I used it sparingly, but somehow, it was snuck into everything. The food was good -- gumbo, white lasagna, all sorts of things. I'd counted my calories in the past and after a lot of frustration, got good at looking up calories for all of the ingredients of something I cooked, adding them up, then estimating what fraction of the dish I ate in a sitting. It's a pain, but you eventually memorize the calories for things you eat often, or drink.

I guess what was interesting was not the gradual weight loss, but the gradual process of learning how to lose weight, and the gradual process of re-calibrating my body. I started with cutting back drastically on one thing -- butter -- to the point where I'm on my second pound of butter in these six odd months. Otherwise, I did things pretty much like I always had been, except I was writing down my calories.

Depending on the day, I'd eat between about 2000 and 3000 or more. Bad days were parties, hang over recovery days, or days after a lot of physical exercise. I didn't do anything radical to alter this at first -- I just became mindful of it. If I had tried to go cold turkey, my body would have freaked out, and my survival instinct would have easily overpowered my will.

Logging calories, it became pretty clear that I was going to need to get the average down. The strategy of trying to eat exactly within target bounds all of the time is a bad one. First party, or next time you're invited to a meal, or you eat out, you're screwed. It's easy to go to a party, have beer and pizza, and suck down 3000 calories.

I guess I should mention that 3500 calories roughly translates to a pound. When I blow my calorie budget and hit 3000 rather than 2000, I've basically put on a third of a pound right then and there. A common guideline is to cut back 500 calories every day and lose a pound a week (7 * 500 = 3500). Any more than that, the body panics and starts to conserve, so you just find yourself with no energy. That's no good. Then you're not really losing weight and you feel like crap.

Our ancestors routinely walked hundreds of miles a week and had a calorie expenditure that puts us to shame. We're built to burn fuel. But it's still easier to just not eat it, up to a certain point.

One bit of advice I read was to start eating the same few things over and over. When something is a treat, you're going to eat more enthusiastically, and the way we behave, almost every meal is a treat. This kind of explains the Subway Jared thing. I heard a story about a guy who ate at McDonalds and lost a pile of weight, but he switched from the burgers to the salads. That all kinds of doesn't sound appealing.

I'm preoccupied with code and don't want to be cooking a bunch of different things, and I don't really do fast food except for Subway now and then, I'm opposed to eating out at finer establishments by myself, and eating at the bar and drinking too is too expensive so I try to just drink when I hit the pub. Those bits of resolve put me in a prime place to buy ingredients to make a few simple things and eat those over and over.

Knowing how to cook also helped immensely. If you don't know how to cook, buy a fire extinguisher, a kitchen timer, and order up a bunch of Julia Child (The French Chef) and Alton Brown (Good Eats). If something looks good and fun to make, try it! If you walk away from the stove, set the timer. Don't close the door so you don't smell the smoke. The worst that'll happen is you'll have some pots to scrub and no food.

So, one week, I'd eat veggie reubens every lunch, and another, vegetable soup. Cabbage tomato soup is easy to make, tasty, and healthy. I started to pick out things that I could make that were I enjoyed eating, were reasonably filling, and started favoring those. But obviously you can't just go to veggie soup like that. A favorite is mayo (measured 1 tablespoon, ugh, I hate measuring my food but with some things like mayo and peanut butter, ya gotta), tomato, pickle, sprout sandwich with ketchup. It's a long, slow adjustment period to getting used to getting less fat, less sugar, fewer carb-rich grains, etc. I started weening myself off during lunch and then having a normal dinner, then later started to simplify my dinners too. This was a natural process of optimizing away from food items that "cost" a lot of calories but didn't go far enough in filling me up. Some things are clearly empty calories -- soda doesn't fill you up. Eliminating things like that is natural. At first, I was still eating vast amounts of ketchup. I adore ketchup. But even the 30 calories a tablespoon thanks to the corn syrup started to become unattractive and salsa got substituted for a lot of things. Rather than mayo on tuna, I'd used BBQ sauce, but all of the ones at the grocery store had tons of corn syrup in them, so I got some stuff from Sprouts. Your local health food store probably has a similar deal. I love tomatoes, and I can get lots of tomato but without the corn syrup, so that's what I do. As far as what foods you substitute for what other foods, and how often or under what circumstances you make that substitution is up to you. If you entirely get rid of the foods you really enjoy, you'll fail, but you'll probably find that you can find purer forms of your favorite food that you like almost as much.

My stomach "shrunk" (perhaps this is a literal phenomenon, I don't know). Unless I'm nursing a hangover, I can't stomach a whole soda -- it's just disgustingly sweet. It would be like a person used to drinking trying to chow down on nice bowl full of sugar with a spoon. I can eat only very small amounts of fatty, rich foods. It feels rich in my stomach, and too much doesn't sit.

I'm not eating meat except for some seafood, leaning towards what can be sustainably produced and not eating anything intelligent enough that it can be trained to plant bombs on enemy vessels. This bit of resolve was also helpful. You can get full on veggies and not eat too many calories, but watch out for the cereal grains (aka carbs). As to whether you want to try to do an Atkins thing is up to you, but grains pack a lot of calories.

Another habit I developed that helped was favoring higher quality foods. Rather than getting the ten pound block of cheese, I'd rather buy a small wedge of one of those cheeses they sell for serving with wine. One thing I was doing a lot was getting these little wheels of Mexican cheeses, especially Panela, and frying up about a hundred calories worth of it along with bell peppers, serranos, and whatever else, and eating it with black beans and salsa on toasted mini corn tortillas. Sometimes I substituted a small avocado, which is also kind of a calorie bomb. But by buying the more expensive version, you'll enjoy each calorie more, and it just won't be practical to enjoy vast amounts of it. Don't shop at Walmart. Shop at the upscale grocery store, if you can, or specialty stores, like the Asian market, or Indian market, or so on. The health food store is awesome but sometimes they try to pull fast ones on you. Get smaller amounts of better quality everything. Learn how to cook vegetables. While veggies are cheap, they're the most expensive calories you can buy. Here's a very, very simple thing you can do: buy greens and cook them down in enough water to cover them, in a covered pot, for a couple of hours on medium low heat. Don't use iceberg lettuce -- that would be stupid. Spinach will work, but they have all kinds of greens at the grocery store. Get anything that seems robust. Mustard greens, kale, collard greens, any of that will work. Salt it a bit if you please but you don't have to add anything else and you have a delightful little side dish.

Your body craves protein, especially if you're getting exercise. Tuna has a good protein to calorie ratio but not many foods do. Don't think that only meat has protein. Cereal grains (wheat, oats, barley, rye, rice, etc) all do too, and so do nuts and lots of other things. But your best bet is to get the protein shake mix that body builders get. The health food store sells it in all kinds of varieties. Find the one you like. Beware -- some are loaded with sugars, but most are pretty sane.

One crutch I used was to tell myself that I don't have to eat any given thing I really wanted to eat that day. Yes, I really want to eat cookie dough, but cookie dough will still be there tomorrow. I'll eat it, just not now, later. If I had something kind of naughty, it's easy to put other naughty things off until later with that crutch.

I said that parties normally blow the whole deal when you shoot for an exact calorie amount each day. Well, I did 1500 on a lot of days, and then permitted myself 2500 or even 3000 days now and then. It's about the average. Honestly, my average was never very good -- I average very near 2000 calories. If I averaged 1800, I'd have lost a lot more weight by now, or lost it quicker, or whatever. 1500 calories is hard to do. It basically means no beer and some upsettingly non-caloric food. I've had many meals of black beans with salsa on it, or hominy with salsa on it, or vegetable soup, or raw carrots. Oh, I have to have a latte every morning. I have a used espresso maker from Goodwill, and my stomach can't handle black coffee any more. In fact, I have to pour lots of milk on it to buffer it, preferably whole milk. So that's 150 calories each morning right there. One thing I've not done is go hungry -- at least not very often. But I do have the attitude of it won't kill me to miss a meal. Being hungry isn't a disaster. Still, I'm not trying to arrange that situation. Trying to each a tiny peace of lasagna then just stop eating, especially when there's a whole pan of it left, seems doomed to failure to me. It's easier to just eat carrots.

Okay -- the sites. calorieking.com was handy for not just getting calories for various foodstuffs, including averages when you have no idea, but also for calories burned for exercise. I didn't subtract exercise calories and try to run a baseline anyway. I did pick up my cardio and start doing a lot more biking, especially since only the lower half of my body is functioning properly right now. But I did that, ignored the calorie implications, continued to log calories, not shooting for anything in particular, just trying to optimize for a lower number. But still, it feels good to think, they, I biked hard for two hours there -- that's good for 1400 calories!

http://www.diet-blog.com/archives/2007/04/26/what_do_300_calorie_meals_look_like .php -- totally awesome.

http://www.wisegeek.com/what-does-200-calories-look-like.htm -- totally f'n awesome.

http://www.mymoneyblog.com/archives/2007/01/what-does-200-calories-cost-the-econ omics-of-obesity.html

I guess it boils down to a few things: not defining hard success/fail conditions but just working on improving; slowly acclimating to less rich and less sugary foods and not trying to force the matter; learning about the food value (nutrition and calories) not only of the foods you presently eat and like to eat but of alternative foods and strange things you might never have heard of, like hominy; learning about your own habits and mechanisms and how you relate to food and different foods so that you can optimize intelligently.

Not really much to brag about after all of that fuss and bluster, but I went from 185 to 165.

Tonight, I was in Walmart. I didn't buy any food, but I gave the Ben and Jerry's a baleful look, and salivated at the cookie dough tubes. I think I need to actually pull off a couple 1500 calorie days so I can schedule a small amount of that stuff in. I did have bread pudding the other day, and I still have beer. In fact, it's the beer calories that necessitate the hominy-and-salsa and carrots-for-dinner scenarios. If I just stopped drinking beer, my calorie intake would drop radically and I wouldn't have to adjust my food, but I know myself better than that.

Here's one thing that's hard: I'm biking from Phoenix to Tempe, joining a group, then biking to downtown Scottsdale for beer, and coming back. A couple bombers is good for 600 or a lot more calories. I'm ravenous after the ride -- especially when I first started doing it. So I'm doing the carrots-for-dinner type thing before the ride so I have calories left for beer.

Something I'm going to start paying attention to here is getting too efficient. I'm not sure at what point I started really effectively losing weight. If it was before I started eating really obnoxiously, I'd like to scale back a bit. I don't want to try to lose weight *fast*. I'm not going to a high school reunion or anything like that. In the interest of buckling in for the long haul -- I'm thinking of going for 155, which is 5 pounds over the center of the range for my "ideal" weight -- I want this to be sustainable. In the really long haul, I want to know how much to eat to sustain my weight.

I'm bloated and over budget right now. Did a bit of a drinking bender last night and was hung over and dehydrated. Desperately wanting to feel better so I could do my ride today, I kept drinking soda and gatoraid, and eating canned Indian food. I'm pretty good at only having a couple when I got out, but I also don't like people out drinking me =P

If you (if anyone) read all of this, I probably put you off of a determined, controlled weight reduction by describing these serious bike rides and then eating carrots. Well, if you don't have the latte-and-beer habit (which are empty calories) that I do, it'll be easier. On the other hand, there will probably be not-very-optimal calorie foods you won't give up. But I like to think that there are some good tips for slightly altering things such that you're better off in general with little or no suffering. Simply learning to cook with veggies and weening yourself off of quite so much sugar and fat and getting used to less rich food could go a long way.

-scott

Friday June 20, 2008
09:11 PM

Perl 6 implementation attempts

pugs:

Asking around on #perl6 about getting pugs going, I was told it's basically abandonware. ghc has passed it by, and the code in the repository has been known not to build for some time now. No one is working on fixing it or extending it.

Quoting extensively rather than paraphrasing, mostly from diakopter:

STD.pm:

also, [...] STD.pm is *the* Perl 6 grammar; Larry's effort is separate from that - his effort is comprised of gimme5/Cursor5, which together produce STD5.pm from STD.pm

Larry's effort:

Larry Wall, at YAPC, demoed his Perl 6 parser (generated into Perl 5 from STD.pm (Perl 6) by gimme5/Cursor5).
That's src/perl6/*5.* in the pugs source code.
  at one point TimToady had a program that would convert STD.pm to a dialect pugs could understand... but nowadays his script
takes it all the way to Perl 5.
That's in /src/perl6 in the pugs repo.

Naturally, the denizens suggested other projects:

smop/sm0p:

  scrottie: there are actually other attempts... smop/sm0p promises to reignite in early July when ruoso finishes his $project...
also there's the measly parser/interpreter I built and am actively working on

elf:

  well, there's also elf, which is a very fast implementation on Perl 5
  mncharity runs elf
  elf is fairly complete, actually... I just can't read the code for the life of me or else I'd help out :)
  scrottie: pmurias and moritz_ help out with elf
  scrottie: it doesn't have a homepage, I don't think... the source is in the pugscode svn, like every implementation but rakudo

MP6/KP6:

  scrottie: there is also MP6/KP6, which is a (bootstrapped!) implementation in Perl 5... but apparently (I can't substantiate) it
turned out to be quite slow... (probably not nearly as slow as yap6 will be).... fglock built that.

  so anyway, in order of activity, it goes rakudo, STD5 (Larry's parser), elf, yap6, smop, kp6, pugs.... but smop will shortly be 2nd/3rd again, I'm sure. in order of completeness, it goes pugs, elf/rakudo (not sure on that order), kp6, smop, yap6
(probably shouldn't be on this list yet)... I'm sure I've left out something somewhere...

Wednesday May 21, 2008
09:28 AM

Why I'm passionate about Perl

Why I'm Passionate About Perl

The person who introduced me to Perl showed me that...

One large group in a large companies introduced me to Perl, and showed me that such a group can and will do everything in Perl.

# I first starting using Perl to...

My very first assigned task was to find all of the other Perl installs referenced from the she-bang lines of thousands of user's scripts. The powers that be, for security reasons, declared that Perl would not be centrally installed, so hundreds of versions were installed in home directories, some of them old even for Perl 4.

# I kept using Perl because...

Almost all of my programming up until that point had been programming games on the Atari 8 bit home computer and then later Amiga, which was *fun*, and programming games on Unix, which was *fun*. On Unix, I was programming in the language would become Pike but it wasn't yet stand alone. awk was neat, and I knew ed and some sed, and I'd learned C on the Atari and was happily assimilating the Unix manuals. Perl just proved to be a fantastic intersection from my wheelin', game programmin', hackin' past and my Unix present. It was another language that emphasized possibilities and creativity and it was one I felt I could express not only my business problems in, but my own personal madness.

# I can't stop thinking about Perl...

It's major artillery for me. When you're packin' this kinda heat, you can't stop thinking about it. I could conquer the world with this baby.

# I'm still using Perl because...

It's almost performance art. My friends show me their bits of cleverness, I try to match them. We look for problems to solve. It's almost like we're a roving band of level 20 D&D characters, way too powerful for our own good, just searching for anything that moves so we can take it on. Some times the cleverness is short examples, other times, modules. Sometimes they graduate from one to the other.

# I get other people to use Perl by...

Telling them not to use Perl. This doesn't always work. I mostly tell people to use Ruby or C# (*not* because it's similar but usually it's one of these two). Of course, I tell them I use a lot of Perl. Is this mean and hypocritical? No. One does not reach enlightenment by being pandered to. Before I was given Perl, at another outfit, most of the outfit used Perl and they sized me up, and decided I would program VBA/ASP. And it's probably better that way -- I would have written wretched Perl. I wasn't ready. Arguably, most VBA/ASP programmers need to spend a whole lot of time with assembly language first, not because it's a better language, but otherwise they're going to make a mockery of VBA. That's not to say that Perl can't be a first language, but as a Huffman coded summation of Unix, it's a big dose. It would be like giving a baby a fine wine.

# I also program in ... and ..., but I like Perl better since...

Java, Pike, 6502, Forth, ... too many to list.

The problem with hype is that the camp originating it starts to buy into it long before anyone in any other camp does. Look at Microsoft and how out of touch personal on that campus are -- it's legendary. Jobs' reality distortion field seems to be proximity based. While this might be useful for creating converts, the affects on those already in the camp are terrible -- it breeds circular logic, isolationism, piety, and, ultimately eyes-closed ignorance. I do not want that. In my mind, this was one of the worst features of Java.

-scott

07:59 AM

Web 2.0 Spam

"The ENTIRE Internet is being UPGRADED"

Hello,

Your friend, .... ....... wants you to see this NEW INTERNET UPGRADE.

The ENTIRE Internet is about to be upgraded to Web 2.0 functionality and it will not cost you a penny!

Take a look before it launches this summer:

http://www.webupgrade.....com/mmoonneeyy

Also - we are giving away $1 million dollars split between our members to help spread the word (see details on website)

--------------------------------

I just had to share this one. Best part, it comes from an AOL user.

-scott

Monday May 19, 2008
05:49 PM

Advice to a friend on shutting up and listening

I disconnected you so you'd shut up for a moment and process what you were
told. Even that wasn't adequate, apparently. I'm not saying this to be
mean -- and I've said this before in other ways -- but you're not going
to go far in this world -- dating, in jobs, with friends -- anything --
unless you develop the ability to _listen_ to what people said and
_demonstrate_ that you heard them. If either don't respond or turn around
with something that dismisses it, the message is "I don't care what you
think". Of *course* you have your own opinions and ideas. You don't
need to respond immediately with a demonstration of it to prove it.
You need to recognize absolutes in statements. When you're dating
and your girlfriend says that absolutely under no condition should
she ever find you naked with another girl, you don't turn around and
say "yeah but". _Do not_. Absolute. I'm sure you're smart and
clever enough to think of a situation where this might happen where
it isn't your fault, and you _could_ argue this point, but you do not.
You refrain from. People use less strong words but mean the same thing --
the subtext is "I require this amount of respect from you or you've
crossed a line". I cross a lot of lines; you don't realize it, but
you do too. Just now, you crossed one with me. I'm not angry and
I'm not hurt because I know it wasn't directed at me, but I'm not
letting it slip either. Most people let these slip and then just
decide not to have anything to do with you -- again, in dating,
jobs, friendships, and so on.

Let's recap. I had told you not to argue advice from qualified
friends with stuff form the Internet just as you wouldn't argue
with your doctor using material on the Internet as a source because
the stuff on the Internet is for *someone* whereas what your
doctor says is for *you*.

You immediately argued the point, saying essentially that you
take everything into consideration.

This is the Slashdot style of arguing -- there's always an
exception, a counter example, a reason against -- but the only
motive for searching for them is to intentionally miss the point
and keep an argument alive forever. In the spirit of learning
and then getting things done, I like arguments that are *not*
kept alive forever or argued for the sake of it. I do not
enjoy these. You don't have to agree with what other people
insist upon, but you do have to demonstrate respect for those
things they insist upon.

The difference is intention -- people can _tell_ whether you're _trying_ to understand them and their needs so that you can look out for them or whether you're smacking them down so you have an excuse for not. Too many nerds subscribe to the Slashdot School of Arguing, which is also the Politics School of Arguing, which is about winning, or not losing, or drawing it out to delay any ending at all. That's not an honest, sincere attempt to communication and establishing mutual respect that's needed for consensual relationships like friendships, jobs, and dating. You can't browbeat people into being your friend, you can't browbeat employers into hiring you, and you can't browbeat women into liking you. (Last paragraph added for here.)

-scott

Friday May 02, 2008
01:28 AM

"The Singularity" is stupid and Ray is an idiot

Dear programmers,

You should know better. When they show futuristic computer interfaces on Hollywood, where "hacking" consists of clicking on a button, you laugh. That's not futuristic -- it's naive, of a bygone era. Yet you accept an equally contextually stripped view of AI.

Back to "hacking": rather than being simplified, computer security is the sum of all past knowledge, plus more. We chuckle at the days when you could sniff a connection and see plain text passwords float by. Now we're doing cryptanalysis and statistical models to predict where heap will be allocated because stacks have caneries. It's *more* complicated, not less.

Back to AI. There's tons of it floating around. Airlines use complex models to price tickets. Netflix and Amazon have complicated "preference engines". The drug industry datamines for drug interactions and compliance. Elevators, rice cookers, and small electric scooters run continuous optimization problems. Sure, it's not Wintermute, but anything resembling Wintermute will have a story that completely includes all of the past, present, and near future developments. It won't exist in a vaccum. I won't be like Terminator, where some guy is working in his beautiful suburban home trying to write an AI. It'll be a complex collusion between math, psychology, anthropology, various industries, and hobby, and it'll be an extremely complex story. And there will be no singularity.

To understand this, you need to stop romanticizing "free will" and "self awareness". A British TV programme comes to mind where ad consultants were hired and subconciously programmed with the ad they were going to made, and they did it. That's not to say that humans are predictable and completely programmable -- they're too complex to be -- but that's exactly the point. AIs of the future will be more complex, but there will be no magical point. Present AIs have shocked and surprised their creators -- GumbyBRAIN comes up with some amazing stuff, and computer generated art and music, and behavior studies, and that one neural net that learned to race cars aggressively all impress the hell out of us and surprise us.

Why do humans have "free will"? Because looking out for our own interests rather than those higher on the pecking order, even if only in fits and bursts and in little rebellions, is beneficial to our own survival and the survival of our race.

Why do humans have "self awareness"? Basically the same reason -- if can't communicate a concept of self and aggressively protect it, our real, actual physical self would easily be lost and we wouldn't have offspring.

Here's another myth: humans have no instinct. Anthropology has a lot to say about that one. Then there's psychology. How many ads have you seen today that use sex to sell something? But it goes much further than that -- what makes us feel safe, happy, anxious, and so on, all have roots in instinct. We are not perfectly self aware, universe aware beings waiting for software worthy of us. We're not that much better than the classification, clustering, optimizing, planning, regressing, associating algorithms we're snidely critiquing -- in performance we are, in design we aren't.

Here's my dystopia for you:

Humans will be slaves to machines, but not in the Google data center sense, where they walk around replacing components, at least not entirely. Instead, computers will have better and better models of us, like Netflix' preference engine, and humans controlling AIs will better able to enslave, manipulate, subdue, and repress populations of humans they've somehow gained governmental, military, or commercial domain over.

Computing will continue to become cheaper. People will do interesting things with it. If I knew what, I'd go do it now rather than blather at you. Tomorrow will be interesting enough that attempts to predict it from today will fail but that won't stop people from trying. We can only predict, from past experience, what won't happen. It's a lot easier to predict that there won't be flying cars in ten years than to predict what *will* happen in ten years.

Our sense of self preservation will send us seeking new lands and computers will help. Our sense of self preservation and our desire to preserve ourselves and form offspring will make any of us who move into computers losers. Read what Freakonomics had to say about the stupidity of powerful leaders *not* using their position for sexual gain -- it's this same misunderstanding that makes us think that if we get something we want (eternal life), we'll give up something else (real children). Yes, we'll move more and more of ourselves into the computer. Our LiveJournal pages will stay up long after we're dead. We'll have chatter bots programmed with our dialogue, and whatever more sophisticated things we come up with, but, even though a computer simulation of ourself might be perfect in every regard, we will reject it as a replacement.

Humans and machines will continue to become closer. I never would have predicted this love affair with cell phones. As machines do more and more useful, interesting, and entertaining things, we'll accept them into more roles. Right now, computers are doing a large part of the work of painting and animating the movies we watch. That thought would be laughable fifty years ago. ClearChannel uses mathematical models to decide how often and when to play stuff -- it's no accident they play that same crappy song five to six times a day. They do that to make you buy the album. Given enough repetition, you *will* go buy the album, for most values of "you". Who would have thought that we'd trust our decision of which music to listen to to some computer program? Dating isn't there yet but it will be, just as soon as I finish applying preference engine logic to the problem -- muahahaha. We can already email matches for a small fee. How long until it's just a phone call through an automated system, right to their phone, as we accept our increasingly computerized, connected state? Just as computers constrain us, they also let us express ourselves. Our own self value has always been driven by other people's value of us; we seek to impress people and to establish value in their eyes. Now we do that with funny animations, captioned cat cartoons, prose...

I think I better go.

-scott

Tuesday April 29, 2008
07:20 AM

an aggregation of myself

http://meta-me.org/feed.last.cgi?uid=scrottie&format=text

Specifically, I'm on Twitter and LiveJournal (active as of somewhat recently) too.

The meta-me thingie is pretty beta right now but feel free to play with it, to track your friends or help them track you. I might merge in the code from my more recent Twitter->LiveJournal gateway that batches and posts Twitter messages on LJ, and set meta-me up so that it'll batch and post data from your various feeds onto LJ and/or other places. RSS ain't done until it has feedback loops.

-scott

05:09 AM

Solaris in a nutsa^Hhell.

Not very often do I want to throw a book away, but I got a small pile of Solaris administration books hoping to finally be able to solve this riddle -- of how to make this crapware go. Well, the books are crapware for the most part. They wave hands at actually doing anything while coping and pasting man page documentation at you and introducing you to the basics of shell. None of these have almost anything to do with Solaris. So, in the interest of being able to chuck these, I'm compiling the few useful tidbits I can find in them, here. Normally I don't buy any book I can digest in one sitting at a bookstore/coffee shop like B&N (and then often pay retail price if I find myself white knuckle clutching the thing when I have to go), but I got these from half.com, so they came sight unseen. Here goes.

prtconf, sysdef, dmesg... touch /reconfigure. volrmmount -e zip0. /etc/init.d/volmgt stop. /dev/dsk. pkgadd, pkgrm, pkginfo. admintool. showrev -p; pkgparam PATCHLIST; patchadd -R -p; patchadd -p; smpatch. useradd, usermod, userdel. format. labelit, volcopy, fstyp, tunefs, mkfs. fuser. ps, pgrep, prstat, sdtprocess. smc -- Solaris Management Console. smc, smcron, smdiskless, smexec, smgropu, smlog, smmultiuser, smosservice, smprofile, smrole, smserialport, smuser, auths, profiles, roleadd, roles. ...

-scott

Saturday April 12, 2008
03:05 AM

To maintences programmers, all languages are the same

Yeah, it's a bold assertion because it flies in the face of so many gripes from so many people for so long. Take the dailywtf. "I'm maintaining this horrible ASP programming" or "the guy who worked here wrote this in Perl". I wrote earlier about about the rot of Phoenix.PM as the entire congregation defected leaving only maintenance programmers.

These are programs that have been driven into the ground. Fear of refactoring, having the wrong people calling the shots, and the wrong priorities turned them into dung. This can happy in any language. Java has now been around long enough that programmers written in Java have descent into chaos. I've seen them. I've been hired to hire Indian programmers and I insisted on reviewing code before hiring a firm. All of them had terrible voodoo chicken bones code that in 100 lines foreshadowed million line voodoo code projects. And it was all in Java.

A program in any language in a historically badly run project evolves to somewhere past point of insanity. No self respecting programmer will try to continue adding features at this point, accelerating the descent when companies hire novices to try to extend the dung heap. The good programmers are put on maintenance; they won't do anything else, and keeping the thing running is a challenge.

But you know this. What matters is that the economics completely change when the project goes to hell.

The expectations for a maintenance programmer are calibrated to the difficulty of the project. None of the schedules, deadlines, SLOC, milestones, or other productivity metrics apply. There are easy bugs and hard bugs and sometimes the hard bugs live for a very long time time. Doesn't matter if it's COBOL, Perl, Java, ASP, or what. The maintenance programmer proved himself over and over again to his employer, so the lack of metrics don't matter. He's woken up at insane hours, worked late, and traced down insanely involved problems keeping the whole thing wedge. But... the language doesn't matter. The difficulty of fixing problems doesn't vary. It's a matter of definition: the project grew in whatever language until its unmaintainable, where ever that is for the language, and then the good programmers are just keeping the boat afloat.

Phoenix.PM is almost entirely composed of maintenance programmers. Programmers who like to write new code left a long time ago. And that was in other languages, for the most part: Java, C++, Python, Ruby...

But as a maintenance programmer, you're not writing code. And if you're proficient in a language, you can read the code. The idiom doesn't matter. The idiom doesn't make you more or less efficient at hunting action-at-a-distance problems. The hard bugs aren't in the expressions, they're in the interactions between parts of the system... or the lack of parts of the system. The fact that Perl's syntax can be confusing is completely irrelevant to maintenance programmers. Those are the easiest bugs they encounter in their job.

So, the conclusion that could easily be drawn from reading the dailywtf... that Perl is horrible, because there's so much horrible Perl out there... is a fallacy. Or that ASP is horrible because there's so much bad ASP out there... in both cases, I suspect the real problem is that programs overgrew their design, weren't redesigned and refactored, and the good programmers were forced into maintenance by business need.

If you're a good programmer who likes writing code, you're forced away from entire languages. You're suddenly unable to touch Perl, as an employee, because the only jobs are maintenance or else adding features to a completely fucked system, which you won't do. A few dozen companies mismanaging projects ruined the market for you.

And, conversely, PR won't do any good for Perl. The only thing to do is... start new projects. CPAN modules are good, but "Web 2.0", or "dot com" or whatever businesses. Make stuff in it that people care about. Create new projects that'll require maintenance, perhaps, and might be easy to maintain, but regardless *aren't* maintenance gigs right now.

-scott