#NEWLINE# def get_best_cpu_topology( flavor , image_meta , allow_threads = True , numa_topology = None ) : #NEWLINE# #INDENT# 'Get best CPU topology according to settings\n\n    :param flavor: Flavor object to query extra specs from\n    :param image_meta: nova.objects.ImageMeta object instance\n    :param allow_threads: if the hypervisor supports CPU threads\n    :param numa_topology: InstanceNUMATopology object that may contain\n                          additional topology constraints (such as threading\n                          information) that we should consider\n\n    Look at the properties set in the flavor extra specs and\n    the image metadata and build up a list of all possible\n    valid CPU topologies that can be used in the guest. Then\n    return the best topology to use\n\n    :returns: a nova.objects.VirtCPUTopology instance for best topology\n    ' #NEWLINE# return _get_desirable_cpu_topologies ( flavor , image_meta , allow_threads , numa_topology ) [ 0 ]