def _build_mix_args(mtrack, stem_indices, alternate_weights, alternate_files,
                    additional_files):
    """Create lists of filepaths and weights to use in final mix.

    Parameters
    ----------
    mtrack : Multitrack
        Multitrack object
    stem_indices : list
        stem indices to include in mix.
        If None, mixes all stems
    alternate_weights : dict
        Dictionary with stem indices as keys and mixing coefficients as values.
        Stem indices present that are not in this dictionary will use the
        default estimated mixing coefficient.
    alternate_files : dict
        Dictionary with stem indices as keys and filepaths as values.
        Audio file to use in place of original stem. Stem indices present that
        are not in this dictionary will use the original stems.
    additional_files : list of tuples
        List of tuples of (filepath, mixing_coefficient) pairs to additionally
        add to final mix.

    Returns
    -------
    filepaths : list
        List of filepaths that were included in mix.
    weights : list
        List of weights that were used in mix

    """
    if stem_indices is None:
        stem_indices = list(mtrack.stems.keys())

    if alternate_files is None:
        alternate_files = {}

    if alternate_weights is None:
        alternate_weights = {}

    weights = []
    filepaths = []
    for index in stem_indices:
        if index in alternate_files.keys():
            filepaths.append(alternate_files[index])
        else:
            filepaths.append(mtrack.stems[index].audio_path)

        if index in alternate_weights.keys():
            weights.append(alternate_weights[index])
        else:
            if mtrack.stems[index].mixing_coefficient is not None:
                mix_coeff = mtrack.stems[index].mixing_coefficient
            else:
                print(
                    '[Warning] Multitrack does not have mixing coefficients. '
                    'Using uniform stem weights.'
                )
                mix_coeff = 1
            weights.append(mix_coeff)

    if additional_files is not None:
        for fpath, weight in additional_files:
            filepaths.append(fpath)
            weights.append(weight)

    return filepaths, weights