    def train(self,
              training_config=None,
              train_dataset=None,
              eval_dataset=None,
              resume_checkpoint_path=None,
              **kwargs):
        """
        Start to train an operator.

        Args:
            training_config (`TrainingConfig`):
                The config of this trainer.
            train_dataset (`Union[Dataset, TowheeDataSet]`):
                Training dataset.
            eval_dataset (`Union[Dataset, TowheeDataSet]`):
                Evaluate dataset.
            resume_checkpoint_path (`str`):
                If resuming training, pass into the path.
            **kwargs (`Any`):
                Keyword Args.
        """
        self.setup_trainer(training_config, train_dataset, eval_dataset, **kwargs)
        self.trainer.train(resume_checkpoint_path)
Start to train an operator.

Args:
training_config (`TrainingConfig`):
The config of this trainer.
train_dataset (`Union[Dataset, TowheeDataSet]`):
Training dataset.
eval_dataset (`Union[Dataset, TowheeDataSet]`):
Evaluate dataset.
resume_checkpoint_path (`str`):
If resuming training, pass into the path.
**kwargs (`Any`):
Keyword Args.
towhee/operator/base.py