Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add Python 3.11 correction factor #10

Draft
wants to merge 4 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion src/db12/benchmark.py
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,11 @@ def get_norm_correction(norm_computed):
try:
with open("/proc/cpuinfo", "r") as file_object:
content = file_object.read()
cpu_brand_name = re.findall("model name\t: ([a-zA-Z]*)", content)[0]
cpu_brand_name = re.findall("vendor_id\t: ([a-zA-Z]*)", content)[0]
if cpu_brand_name == "GenuineIntel":
cpu_brand_name = "Intel"
elif cpu_brand_name == "AuthenticAMD":
cpu_brand_name = "AMD"
except (IOError, IndexError):
logging.warning(
"Cannot correct the score, return the raw norm: cannot access CPU information"
Expand Down
6 changes: 6 additions & 0 deletions src/db12/factors.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@
"Intel": 0.86,
"AMD": 0.71
}
},
"3.11": {
"cpu_brand": {
"Intel": 0.912400392678881,
"AMD": 0.912400392678881
}
Comment on lines +8 to +13
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If I understand correctly, these factors aim at aligning the DB12 score, computed with python3.11, with the HEPScore. Am I right?

factors.json was originally introduced to align the original DB12 score, computed with python2, with the DB12 score computed with python3.9.

The questions are:

  • do we want to introduce this HEPScore scaling factor directly in the DB12 repo?

    • DB12 can also be used outside of the LHC context
    • The HEPSPEC06 scaling factor was set in LHCbDIRAC
  • do we still want to be aligned with the original DB12 score (python2)?

    • DB12 can be used outside of the LHC context again.
    • Regarding LHCb MC sim applications, the raw python3.9 DB12 score was more accurate than the original DB12 score on AMD CPUs (and a bit less accurate on Intel but not significantly...)
    • May be we need to compare the raw python3.11 DB12 score to the LHCb MC sim applications now.

Any opinion about that @fstagni?

}
}
}
Loading