Source code for cogdl.trainers.base_trainer

from abc import ABC, abstractmethod
from argparse import ArgumentParser


[docs]class BaseTrainer(ABC): @classmethod @abstractmethod
[docs] def build_trainer_from_args(cls, args): """Build a new trainer instance.""" raise NotImplementedError( "Trainers must implement the build_trainer_from_args method"
)