Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
MetObsCommon
Manage
Activity
Members
Plan
Wiki
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
MetObs
MetObsCommon
Commits
1367eb5c
Verified
Commit
1367eb5c
authored
Mar 15, 2023
by
David Hoese
Browse files
Options
Downloads
Patches
Plain Diff
Change influxdb tasks to be task.every range
parent
78a45370
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
metobscommon/influxdb.py
+1
-2
1 addition, 2 deletions
metobscommon/influxdb.py
with
1 addition
and
2 deletions
metobscommon/influxdb.py
+
1
−
2
View file @
1367eb5c
...
...
@@ -148,7 +148,6 @@ def create_tasks(args):
# Assume that data coming from realtime sources are no more than 1 minute late
# XXX: Do I need to get 2x the interal of data?
# XXX: Do I need to do anything about per-site/inst pair or per-symbol?
AGGREGATE_FLUX_TASK_FORMAT
=
"""
option task = {{
...
...
@@ -158,7 +157,7 @@ option task = {{
}}
from(bucket:
"
{raw_bucket}
"
)
|> range(start: -
(
task.every
* 2)
)
|> range(start: -task.every)
|> filter(fn: (r) => r[
"
_measurement
"
] ==
"
metobs
"
)
|> aggregateWindow(every: {interval}, fn: mean)
|> set(key:
"
_measurement
"
, value:
"
metobs_{interval}
"
)
...
...
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
sign in
to comment