User:TheLarry/Notebook/Larrys Notebook/2009/08/16

From OpenWetWare
Jump to navigationJump to search
Owwnotebook icon.png Tracking Spinning μTs Report.pngMain project page
Resultset previous.pngPrevious entry      Next entryResultset next.png

Adding to the program from the list from yesterday


The first thing i gotta do is find the radius of these objects. The problem is that most of these seem to be better described by an ellipse and not actually by a circle. There is a .vi that will fit an ellipse to the object but it needs 6 points to work. I can get these points from things like the clamp .vi. The problem with clamp is it needs a rectangle surrounding the object. That shouldn't be a problem since the match pattern gives a bounding box around the object. but it gives this box using 5 points (why i am not sure). And the rectangle needed for the clamp should be top left point and bottom right plus the angle. So i gotta write a that transforms the bounding box to a rectangle.

Fitting an ellipse to this is a giant pain in my ass. I need 6 points to do it, and it can get royally fucked if i find bad points. this might work a lot better if i threshold it and turn it into a binary image, but that would make it harder on the user. I wanna see how easy it is. OK i got the radii through thresholding and then some magic. right now i am using an automatic threshold value this seems like a good choice but i'll see what i can do to make it more user friendly when i am done. right now i am gonna go get some lunch and be back later.

With the radii i can find tangential velocity. it just occurred to me i don't know how to find tangential velocity for an ellipse. this could be interesting.

I have successfully implemented a thresholding, then finding all points on the ellipse, and then i fit an ellipse with these points to find the radii. The automatic thresholding can be changed just not to manual yet. I will put that in and have a window pop up kind of like in my tracking software, but i am pretty sure this auto thresholding is fine.

Tangential Velocity

This is made tougher since off hand i don't know the equation for this with an ellipse. it's gotta be out there though. So apparently it isn't out there. ellipses are a pain in the fucking ass and they apparently have unknown tangential velocities if they are spinning. i gotta talk to Koch about this. And see if it is necessary to describe them as ellipses.

IMAQ Rotation Detect

With the radii known now i wanna see if i can use this to find better answers.

Ahh fuckett. it's sunday and i am feeling defeated. i don't know ellipses and the rotation detect needs the objects to be circles. it wants only one radius. I can do this of course by throwing out the ellipse shit and make them circles. but i am feeling defeated. sorry koch, i won't have this done by monday. oh yeah and the Rockies got killed in game 1. very disappointing.

OK the rox got a second game and i am back at it. This IMAQ rotation is garbage, and i don't think worth my time fixing. It basically did jack shit. it said the μT went from 3 degrees to 5 degrees while the match pattern said it went around the circle twice. So fuckett. that's done.


For right now i am going with a circle, and i'll talk to Koch about the ellipse idea later.

The tangential velocity equation is [math]\displaystyle{ v_T=\omega R }[/math]

To figure out the tangential i'll need ω. This is the slope of the line of angle versus time. so two things i gotta do. convert degrees into radians and make sure it adds onto 360 like i mentioned yesterday. koch linked a .vi that might help i'll take a look at that.

Koch's program looks at time, and does what i want except my circles can go in either direction. Koch looks and says if one number is larger than another do something, but i can't do that because on microtubule may go clockwise while another goes counter. I could look at the first couple and then decide if it is going counter or clock and than choose the greater than less than stuff. Goodness gracious i kept thinking that i'll do this during the program, but i can do this afterwards when all the data was collected let me think

my first attempt failed. i gotta try again. this is kind of annoying. ok i am gonna have dinner. i might be back to try some more.