Question: . ( Particle Tracking ) The next step is to determine how far a bead moved from one time step t to the next t
Particle Tracking The next step is to determine how far a bead moved from one time step t to the next t t For our data, t seconds per frame. We assume the data is such that each bead moves a relatively small amount, and that two beads do not collide. However, we must account for the possibility that the bead disappears from the frame, either by departing the microscopes field of view in the x or y direction, or moving out of the microscopes depth of focus in the zdirection. Thus, for each bead at time t t we calculate the closest bead at time t in Euclidean distance and identify these two as the same beads. However, if the distance is too large, ie greater than delta pixels, we assume that one of the beads has either just begun or ended its journey. We record the displacement that each bead travels in the t units of time. Implement a program called beadtracker.py that accepts p int tau float delta float and a sequence of JPEG filenames as commandline arguments; identifies the beads in each JPEG image using BlobFinder; and writes to standard output one per line, formatted with decimal places to the right of decimal point the radial distance that each bead moves from one frame to the next assuming it is no more than delta Note that it is not necessary to explicitly track a bead through a sequence of frames you only need to worry about identifying the same bead in two consecutive frames. Accept commandline arguments pixels int tau float and delta float Construct a BlobFinder object for the frame sysargv and from it get a list of beads prevBeads that have at least pixels pixels For each frame starting at sysargv: Construct a BlobFinder object and from it get a list of beads currBeads that have at least pixels pixels For each bead currBead in currBeads, find a bead prevBead from prevBeads that is no further than delta and is closest to currBead, and if such a bead is found, write its distance using format string f
to currBead Write a newline character Set prevBeads to currBeads
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
