你已经派生过 gprMax
镜像自地址
https://gitee.com/sunhf/gprMax.git
已同步 2025-08-06 20:46:52 +08:00
Adjust print messages for host information.
这个提交包含在:
@@ -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))
|
||||
|
在新工单中引用
屏蔽一个用户