C# Class BP_LDA.LDA_Learn

Mostra file Open project: jvking/bp-lda

Public Methods

Method Description
BackPropagation_LDA ( SparseMatrix Xt, SparseMatrix Dt, DNNRun_t DNNRun, paramModel_t paramModel, Grad_t Grad ) : void
ComputeCrossEntropy ( SparseMatrix Xt, DenseMatrix Phi, DenseMatrix theta_top ) : float
ComputeCrossEntropy ( SparseMatrix Xt, DenseMatrix Phi, DenseMatrix theta_pool, int nHidLayerEffective ) : float
ComputeInverseDocumentFrequency ( SparseMatrix InputData ) : DenseColumnVector
ComputeNumberOfErrors ( SparseMatrix Dt, DenseMatrix y ) : int
ComputeNumberOfErrors ( SparseMatrix Dt, SparseMatrix y ) : int
ComputeRegularizedCrossEntropy ( SparseMatrix Xt, DenseMatrix Phi, DenseMatrix theta_top, DenseColumnVector b ) : float
ComputeSupervisedLoss ( SparseMatrix Dt, DenseMatrix y, string OutputType ) : float
ComputeSupervisedLoss ( SparseMatrix Dt, SparseMatrix y, string OutputType ) : float
DumpingFeature_BP_LDA ( SparseMatrix InputData, paramModel_t paramModel, int BatchSize_normal, string FeatureFileName, string DataName ) : void
ExternalEvaluation ( string ExternalEvalToolPath, string ResultFile, string TestLabelFile, int epoch, string EvalDataName ) : void
ForwardActivation_LDA ( SparseMatrix Xt, DNNRun_t DNNRun, paramModel_t paramModel, bool flag_IsTraining ) : void
ModelInit_LDA_Feedforward ( paramModel_t paramModel ) : void
PrecomputeLearningRateSchedule ( int nBatch, int nEpoch, double LearnRateStart, double LearnRateEnd, double Accuracy ) : double[]
PredictingOutput_BP_sLDA ( SparseMatrix TestData, paramModel_t paramModel, int BatchSize_normal, string ScoreFileName ) : void
SMD_Update ( DenseMatrix X, DenseMatrix Grad, DenseRowVector LearningRatePerCol, float eta ) : float
Testing_BP_LDA ( SparseMatrix TestData, paramModel_t paramModel ) : float
Testing_BP_LDA ( SparseMatrix TestData, paramModel_t paramModel, int BatchSize_normal ) : float
Testing_BP_sLDA ( SparseMatrix TestData, SparseMatrix TestLabel, paramModel_t paramModel ) : float
Testing_BP_sLDA ( SparseMatrix TestData, SparseMatrix TestLabel, paramModel_t paramModel, int BatchSize_normal, string ScoreFileName, string EvalDataName ) : float
TrainingBP_LDA ( SparseMatrix TrainData, SparseMatrix TestData, paramModel_t paramModel, paramTrain_t paramTrain, string ModelFile, string ResultFile ) : void
TrainingBP_sLDA ( SparseMatrix TrainData, SparseMatrix TrainLabel, SparseMatrix TestData, SparseMatrix TestLabel, SparseMatrix ValidData, SparseMatrix ValidLabel, paramModel_t paramModel, paramTrain_t paramTrain, string ModelFile, string ResultFile ) : void

Method Details

BackPropagation_LDA() public static method

public static BackPropagation_LDA ( SparseMatrix Xt, SparseMatrix Dt, DNNRun_t DNNRun, paramModel_t paramModel, Grad_t Grad ) : void
Xt LinearAlgebra.SparseMatrix
Dt LinearAlgebra.SparseMatrix
DNNRun DNNRun_t
paramModel paramModel_t
Grad Grad_t
return void

ComputeCrossEntropy() public static method

public static ComputeCrossEntropy ( SparseMatrix Xt, DenseMatrix Phi, DenseMatrix theta_top ) : float
Xt LinearAlgebra.SparseMatrix
Phi LinearAlgebra.DenseMatrix
theta_top LinearAlgebra.DenseMatrix
return float

ComputeCrossEntropy() public static method

public static ComputeCrossEntropy ( SparseMatrix Xt, DenseMatrix Phi, DenseMatrix theta_pool, int nHidLayerEffective ) : float
Xt LinearAlgebra.SparseMatrix
Phi LinearAlgebra.DenseMatrix
theta_pool LinearAlgebra.DenseMatrix
nHidLayerEffective int
return float

ComputeInverseDocumentFrequency() public static method

public static ComputeInverseDocumentFrequency ( SparseMatrix InputData ) : DenseColumnVector
InputData LinearAlgebra.SparseMatrix
return LinearAlgebra.DenseColumnVector

ComputeNumberOfErrors() public static method

public static ComputeNumberOfErrors ( SparseMatrix Dt, DenseMatrix y ) : int
Dt LinearAlgebra.SparseMatrix
y LinearAlgebra.DenseMatrix
return int

ComputeNumberOfErrors() public static method

public static ComputeNumberOfErrors ( SparseMatrix Dt, SparseMatrix y ) : int
Dt LinearAlgebra.SparseMatrix
y LinearAlgebra.SparseMatrix
return int

ComputeRegularizedCrossEntropy() public static method

public static ComputeRegularizedCrossEntropy ( SparseMatrix Xt, DenseMatrix Phi, DenseMatrix theta_top, DenseColumnVector b ) : float
Xt LinearAlgebra.SparseMatrix
Phi LinearAlgebra.DenseMatrix
theta_top LinearAlgebra.DenseMatrix
b LinearAlgebra.DenseColumnVector
return float

ComputeSupervisedLoss() public static method

public static ComputeSupervisedLoss ( SparseMatrix Dt, DenseMatrix y, string OutputType ) : float
Dt LinearAlgebra.SparseMatrix
y LinearAlgebra.DenseMatrix
OutputType string
return float

ComputeSupervisedLoss() public static method

public static ComputeSupervisedLoss ( SparseMatrix Dt, SparseMatrix y, string OutputType ) : float
Dt LinearAlgebra.SparseMatrix
y LinearAlgebra.SparseMatrix
OutputType string
return float

DumpingFeature_BP_LDA() public static method

public static DumpingFeature_BP_LDA ( SparseMatrix InputData, paramModel_t paramModel, int BatchSize_normal, string FeatureFileName, string DataName ) : void
InputData LinearAlgebra.SparseMatrix
paramModel paramModel_t
BatchSize_normal int
FeatureFileName string
DataName string
return void

ExternalEvaluation() public static method

public static ExternalEvaluation ( string ExternalEvalToolPath, string ResultFile, string TestLabelFile, int epoch, string EvalDataName ) : void
ExternalEvalToolPath string
ResultFile string
TestLabelFile string
epoch int
EvalDataName string
return void

ForwardActivation_LDA() public static method

public static ForwardActivation_LDA ( SparseMatrix Xt, DNNRun_t DNNRun, paramModel_t paramModel, bool flag_IsTraining ) : void
Xt LinearAlgebra.SparseMatrix
DNNRun DNNRun_t
paramModel paramModel_t
flag_IsTraining bool
return void

ModelInit_LDA_Feedforward() public static method

public static ModelInit_LDA_Feedforward ( paramModel_t paramModel ) : void
paramModel paramModel_t
return void

PrecomputeLearningRateSchedule() public static method

public static PrecomputeLearningRateSchedule ( int nBatch, int nEpoch, double LearnRateStart, double LearnRateEnd, double Accuracy ) : double[]
nBatch int
nEpoch int
LearnRateStart double
LearnRateEnd double
Accuracy double
return double[]

PredictingOutput_BP_sLDA() public static method

public static PredictingOutput_BP_sLDA ( SparseMatrix TestData, paramModel_t paramModel, int BatchSize_normal, string ScoreFileName ) : void
TestData LinearAlgebra.SparseMatrix
paramModel paramModel_t
BatchSize_normal int
ScoreFileName string
return void

SMD_Update() public static method

public static SMD_Update ( DenseMatrix X, DenseMatrix Grad, DenseRowVector LearningRatePerCol, float eta ) : float
X LinearAlgebra.DenseMatrix
Grad LinearAlgebra.DenseMatrix
LearningRatePerCol LinearAlgebra.DenseRowVector
eta float
return float

Testing_BP_LDA() public static method

public static Testing_BP_LDA ( SparseMatrix TestData, paramModel_t paramModel ) : float
TestData LinearAlgebra.SparseMatrix
paramModel paramModel_t
return float

Testing_BP_LDA() public static method

public static Testing_BP_LDA ( SparseMatrix TestData, paramModel_t paramModel, int BatchSize_normal ) : float
TestData LinearAlgebra.SparseMatrix
paramModel paramModel_t
BatchSize_normal int
return float

Testing_BP_sLDA() public static method

public static Testing_BP_sLDA ( SparseMatrix TestData, SparseMatrix TestLabel, paramModel_t paramModel ) : float
TestData LinearAlgebra.SparseMatrix
TestLabel LinearAlgebra.SparseMatrix
paramModel paramModel_t
return float

Testing_BP_sLDA() public static method

public static Testing_BP_sLDA ( SparseMatrix TestData, SparseMatrix TestLabel, paramModel_t paramModel, int BatchSize_normal, string ScoreFileName, string EvalDataName ) : float
TestData LinearAlgebra.SparseMatrix
TestLabel LinearAlgebra.SparseMatrix
paramModel paramModel_t
BatchSize_normal int
ScoreFileName string
EvalDataName string
return float

TrainingBP_LDA() public static method

public static TrainingBP_LDA ( SparseMatrix TrainData, SparseMatrix TestData, paramModel_t paramModel, paramTrain_t paramTrain, string ModelFile, string ResultFile ) : void
TrainData LinearAlgebra.SparseMatrix
TestData LinearAlgebra.SparseMatrix
paramModel paramModel_t
paramTrain paramTrain_t
ModelFile string
ResultFile string
return void

TrainingBP_sLDA() public static method

public static TrainingBP_sLDA ( SparseMatrix TrainData, SparseMatrix TrainLabel, SparseMatrix TestData, SparseMatrix TestLabel, SparseMatrix ValidData, SparseMatrix ValidLabel, paramModel_t paramModel, paramTrain_t paramTrain, string ModelFile, string ResultFile ) : void
TrainData LinearAlgebra.SparseMatrix
TrainLabel LinearAlgebra.SparseMatrix
TestData LinearAlgebra.SparseMatrix
TestLabel LinearAlgebra.SparseMatrix
ValidData LinearAlgebra.SparseMatrix
ValidLabel LinearAlgebra.SparseMatrix
paramModel paramModel_t
paramTrain paramTrain_t
ModelFile string
ResultFile string
return void