de.unihalle.informatik.MiToBo.tracking.multitarget.datatypes.impl
Class ObservationAdjacency

java.lang.Object
  extended by de.unihalle.informatik.MiToBo.tracking.multitarget.datatypes.abstracts.MatchingAdjacencyMatrix
      extended by de.unihalle.informatik.MiToBo.tracking.multitarget.datatypes.impl.ObservationAdjacency
All Implemented Interfaces:
AdjacencyMatrix<PartitGraphNodeID>

public class ObservationAdjacency
extends MatchingAdjacencyMatrix

An adjacency matrix for observations in a time series used for greedyGourmet-partitioning. Observation of one time point form a partition. Edges are undirected.

Author:
Oliver Gress

Field Summary
private  int[] cumulatedObservations
          cumulated number of previous observations for each time step, required to determine the individual array sizes in the adjacency matrix
private  PartitGraphNodeID[] nodes
           
private  int[] numObservations
           
protected  int totalObservations
          total number of observations over all frames
protected  int[] votesClutter
           
protected  int[] votesTarget
           
protected  double[][] Zadj
          adjacency votes matrix: which observations are associated (same track) and how many particles vote for these associations
 
Constructor Summary
ObservationAdjacency(ObservationAdjacency oa)
           
ObservationAdjacency(java.util.Vector<MultiState<MotionModelID>> observations, DataAssociationExclusive[][] associations)
          Deprecated. 
ObservationAdjacency(java.util.Vector<MultiState<MotionModelID>> observations, RBMCDASampleInfo<MotionModelID>[] sampleinfos)
          Constructor that initializes the adjacency matrix with the given observations and sets edge weights according to the information from RBMCDA-samples
 
Method Summary
 double getMaxWeight()
           
 double getMinWeight()
           
 PartitGraphNodeID[] getNodes()
          Get graph nodes
 double getVotesAdjacency(int t1, int m1, int t2, int m2)
           
 int getVotesClutter(int t, int m)
           
 int getVotesTarget(int t, int m)
           
 double getWeight(PartitGraphNodeID nodeSrc, PartitGraphNodeID nodeTgt)
          Get weight of edge from nodeSrc to nodeTgt.
 boolean isDirected()
          Returns true if graph has directed edges, false if undirected
 int numOfNodes()
          Get number of graph nodes
 void setVotesAdjacency(int t1, int m1, int t2, int m2, double value)
           
 void setVotesClutter(int t, int m, int value)
           
 void setVotesTarget(int t, int m, int value)
           
 void setWeight(PartitGraphNodeID nodeSrc, PartitGraphNodeID nodeTgt, double weight)
          Set weight of edge from nodeSrc to nodeTgt.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

cumulatedObservations

private int[] cumulatedObservations
cumulated number of previous observations for each time step, required to determine the individual array sizes in the adjacency matrix


nodes

private PartitGraphNodeID[] nodes

numObservations

private int[] numObservations

totalObservations

protected int totalObservations
total number of observations over all frames


votesClutter

protected int[] votesClutter

votesTarget

protected int[] votesTarget

Zadj

protected double[][] Zadj
adjacency votes matrix: which observations are associated (same track) and how many particles vote for these associations

Constructor Detail

ObservationAdjacency

public ObservationAdjacency(ObservationAdjacency oa)

ObservationAdjacency

@Deprecated
public ObservationAdjacency(java.util.Vector<MultiState<MotionModelID>> observations,
                                       DataAssociationExclusive[][] associations)
Deprecated. 


ObservationAdjacency

public ObservationAdjacency(java.util.Vector<MultiState<MotionModelID>> observations,
                            RBMCDASampleInfo<MotionModelID>[] sampleinfos)
Constructor that initializes the adjacency matrix with the given observations and sets edge weights according to the information from RBMCDA-samples

Parameters:
observations - vector of observations. Each entry in the vector corresponds to a time point.
sampleinfos - information from RBMCDA-samples
Method Detail

getMaxWeight

public double getMaxWeight()

getMinWeight

public double getMinWeight()

getNodes

public PartitGraphNodeID[] getNodes()
Description copied from interface: AdjacencyMatrix
Get graph nodes


getVotesAdjacency

public double getVotesAdjacency(int t1,
                                int m1,
                                int t2,
                                int m2)

getVotesClutter

public int getVotesClutter(int t,
                           int m)

getVotesTarget

public int getVotesTarget(int t,
                          int m)

getWeight

public double getWeight(PartitGraphNodeID nodeSrc,
                        PartitGraphNodeID nodeTgt)
Description copied from interface: AdjacencyMatrix
Get weight of edge from nodeSrc to nodeTgt.


isDirected

public boolean isDirected()
Description copied from interface: AdjacencyMatrix
Returns true if graph has directed edges, false if undirected


numOfNodes

public int numOfNodes()
Description copied from interface: AdjacencyMatrix
Get number of graph nodes


setVotesAdjacency

public void setVotesAdjacency(int t1,
                              int m1,
                              int t2,
                              int m2,
                              double value)

setVotesClutter

public void setVotesClutter(int t,
                            int m,
                            int value)

setVotesTarget

public void setVotesTarget(int t,
                           int m,
                           int value)

setWeight

public void setWeight(PartitGraphNodeID nodeSrc,
                      PartitGraphNodeID nodeTgt,
                      double weight)
Description copied from interface: AdjacencyMatrix
Set weight of edge from nodeSrc to nodeTgt.