Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle scenario where dataset's last data point is complete and must not be ignored #183

Open
sachinkbansal opened this issue Oct 13, 2021 Discussed in #172 · 0 comments
Labels
anomalyDefinition enhancement New feature or request

Comments

@sachinkbansal
Copy link
Contributor

Discussed in #172

Originally posted by PhilippeDo October 8, 2021
I have now this error when I tried to use prophet

{"d2b9be2a-6d27-4e61-a577-3d99892e94e0": {"dimVal": null, "error": "{\"message\": \"single positional indexer is out-of-bounds\", \"stackTrace\": \"Traceback (most recent call last):\\n File \\\"/code/ops/tasks/anomalyDetection.py\\\", line 56, in anomalyService\\n result = detect(df, granularity, detectionRuleType, anomalyDef)\\n File \\\"/code/ops/tasks/anomalyDetection.py\\\", line 29, in detect\\n return prophetDetect(df, granularity)\\n File \\\"/code/ops/tasks/detectionTypes/prophet.py\\\", line 47, in prophetDetect\\n lastISO = df.iloc[-1][\\\"ds\\\"]\\n File \\\"/opt/venv/lib/python3.7/site-packages/pandas/core/indexing.py\\\", line 895, in __getitem__\\n return self._getitem_axis(maybe_callable, axis=axis)\\n File \\\"/opt/venv/lib/python3.7/site-packages/pandas/core/indexing.py\\\", line 1501, in _getitem_axis\\n self._validate_integer(key, axis)\\n File \\\"/opt/venv/lib/python3.7/site-packages/pandas/core/indexing.py\\\", line 1444, in _validate_integer\\n raise IndexError(\\\"single positional indexer is out-of-bounds\\\")\\nIndexError: single positional indexer is out-of-bounds\\n\"}", "success": false}}

I used the following in DATASET section

select DATE_FORMAT(date, '%Y-%m-%d %H') as Date,
pagelt from pageloadtime2

and then when I run, the dataset looks liks this. It is a minimal dataset withou dimension, with only a measure and a timestamp

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
anomalyDefinition enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants