Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
acts-core
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD 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
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
acts
acts-core
Commits
fde5374b
Commit
fde5374b
authored
5 years ago
by
leggett
Browse files
Options
Downloads
Patches
Plain Diff
apply formatting artifacts
parent
1e575ddf
No related branches found
No related tags found
1 merge request
!784
Seedfinder test: specify input file on command line, quiet output
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
Tests/UnitTests/Core/Seeding/SeedfinderTest.cpp
+27
-28
27 additions, 28 deletions
Tests/UnitTests/Core/Seeding/SeedfinderTest.cpp
with
27 additions
and
28 deletions
Tests/UnitTests/Core/Seeding/SeedfinderTest.cpp
+
27
−
28
View file @
fde5374b
...
@@ -67,50 +67,49 @@ std::vector<const SpacePoint*> readFile(std::string filename) {
...
@@ -67,50 +67,49 @@ std::vector<const SpacePoint*> readFile(std::string filename) {
}
}
int
main
(
int
argc
,
char
**
argv
)
{
int
main
(
int
argc
,
char
**
argv
)
{
std
::
string
file
{
"sp.txt"
};
std
::
string
file
{
"sp.txt"
};
bool
help
(
false
);
bool
help
(
false
);
bool
quiet
(
false
);
bool
quiet
(
false
);
int
opt
;
int
opt
;
while
((
opt
=
getopt
(
argc
,
argv
,
"hf:q"
))
!=
-
1
)
{
while
((
opt
=
getopt
(
argc
,
argv
,
"hf:q"
))
!=
-
1
)
{
switch
(
opt
)
{
switch
(
opt
)
{
case
'f'
:
case
'f'
:
file
=
optarg
;
file
=
optarg
;
break
;
break
;
case
'q'
:
case
'q'
:
quiet
=
true
;
quiet
=
true
;
break
;
break
;
case
'h'
:
case
'h'
:
help
=
true
;
help
=
true
;
default:
/* '?' */
default:
/* '?' */
std
::
cerr
<<
"Usage: "
<<
argv
[
0
]
std
::
cerr
<<
"Usage: "
<<
argv
[
0
]
<<
" [-hq] [-f FILENAME]
\n
"
;
<<
" [-hq] [-f FILENAME]
\n
"
;
if
(
help
)
{
if
(
help
)
{
std
::
cout
<<
" -h : this help"
<<
std
::
endl
;
std
::
cout
<<
" -h : this help"
<<
std
::
endl
;
std
::
cout
std
::
cout
<<
" -f FILE : read spacepoints from FILE. Default is
\"
"
<<
" -f FILE : read spacepoints from FILE. Default is
\"
"
<<
file
<<
"
\"
"
<<
std
::
endl
;
<<
file
<<
"
\"
"
<<
std
::
endl
;
std
::
cout
<<
" -q : don't print out all found seeds"
<<
std
::
endl
;
std
::
cout
<<
" -q : don't print out all found seeds"
}
<<
std
::
endl
;
}
exit
(
EXIT_FAILURE
);
exit
(
EXIT_FAILURE
);
}
}
}
}
std
::
ifstream
f
(
file
);
std
::
ifstream
f
(
file
);
if
(
!
f
.
good
())
{
if
(
!
f
.
good
())
{
std
::
cerr
<<
"input file
\"
"
<<
file
<<
"
\"
does not exist
\n
"
;
std
::
cerr
<<
"input file
\"
"
<<
file
<<
"
\"
does not exist
\n
"
;
exit
(
EXIT_FAILURE
);
exit
(
EXIT_FAILURE
);
}
}
auto
start_read
=
std
::
chrono
::
system_clock
::
now
();
auto
start_read
=
std
::
chrono
::
system_clock
::
now
();
std
::
vector
<
const
SpacePoint
*>
spVec
=
readFile
(
file
);
std
::
vector
<
const
SpacePoint
*>
spVec
=
readFile
(
file
);
auto
end_read
=
std
::
chrono
::
system_clock
::
now
();
auto
end_read
=
std
::
chrono
::
system_clock
::
now
();
std
::
chrono
::
duration
<
double
>
elapsed_read
=
end_read
-
start_read
;
std
::
chrono
::
duration
<
double
>
elapsed_read
=
end_read
-
start_read
;
std
::
cout
<<
"read "
<<
spVec
.
size
()
<<
" SP from file "
<<
file
std
::
cout
<<
"read "
<<
spVec
.
size
()
<<
" SP from file "
<<
file
<<
" in "
<<
" in "
<<
elapsed_read
.
count
()
<<
"s"
<<
elapsed_read
.
count
()
<<
"s"
<<
std
::
endl
;
<<
std
::
endl
;
Acts
::
SeedfinderConfig
<
SpacePoint
>
config
;
Acts
::
SeedfinderConfig
<
SpacePoint
>
config
;
// silicon detector max
// silicon detector max
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment