emperor: (Default)
Add MemoryShare This Entry
posted by [personal profile] emperor at 02:25pm on 06/04/2006
Some days at work I really wish I had cow-orkers who also did a lot of coding. Today has been one of those days. I've spent the day thus far debugging a piece of code I wrote the other day. After many runs, and adding a lot of fprintf calls for debugging, I eventually tracked the problem down. It wasn't in the new and quite complex algorithm I'd written recently, but rather in a tiny utility function I wrote and tested ages ago. Under one rare edge case it would return the wrong length answer, leading to a bit of code calculating the dyad census wrongly.

All a bit frustrating, really. Still, the machine is now crunching data and running simulations, and by tomorrow I'll have some more stuff to put in the talk I'm giving next week...
There are 7 comments on this entry. (Reply.)
deborah_c: (GaFilk 2006)
posted by [personal profile] deborah_c at 01:47pm on 06/04/2006
Misreading that as "dryad census" gives entirely the wrong impression of your work (although it does make the sentence marginally more comprehensible ;-)
 
posted by [identity profile] sain-bano.livejournal.com at 01:54pm on 06/04/2006
Tell me about it. I've spend the last 2 days trying to work out why my disability living allowance model outputs a dataset but doesn't do anything to it. I've only just started modelling so at the moment I'm just trying to be really simple and kill off 3% of popn each year. Anyway, after much squinting at code, I just realised that the problem was that I'm supposed to have access to the random number generator on the server and don't, so my microsimulation just spits out 1's all the time. Why couldn't someone have told me about this 3 days ago?

/goes to poke computing department
 
posted by [identity profile] atreic.livejournal.com at 02:02pm on 06/04/2006
I'm just trying to be really simple and kill off 3% of popn each year.

Arrgh! *runs and hides from the homocidal civil servents*
 
posted by [identity profile] sain-bano.livejournal.com at 02:40pm on 06/04/2006
They're disabled and old - it's a fairly accurate exit rate.
 
posted by [identity profile] wellinghall.livejournal.com at 06:03pm on 06/04/2006
Sounds like you need some actuarial input ...
 
posted by [identity profile] uisgebeatha.livejournal.com at 09:38pm on 06/04/2006
*waves hand*

I do lots of coding on a daily basis, me. Jack of all trades, master of none. Although I can't say I'm taking to writing algorithms in PHP like a duck to water...anyone out there happen to be a PHP expert? :/
ext_243: (hexa)
posted by [identity profile] xlerb.livejournal.com at 06:27am on 07/04/2006
Coverage testing, anyone? (Not that I've used it myself, but I believe it's the accepted way to avoid having a testsuite that just happens to miss that one really exotic case.)

October

SunMonTueWedThuFriSat
      1
 
2
 
3
 
4
 
5
 
6
 
7
 
8
 
9
 
10
 
11
 
12
 
13
 
14
 
15
 
16
 
17
 
18
 
19
 
20
 
21
 
22
 
23
 
24
 
25
26
 
27
 
28
 
29
 
30
 
31