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

xgbod_example.py demo code execution generated strange warning messages #156

Closed
kdlin opened this issue Jan 8, 2020 · 1 comment
Closed

xgbod_example.py demo code execution generated strange warning messages #156

kdlin opened this issue Jan 8, 2020 · 1 comment

Comments

@kdlin
Copy link

@kdlin kdlin commented Jan 8, 2020

I ran the xgbod_example.py demo code, https://github.com/yzhao062/pyod/blob/master/examples/xgbod_example.py. The following warning messages were displayed.

/Users/dlin/opt/anaconda3/lib/python3.7/site-packages/pyod/models/base.py:349: UserWarning: y should not be presented in unsupervised learning.
"y should not be presented in unsupervised learning.")
/Users/dlin/opt/anaconda3/lib/python3.7/site-packages/sklearn/ensemble/iforest.py:247: FutureWarning: behaviour="old" is deprecated and will be removed in version 0.22. Please use behaviour="new", which makes the decision_function change to match other anomaly detection algorithm API.
FutureWarning)
/Users/dlin/opt/anaconda3/lib/python3.7/site-packages/sklearn/ensemble/iforest.py:247: FutureWarning: behaviour="old" is deprecated and will be removed in version 0.22. Please use behaviour="new", which makes the decision_function change to match other anomaly detection algorithm API.
FutureWarning)
/Users/dlin/opt/anaconda3/lib/python3.7/site-packages/sklearn/ensemble/iforest.py:247: FutureWarning: behaviour="old" is deprecated and will be removed in version 0.22. Please use behaviour="new", which makes the decision_function change to match other anomaly detection algorithm API.
FutureWarning)
/Users/dlin/opt/anaconda3/lib/python3.7/site-packages/sklearn/ensemble/iforest.py:247: FutureWarning: behaviour="old" is deprecated and will be removed in version 0.22. Please use behaviour="new", which makes the decision_function change to match other anomaly detection algorithm API.
FutureWarning)
/Users/dlin/opt/anaconda3/lib/python3.7/site-packages/sklearn/ensemble/iforest.py:247: FutureWarning: behaviour="old" is deprecated and will be removed in version 0.22. Please use behaviour="new", which makes the decision_function change to match other anomaly detection algorithm API.
FutureWarning)
/Users/dlin/opt/anaconda3/lib/python3.7/site-packages/sklearn/ensemble/iforest.py:247: FutureWarning: behaviour="old" is deprecated and will be removed in version 0.22. Please use behaviour="new", which makes the decision_function change to match other anomaly detection algorithm API.
FutureWarning)
/Users/dlin/opt/anaconda3/lib/python3.7/site-packages/sklearn/ensemble/iforest.py:247: FutureWarning: behaviour="old" is deprecated and will be removed in version 0.22. Please use behaviour="new", which makes the decision_function change to match other anomaly detection algorithm API.
FutureWarning)
/Users/dlin/opt/anaconda3/lib/python3.7/site-packages/sklearn/ensemble/iforest.py:247: FutureWarning: behaviour="old" is deprecated and will be removed in version 0.22. Please use behaviour="new", which makes the decision_function change to match other anomaly detection algorithm API.
FutureWarning)

Some of the issues include:

  1. It did not like the Y labels.
  2. Somehow iforest.py was called.
@yzhao062
Copy link
Owner

@yzhao062 yzhao062 commented Jan 15, 2020

Yes. This is expected. XGBOD is based on two parts: supervised xgboost model and unsupervised anomaly detection models. The latter does not need y; iforest is part of the unsupervised models.

what happens is we run a bunch of unsupervised models and use their outlier scores as the new features appended to the orignal feature space. Finally, xgboost is trained on the enhanced feature space.

@yzhao062 yzhao062 closed this Feb 19, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.