Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
LINC
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Container Registry
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
Show more breadcrumbs
ResearchAndDevelopment
LINC
Commits
e38e2cf9
Commit
e38e2cf9
authored
3 years ago
by
Matthijs van der Wild
Browse files
Options
Downloads
Patches
Plain Diff
Improved error handling
Former-commit-id:
82018ffe
[formerly
436d0cca
] Former-commit-id:
c2b5e634
Former-commit-id:
93f1fd05
parent
a8a1cffb
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
test_jobs/check_workflow_results.py
+4
-1
4 additions, 1 deletion
test_jobs/check_workflow_results.py
with
4 additions
and
1 deletion
test_jobs/check_workflow_results.py
+
4
−
1
View file @
e38e2cf9
...
...
@@ -20,6 +20,7 @@ def main(check, control):
control_path : str
Path to control results directory
"""
error
=
False
#Check that all expected output files are present
dcmp
=
dircmp
(
check
,
control
)
...
...
@@ -30,6 +31,7 @@ def main(check, control):
if
len
(
dcmp
.
right_only
)
>
0
:
print
(
'
ERROR: The following files are present in the control but not in the
'
'
output: {}
'
.
format
(
dcmp
.
right_only
))
error
=
True
check_path
=
check
+
'
/cal_values/cal_solutions.h5
'
control_path
=
control
+
'
/cal_values/cal_solutions.h5
'
...
...
@@ -65,6 +67,7 @@ def main(check, control):
axis
=
freq_axis_index
)
if
not
np
.
allclose
(
check_soltabval
,
matching_vals
,
rtol
=
1e-03
,
atol
=
1e-03
,
equal_nan
=
True
):
error
=
True
print
(
"
Val array of soltab {} does not match the control
"
.
format
(
soltabname
))
with
open
(
"
check_soltab.{}.val
"
.
format
(
soltabname
),
"
w
"
)
as
f
:
f
.
write
(
str
(
check_soltabval
[:]))
...
...
@@ -74,7 +77,7 @@ def main(check, control):
print
(
"
Val array of soltab {} matches the control
"
.
format
(
soltabname
))
check_h5
.
close
()
control_h5
.
close
()
sys
.
exit
(
0
)
sys
.
exit
(
error
)
if
__name__
==
'
__main__
'
:
descriptiontext
=
"
Checks the output of a workflow run.
\n
"
...
...
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