code: def align_mesh_to_template(source, target, scale_corrective=1.2):
      scale = Scale(
          (target.norm() / source.norm()) * scale_corrective,
          n_dims=target.n_dims,
      )
      translation = Translation(target.centre() - source.centre())
      return translation.compose_before(scale)
  
file_path: insightface/reconstruction/ostec/utils/image_rasterization.py
imports: from menpo3d.rasterize import rasterize_barycentric_coordinate_images, rasterize_mesh_from_barycentric_coordinate_images
  from menpo.transform import Rotation, Translation, Scale
  from menpo3d.camera import PerspectiveProjection, PerspectiveCamera
  import numpy
label_desc: Use image node_id 5 for calling a global function with example usage: align_mesh_to_template(source, target, scale_corrective) and returns: translation