SNAP Library, User Reference
2012-10-02 12:56:23
SNAP, a general purpose network analysis and graph mining library
|
!!!!! MYUNGHWAN, CHECK! More...
Public Member Functions | |
TKroneckerLL () | |
TKroneckerLL (const PNGraph &GraphPt, const TFltV &ParamV, const double &PermPSwapNd=0.2) | |
TKroneckerLL (const PNGraph &GraphPt, const TKronMtx &ParamMtx, const double &PermPSwapNd=0.2) | |
TKroneckerLL (const PNGraph &GraphPt, const TKronMtx &ParamMtx, const TIntV &NodeIdPermV, const double &PermPSwapNd=0.2) | |
int | GetNodes () const |
int | GetKronIters () const |
PNGraph | GetGraph () const |
void | SetGraph (const PNGraph &GraphPt) |
const TKronMtx & | GetProbMtx () const |
const TKronMtx & | GetLLMtx () const |
int | GetParams () const |
int | GetDim () const |
void | SetDebug (const bool Debug) |
const TFltV & | GetLLHist () const |
const TVec< TKronMtx > & | GetParamHist () const |
bool | IsObsNode (const int &NId) const |
bool | IsObsEdge (const int &NId1, const int &NId2) const |
bool | IsLatentNode (const int &NId) const |
bool | IsLatentEdge (const int &NId1, const int &NId2) const |
void | SetPerm (const char &PermId) |
void | SetOrderPerm () |
void | SetRndPerm () |
void | SetDegPerm () |
void | SetBestDegPerm () |
!!!!! MYUNGHWAN, CHECK! | |
void | SetPerm (const TIntV &NodePermV) |
void | SetIPerm (const TIntV &Perm) |
!!!!! MYUNGHWAN, CHECK! | |
const TIntV & | GetPermV () const |
void | AppendIsoNodes () |
void | RestoreGraph (const bool RestoreNodes=true) |
!!!!! MYUNGHWAN, CHECK! | |
double | GetFullGraphLL () const |
double | GetFullRowLL (int RowId) const |
double | GetFullColLL (int ColId) const |
double | GetEmptyGraphLL () const |
double | GetApxEmptyGraphLL () const |
void | InitLL (const TFltV &ParamV) |
void | InitLL (const TKronMtx &ParamMtx) |
void | InitLL (const PNGraph &GraphPt, const TKronMtx &ParamMtx) |
double | CalcGraphLL () |
double | CalcApxGraphLL () |
double | GetLL () const |
double | GetAbsErr () const |
double | NodeLLDelta (const int &NId) const |
double | SwapNodesLL (const int &NId1, const int &NId2) |
bool | SampleNextPerm (int &NId1, int &NId2) |
double | GetEmptyGraphDLL (const int &ParamId) const |
double | GetApxEmptyGraphDLL (const int &ParamId) const |
const TFltV & | CalcGraphDLL () |
const TFltV & | CalcFullApxGraphDLL () |
const TFltV & | CalcApxGraphDLL () |
double | NodeDLLDelta (const int ParamId, const int &NId) const |
void | UpdateGraphDLL (const int &SwapNId1, const int &SwapNId2) |
const TFltV & | GetDLL () const |
double | GetDLL (const int &ParamId) const |
void | SampleGradient (const int &WarmUp, const int &NSamples, double &AvgLL, TFltV &GradV) |
double | GradDescent (const int &NIter, const double &LrnRate, double MnStep, double MxStep, const int &WarmUp, const int &NSamples) |
double | GradDescent2 (const int &NIter, const double &LrnRate, double MnStep, double MxStep, const int &WarmUp, const int &NSamples) |
void | SetRandomEdges (const int &NEdges, const bool isDir=true) |
!!!!! MYUNGHWAN, CHECK! | |
void | MetroGibbsSampleSetup (const int &WarmUp) |
void | MetroGibbsSampleNext (const int &WarmUp, const bool DLLUpdate=false) |
void | RunEStep (const int &GibbsWarmUp, const int &WarmUp, const int &NSamples, TFltV &LLV, TVec< TFltV > &DLLV) |
double | RunMStep (const TFltV &LLV, const TVec< TFltV > &DLLV, const int &GradIter, const double &LrnRate, double MnStep, double MxStep) |
void | RunKronEM (const int &EMIter, const int &GradIter, double LrnRate, double MnStep, double MxStep, const int &GibbsWarmUp, const int &WarmUp, const int &NSamples, const TKronEMType &Type=kronNodeMiss, const int &NMissing=-1) |
TFltV | TestSamplePerm (const TStr &OutFNm, const int &WarmUp, const int &NSamples, const TKronMtx &TrueMtx, const bool &DoPlot=true) |
TFltQu | TestKronDescent (const bool &DoExact, const bool &TruePerm, double LearnRate, const int &WarmUp, const int &NSamples, const TKronMtx &TrueParam) |
void | GradDescentConvergence (const TStr &OutFNm, const TStr &Desc1, const bool &SamplePerm, const int &NIters, double LearnRate, const int &WarmUp, const int &NSamples, const int &AvgKGraphs, const TKronMtx &TrueParam) |
Static Public Member Functions | |
static PKroneckerLL | New () |
static PKroneckerLL | New (const PNGraph &GraphPt, const TKronMtx &ParamMtx, const double &PermPSwapNd=0.1) |
static PKroneckerLL | New (const PNGraph &GraphPt, const TKronMtx &ParamMtx, const TIntV &NodeIdPermV, const double &PermPSwapNd=0.2) |
static double | CalcChainR2 (const TVec< TFltV > &ChainLLV) |
static void | ChainGelmapRubinPlot (const TVec< TFltV > &ChainLLV, const TStr &OutFNm, const TStr &Desc) |
static void | TestBicCriterion (const TStr &OutFNm, const TStr &Desc1, const PNGraph &G, const int &GradIters, double LearnRate, const int &WarmUp, const int &NSamples, const int &TrueN0) |
static void | TestGradDescent (const int &KronIters, const int &KiloSamples, const TStr &Permutation) |
Friends | |
class | TPt< TKroneckerLL > |
!!!!! MYUNGHWAN, CHECK!
TKroneckerLL::TKroneckerLL | ( | ) | [inline] |
TKroneckerLL::TKroneckerLL | ( | const PNGraph & | GraphPt, |
const TFltV & | ParamV, | ||
const double & | PermPSwapNd = 0.2 |
||
) |
TKroneckerLL::TKroneckerLL | ( | const PNGraph & | GraphPt, |
const TKronMtx & | ParamMtx, | ||
const double & | PermPSwapNd = 0.2 |
||
) |
TKroneckerLL::TKroneckerLL | ( | const PNGraph & | GraphPt, |
const TKronMtx & | ParamMtx, | ||
const TIntV & | NodeIdPermV, | ||
const double & | PermPSwapNd = 0.2 |
||
) |
void TKroneckerLL::AppendIsoNodes | ( | ) |
const TFltV & TKroneckerLL::CalcApxGraphDLL | ( | ) |
double TKroneckerLL::CalcApxGraphLL | ( | ) |
double TKroneckerLL::CalcChainR2 | ( | const TVec< TFltV > & | ChainLLV | ) | [static] |
const TFltV & TKroneckerLL::CalcFullApxGraphDLL | ( | ) |
const TFltV & TKroneckerLL::CalcGraphDLL | ( | ) |
double TKroneckerLL::CalcGraphLL | ( | ) |
void TKroneckerLL::ChainGelmapRubinPlot | ( | const TVec< TFltV > & | ChainLLV, |
const TStr & | OutFNm, | ||
const TStr & | Desc | ||
) | [static] |
double TKroneckerLL::GetAbsErr | ( | ) | const [inline] |
double TKroneckerLL::GetApxEmptyGraphDLL | ( | const int & | ParamId | ) | const |
double TKroneckerLL::GetApxEmptyGraphLL | ( | ) | const |
int TKroneckerLL::GetDim | ( | ) | const [inline] |
const TFltV& TKroneckerLL::GetDLL | ( | ) | const [inline] |
double TKroneckerLL::GetDLL | ( | const int & | ParamId | ) | const [inline] |
double TKroneckerLL::GetEmptyGraphDLL | ( | const int & | ParamId | ) | const |
double TKroneckerLL::GetEmptyGraphLL | ( | ) | const |
double TKroneckerLL::GetFullColLL | ( | int | ColId | ) | const |
double TKroneckerLL::GetFullGraphLL | ( | ) | const |
double TKroneckerLL::GetFullRowLL | ( | int | RowId | ) | const |
PNGraph TKroneckerLL::GetGraph | ( | ) | const [inline] |
int TKroneckerLL::GetKronIters | ( | ) | const [inline] |
double TKroneckerLL::GetLL | ( | ) | const [inline] |
const TFltV& TKroneckerLL::GetLLHist | ( | ) | const [inline] |
const TKronMtx& TKroneckerLL::GetLLMtx | ( | ) | const [inline] |
int TKroneckerLL::GetNodes | ( | ) | const [inline] |
const TVec<TKronMtx>& TKroneckerLL::GetParamHist | ( | ) | const [inline] |
int TKroneckerLL::GetParams | ( | ) | const [inline] |
const TIntV& TKroneckerLL::GetPermV | ( | ) | const [inline] |
const TKronMtx& TKroneckerLL::GetProbMtx | ( | ) | const [inline] |
double TKroneckerLL::GradDescent | ( | const int & | NIter, |
const double & | LrnRate, | ||
double | MnStep, | ||
double | MxStep, | ||
const int & | WarmUp, | ||
const int & | NSamples | ||
) |
!!!!! MYUNGHWAN, CHECK!
!!!!! MYUNGHWAN, CHECK!
double TKroneckerLL::GradDescent2 | ( | const int & | NIter, |
const double & | LrnRate, | ||
double | MnStep, | ||
double | MxStep, | ||
const int & | WarmUp, | ||
const int & | NSamples | ||
) |
void TKroneckerLL::GradDescentConvergence | ( | const TStr & | OutFNm, |
const TStr & | Desc1, | ||
const bool & | SamplePerm, | ||
const int & | NIters, | ||
double | LearnRate, | ||
const int & | WarmUp, | ||
const int & | NSamples, | ||
const int & | AvgKGraphs, | ||
const TKronMtx & | TrueParam | ||
) |
void TKroneckerLL::InitLL | ( | const TFltV & | ParamV | ) |
void TKroneckerLL::InitLL | ( | const TKronMtx & | ParamMtx | ) |
void TKroneckerLL::InitLL | ( | const PNGraph & | GraphPt, |
const TKronMtx & | ParamMtx | ||
) |
bool TKroneckerLL::IsLatentEdge | ( | const int & | NId1, |
const int & | NId2 | ||
) | const [inline] |
bool TKroneckerLL::IsLatentNode | ( | const int & | NId | ) | const [inline] |
bool TKroneckerLL::IsObsEdge | ( | const int & | NId1, |
const int & | NId2 | ||
) | const [inline] |
bool TKroneckerLL::IsObsNode | ( | const int & | NId | ) | const [inline] |
void TKroneckerLL::MetroGibbsSampleNext | ( | const int & | WarmUp, |
const bool | DLLUpdate = false |
||
) |
void TKroneckerLL::MetroGibbsSampleSetup | ( | const int & | WarmUp | ) |
static PKroneckerLL TKroneckerLL::New | ( | ) | [inline, static] |
PKroneckerLL TKroneckerLL::New | ( | const PNGraph & | GraphPt, |
const TKronMtx & | ParamMtx, | ||
const double & | PermPSwapNd = 0.1 |
||
) | [static] |
PKroneckerLL TKroneckerLL::New | ( | const PNGraph & | GraphPt, |
const TKronMtx & | ParamMtx, | ||
const TIntV & | NodeIdPermV, | ||
const double & | PermPSwapNd = 0.2 |
||
) | [static] |
double TKroneckerLL::NodeDLLDelta | ( | const int | ParamId, |
const int & | NId | ||
) | const |
double TKroneckerLL::NodeLLDelta | ( | const int & | NId | ) | const |
void TKroneckerLL::RestoreGraph | ( | const bool | RestoreNodes = true | ) |
!!!!! MYUNGHWAN, CHECK!
void TKroneckerLL::RunEStep | ( | const int & | GibbsWarmUp, |
const int & | WarmUp, | ||
const int & | NSamples, | ||
TFltV & | LLV, | ||
TVec< TFltV > & | DLLV | ||
) |
void TKroneckerLL::RunKronEM | ( | const int & | EMIter, |
const int & | GradIter, | ||
double | LrnRate, | ||
double | MnStep, | ||
double | MxStep, | ||
const int & | GibbsWarmUp, | ||
const int & | WarmUp, | ||
const int & | NSamples, | ||
const TKronEMType & | Type = kronNodeMiss , |
||
const int & | NMissing = -1 |
||
) |
double TKroneckerLL::RunMStep | ( | const TFltV & | LLV, |
const TVec< TFltV > & | DLLV, | ||
const int & | GradIter, | ||
const double & | LrnRate, | ||
double | MnStep, | ||
double | MxStep | ||
) |
void TKroneckerLL::SampleGradient | ( | const int & | WarmUp, |
const int & | NSamples, | ||
double & | AvgLL, | ||
TFltV & | GradV | ||
) |
bool TKroneckerLL::SampleNextPerm | ( | int & | NId1, |
int & | NId2 | ||
) |
void TKroneckerLL::SetBestDegPerm | ( | ) |
!!!!! MYUNGHWAN, CHECK!
void TKroneckerLL::SetDebug | ( | const bool | Debug | ) | [inline] |
void TKroneckerLL::SetDegPerm | ( | ) |
void TKroneckerLL::SetGraph | ( | const PNGraph & | GraphPt | ) |
void TKroneckerLL::SetIPerm | ( | const TIntV & | Perm | ) |
!!!!! MYUNGHWAN, CHECK!
void TKroneckerLL::SetOrderPerm | ( | ) |
void TKroneckerLL::SetPerm | ( | const char & | PermId | ) |
void TKroneckerLL::SetPerm | ( | const TIntV & | NodePermV | ) | [inline] |
void TKroneckerLL::SetRandomEdges | ( | const int & | NEdges, |
const bool | isDir = true |
||
) |
!!!!! MYUNGHWAN, CHECK!
void TKroneckerLL::SetRndPerm | ( | ) |
double TKroneckerLL::SwapNodesLL | ( | const int & | NId1, |
const int & | NId2 | ||
) |
void TKroneckerLL::TestBicCriterion | ( | const TStr & | OutFNm, |
const TStr & | Desc1, | ||
const PNGraph & | G, | ||
const int & | GradIters, | ||
double | LearnRate, | ||
const int & | WarmUp, | ||
const int & | NSamples, | ||
const int & | TrueN0 | ||
) | [static] |
void TKroneckerLL::TestGradDescent | ( | const int & | KronIters, |
const int & | KiloSamples, | ||
const TStr & | Permutation | ||
) | [static] |
TFltQu TKroneckerLL::TestKronDescent | ( | const bool & | DoExact, |
const bool & | TruePerm, | ||
double | LearnRate, | ||
const int & | WarmUp, | ||
const int & | NSamples, | ||
const TKronMtx & | TrueParam | ||
) |
TFltV TKroneckerLL::TestSamplePerm | ( | const TStr & | OutFNm, |
const int & | WarmUp, | ||
const int & | NSamples, | ||
const TKronMtx & | TrueMtx, | ||
const bool & | DoPlot = true |
||
) |
void TKroneckerLL::UpdateGraphDLL | ( | const int & | SwapNId1, |
const int & | SwapNId2 | ||
) |
friend class TPt< TKroneckerLL > [friend] |