def acoustic_similarity_mapping(path_mapping, analysis_function, distance_function, stop_check=None, call_back=None, multiprocessing=True):
num_cores = int((<NUM_LIT:3> * cpu_count()) / <NUM_LIT:4>)<EOL>segments = set()<EOL>for x in path_mapping:<EOL><INDENT>segments.update(x)<EOL><DEDENT>if multiprocessing:<EOL><INDENT>cache = generate_cache_mp(segments, analysis_function, num_cores, call_back, stop_check)<EOL>asim = calculate_distances_mp(path_mapping, cache, distance_function, num_cores, call_back, stop_check)<EOL><DEDENT>else:<EOL><INDENT>cache = generate_cache_th(segments, analysis_function, num_cores, call_back, stop_check)<EOL>asim = calculate_distances_th(path_mapping, cache, distance_function, num_cores, call_back, stop_check)<EOL><DEDENT>return asim<EOL>
Takes in an explicit mapping of full paths to .wav files to have
    acoustic similarity computed.

    Parameters
    ----------
    path_mapping : iterable of iterables
        Explicit mapping of full paths of .wav files, in the form of a
        list of tuples to be compared.


    Returns
    -------
    dict
        Returns a list of tuples corresponding to the `path_mapping` input,
        with a new final element in the tuple being the similarity/distance
        score for that mapping.