https://github.com/Microsoft/CNTK
Raw File
Tip revision: 5b4155e634744d7c5f5b6e81a14c41c735d8d09b authored by thhoens on 30 June 2016, 23:30:47 UTC
Revert to cuda 7
Tip revision: 5b4155e
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