tuffy.ground.partition
Class Partitioning

java.lang.Object
  extended by tuffy.ground.partition.Partitioning

public class Partitioning
extends java.lang.Object

Utilities for partitioning the MRF generated by the grounding process.


Field Summary
private  RDB db
           
private  MarkovLogicNetwork mln
           
 
Constructor Summary
Partitioning(Grounding g)
          Construct a partitioning worker based on the grounding result.
 
Method Summary
 PartitionScheme partitionAtoms(double ramBudgetPerPartition)
          Agglomeratively cluster the atoms in the MRF into partitions while heuristically minimizing the (weighted) cut size.
 void partitionClauses(PartitionScheme pmap)
          Given a partitioning scheme, partition the data accordingly.
 PartitionScheme partitionMRF(double maxPartitionSize)
           
private  double perAtomWeight()
           
private  double perClauseSharedWeight(int nlits)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

mln

private MarkovLogicNetwork mln

db

private RDB db
Constructor Detail

Partitioning

public Partitioning(Grounding g)
Construct a partitioning worker based on the grounding result.

Parameters:
g - the grounding worker
Method Detail

perAtomWeight

private double perAtomWeight()

perClauseSharedWeight

private double perClauseSharedWeight(int nlits)

partitionAtoms

public PartitionScheme partitionAtoms(double ramBudgetPerPartition)
Agglomeratively cluster the atoms in the MRF into partitions while heuristically minimizing the (weighted) cut size. The heuristic is to scan through all clauses in the descending-abs(weight) order.

Parameters:
ramBudgetPerPartition - size bound of a partition, roughly proportional to the number of atoms and clauses in each partition
Returns:
a partitioning scheme

partitionMRF

public PartitionScheme partitionMRF(double maxPartitionSize)

partitionClauses

public void partitionClauses(PartitionScheme pmap)
Given a partitioning scheme, partition the data accordingly.