code: def cmd_finetune(
      dataset,
      run_name,
      checkpoint_dir,
      model_name,
      model_dir,
      steps,
      restore_from,
      sample_every,
      save_every,
      print_every,
      optimizer,
      overwrite,
      multi_gpu,
  ):
      """Wrapper script for finetuning the model via the CLI."""
  
      if not is_gpt2_downloaded(
          model_dir=model_dir, model_name=model_name
      ):
          download_gpt2(model_dir=model_dir, model_name=model_name)
  
      sess = start_tf_sess()
      finetune(
          sess,
          dataset=dataset,
          run_name=run_name,
          checkpoint_dir=checkpoint_dir,
          model_name=model_name,
          model_dir=model_dir,
          steps=steps,
          restore_from=restore_from,
          sample_every=sample_every,
          save_every=save_every,
          print_every=print_every,
          optimizer=optimizer,
          overwrite=overwrite,
          multi_gpu=multi_gpu,
      )
  
imports: import tarfile
  import os
  import json
  import requests
  import sys
  import shutil
  import re
  from tqdm import tqdm, trange
  import numpy
  import tensorflow
  from tensorflow.core.protobuf import rewriter_config_pb2
  from tensorflow.python.client import device_lib
  import time
  from datetime import datetime
  import csv
  import argparse
  from sys import exit
  import codecs
  from gpt_2_simple.src import model, sample, encoder, memory_saving_gradients
  from gpt_2_simple.src.load_dataset import load_dataset, Sampler
  from gpt_2_simple.src.accumulate import AccumulatingOptimizer
label_desc: Use image node_id 21 for calling a global function with example usage: cmd_finetune(dataset, run_name, checkpoint_dir, model_name, model_dir, steps, restore_from, sample_every, save_every, print_every, optimizer, overwrite, multi_gpu) without return types