docstr: :param dataset: a child of torch.utils.data.Dataset
  :param args: a dataclass that contains settings
  :return: None
docstr_tok: [":","param","dataset",":","a","child","of","torch.utils.data.Dataset",":","param","args",":","a","dataclass","that","contains","settings",":","return",":","None"]
code: def _run_train(
      self, train_dataset, eval_dataset, args, data_collator
  ):
      """
      :param dataset: a child of torch.utils.data.Dataset
      :param args: a dataclass that contains settings
      :return: None
      """
  
      # if model has not been moved to device and DeepSpeed is not being used
      if not self._on_device and not args.deepspeed:
          self.logger.info(f"Moving model to {self.device}")
          self.model.to(self.device)
          self._on_device = True
  
      training_args = self._get_training_args(args)
  
      os.environ["WANDB_PROJECT"] = args.project_name
  
      if self._type == "wp":
          self._data_collator.mlm_probability = args.mlm_probability
  
      if self._type == "tt":
          train_class = Seq2SeqTrainer
      else:
          train_class = Trainer
  
      trainer = train_class(
          model=self.model,
          args=training_args,
          train_dataset=train_dataset,
          eval_dataset=eval_dataset,
          tokenizer=self.tokenizer,
          data_collator=data_collator,
      )
      trainer.add_callback(FistStep())
      trainer.train()
  
imports: import logging
  import os
  import tempfile
  from typing import Union
  from datasets import Dataset, DatasetDict, load_dataset, load_from_disk
  import torch
  from transformers import AutoConfig, AutoModel, AutoTokenizer, Seq2SeqTrainer, Seq2SeqTrainingArguments, Trainer, TrainingArguments
  from happytransformer.args import EvalArgs, TrainArgs
  from happytransformer.fine_tuning_util import EvalResult, FistStep, ZERO_2_SETTINGS, ZERO_3_SETTINGS
label_desc: Use image node_id 13 for calling the HappyTransformer obj's underlying member method code with example usage: obj._run_train(train_dataset, eval_dataset, args, data_collator) without return types