Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
H
hep-workloads
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Requirements
Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
HEP-Benchmarks
hep-workloads
Merge requests
!252
Resolve
BMK-150
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Resolve
BMK-150
BMK-150
into
qa
Overview
0
Commits
3
Pipelines
1
Changes
2
Merged
Andrea Sciaba
requested to merge
BMK-150
into
qa
5 years ago
Overview
0
Commits
3
Pipelines
1
Changes
2
Expand
Closes
BMK-150
0
0
Merge request reports
Compare
qa
qa (base)
and
latest version
latest version
3f13428e
3 commits,
5 years ago
2 files
+
44
−
14
Side-by-side
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
2
Search (e.g. *.vue) (Ctrl+P)
cms/digi/cms-digi/cms-digi-bmk.sh
+
30
−
0
Options
@@ -36,6 +36,25 @@ function doOne(){
@@ -36,6 +36,25 @@ function doOne(){
return
$status
return
$status
}
}
function
getEvents
(){
export
CMSSW_RELEASE
=
CMSSW_10_2_9
export
VO_CMS_SW_DIR
=
/cvmfs/cms.cern.ch
source
$VO_CMS_SW_DIR
/cmsset_default.sh
export
SCRAM_ARCH
=
slc6_amd64_gcc700
[[
!
-e
${
CMSSW_RELEASE
}
]]
&&
scram project CMSSW
${
CMSSW_RELEASE
}
&> /dev/null
(
pushd
${
CMSSW_RELEASE
}
;
eval
`
scramv1 runtime
-sh
`
;
popd
)
&> /dev/null
ln
-s
${
BMKDIR
}
/data/
*
.root
.
evts
=
`
python
-c
"import ROOT;f=ROOT.TFile.Open('gensim.root');print f.Get('Events').GetEntries();"
`
STATUS
=
$?
rm
-rf
${
CMSSW_RELEASE
}
rm
-f
gensim.root
if
[[
$STATUS
!=
0
]]
;
then
return
0
else
return
$evts
fi
}
# Optional function validateInputArguments may be defined in each benchmark
# Optional function validateInputArguments may be defined in each benchmark
# If it exists, it is expected to set NCOPIES, NTHREADS, NEVENTS_THREAD
# If it exists, it is expected to set NCOPIES, NTHREADS, NEVENTS_THREAD
# (based on previous defaults and on user inputs USER_NCOPIES, USER_NTHREADS, USER_NEVENTS_THREADS)
# (based on previous defaults and on user inputs USER_NCOPIES, USER_NTHREADS, USER_NEVENTS_THREADS)
@@ -59,6 +78,17 @@ function validateInputArguments(){
@@ -59,6 +78,17 @@ function validateInputArguments(){
fi
fi
# Number of events per thread
# Number of events per thread
if
[
"
$USER_NEVENTS_THREAD
"
!=
""
]
;
then
NEVENTS_THREAD
=
$USER_NEVENTS_THREAD
;
fi
if
[
"
$USER_NEVENTS_THREAD
"
!=
""
]
;
then
NEVENTS_THREAD
=
$USER_NEVENTS_THREAD
;
fi
# Extract number of events in input file
getEvents
evts
=
$?
if
[[
$evts
==
0
]]
;
then
s_msg
=
"[ERROR] Cannot extract number of events from input file"
return
1
fi
if
[[
$((
NEVENTS_THREAD
*
NTHREADS
))
-gt
$evts
]]
;
then
s_msg
=
"[ERROR] Requested number of events (
$((
NEVENTS_THREAD
*
NTHREADS
))
) exceeds number of input events (
$evts
)"
return
1
fi
# Return 0 if input arguments are valid, 1 otherwise
# Return 0 if input arguments are valid, 1 otherwise
# Report any issues to parseResults via s_msg
# Report any issues to parseResults via s_msg
export
s_msg
=
"ok"
export
s_msg
=
"ok"
Loading