#garfield Logs
Oct 09 2023
#garfield Calendar
01:55 AM rue_shop2: 4mbit
02:27 PM rue_mohr: ok I need to change the fish water
02:27 PM rue_mohr: the greenhouse tank is up to 500L, so it wont be a problem on volume
02:28 PM rue_mohr: I'm starting to understand where the FSMs have their hard limits and getting ideas on how ram integration would work
02:28 PM rue_mohr: there is a border that enters time-division-computations
02:49 PM polprog: i kinda like that we play with random crap like eproms and gals and fpgas at the same time exploring the fundamentals of computer science
02:51 PM rue_mohr: I'm pushing in a different direction than It all went
02:51 PM rue_mohr: retrofuturistic
02:51 PM polprog: yeah
02:52 PM polprog: you could like 9front then
02:52 PM rue_mohr: in 89, when I was littler' I swore computers weren't needed
02:52 PM rue_mohr: that state machines could do anything
02:52 PM rue_mohr: so, now I'v made computers out of state machines, and the circle closed,
02:52 PM rue_mohr: which is magical
02:53 PM rue_mohr: and I'm exploring the circle trying to work out what all can be done
02:53 PM polprog: i had the neural networks class today
02:53 PM rue_mohr: sorry 98
02:53 PM rue_mohr: heh
02:53 PM polprog: we will likely gonna have the whole basics covered
02:53 PM polprog: i gotta rip/save the lecture slides for future reference
02:53 PM rue_mohr: in 98 I invisioned a state machine that used ram as part of its processing loop
02:53 PM rue_mohr: I want to figure it out
02:53 PM polprog: hmmm
02:54 PM rue_mohr: polprog, what did they cover today?
02:54 PM polprog: just some technical aspects and a simple example with two neurons
02:54 PM polprog: using numpy because its just two matrices multiplying, so you could implement that in C if you wanted
02:54 PM rue_mohr: today I realize that the main limit of the state machine is the ability to handle storage, so the ram is starting to take light
02:55 PM rue_mohr: what are the sizes of the matrixies
02:55 PM polprog: next lab is some basic network written from the ground up with numpy and then we will be using torch library
02:55 PM polprog: NxN matrix for N neurons
02:55 PM rue_mohr: ah
02:55 PM polprog: so two by two now
02:55 PM polprog: 2x2 matrix multiplied by a 2-vector
02:55 PM rue_mohr: so there are matrixes for weights, inputs and outputs
02:56 PM polprog: its matrices all the way down
02:56 PM rue_mohr: how many matrixes did they use and what did they represent?
02:57 PM polprog: one matrix W, 2x2, for coefficients, and one vector for neuron values
02:57 PM polprog: one i will finish the homework ill show you
02:57 PM rue_mohr: coefficients are weights, yes?
02:57 PM polprog: yes
02:57 PM rue_mohr: mmm
02:57 PM rue_mohr: and then the other matrix starts as the input values but is the results after its multiplied
02:58 PM polprog: yes
02:58 PM rue_mohr: hmm
02:58 PM * rue_mohr hates matrixies
02:58 PM polprog: The output is a vector, a 2x1 matrix
02:58 PM rue_mohr: input is 1x2?
02:58 PM polprog: I will try to write it in pure C just to see how fast can it be and how complicted it will be
02:58 PM polprog: input is 2x1
02:59 PM polprog: or 1x2 depending how you look at it
02:59 PM polprog: i will make a txt file with it soon
02:59 PM rue_mohr: is it perpendicular to the output?
02:59 PM polprog: its a vector, it's assumed that you transpose (turn around) it when you multiply by matrices
02:59 PM polprog: er
02:59 PM polprog: when you multiply a matrix by it
02:59 PM polprog: ill draw this out for you, not today tho :<
02:59 PM rue_mohr: matrix2d.c
02:59 PM rue_mohr: matrix2d.h
03:00 PM polprog: gotta be at work tomrrow
03:00 PM polprog: 8 hours :<
03:00 PM polprog: maybe ill try to code something up at break at work if the day is slow
03:00 PM rue_mohr: double determinantMatrix2d ( matrix2d_t * this) ;
03:00 PM rue_mohr: matrix2d_t * setUnityMatrix2d ( matrix2d_t * this) ;
03:00 PM rue_mohr: char * showMatrix2d ( char * s, unsigned int bl, matrix2d_t * this) ;
03:00 PM rue_mohr: matrix2d_t * translateMatrix2d ( matrix2d_t * this, point2d_t f ) ;
03:00 PM rue_mohr: matrix2d_t * scaleMatrix2d ( matrix2d_t * this, point2d_t f) ;
03:00 PM rue_mohr: matrix2d_t * rotateMatrix2d ( matrix2d_t * this, double a) ;
03:00 PM rue_mohr: matrix2d_t * copyMatrix2d ( matrix2d_t * to, matrix2d_t * from) ;
03:00 PM rue_mohr: matrix2d_t * multiplyMatrix2d ( matrix2d_t * that, matrix2d_t * this) ;
03:00 PM rue_mohr: matrix1x3_t * narrowMultiplyMatrix2d ( matrix1x3_t * this, matrix2d_t * by ) ;
03:00 PM rue_mohr: point2d_t * applyMatrix2d ( matrix2d_t * this, point2d_t * that) ;
03:00 PM rue_mohr: matrix2d_t * recipMatrix2d ( matrix2d_t * this ); // returns NULL if the det. is zero
03:01 PM polprog: what is that from?
03:01 PM rue_mohr: that last one, the recipricol matrix, was an astounding moment for me to solve
03:01 PM rue_mohr: its my matrix library
03:01 PM polprog: oh yeah the reciprocal is a hard operation
03:01 PM polprog: care to share?
03:01 PM rue_mohr: always, 1 sec
03:02 PM polprog: i think ill try to port my changes in that u-boot code to a separate "board" and then try to port that to u-boot mainline
03:02 PM polprog: maybe even send in a patch
03:03 PM rue_mohr: http://ruemohr.org/%7Eircjunk/programming/c/matrix2d.c
03:03 PM rue_mohr: http://ruemohr.org/%7Eircjunk/programming/c/matrix2d.h
03:03 PM polprog: thank you!
03:05 PM rue_mohr: I suppose it would help if it weren't a fixed size...
03:05 PM rue_mohr: ah well
03:06 PM polprog: i might try to write a variable sized one
03:06 PM rue_mohr: this is what tensor flow is for
03:06 PM rue_mohr: granted its a level up
03:06 PM polprog: tensorflow and torch are two major libraries with torch being liked by the scientists more
03:07 PM rue_mohr: interesting
03:07 PM polprog: but you cant run either on an 8051 :P or stm32
03:07 PM rue_mohr: hahah
03:07 PM polprog: i want to write it in C so its small and has a chance to run on the smol cpus
03:07 PM polprog: im sure i could implement something simple on an stm32
03:07 PM rue_mohr: I forgot how tensors work, might look that up again sometime
03:07 PM rue_mohr: well, if you only need multiply, then its all good
03:08 PM polprog: all of that is for 3x3 matrices
03:08 PM rue_mohr: wut
03:08 PM polprog: mathematicians count from 1
03:08 PM rue_mohr: its not variable by the size of the input array?
03:08 PM polprog: its silly i know
03:08 PM polprog: you have it hardcoded for M[0] to M[8]
03:09 PM polprog: allright, i will try to implement something similar
03:09 PM polprog: a variable size matrix library should be fairly easy to write
03:10 PM rue_mohr: I did a lot of math and came up with that, saying it was an amazing soluton thats just not out there
03:10 PM polprog: without the reciprocal, id have to grab my math books for that
03:10 PM rue_mohr: please, test it and report back
03:10 PM polprog: will do
03:11 PM rue_mohr: I couldn't understand why the reciprical wasn't part of the standard tool set
03:11 PM rue_mohr: as you kinda need it to work out .... uh, something in reverse
03:11 PM rue_mohr: :]
03:12 PM polprog: did i tell you that I got u-boot working on that min210 board?
03:12 PM polprog: mini210*
03:13 PM rue_mohr: yea, awesome victory!
03:13 PM rue_mohr: A = B*C but where B is the unknown matrix... I think
03:13 PM polprog: im rusty on that
03:13 PM polprog: gotta read up...
03:14 PM rue_mohr: yea, I'm more rusty
03:14 PM rue_mohr: I really do hate them
03:14 PM rue_mohr: mostly for being touted as an amazing solution when in fact using them is often more overhead
03:15 PM polprog: depends on the implementation
03:15 PM polprog: they are useful for linear equations
03:15 PM polprog: like with rotation in graphics
03:15 PM rue_mohr: I know you need to get back to the homework, but do you know if they will be doing the number recognition thing as part of the course?
03:16 PM polprog: not sure but doing the MNIST number recog is fairly standard and I would love to learn doing it properly and not by importing a tensorflow demo
03:16 PM polprog: So likely yes
03:16 PM polprog: we will have perceptrons
03:17 PM rue_mohr: mm
03:17 PM rue_mohr: I'll be back from work in 3 hours (on a normal day)
03:17 PM polprog: ill be sleeping in 3 hours :P
03:17 PM polprog: how much do you work a day
03:17 PM rue_mohr: so this week, post what you can and I'll leave questions/comments
03:18 PM polprog: sure
03:18 PM rue_mohr: I do 7.5Hrs paid, 8 hrs real
03:19 PM polprog: hm
03:19 PM polprog: and you still have so much time to play
03:19 PM polprog: :<
03:19 PM polprog: i do 8h real, 8h paid 3/5 a week
03:19 PM polprog: well. Now its 4/5 days a week but i dont work 8h every day
03:21 PM polprog: with the current class schedule i could have a nice bit of midweek free time on wednesday, as i just signed out of the lecture on wed
03:21 PM polprog: so i could take 8 hours each day tue, thu, fri
03:21 PM polprog: then have classes on monday and wed afternoon
03:21 PM polprog: I think that will work well
03:21 PM polprog: HR is gonna kill me for changing the work schedule for the third time this month
03:21 PM rue_mohr: heh
03:22 PM rue_mohr: it probably comes with having employees that are students
03:22 PM polprog: i think ill leave it as is this month because who know what schedule changes the uni brings haha
03:22 PM polprog: yeah half of people in this company are either doing masters or phds, they are very flexible and understanding
03:23 PM rue_mohr: going to get the fish tank water changed, see ya later
03:23 PM polprog: make sure to put the fixh back in when you are done
03:23 PM polprog: cya
03:23 PM polprog: fish*
04:41 PM rue_mohr: oh I leave them in there
04:41 PM rue_mohr: its done
04:41 PM rue_mohr: I just take the tank down to like 5% and fill it back up
04:42 PM rue_mohr: oh thats interesting
04:43 PM rue_mohr: with the ability to solve the reciprical matrix, you can instantly derive an answer for a given input and output
04:43 PM rue_mohr: huh, maybe I'm not thinking that thru right
08:45 PM Tom_L: you mustuv been off today
09:21 PM rue_shop2: yup
09:55 PM Tom_L: cnc was reduced to cutting a house key today :)
10:07 PM rue_shop2: hah
10:12 PM Tom_L: i wrote a program and just juggle the cuts around for different keys