Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
SaQC
Manage
Activity
Members
Labels
Plan
Issues
36
Issue boards
Milestones
Wiki
Code
Merge requests
8
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
rdm-software
SaQC
Commits
4ba0c0db
Commit
4ba0c0db
authored
5 years ago
by
David Schäfer
Browse files
Options
Downloads
Plain Diff
Merge branch 'bugfixes' into 'master'
Bugfixes See merge request
!11
parents
a6c875f1
300238ca
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!11
Bugfixes
Pipeline
#2416
passed with stage
in 6 minutes and 35 seconds
Changes
4
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
saqc/core/config.py
+1
-1
1 addition, 1 deletion
saqc/core/config.py
saqc/core/core.py
+1
-1
1 addition, 1 deletion
saqc/core/core.py
saqc/core/reader.py
+1
-1
1 addition, 1 deletion
saqc/core/reader.py
saqc/funcs/constants_detection.py
+2
-2
2 additions, 2 deletions
saqc/funcs/constants_detection.py
with
5 additions
and
5 deletions
saqc/core/config.py
+
1
−
1
View file @
4ba0c0db
...
...
@@ -6,7 +6,7 @@ class Fields:
VARNAME
=
"
varname
"
START
=
"
start_date
"
END
=
"
end_date
"
TESTS
=
"
test
*
"
TESTS
=
"
test
"
PLOT
=
"
plot
"
LINENUMBER
=
"
line
"
...
...
This diff is collapsed.
Click to expand it.
saqc/core/core.py
+
1
−
1
View file @
4ba0c0db
...
...
@@ -88,7 +88,7 @@ def run(
config
=
readConfig
(
config_file
,
data
)
# split config into the test and some 'meta' data
tests
=
config
.
filter
(
regex
=
Fields
.
TESTS
)
tests
=
config
.
filter
(
regex
=
Fields
.
TESTS
+
'
*
'
)
meta
=
config
[
config
.
columns
.
difference
(
tests
.
columns
)]
# prepapre the flags
...
...
This diff is collapsed.
Click to expand it.
saqc/core/reader.py
+
1
−
1
View file @
4ba0c0db
...
...
@@ -125,7 +125,7 @@ def checkConfig(config_df: pd.DataFrame, data: pd.DataFrame, flagger: BaseFlagge
if
pd
.
isnull
(
config_row
[
F
.
VARNAME
])
or
not
var_name
:
_raise
(
config_row
,
SyntaxError
,
f
"
non-optional column
'
{
F
.
VARNAME
}
'
is missing or empty
"
)
test_fields
=
config_row
.
filter
(
regex
=
F
.
TESTS
).
dropna
()
test_fields
=
config_row
.
filter
(
regex
=
F
.
TESTS
+
'
*
'
).
dropna
()
if
test_fields
.
empty
:
_raise
(
config_row
,
SyntaxError
,
f
"
at least one test needs to be given for variable
"
,
...
...
This diff is collapsed.
Click to expand it.
saqc/funcs/constants_detection.py
+
2
−
2
View file @
4ba0c0db
...
...
@@ -22,9 +22,9 @@ def flagConstant(data, field, flagger, thresh, window, **kwargs):
"""
d
=
data
[
field
]
# find all constant values in forward search
# find all constant values in
a row with a
forward search
r
=
d
.
rolling
(
window
=
window
)
mask
=
(
r
.
max
()
-
r
.
min
()
)
<=
thresh
mask
=
(
r
.
max
()
-
r
.
min
()
<=
thresh
)
&
(
r
.
count
()
>
1
)
# backward rolling for offset windows hack
bw
=
mask
[::
-
1
].
copy
()
...
...
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