--------------------------------------------------------------
-- Distributed Convex Belief Propagation (dcBP) File Format --
--------------------------------------------------------------
The distributed convex BP file format is a binary format, i.e. all values are binary and they are stacked into the file one after the other. The size of the variables (32bit or 64bit) matters. Two reason make this format very efficient:
- It is a binary file format
- It allows potentials to be specified only once and shared between multiple factors. Hence, if all your pairwise factors have the same regularization potential, you specify the potential only once.
Further extensions to the UAI format are
- specification of c_i and c_alpha
- assigning nodes to specific machines
Used data types:
- uint - unsigned int
- float - floating point number, 32 bit
- double - floating point number, 64 bit
The values within the file are in the following order:
: 4 denotes single precision (float) and 8 defines double precision (double) accuracy
: number of nodes n in your graphical model
{}: the size of this set is equal to the number of nodes n; its i-th value defines the cardinality, i.e. the number of states of the i-th node; i in {0,...,n-1}
{}: the size of this set is equal to the number of nodes n; its i-th value defines the ID of the machine, the i-th node is assigned to; the machine ID starts counting at zero
{ or }: the size of this set is equal to the number of nodes n; its i-th value defines c_i; depending on the chosen accuracy it is a 32bit float or a 64 bit double
: number of potentials of any kind (unary,pairwise,higher order)
{{}}: one outer set specifies a factor of the graphical model; the first value denotes the number of connected variables; the next value provides a unique ID (counting starts at zero) for the factor potential, i.e. multiple factors can share the same potential; the next set specifies the IDs of the involved variables; the order of the variables is important
{ or }: the size of this set is equal to the number of factors with factor size larger than 1; its i_th value defines c_alpha; the c_alpha are assigned using the previously defined order
{{ or