Adjust print messages for host information.

这个提交包含在:
Craig Warren
2017-02-27 17:57:41 +00:00
父节点 60ae7d6b6c
当前提交 72431a89e1

查看文件

@@ -91,8 +91,8 @@ def run_main(args):
# Get information about host machine
hostinfo = get_host_info()
hyperthreading = ', hyperthreading active' if hostinfo['hyperthreading'] else ''
print('\nHost: {}; {} x {} ({} total physical cores{}); {} RAM; {}'.format(hostinfo['machineID'], hostinfo['sockets'], hostinfo['cpuID'], hostinfo['physicalcores'], hyperthreading, human_size(hostinfo['ram'], a_kilobyte_is_1024_bytes=True), hostinfo['osversion']))
hyperthreading = ', {} cores with Hyper-Threading'.format(hostinfo['logicalcores']) if hostinfo['hyperthreading'] else ''
print('\nHost: {}; {} x {} ({} cores{}); {} RAM; {}'.format(hostinfo['machineID'], hostinfo['sockets'], hostinfo['cpuID'], hostinfo['physicalcores'], hyperthreading, human_size(hostinfo['ram'], a_kilobyte_is_1024_bytes=True), hostinfo['osversion']))
# Create a separate namespace that users can access in any Python code blocks in the input file
usernamespace = {'c': c, 'e0': e0, 'm0': m0, 'z0': z0, 'number_model_runs': numbermodelruns, 'input_directory': os.path.dirname(os.path.abspath(inputfile.name))}
@@ -203,7 +203,7 @@ def run_benchmark_sim(args, inputfile, usernamespace):
# Number of threads to test - start from max physical CPU cores and divide in half until 1
minthreads = 1
maxthreads = hostinfo['cpucores']
maxthreads = hostinfo['physicalcores']
threads = []
while minthreads < maxthreads:
threads.append(int(minthreads))