GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

Issues (4082)

Orange/regression/svm.py (21 issues)

1
import sklearn.svm as skl_svm
0 ignored issues
show
The import sklearn.svm could not be resolved.

This can be caused by one of the following:

1. Missing Dependencies

This error could indicate a configuration issue of Pylint. Make sure that your libraries are available by adding the necessary commands.

# .scrutinizer.yml
before_commands:
    - sudo pip install abc # Python2
    - sudo pip3 install abc # Python3
Tip: We are currently not using virtualenv to run pylint, when installing your modules make sure to use the command for the correct version.

2. Missing __init__.py files

This error could also result from missing __init__.py files in your module folders. Make sure that you place one file in each sub-folder.

Loading history...
2
3
from Orange.regression import SklLearner
4
from Orange.preprocess import Normalize
5
6
__all__ = ["SVRLearner", "NuSVRLearner"]
7
8
svm_pps = SklLearner.preprocessors + [Normalize()]
9
10
11
class SVRLearner(SklLearner):
12
    __wraps__ = skl_svm.SVR
13
    name = 'svr'
14
    preprocessors = svm_pps
15
16
    def __init__(self, kernel='rbf', degree=3, gamma=0.0, coef0=0.0,
0 ignored issues
show
The argument gamma seems to be unused.
Loading history...
The argument coef0 seems to be unused.
Loading history...
The argument degree seems to be unused.
Loading history...
The argument kernel seems to be unused.
Loading history...
17
                 tol=0.001, C=1.0, epsilon=0.1, shrinking=True,
0 ignored issues
show
The argument C seems to be unused.
Loading history...
The argument shrinking seems to be unused.
Loading history...
The argument epsilon seems to be unused.
Loading history...
The argument tol seems to be unused.
Loading history...
18
                 cache_size=200, max_iter=-1, preprocessors=None):
0 ignored issues
show
The argument cache_size seems to be unused.
Loading history...
The argument max_iter seems to be unused.
Loading history...
19
        super().__init__(preprocessors=preprocessors)
20
        self.params = vars()
21
        self.supports_weights = True
22
23
24
class NuSVRLearner(SklLearner):
25
    __wraps__ = skl_svm.NuSVR
26
    name = 'nu svr'
27
    preprocessors = svm_pps
28
29
    def __init__(self, nu=0.5, C=1.0, kernel='rbf', degree=3, gamma=0.0,
0 ignored issues
show
The argument C seems to be unused.
Loading history...
The argument gamma seems to be unused.
Loading history...
The argument nu seems to be unused.
Loading history...
The argument degree seems to be unused.
Loading history...
The argument kernel seems to be unused.
Loading history...
30
                 coef0=0.0, shrinking=True, tol=0.001,
0 ignored issues
show
The argument shrinking seems to be unused.
Loading history...
The argument tol seems to be unused.
Loading history...
The argument coef0 seems to be unused.
Loading history...
31
                 cache_size=200, max_iter=-1, preprocessors=None):
0 ignored issues
show
The argument cache_size seems to be unused.
Loading history...
The argument max_iter seems to be unused.
Loading history...
32
        super().__init__(preprocessors=preprocessors)
33
        self.params = vars()
34
        self.supports_weights = True
35
36
37
if __name__ == '__main__':
38
    import Orange
39
40
    data = Orange.data.Table('housing')
41
    learners = [SVRLearner(), NuSVRLearner()]
42
    res = Orange.evaluation.CrossValidation(data, learners)
43
    for l, ca in zip(learners, Orange.evaluation.RMSE(res)):
44
        print("learner: {}\nRMSE: {}\n".format(l, ca))
45
46