src/TemporalTrainer/TemporalTrainer.cpp
// TODO: at some point this and LearnIt2Trainer/trainer.cpp should be
// refactored and the common code put in a base class

at some point this and LearnIt2Trainer/trainer.cpp should be
refactored and the common code put in a base class
at some point this and LearnIt2Trainer / trainer . cpp should be refactored and the common code put in a base class
TemporalTrainer::TemporalTrainer(TemporalDB_ptr db, MultiAlphabet_ptr alphabet,
		MultilabelInferenceDataView_ptr data, bool activeLearning) 
: FunctionWithGradient(alphabet->size()), _canFinish(!activeLearning),
_alphabet(alphabet), _data(data), _db(db), _iteration(0), _ll(0.0),
	_typeTable(db->makeTypeTable())
{
	setParams(alphabet->getWeights());
}
TemporalTrainer :: TemporalTrainer ( TemporalDB_ptr db , MultiAlphabet_ptr alphabet , MultilabelInferenceDataView_ptr data , bool activeLearning ) : FunctionWithGradient ( alphabet -> size ( ) ) , _canFinish ( ! activeLearning ) , _alphabet ( alphabet ) , _data ( data ) , _db ( db ) , _iteration ( 0 ) , _ll ( 0.0 ) , _typeTable ( db -> makeTypeTable ( ) ) { setParams ( alphabet -> getWeights ( ) ) ; }
TODO: at some point this and LearnIt2Trainer/trainer.cpp should be
refactored and the common code put in a base class
TODO : at some point this and LearnIt2Trainer / trainer . cpp should be refactored and the common code put in a base class
/*if (db->readOnly()) {
		throw UnexpectedInputException("TemporalTrainer::TemporalTrainer",
			"Cannot construct TemporalTrainer from a read-only temporal DB");
	}*/