Die Zoomkamera muss für ihre Verwendung an einen USB 3 Port angeschlossen werden. Der Port muss in der Lage sein genug Strom zu liefern, dies kann besonders bei Leonie`s Ports problematisch sein. Die Zoomkamera zeigt auf der Rückseite ihren Zustand und ob sie genug Strom bekommt an.
Die Kamera kann nun mit dem von Pleora mitgelieferten „eBusplayer“ ausgeführt werden. Der eBusplayer befindet sich unter dem Installationspfad von Pleora im Ordner examples, eBusplayer.
Ausführung im Terminal: „./eBUSPlayer“.
Alternativ kann auch der von uns angepasste eBUSPlayer verwendet werden. Dieser befindet sich in der von uns aufgesetzten Virtual Machine unter dem Pfad des Originalen eBUSPLayer.
Mit dem angepassten eBUSPlayer kann bequem über eine GUI gezoomt werden. Außerdem lassen sich selbst implementierte Zoom Algorithmen leicht und unabhängig von Leonie testen.
Zusammenhang der Softwarekomponenten
Der Zusammenhang der Software und Hardware ist im Strukturbild auf Abbildung 5 dargestellt.
Condensation Algorithmus
Das Theoriethema zum Tracking (ACI) haben wir anhand der im Ordner „Papers“ angehängten Wissenschaftlichen Ausarbeitungen bearbeitet. Insbesondere in der Masterthesis „Face Tracking Controlled Active Camera System“ wird der Condensation Algorithmus sehr gut erklärt. Im folgenden wird der Condensation Algorithmus kurz zusammengefasst.
Veröffentlicht wurde der Condensationalgorithmus von den Autoren Michael Isard und Andrew Blake im Jahre 1998. Condensation steht dabei für Conditional Density Propagation
Das folgende Bild zeigt schematisch den Ablauf einer Iteration des Condensationalgorithmuses. Basis für jede Iteration bildet das gewichtete Sampleset der vorangegangenen Runde. Hier sehen wir dieses Sampleset, wobei der Kreisdurchmesser die Gewichtung der einzelnen Samples darstellt. Bevor wir nun also den Ablauf durchgehen sollten wir erstmal die Frage klären, was ist überhaupt ein sample? Eine der grundlegenden Ideen des Condensationalgorithmuses ist es nicht das gesamte Bild nach dem Objekt zu durchsuchen was sehr rechenaufwändig ist, sondern in gewisser Weiße den Spieß rumzudrehen.
Dazu wird das Bayestheorem angewendet und statt der Bestimmung einer Objektposition, wird an einer definierten Stelle die Wahrscheinlichkeit, dass sich das Objekt hier befindet berechnet. Diese definierte Stelle ist ein Sample, welche wir als Kreise im vorherigen Bild gesehen haben. Samples werden aus diesem Grund auch als Hypothesen für die Objektposition bezeichnet, denen halt eine Zutreffungswahrscheinlichkeit zugeordnet wird.
Im ersten Schritt wird ein gewichtetes Ziehen mit Zurücklegen durchgeführt. Ihr solltet solches ein Zufallsverfahren noch vom letzten Semester aus CI unter dem Namen Rouletteverfahren noch kennen. Die Gewichtung beim Ziehen entspricht dabei der Gewichtung der Samples oder wie in unserem Fall dem Sampledurchmesser. Wie man an den Pfeilen im Bild sehen kann wurde dieses Sample zb. 3-mal gezogen und dieses gar nicht. Gezogen wird so oft wie wir Samples in unserem Ausgangsset hatten, so dass wir wieder auf dieselbe Menge kommen.
Da wir sich bewegende Objekte tracken wollen werden die Samples im folgenden Schritt verschoben, was man hier an den Pfeilen sehen kann. Jetzt liegen aber durch das Ziehen mehrere Samples auf einem Ort bzw. mehrere Hypothesen sind bei uns nun identisch. Würde man den nächsten Schritt, das Zerstreuen von aufeinanderliegenden Samples nicht durchführen würden irgendwann alle Samples auf derselben Stelle sich befinden, wodurch wir nur noch einen Punkt im Bild betrachten würden. Daher werden im nächsten Schritt diese aufeinanderliegenden Samples in ihrer Position verändert.
Anschließend wird nun das nächste Bild aus unserem Bildstream entnommen und bewertet wie wahrscheinlich es ist, dass das ein Objekt sich an der Position der Samples befindet. Dieses Ergebnis dient der neuen Gewichtung der Samples. Samples welche sich aufgrund unserer Drift und der Objektbewegung nicht mehr auf dem Objekt liegen, werden geringer gewichtet und damit im beim nächsten Durchlauf statistisch seltener gezogen, Samples die auf dem zu trackenden Objekt liegen werden statistisch bevorzugt gezogen. Das Ausgangset an Samples hier bildet die Basis für den nächsten Durchlauf. Somit hätten wir eine Iteration des Condesationalgorithmuses ausgeführt.
Soweit zum Basiscondensationalgorithmus von Isard und Blake, inzwischen gibt es einige Verbesserungen, unteranderem auch von unserem Professor. Eine dieser Optimierungen ist es den Rechenaufwand beim Bestimmen der Gewichtung der Samples zu verringern. Dazu wird auf Samples mit geringerem Gewicht möglichst wenig Rechenaufwand verschwendet, da deren Ergebnis eh nicht so von Interesse ist. Das folgende Bild zeigt dies. Die Punkte, welche wir hier sehen sind die Samples. In die Berechnung von stärker gewichteten Samples wird mehr Rechenaufwand investiert, da sie von größerem Interesse sind. Dementsprechend sind auch die Flächen um ein Sample herum eingefärbt. Je mehr Lila eine Fläche ist, desto Interessanter das Sample und umso größer der eingesetzte Rechenaufwand.
Wie zu erwarten bekommen besonders die Samples in Objektnähe einen erhöhten Recheneinsatz. Was wir hier nun auf dem Bild sehen, ist aber lediglich ein zweidimensionaler Ansatz zum Tracken. Interessanter wäre es doch auch Objekte zu tracken die keinen konstanten Abstand zu unserer Kamera haben, um daran die Zoomcam anpassen zu können. Je nach Abstand zur Kamera verändert sich ja die Größe des Objekts im Bild, daher wird zum tracken in der dritten Dimension die Objektgröße herangezogen. Das verwendete Prinzip der Imagepyramide haben wir schon beim Slidingwindowverfahren kennengelernt.
Hier sehen wir so eine Imagepyramide. Da wir keine feste Objektgröße garantieren können wird das Bild nicht nur in seiner Originalgröße mit dem zu suchenden Modell verglichen, sondern auch in seinen kleiner skalierten Formen. Hier sieht man ganz schön, dass in den kleineren skalierten Stadien des Bilds immer andere Gesichter gefunden werden. Je Größer ein Objekt, desto geringer der Abstand Z und desto eher wird das Objekt in einem sehr kleinen Bild gefunden. Mithilfe dieses gerade erläuterten Verfahrens werden Objekte nicht nur in x- und y-Richtung sondern auch in der Tiefe bzw. in z-Richtung getrackt.
Das Folgende Bild veranschaulicht das Dreidimensionale Tracken. Oben sehen wir die drei Bilder mit den zwei Personen die getrackt werden. Die linke Person macht dabei erst einen Schritt nach Rechts und dann nach vorne, wohingegen die Person auf der rechten Seite Still stehen bleibt. Darunter sehen wir die X/Y und Z-Position unserer Samples. Rot sind die Samples vom ersten Bild, Lila die vom zweiten und in Blau sehen wir die Samples vom letzten Bild. Wie wir sehen können bewegt sich das Zentrum der Samplewolke mit der zu trackenden Person mit, dargestellt wird dies auch von der grünen Linie.
Im Demonstrationsvideo im Anhang sieht man ein Beispielvideo für das dreidimensionale Tracking einer Person. Ihr könnt dabei gut sehen wie die Samples sich im Gesicht der Person Sammeln und das entstehende Samplecluster auch der Person folgt. Die Tiefeninformation ist in diesem Fall in Form eines Tiefenhistogramms an der oberen linken Bildecke dargestellt.
ENG:
The zoom camera must be connected to a USB 3 port for use. The port must be able to provide enough power, which can be problematic especially with Leonie’s ports. The zoom camera shows on the back their condition and if they get enough power.
The camera can now be executed with the “eBusplayer” supplied by Pleora. The eBusplayer is located under the installation path of Pleora in the folder examples, eBusplayer.
Execution in the terminal: “./eBUSPlayer”.
Alternatively, the customized eBUSPlayer can be used. This is located in the virtual machine we have installed under the path of the original eBUSPLayer.
The adapted eBUSPlayer can be conveniently zoomed in via a GUI. In addition, even implemented zoom algorithms can be tested easily and independently of Leonie.
CONTEXT OF THE SOFTWARE COMPONENTS
The relationship between software and hardware is shown in the structure diagram on Figure 5.
CONDENSATION ALGORITHM
We have worked on the theory topic on tracking (ACI) using the scientific papers attached to the “Papers” folder. Especially in the master thesis “Face Tracking Controlled Active Camera System” the Condensation Algorithm is explained very well. In the following, the condensation algorithm is briefly summarized.
The condensed algorithm was published by the authors Michael Isard and Andrew Blake in 1998. Condensation stands for Conditional Density Propagation
The following figure shows schematically the course of an iteration of the condensing algorithm. The basis for each iteration is the weighted sample set from the previous round. Here we see this sample set, where the circle diameter represents the weighting of the individual samples. So before we go through the process we should first clarify the question, what is a sample? One of the basic ideas of the condensing algorithm is not to search the entire image for the object, which is very computationally expensive, but to turn the tables in a certain whiteness.
For this purpose, the Bayestheorem is used and instead of determining an object position, the probability that the object is here is calculated at a defined location. This defined location is a sample that we have seen as circles in the previous image. For this reason, samples are also called hypotheses for the object position, to which an appropriation probability is assigned.
In the first step, a weighted drag with dragback is performed. You should still know such a random process from the last semester of CI under the name of roulette. The weighting when dragging corresponds to the weighting of the samples or as in our case the sample diameter. As you can see from the arrows in the picture, this sample was eg. Pulled 3 times and this not at all. Being pulled as often as we had samples in our starting set, so we come back to the same amount.
Since we want to track moving objects, the samples are moved in the following step, which you can see here by the arrows. Now, however, by dragging several samples on one place or multiple hypotheses are now identical to us. If one did not carry out the next step, the scattering of superimposed samples, all samples would eventually be in the same place, whereby we would only consider one point in the picture. Therefore, in the next step, these superimposed samples are changed in position.
Then, the next image is taken from our image stream and it is assessed how likely it is that an object is located at the position of the samples. This result serves the new weighting of the samples. Samples which are no longer on the object because of our drift and the object movement, are weighted less and thus drawn statistically less frequently in the next run, samples are on the tracked object statistically preferred pulled. The output set of samples here forms the basis for the next run. Thus we would have performed an iteration of the Condesationalgorithmuses.
As far as the base condensing algorithm of Isard and Blake, meanwhile there are some improvements, among others also from our professor. One of these optimizations is to reduce the computational burden of determining the weighting of the samples. For this purpose, the least possible amount of computation is wasted on samples with lower weight, since their result is not of much interest anyway. The following picture shows this. The points we see here are the samples. More computational effort is invested in the calculation of more weighted samples because they are of greater interest. Accordingly, the areas are also colored around a sample.
The more purple a surface is, the more interesting the sample and the greater the amount of computation used.
As you might expect, the samples in the vicinity of the object get an increased amount of computation. What we see here in the picture is just a two-dimensional approach to tracking. It would be more interesting to also track objects that do not have a constant distance to our camera in order to adjust the zoomcam. Depending on the distance to the camera, the size of the object in the image changes, so the object size is used for tracking in the third dimension. We already got to know the principle of the image pyramid used in the sliding window process.
Here we see such an image pyramid. Since we can not guarantee a fixed object size, the image is compared not only in its original size with the model to be searched, but also in its smaller scales. Here you can see very well that in the smaller scaled stages of the image always different faces are found. The larger an object, the smaller the distance Z and the sooner the object is found in a very small image. By means of this method just described, objects are tracked not only in the x and y direction but also in the depth or in the z direction.
The following image illustrates the Three-Dimensional Tracking. Above we see the three pictures with the two people being tracked. The left person makes only one step to the right and then forward, whereas the person on the right side stops still. Below that we see the X / Y and Z position of our samples. Red are the samples from the first image, purple from the second and in blue we see the samples from the last image. As we can see, the center of the sample cloud moves with the person being tracked, as shown by the green line.
The demonstration video in the appendix shows a sample video for the three-dimensional tracking of a person. You can easily see how the samples collect in the face of the person and the resulting sample cluster also follows the person. The depth information in this case is shown in the form of a depth histogram on the upper left corner of the image.