You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: spm_shoot_update.m
    path of file: ./repos/spm/toolbox/Shoot
    
    the code of the file until where you have to start completion: function [u0,ll1,ll2] = spm_shoot_update(g,f,u0,phi,dt,prm, bs_args,scale)
% Shooting Of Diffeomorphisms (Spawn Of Dartel)
% FORMAT u0 = spm_shoot_update(g,f,u0,phi,dt,prm, bs_args)
% g        - template
% f        - individual
% u0       - initial velocity
% phi      - deformation
% dt       - Jacobian determinants
% prm      - Parameters of differential operator

    
function [u0,ll1,ll2] = spm_shoot_update(g,f,u0,phi,dt,prm, bs_args,scale)
% Shooting Of Diffeomorphisms (Spawn Of Dartel)
% FORMAT u0 = spm_shoot_update(g,f,u0,phi,dt,prm, bs_args)
% g        - template
% f        - individual
% u0       - initial velocity
% phi      - deformation
% dt       - Jacobian determinants
% prm      - Parameters of differential operator
% bs_args  - interpolation settings
% scale    - scaling of the update step
%
% u0       - updated initial velocity
% ll1      - matching part of objective function
% ll2      - regularisation part of objective function
%
% The easiest way to figure out what this function does is to read the code.
%__________________________________________________________________________

% John Ashburner
% Copyright (C) 2009-2022 Wellcome Centre for Human Neuroimaging


if nargin<8, scale = 1.0; end