that were last year. Phsaw, get with the times! All the cool coders are doing fuzzy logic now!
either that or my prof is stuck in the 80s. *sigh*
This course had so much potential, and it's really just sucking. "Androids in design and practice" how could I not take it? Turns out he's making us implement and document his pet project of an environment (which blows big time) under Python. Now Python isn't the greatest language ever, but it's not bad. He's making us (aka a bunch of C++ coders) learn Python and use it to create this environment. Not so bad if he'd give us some guidance... Sorry. I'm bitching to you. Know python? here, check this out. see if it makes sense and let me know. FYI: images are lists of characters. Bitmaps in their truest form. heh.
Hmm.. none of hte formatting transfered. hope it came through in the e-mail. Not that you're going to feel like debugging my code for me. but anyway. Off to sleep soon. mmm... sleep...
no subject
Date: 2002-04-16 07:52 pm (UTC)no subject
Date: 2002-04-16 08:16 pm (UTC)Phsaw, get with the times!
All the cool coders are doing fuzzy logic now!
either that or my prof is stuck in the 80s.
*sigh*
This course had so much potential, and it's really just sucking.
"Androids in design and practice"
how could I not take it?
Turns out he's making us implement and document his pet project of an environment (which blows big time) under Python.
Now Python isn't the greatest language ever, but it's not bad.
He's making us (aka a bunch of C++ coders) learn Python and use it to create this environment.
Not so bad if he'd give us some guidance...
Sorry. I'm bitching to you.
Know python? here, check this out. see if it makes sense and let me know.
FYI:
images are lists of characters. Bitmaps in their truest form. heh.
def motion(self)
mimage = Camera()
image1 = mimage.update()
image2 = mimage.update()
image1.grayScale()
image2.grayScale()
compMotion = image()
compMotion.width = image1.width
compMotion.height = image1.height
compMotion.depth = 1
compMotion.data = [0] * compMotion.height * compMotion.width * 1
x = 0
movedPixelCount = 0
while (x < compMotion.width * compMotion.height):
if (abs(image1.data[x] - image2.data[x]) > 20):
compMotion.data[x] = "M"
movedPixelCount += 1
else:
compMotion.data[x] = "."
x += 1
compMotion.saveToFile(MotionBitMap)
#if you want return values, uncomment this.
if (movedPixelCount > 5):
return 1
else:
return 0
no subject
Date: 2002-04-16 08:37 pm (UTC)Not that you're going to feel like debugging my code for me. but anyway.
Off to sleep soon.
mmm... sleep...