de.jstacs.sequenceScores.statisticalModels.trainable.hmm.states
Interface DifferentiableState

All Superinterfaces:
State
All Known Implementing Classes:
SimpleDifferentiableState

public interface DifferentiableState
extends State

This interface declares a method that allows to evaluate the gradient which is essential for numerical optimization.

Author:
Jens Keilwagen

Method Summary
 double getLogScoreAndPartialDerivation(int startPos, int endPos, IntList indices, DoubleList partDer, Sequence seq)
          This method allows to compute the logarithm of the score and the gradient for the given subsequences.
 
Methods inherited from interface de.jstacs.sequenceScores.statisticalModels.trainable.hmm.states.State
getGraphvizNodeOptions, getLogScoreFor, isSilent, toString
 

Method Detail

getLogScoreAndPartialDerivation

double getLogScoreAndPartialDerivation(int startPos,
                                       int endPos,
                                       IntList indices,
                                       DoubleList partDer,
                                       Sequence seq)
                                       throws OperationNotSupportedException,
                                              WrongLengthException
This method allows to compute the logarithm of the score and the gradient for the given subsequences.

Parameters:
startPos - the start position (inclusive)
endPos - the end position (inclusive)
indices - a list for the parameter indices
partDer - a list for the partial derivations
seq - the Sequence(s)
Returns:
the logarithm of the score
Throws:
WrongLengthException - if the length can not be modeled
OperationNotSupportedException - if the reverse complement of the sequence can not be computed