docstr: Iterate a couple times over a model
docstr_tok: ["Iterate","a","couple","times","over","a","model"]
code: def run_training(
      self,
      tmp_path,
      fake_embeddings,
      train_file,
      dev_file,
      extra_args=None,
  ):
      """
      Iterate a couple times over a model
      """
      trainer, train_set, args = self.build_model(
          tmp_path, fake_embeddings, train_file, dev_file, extra_args
      )
      dev_set = data.read_dataset(
          args.dev_file, args.wordvec_type, args.min_train_len
      )
      labels = data.dataset_labels(train_set)
  
      save_filename = os.path.join(args.save_dir, args.save_name)
      checkpoint_file = utils.checkpoint_name(
          args.save_dir, save_filename, args.checkpoint_save_name
      )
      classifier.train_model(
          trainer,
          save_filename,
          checkpoint_file,
          args,
          train_set,
          dev_set,
          labels,
      )
      return trainer
  
imports: import os
  import pytest
  import numpy
  import stanza.models.classifier
  import stanza.models.classifiers.data
  from stanza.models.classifiers.trainer import Trainer
  from stanza.models.common import pretrain
  from stanza.models.common import utils
  from stanza.tests.classifiers.test_data import train_file, dev_file, test_file, DATASET, SENTENCES
label_desc: Use image node_id 2 for calling the TestClassifier obj's underlying member method code with example usage: obj.run_training(tmp_path, fake_embeddings, train_file, dev_file, extra_args) and returns: trainer