https://github.com/Microsoft/CNTK
Raw File
Tip revision: 10fa0e2768c2a9ba5a1569171811c055abc9514a authored by yuxiaoguo on 09 March 2017, 02:44:26 UTC
small fixs
Tip revision: 10fa0e2
UtteranceDerivativeComputationInterface.h
#pragma once

#include "Matrix.h"
#include "basetypes.h"

namespace Microsoft { namespace MSR { namespace CNTK {

// This class defines the interface for utterance derivative computation.
template <class ElemType>
class UtteranceDerivativeComputationInterface
{
public:
    // Computes derivative and objective for given utterance ID and
    // log-likelihood from neural network output.
    virtual bool ComputeDerivative(const wstring& /*uttID*/,
                                   const Matrix<ElemType>& /*logLikelihood*/,
                                   Matrix<ElemType>* /*derivative*/,
                                   ElemType* /*objective*/) = 0;

    // Returns true if we have resources to comptue the derivative, otherwise
    // returns false.
    virtual bool HasResourceForDerivative(const wstring& /*uttID*/) const = 0;
};
} } }
back to top