Skip to content

Issue 180 improve find anomalies primitive#181

Merged
csala merged 5 commits intoMLBazaar:masterfrom
AlexanderGeiger:issue-180-improve-find_anomalies-primitive
Jul 8, 2019
Merged

Issue 180 improve find anomalies primitive#181
csala merged 5 commits intoMLBazaar:masterfrom
AlexanderGeiger:issue-180-improve-find_anomalies-primitive

Conversation

@AlexanderGeiger
Copy link
Copy Markdown
Contributor

Addresses the changes mentioned in #180 to improve the custom.timeseries_anomalies.find_anomalies primitive

  • Add optional threshold for unusually low errors
  • Add possibility to use overlapping thresholds
  • Once an anomalous region is found, increase the region by a predefined size to make the pruning afterwards more stable
  • Fix the calculation of anomaly score to work with consecutive and overlapping sequences

@AlexanderGeiger
Copy link
Copy Markdown
Contributor Author

AlexanderGeiger commented Jul 2, 2019

Just noticed that Travis uses tests/custom/test_timeseries_anomalies.py to check correctness of the code. However, I changed some of the inputs/outputs of the functions inside the Primitive and now the previously designed test-cases don't match anymore.
I will update the test file as well in order to cover the new cases.

@csala
Copy link
Copy Markdown
Contributor

csala commented Jul 8, 2019

Hi @AlexanderGeiger
All looks good except one detail: the dosctring format.

Your current format is apparently valid, but it doesn't render right on Sphinx when the docs are generated.

Can you change it to this one instead?

Some long text that needs to be wrapped in more than one line because
it is too long to be in a single line.

Args:
    variable_name (variable_type):
        Variable description.
    variable_name (variable_type):
        Variable description that needs to be wrapped in more than one line
        because it is too long to be in a single line.
    variable_name (variable_type):
        Optional. Variable description (including default value).

Returns:
    output_type:
        Output description that needs to be wrapped in more than one line
        because it is too long to be in a single line.

The key points are:

  • Variable descriptions should always be in a separated line with an extra level of indentation, even if they are short.
  • If an Arg is optional, it should be said in the description, not inside the parenthesis, which is rendered as strictly the "argument type".
  • The return types should be without parenthesis.
  • When wrapping a long line in more than one, there should be no additional indentation.

@csala csala merged commit d8550c0 into MLBazaar:master Jul 8, 2019
@AlexanderGeiger AlexanderGeiger deleted the issue-180-improve-find_anomalies-primitive branch July 8, 2019 18:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants