code: def ensemble(args, model, checkpoints):
      preds = []
      meta = None
      for checkpoint in checkpoints:
          model.load_state_dict(torch.load(checkpoint))
          model = model.cuda()
          print("predicting...", checkpoint)
  
          pred, meta = do_tta_predict(
              args, model, checkpoint, tta_num=2
          )
          preds.append(pred)
  
      y_pred_test = generate_preds(
          np.mean(preds, 0),
          (settings.ORIG_H, settings.ORIG_W),
          args.pad_mode,
      )
  
      submission = create_submission(meta, y_pred_test)
      submission.to_csv(args.sub_file, index=None, encoding="utf-8")
  
imports: import os
  import glob
  import argparse
  import numpy
  import torch
  import torch.optim
  import torch.nn.functional
  import settings
  from loader import get_test_loader, add_depth_channel
  from models import UNetResNetV4, UNetResNetV5, UNetResNetV6, UNet7, UNet8
  from postprocessing import crop_image, binarize, resize_image
  from metrics import intersection_over_union, intersection_over_union_thresholds
  from utils import create_submission
label_desc: Use image node_id 3 for calling a global function with example usage: ensemble(args, model, checkpoints) without return types