code: def xception(num_classes=1000, pretrained="imagenet"):
      model = Xception(num_classes=num_classes)
      if pretrained:
          settings = pretrained_settings["xception"][pretrained]
          assert (
              num_classes == settings["num_classes"]
          ), "num_classes should be {}, but is {}".format(
              settings["num_classes"], num_classes
          )
  
          model = Xception(num_classes=num_classes)
          model.load_state_dict(model_zoo.load_url(settings["url"]))
  
          model.input_space = settings["input_space"]
          model.input_size = settings["input_size"]
          model.input_range = settings["input_range"]
          model.mean = settings["mean"]
          model.std = settings["std"]
  
      # TODO: ugly
      model.last_linear = model.fc
      del model.fc
      return model
  
imports: from __future__ import print_function, division, absolute_import
  import math
  import torch
  import torch.nn
  import torch.nn.functional
  import torch.utils.model_zoo
  from torch.nn import init
label_desc: Use image node_id 1 for calling a global function with example usage: xception(num_classes, pretrained) and returns: model