scieee AI-readable full text Open interactive document viewer

Instance Reduction for One-Class Classification

Krawczyk, Bartosz,Triguero, Isaac,García López, Salvador,Wozniak, Michal,Herrera Triguero, Francisco

Abstract

Polish National Science Center UMO-2015/19/B/ST6/01597

Full text

Knowledge and Information Systems manuscript No. (will be inserted by the editor) Instance Reduction for One-Class Classification Bartosz Krawczyk ·Isaac Triguero · Salvador Garc´ıa ·Micha l Wo´zniak · Francisco Herrera Received: date / Accepted: date Abstract Instance reduction techniques are data preprocessing methods originally developed to enhance the nearest neighbor rule for standard classification. They reduce the training data by selecting or generating representative examples of a given problem. These algorithms have been designed and widely analyzed in multi-class problems providing very competitive results. However, this issue was rarely addressed in the context of one-class classification. In Micha l Wo´zniak was supported by the Polish National Science Center under the grant no. DEC-2013/09/B/ST6/02264. Salvador Garc´ıa and Francisco Herrera were supported by the Spanish National Research Project TIN2014-57251-P and the Andalusian Research Plan P11-TIC-7765. Bartosz Krawczyk Department of Computer Science Virginia Commonwealth University, Richmond, VA, USA E-mail: [email protected] Isaac Triguero School of Computer Science Automated Scheduling, Optimisation and Planning (ASAP) Group University of Nottingham, Nottingham, UK E-mail: [email protected] Salvador Garc´ıa Department of Computer Science and Artificial Intelligence University of Granada, CITIC-UGR, Granada, Spain E-mail: salv[email protected] Micha l Wo´zniak Department of Systems and Computer Networks Wroc law University of Technology, Wroc law, Poland E-mail: [email protected] Francisco Herrera Department of Computer Science and Artificial Intelligence University of Granada, CITIC-UGR, Granada, Spain Faculty of Computing and Information Technology King Abdulaziz University, Jeddah, Saudi Arabia E-mail: [email protected] 2 Bartosz Krawczyk et al. this specific domain a reduction of the training set may not only decrease the classification time and classifier’s complexity, but also allows us to handle internal noisy data and simplify the data description boundary. We propose two methods for achieving this goal. The first one is a flexible framework that adjusts any instance reduction method to one-class scenario by introduction of meaningful artificial outliers. The second one is a novel modification of evolutionary instance reduction technique that is based on differential evolution and uses consistency measure for model evaluation in filter or wrapper modes. It is a powerful native one-class solution that does not require an access to counterexamples. Both of the proposed algorithms can be applied to any type of one-class classifier. On the basis of extensive computational experiments, we show that the proposed methods are highly efficient techniques to reduce the complexity and improve the classification performance in one-class scenarios. Keywords machine learning ·one-class classification ·instance reduction · training set selection ·evolutionary computing 1 Introduction Data preprocessing is an essential step within the machine learning process [41,21,42]. This kind of techniques aims to simplify the training data by removing noisy and redundant data, so that, machine learning algorithms can be later applied faster and more accurately. In the literature, we can find techniques that focus on the attribute space and others that take into consideration the instance space. From the perspective of attributes, the most well-known data reduction processes are feature selection, feature weighting and feature extraction [4,7,30,44]. Taking into consideration the instance space, we may highlight instance reduction (InR) methods [17,51]. Instance reduction models search for a reduced set of instances that represents the original training data [14]. These techniques could be grouped into instance selection [17] and instance generation [51] models. The former only selects a subset of instances from the training dataset [35]. The latter may select or generate new artificial instances. Thus, InR can be seen as a combinatorial and optimization problem. Most of the existing InR models have been designed to improve the classification capabilities of the nearest neighbor rule [10], and they are denoted as prototype reduction methods. Among the existing InR methods, evolutionary algorithms have been stressed as the most promising ones [53]. The issue of data preprocessing was so far rarely addressed in the context of one-class classification (OCC) [28]. This branch of machine learning focuses on scenarios in which we do not have access to counterexamples during the training phase. Therefore, a classifier must be trained using objects coming only from a single class, thus creating a data description. Here the quality of training objects has even greater influence on the classification stage than in binary and multi-class problems, as we need to capture such properties of the target class that will allow us to discriminate against unknown outliers. Noisy Instance Reduction for One-Class Classification 3 or rare objects can undermine the performance of one-class classifier, leading to overestimated class boundary [36]. At the same time, training OCC models on large-scale and big data may be of high computational complexity, which will hinder the learning process. This is especially vivid in cases of massive, streaming or complex datasets [33]. Therefore, there is a need for dedicated InR methods. Our preliminary works on applying InR in OCC [32] showed the potential of this approach. However, this study was limited only to the nearest neighbor data description model and two simple instance reduction techniques. Additionally, we confronted issues with some datasets in which some methods did not provide enough instances to perform the classification step. Therefore, we concluded that there is a need to develop instance reduction methods that can work with any one-class model and are natively tailored to the specific nature of learning in the absence of counterexamples. In this work, we propose to tackle the issue of InR for OCC from two different perspectives and propose flexible methods that can be used by any one-class classifier. Our first proposal stems from the intuitive extension of existing InR methods to learning in the absence of counterexamples. We introduce an universal framework for adapting any InR technique to OCC by artificial counterexamples generation and overlapping data cleaning. This way one may transform a given one-class problem into a binary one by creating outliers and then apply any selected InR technique. Generating artificial counterexamples have been used so far in the process of training one-class classifiers [26], but not during the one-class preprocessing phase. This approach could be viewed as a datalevel solution, as we modify our training data to allow unaltered usage of any InR algorithm from the literature. The second proposal is a specific approach tailored to the nature of oneclass classification. We introduce a novel modification of evolutionary InR technique that is based on differential evolution [15], and more concretely on a memetic algorithm named SFLSDE (Scale Factor Local Search Differential Evolution) [39]. By using a fully unsupervised consistency measure for evaluating set of instances during each iteration we lift the requirement for counterexamples during the reduction phase. Thus, our second proposal is a pure one-class algorithm. We present filter and wrapper modes for our method. This allows user to choose between reduced complexity and a more general solution or a more costly search procedure in order to find a set of instances better fitting the specific one-class learner. This approach could be viewed as an algorithm-level solution, as we modify a specific InR approach to use a criterion suitable for OCC, while leaving our data unaltered. We present a family of data-level and algorithm-level InR methods for OCC and validate their usefulness and impact on training set reduction, classification accuracy and recognition time on the basis of thorough computational experiments. Such a comparison allows us to gain an insight into how we can reduce the size of the training set in the absence of counterexamples, while maintaining or even improving the obtained predictive performance. 4 Bartosz Krawczyk et al. The rest of the manuscript is organized as follows. Next section gives necessary background on OCC and InR. Section 3 discusses the importance of InR in OCC, while Section 4 describe in detail the proposed methodologies. Section 5 presents the evaluation of examined algorithms in a carefully designed experimental study, while final section concludes the paper. 2 Related Works This section provides the necessary background for the remainder of the paper. 2.1 One-Class Classification OCC works under the assumption that during the classifier training stage objects originating only from a single class are available [28,38]. We name this specific class as the target class (concept) and denote it as ωT. The aim of OCC is to derive a decision boundary enclosing all available (or relevant) training objects from ωT. Thus, we achieve a data (concept) description. As the training procedure is carried out with the usage of only objects from a given class, we may refer to OCC as learning in the absence of counterexamples. In OCC scenario, during the classification phase, new objects may appear. They may be new instances from the target class or come from previously unknown distribution(s) that are outside of ωT. Such objects must be rejected by an one-class classifier, as they may be potentially undesirable, harmful or dangerous. We name them as outliers and denote them by ωO. A proper OCC method must display good generalization properties in order not to be overfitted on ωT, and good discrimination abilities to achieve a high rejection rate on ωO. While this taks may seem as quite similar to binary classification (having positive and negative classes), the primary difference lies in the training procedure of a classifier. In the standard binary problems we may expect objects from the other classes to predominantly come from one direction (the distribution of the given class). In OCC the target class should be separated from all the possible outliers, without any knowledge where does outliers may appear. This leads to a need for the decision boundary to be estimated in all directions in the feature space around the target class. One may distinguish four main families of OCC classifiers present in the relevant literature: – Density-based methods aim at capturing a distribution of the target class. During prediction phase, a new object is then compared with the estimated distribution and a decision is made on the basis of its resemblance. This approach suffers from a significant limitation, as it requires a high number of available objects from the target class and assumes a flexible density model [45]. – Reconstruction-based methods are rooted in clustering and data modeling. They aim at capturing the structure of the target class and during Instance Reduction for One-Class Classification 5 prediction phase check if new instances will fit into these structures. If the similarity level is below a given threshold, the new instance is labeled as outlier. [46]. – Boundary-based methods concentrate on estimating only the enclosing boundary for the target class, assuming that such a boundary will be a sufficient descriptor [3,48]. Thy try to find the optimal size of the volume enclosing the given training objects, as one that is too small can lead to an overtrained model, while one that is too big may lead to an extensive acceptance of outliers into the target class. – Ensemble-based methods [43,58] propose a more flexible data description by utilizing several base classifiers. By combining mutually complementary learners one may achieve a better coverage of the target class, especially when dealing with complex distributions [11]. This requires a proper exploitation of competence areas of each base classifier, like unique model properties (for heterogeneous ensembles [40]), or diversified inputs (for homogeneous ensembles [55]). Additionally, often a classifier selection / ensemble pruning step must be conducted to chose the most complementary and effective learners from the available pool [31]. 2.2 Instance Reduction in Standard Classification This section provides a formal definition about InR techniques and its current trends. A formal notation of the InR problem is as follows: Let T R be a training dataset and T S a test set, they are formed by a determined number nand tof samples, respectively. Each sample xmis a tuple (x1 i, x2 i, ..., xd i, ωi), where, xp iis the value of the p-th feature of the i-th sample. This sample belongs to a class ωi. For the T R set the class ωiis known, while it is unknown for T S. InR techniques aim to reduce the available training set T R ={(x1, ω1),· · · ,(xn, ωn)} of labeled instances to a smaller set of instances RS ={x∗ 1, x∗ 2,· · · , x∗ r}, with r < n and each x∗ ieither drawn from T R or artificially constructed. The set RS is later used to train the classifier, rather than the entire set T R, to eventually classify the test set T S. Thus, the instances of RS should be efficiently computed to represent the distributions of the classes and to discern well when they are used to classify the training objects. Most of the existing InR models have been designed and combined with the nearest neighbor classifier [10]. As a lazy learning algorithm [1] it classifies unseen instances to the class to which the majority of their knearest neighbors in the training set belongs based on a certain distance or similarity measure [9]. Thus, the reduction of the training set allows to alleviate the low computational efficiency and high storage requirement of this classifier. Many works extended the application of instance reduction techniques to other classifiers [8] and different domains, such as imbalanced classification [20]. High computational complexity of InR, especially in case of processing large-scale 6 Bartosz Krawczyk et al. datasets, inspired the development of efficient distributed architectures for this task [13,54]. As we stated before, InR is usually divided into those approaches that are limited to select instances from T R, known as instance selection (InS) [17], and those that may generate artificial examples if needed, named as instance generation (InG) [51]. Both strategies have been deeply studied in the literature. Most of the recent proposals are based on evolutionary algorithms to select [16] or generate [53,27] an appropriate RS. 3 The Role of Instance Reduction in One-Class Classification In OCC the quality of training data has a direct influence on the estimated data description. If we deal with well-sampled and representative set of examples, then we can assume that it will reflect the true target class distribution. This will allow us to train a classifier displaying at the same time good generalization over the target concept and high discriminative power against outliers, regardless of their nature. This is however an idealized scenario. In practice we often deal with uncertain or contaminated training sets in OCC [12]. This means that some objects can be influenced by feature or class label noise, thus offering misleading information regarding the nature of the target concept. When a one-class classifier is being trained on such objects it will output an overestimated decision boundary that will lead to increased acceptance of outliers during the prediction phase. Therefore, to improve the one-class classifier performance such objects should be removed beforehand [37]. Some of training objects may be redundant, not carrying any additional useful information for creating an effective data description. This is especially common in large-scale or big data, where abundance of training examples does not directly translate onto their usefulness. Presence of such objects significantly increase the training and testing times of one-class classifiers. A good example of this can be seen during training one-class methods based on Support Vector Machines [48]. Here one is interested only in objects that have high potential of becoming future support vectors [59]. Thus, reducing the number of potential candidates will speed-up the training procedure. One must also be aware of the possible negative results of InR in OCC. Firstly, InR methods are unadvised for density-based one-class classifiers. This family of algorithms requires a large sample of the target class in order to properly estimate its density in the feature space. Hence, reducing the size of the training set will negatively impact the quality of the estimation procedure. From the point of view of any one-class classifier, preserving the original structure of the target class is of uttermost importance. When the training set is subject to a significant level of reduction, the probability of one-class classifier overfitting to a small target concept increases. This will in turn lead to deterioration of generalization capabilities. One cannot assume that only borderline objects within the target concept are important, as outliers may also Instance Reduction for One-Class Classification 7 overlap with the target concept. Therefore, it is highly important to maintain the original object structure, concentrating on removing only redundant or noisy cases. Such a situation is depicted in Figure 1. Finally, as in standard classification tasks, InR is a trade-off between spending additional computational effort for training set reduction versus achieving a speed-up during the classification phase. As we assume that the classifier, once trained, will be extensively used for continuous decision making, thus improving the classification speed is the priority for us. (a) Full training set. (b) Incorrectly reduced instances. (c) Correctly reduced instances. Fig. 1: Examples of instance reduction in OCC. Figure (a) depicts an one-class classifier trained on complete set of target class objects. Figure (b) presents an one-class classifier trained on incorrectly reduced set of objects. Here vital objects both within and on the borders of target concept were removed, thus leading to overfitted data description. Figure (c) shows a one-class classifier trained on a reduced set of instances that preserves the characteristics of the original training set. 8 Bartosz Krawczyk et al. Instance Reduction for OCC has so far been rarely addressed in the literature. Angiulli [2] introduced a Prototype-based Domain Description rule that is similar to standard nearest neighbor-based one-class classifier but exploits only a selected subset of the training set. Cabral and de Oliviera [6] proposed to analyze every limit of all the feature dimensions to find the true border which describes the normal class. Their method simulates the novelty class by creating artificial prototypes outside the normal description and then uses minimal-distance classification. Hadjadji and Chibani [25] described a special model of Auto-Associative Neural Network that can select samples for its own training in each iteration. This approach is not a strict instance reduction method as it aims only at removing noisy examples. One must notice that these literature proposals are specific only to a given classifier (neighborbased or neural network). Therefore, there is a lack of universal InR methods for OCC that could be used with any type of one-class classifier. 4 Applying Instance Reduction to One-Class Classification In this paper we propose two approaches for applying InR for OCC problems: –A scheme for adapting existing InR solutions to one-class scenarios. –A new method based on evolutionary InR with one-class evaluation criterion. Both of these solutions will be described in detail in the following sections. 4.1 Adapting Existing Instance Reduction Methods to One-Class Classification The first proposed approach is a general framework for adapting any existing InR method to OCC problems. As most of InR methods were designed for binary problems, we need to have access to examples from both classes in order to use them. As in real-life OCC scenarios outliers are not available during the training phase, one needs to find another way to have access to them. We propose to generate artificial counterexamples and use them to transform the input one-class problem into a binary one for the sake of InR procedure. This is a data-level approach that modifies the supplied training set in order to make it applicable to any InR methods, without modifying them in any way. We will show now how to generate meaningful outliers when only objects from the target class are available. We assume that outliers are distributed uniformly around the target concept. For this, we can use a d-dimensional Gaussian distribution, following these steps [47]: 1. Generate a set of new outlier objects OS from a specified Gaussian distribution with zero mean and unit variance (making outliers appear all over the decision space similar to white noise): OS ∼ N(0,1).(1) Instance Reduction for One-Class Classification 9 2. For each artificial object calculate its squared Euclidean distance from the target concept origin. Please note that this squared distance r2is distributed as χ2possessing ddegrees of freedom. This allows to determine the overlap ratio between outliers and target concept. r2=∥x∥2.(2) 3. Apply the cumulative distribution of χ2 d(denoted here as χ2 d) in order to transform the r2distribution into an uniform distribution ρ2∈[0; 1], which would lead to determining the new outliers distribution: ρ2=χ2 d(r2) = χ2 d(∥x∥2).(3) 4. Rescale the obtained distribution ρ2using r′= (ρ2)2 dthat r′is distributed as r′∼rd, where r∈[0; 1]: r′= (ρ2)2 d=(χ2 d(∥x∥2)) 2 d.(4) 5. Apply rescaling to all of artificially generated objects using obtained factor r′in order to adapt them to the given decision space: x′=r′ ∥x∥x. (5) These steps allow us to generate a set of artificial outliers uniformly in a ddimensional hypersphere. They will be located in all directions surrounding the target class. This way we are able to transform the original one-class problem into a binary setting and apply any InR algorithm on it. However, this outlier generation method has a significant drawback. There is a high probability that generated artificial outliers will highly overlap with the real target class objects. This can lead to improper selection of prototypes. We are interested in retaining examples that will maintain the best data description. Having outliers within the target class during InR procedure will lead to improper estimation of such potential boundary-building objects. Thus we extend this artificial object generation procedure by a data cleaning step. For this task we propose to apply Tomek links method [50]. Tomek link is a pair of closest neighbors from opposite classes. Let us assume that we have two objects (xi,xj), where xi∈ωTand xj∈ωOand d(xi, xj) is the distance between these two examples. Such a pair is called a Tomek link if there are no examples xkin the dataset that satisfy d(xi, xk)< d(xi, xj) or d(xj, xk)< d(xi, xj). Therefore if two instances form a Tomek link then one of them is a noisy / overlapping sample or both are located on class borders. One may use this as data cleaning method. Original attempts at this task removed objects from both classes. In the proposed approach we clean only artificial outliers, without affecting the original target class. This leads to removing generated overlapping outliers and obtaining a much better problem representation for InR method. 16 Bartosz Krawczyk et al. BAC (TP,FP,TN,FN) = 1 2(TP TP + FN +TN TN + FP). –Additionally, we check the reduction rate metric, which measures the reduction of storage requirements achieved by a InR algorithm: ReductionRate = 1 −size(RS)/size(T S). –We use a 10 fold cross validation for training and testing. –For assessing the ranks of classifiers over all examined benchmarks, we use a Friedman ranking test. It checks if the assigned ranks are significantly different from assigning to each classifier an average rank. –We use the Finner post-hoc test for an 1 x ncomparison. It adjusts the value of αin a step-down manner. We select it due to its high power [18]. Additionally, we examine obtained p-values in order to check how different given two algorithms are. –We use the Shaffer post-hoc test to find out which of the tested classifiers are distinctive among an nxncomparison. It is a modification of popular Holm’s procedure that provides increase in power at the cost of greater complexity of the testing procedure. We have selected it due to its effectiveness in multiple comparison tasks [19]. Additionally, we examine obtained p-values in order to check how different given two algorithms are. –We fix the significance level α= 0.05 for all comparisons. 5.4 General Comments on Obtained Results Firstly let us compare the two proposed approaches: based on adapting existing methods to OCC and using a consistency-based InR. Regardless of the classifier used, both BAC and statistical tests results clearly point out to superiority of the OC-SFLSDE solution. This can be explained by several factors. The adaptation scheme transforms an original one-class problem into a binary one, assuming a uniform distribution of outliers and generating artificial counterexamples. Despite using data cleaning procedures this approach may potentially lead to ill-defined decision boundaries that may mislead the instance reduction algorithm. One must remember that examined methods use nearest neighbor approach for evaluating the reduced set of instances. There however may not be a direct translation between decision boundaries estimated by binary nearest neighbor and actual shape of data description over the target class. Finally, by transforming a one-class task into a binary problem we overlook some difficulties embedded in the nature of OCC, such as overestimated decision boundaries, empty areas within the data description that lead to classifier’s incompetence, or internal noisy samples. These factors may result in a drop of the final accuracy observed for all types of one-class classifiers. The reduction rates displayed by each examined InR algorithm are given in Table 3. Instance Reduction for One-Class Classification 17 Table 3: Reduction rates [%] obtained by different examined instance reduction approaches. Dataset ENN DROP3 ICPL IPADE SSMASFLSDE OCC-filter OCCOCC- OCC wrapper-NN wrapper-MST -wrapper-SVDD Climate 37.04 94.07 88.89 98.89 95.19 81.67 81.67 80.58 80.89 Contraceptive 38.86 74.18 89.01 99.46 97.01 80.25 80.25 78.94 47.28 Credit 20.00 88.99 90.33 99.13 99.42 84.89 84.89 83.92 81.28 Fertility 34.00 94.00 90.00 96.00 94.00 88.73 88.73 88.12 86.73 Habermans 41.18 86.93 87.59 98.04 98.69 85.28 85.28 82.71 83.72 Hepatitis 71.43 71.43 79.23 93.51 92.21 73.08 73.08 70.86 71.24 Hill-Valley 53.80 68.98 71.62 99.34 96.70 75.29 75.29 74.09 72.06 Indian 39.18 78.35 81.45 98.97 98.63 75.82 75.82 74.51 72.88 Mammographic 25.21 82.92 90.00 99.38 98.54 81.03 81.03 78.54 77.90 Musk 74.24 97.73 98.31 99.79 99.36 92.61 92.61 91.30 91.82 Ozone 20.27 97.87 97.85 99.68 95.11 92.30 92.30 88.58 85.60 Parkinsons 36.73 80.61 80.62 94.90 94.90 78.27 78.27 76.37 75.22 Pima 30.99 79.43 80.99 98.70 96.61 73.68 73.68 70.49 68.79 Sonar 31.73 73.08 75.97 97.12 91.35 69.42 69.42 68.76 68.03 Statlog 31.11 89.63 85.93 96.30 96.30 73.12 73.12 72.26 73.12 Wisconsin 15.80 97.70 97.13 99.14 99.14 54.83 54.83 52.64 53.14 MiniBooNE 19.37 93.54 94.19 97.54 97.36 85.49 85.49 82.71 81.09 Twitter Buzz in Social Media 27.43 95.28 97.03 99.01 99.01 87.92 87.92 83.99 80.35 Skin Segmentation 31.54 91.59 91.59 94.12 97.35 81.46 81.46 81.20 80.93 Census-Income 41.54 97.42 95.89 99.11 98.89 79.82 79.82 73.10 71.69 KDD Cup 1999 63.20 89.19 90.86 93.02 93.02 83.19 83.19 82.28 81.93 To cope with these issues OC-SFLSDE (in both wrapper and filter versions) uses a consistency measure which does not require counterexamples. It allows to evaluate the complexity of classifier and how well it captures the target concept without actually being overfitted on training data. Experimental results show that this solution is closer to the nature of one-class problems and offers excellent performance both in filter and wrapper modes. Interestingly OC-SFLSDE is characterized by a slightly lower reduction rates than other methods. This shows that OCC problems cannot be too strongly reduced and a well-represented training set is crucial for proper data description. Additionally, OC-SFLSDE in some cases allows to improve the classification accuracy with respect to the original training set. This shows that by using the proposed hybrid consistency-based solution we are able to filter uncertain or noisy objects that may harm the one-class classifier being trained. While some of the binary methods adopted to OCC offer higher reduction rates and thus increased classification speed-up, OC-SFLSDE returns the best trade-off in terms of classification efficacy and time. 5.5 Results for One-Class Nearest Neighbor The results obtained by examined InR algorithms with OCNN are presented in Table 4, while the outcomes of post-hoc statistical test are presented in Table 5. OCNN was the only classifier that displayed good performance with methods other than the proposed filter approach. For some of datasets ENN and SSMASFLSDE approaches augmented with artificial data were able to deliver satisfactory accuracy as well. This can be explained by the minimal-distance classification approach, similar in both binary and one-class scenarios. Hence 18 Bartosz Krawczyk et al. Table 4: BAC [%] results for different examined instance reduction methods with One-Class Nearest Neighbor classifier. Please note that for this base classifier both filter and wrapper methods are identical, therefore we present results for only one of them. Dataset No reduction ENN DROP3 ICPL IPADE SSMASFLSDE OCC-filter Climate 75.54 75.24 74.68 72.98 70.74 75.24 78.23 Contraceptive 89.76 89.03 88.63 87.11 85.93 89.12 90.76 Credit 79.63 79.38 78.75 76.90 75.69 76.84 79.38 Fertility 86.89 86.03 85.64 86.03 85.9 86.04 87.89 Haberman 70.98 68.78 68.54 68.37 62.90 68.90 70.98 Hepatitis 67.43 67.22 67.01 64.37 61.35 66.31 67.00 Hill-Valley 86.94 86.81 86.67 86.12 85.15 86.52 86.94 Indian 93.41 93.41 93.12 92.53 88.79 92.80 93.41 Mammographic 87.37 86.21 86.92 85.11 84.06 86.80 87.04 Musk (V2) 71.38 70.79 70.54 69.79 68.94 70.50 71.27 Ozone 78.49 76.75 77.32 75.93 75.93 77.83 77.96 Parkinsons 67.39 67.04 66.78 67.02 67.12 67.14 67.39 Pima 90.52 89.78 88.43 88.75 86.42 89.78 89.78 Sonar 82.66 81.66 81.49 78.34 77.83 81.66 82.30 Statlog 68.06 66.18 66.82 64.32 62.11 67.06 70.02 Wisconsin 91.36 90.89 90.15 89.74 88.12 90.89 93.03 MiniBooNE 72.89 65.35 63.72 60.04 67.83 68.22 76.44 Twitter Buzz in Social Media 87.43 82.21 80.10 76.39 82.78 83.19 88.72 Skin Segmentation 92.91 84.90 85.18 81.99 84.78 86.11 93.27 Census-Income 71.90 59.85 60.14 57.72 63.21 63.99 70.01 KDD Cup 1999 72.88 65.31 63.20 58.84 64.25 66.96 74.06 Avg. rank 2.69 3.69 4.81 5.72 2.84 1.25 Table 5: Finner test for comparison between the proposed filter instance reduction and reference methods for One-Class Nearest Neighbor classifier. Symbol ’=’ stands for classifiers without significant differences, ’>’ for situation in which OCC f method is superior and ’<’ for vice versa. hypothesis p-value OCC-filter vs no reduction =0.197458 OCC-filter vs ENN >0.026588 OCC-filter vs DROP3 >0.000174 OCC-filter vs ICPL >0.000000 OCC-filter vs IPADE >0.000000 OCC-filter vs SSMASFLSDE >0.013132 the evaluation of standard instance selection methods based on two-class nearest neighbor was able to locale useful examples for being preserved in the reduced training set. However, our filter-based solution delivered the best performance in 20 datasets. In this scenario filter and wrapper modes were equivalent due to the base classifier used. Statistical testing confirms the superiority of this approach to reference ones. Additionally, it shows that there are no statistically significant differences between this instance reduction method and classifier trained on the full dataset. Instance Reduction for One-Class Classification 19 5.6 Results for Minimum Spanning Tree Data Description The results obtained by examined InR algorithms with MST are presented in Table 6, while the outcomes of post-hoc statistical test are presented in Table 7. Table 6: BAC [%] results for different examined instance reduction methods with Minimum Spanning Tree Data Description classifier. Dataset No reduction ENN DROP3 ICPL IPADE SSMASFLSDE OCC-filter OCC- wrapper-MST Climate 78.36 77.18 60.12 65.53 64.89 68.54 77.45 79.45 Contraceptive 87.75 86.56 76.32 79.32 80.17 80.22 86.89 87.75 Credit 82.45 81.36 62.95 69.75 68.65 75.28 81.64 83.53 Fertility 87.46 86.89 80.41 82.41 82.24 77.49 87.46 87.46 Haberman 70.13 68.53 53.58 57.74 58.05 61.93 69.15 70.02 Hepatitis 71.38 70.36 59.37 66.12 64.74 64.50 69.36 71.16 Hill-Valley 84.23 83.45 76.96 77.43 78.32 77.94 84.23 85.41 Indian 94.14 93.72 78.24 78.94 79.27 84.39 94.51 94.51 Mammographic 85.89 85.02 70.53 77.23 75.51 81.05 85.11 85.11 Musk (V2) 73.76 72.22 55.85 58.34 57.84 62.63 72.88 73.41 Ozone 77.97 77.13 69.93 71.52 72.22 76.86 78.48 80.39 Parkinsons 71.84 71.08 58.47 59.32 60.78 60.94 72.46 72.46 Pima 92.65 91.94 71.04 77.34 75.88 81.56 92.07 92.43 Sonar 81.87 80.83 63.68 67.80 69.97 73.74 81.87 81.87 Statlog 67.27 64.89 50.02 54.53 51.68 61.89 68.37 70.16 Wisconsin 93.53 93.21 84.36 87.27 87.09 90.11 93.21 93.53 MiniBooNE 74.59 62.18 60.94 58.59 63.93 65.42 74.81 77.58 Twitter Buzz in Social Media 88.92 80.05 77.92 74.11 80.22 80.44 85.72 90.01 Skin Segmentation 93.44 81.15 82.03 77.22 81.46 82.02 89.17 94.58 Census-Income 72.55 58.64 59.23 55.97 61.89 62.36 70.99 70.99 KDD Cup 1999 72.53 61.18 59.23 54.38 62.05 64.91 72.55 74.03 Avg. rank 2.91 6.94 5.31 5.37 4.37 1.94 1.16 Table 7: Shaffer test for comparison between the proposed filter and wrapper instance reduction methods and reference approaches for Minimum Spanning Tree classifier. Symbol ’=’ stands for classifiers without significant differences, ’>’ for situation in which the first analyzed method is superior and ’<’ for vice versa. hypothesis p-value hypothesis p-value OCC-filter vs no reduction = 0.614851 OCC-wrapper vs no reduction >0.041704 OCC-filter vs ENN = 0.257327 OCC-wrapper vs ENN >0.019860 OCC-filter vs DROP3 >0.000522 OCC-wrapper vs DROP3 >0.000000 OCC-filter vs ICPL >0.000000 OCC-wrapper vs ICPL >0.000000 OCC-filter vs IPADE >0.000000 OCC-wrapper vs IPADE >0.000000 OCC-filter vs SSMASFLSDE >0.00709 OCC-wrapper vs SSMASFLSDE >0.000016 OCC-filter vs OCC-wrapper <0.044270 MST works significantly better with OC-SFLSDE than with remaining methods. Here we are able to analyze two operating modes: as a filter and as a wrapper. In the first case we can see that obtained results are statistically not 20 Bartosz Krawczyk et al. worse than when using full training set. This shows that despite the lack of knowledge which classifier will be used the filter mode can still deliver meaningfully selected training samples. However, Shaffer test pointed that there are no significant differences between this filter method and ENN approach using artificial counterexamples. For the wrapper mode situation changes in favor of the hybrid evolutionary approach. Here we are able not only to significantly outperform all other methods (including filter version), but we also get improved results in comparison to using the entire training set. Using wrapper solution allows us to evaluate the usefulness of training samples for the minimum spanning tree construction and eliminate redundant, similar or noisy samples which contributes to decreased complexity and improved accuracy. Additional cost connected to training MST at each iteration pays off in the improved final model. When comparing classification times we can see that both filter and wrapper solutions achieve similar reduction rates and response times of the trained classifier. 5.7 Results for Support Vector Data Description The results obtained by examined InR algorithms with SVDD are presented in Table 8, while the outcomes of post-hoc statistical test are presented in Table 9. Table 8: BAC [%] results for different examined instance reduction methods with Support Vector Data Description classifier. –stands for situation in which the number of instances after reduction was too small to efficiently train SVDD classifier. Dataset No reduction ENN DROP3 ICPL IPADE SSMASFLSDE OCC-filter OCC- wrapper-SVDD Climate 81.73 81.73 –72.84 – – 82.38 84.51 Contraceptive 85.38 84.79 79.24 74.62 –65.27 84.90 85.38 Credit 83.90 82.58 78.46 63.56 – – 83.72 84.43 Fertility 82.61 79.71 74.07 – – – 81.12 81.94 Haberman 72.98 71.66 69.31 59.36 – – 71.35 72.56 Hepatitis 70.14 67.48 62.98 63.51 – – 69.54 70.00 Hill-Valley 77.36 75.38 70.93 71.68 – – 76.30 77.04 Indian 93.62 92.54 86.08 82.90 – – 92.98 93.18 Mammographic 87.92 87.44 83.11 59.98 – – 87.44 89.03 Musk (V2) 71.21 70.03 64.82 67.82 48.29 58.58 70.52 71.06 Ozone 75.28 74.00 69.05 54.29 44.89 54.48 76.38 77.81 Parkinsons 74.02 71.33 66.43 62.74 – – 72.35 73.60 Pima 93.26 91.27 80.27 82.73 –51.57 92.18 93.26 Sonar 79.53 78.18 67.98 71.04 – – 79.53 81.13 Statlog 69.32 69.90 –56.68 – – 69.90 69.90 Wisconsin 94.65 94.65 – – – – 94.65 94.65 MiniBooNE 74.23 55.77 54.25 44.46 54.38 57.02 70.05 76.93 Twitter Buzz in Social Media 89.41 69.87 68.42 59.93 62.17 63.03 83.98 91.64 Skin Segmentation 93.72 68.91 70.01 54.81 64.27 67.72 90.02 95.03 Census-Income 76.48 42.20 41.81 39.97 38.55 39.06 69.94 79.11 KDD Cup 1999 73.87 53.99 51.95 46.63 48.63 51.89 72.16 75.86 Avg. rank 2.78 4.66 4.72 6.47 6.16 2.09 1.12 Instance Reduction for One-Class Classification 21 Table 9: Shaffer test for comparison between the proposed filter and wrapper instance reduction methods and reference approaches for Support Vector Data Description classifier. Symbol ’=’ stands for classifiers without significant differences, ’>’ for situation in which the first analyzed method is superior and ’<’ for vice versa. hypothesis p-value hypothesis p-value OCC-filter vs no reduction = 0.162701 OCC-wrapper vs no reduction >0.042915 OCC-filter vs ENN = 0.174658 OCC-wrapper vs ENN >0.027993 OCC-filter vs DROP3 >0.000000 OCC-wrapper vs DROP3 >0.000000 OCC-filter vs ICPL >0.000003 OCC-wrapper vs ICPL >0.000001 OCC-filter vs IPADE >0.000003 OCC-wrapper vs IPADE >0.000000 OCC-filter vs SSMASFLSDE >0.000989 OCC-wrapper vs SSMASFLSDE >0.000000 OCC-filter vs OCC-wrapper <0.028299 SVDD is characterized by the most atypical behavior from the three examined methods. Here, for some of datasets, the standard InR techniques returned too small training set to build a one-class support vector classifier. This is because they use the nearest neighbor approach which has no lower bound on the size of the training set, while methods based on support vectors require a certain amount of samples for processing. SVDD cannot estimate an enclosing boundary with too few samples, as in cases when some InR methods return less than five training samples. Our proposed method once again returns the best performance, especially in the wrapper mode. This allows us to embed the SVDD training procedure with robustness to internal outliers that is of significant benefit to this classifier. SVDD displays the highest gain in classification efficacy from all of examined classifiers when wrapper selection is applied. 5.8 Impact on the Computational Complexity The average runtime of examined InR methods are presented in Figure 2. Average classification times before and after reduction for examined classifiers with respect to small datasets (<10 000 instances) are depicted in Figures 3 – 5, while for large-scale datasets (>= 100 000 instances) are depicted in Figure 6. The red points stand for a baseline classification time, while remaining points stand for reduced classification times after applying examined InR algorithms. This allows us to examine the computational gains from using simplified oneclass learners. In case of OCNN, we can see that our filter is a highly suitable method for OCNN, increasing the classification speed while not decreasing its accuracy. In case of MST, we when comparing classification times we can see that both filter and wrapper solutions achieve similar reduction rates and response times of the trained classifier. As for SVDD, we can see a slightly bigger differences in reduction rates and classification times between filter and wrapper approaches. Using wrapper method results in slightly bigger training set with 22 Bartosz Krawczyk et al. ENN DROP3 IPCL IPADE SSMASFLSDE OCC−filter OCC−wrapper reduction time [s.] 0 50 100 150 200 250 300 Fig. 2: Average reduction times of examined InR methods over all datasets. 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 0 2 4 6 8 10 12 14 16 ● ● ● ●● ● ● ● ● ● ● ●●●● ● ● ● ● ●●● ● ● ●●● ●●●●● ●●● ●●● ● ●● ●● ●●●●● ●●●●●● ● ●● ●● ●●●●● ●●●●●● ● ●● ●● ●●●●● Dataset Classification time [s.] ● ● ● ● ● NN.dd ENN DROP3 IPCL IPADE SSMASFLSDE OCC.filter Fig. 3: Average classification times in seconds for One-Class Nearest Neighbor classifier before and after reduction by examined instance reduction methods over small datasets. potentially higher number of support vectors (which explains the classification time). Still SVDD is characterized by the lowest classification time from all classifiers examined. These additional vectors have a clear positive influence on the classification procedure, which allows us to conclude that wrapper offers Instance Reduction for One-Class Classification 23 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 02468 ● ● ● ●● ● ● ● ● ● ● ● ●● ● ● ● ● ● ●●● ● ● ● ●● ●●●●● ● ● ● ●● ● ● ●● ●● ●●●●● ●●●●●● ● ●● ●● ●●●●● ● ●●●●● ● ●● ●● ●●●●● Dataset Classification time [s.] ● ● ● ● ● MST.dd ENN DROP3 IPCL IPADE SSMASFLSDE OCC.filter OCC.wrapper Fig. 4: Average classification times in seconds for Minimum Spanning Tree classifier before and after reduction by examined instance reduction methods over small datasets. 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 0 2 4 6 ● ● ● ●● ● ● ● ● ● ● ●●● ● ● ● ● ● ●●● ● ●●●●●●●● ● ●● ●●●● ● ●● ● ● ●●●● ●●●●●●●●●● ●● ●●●●●●●●●●●●●● ●●●●●●● Dataset Classification time [s.] ● ● ● ● ● SVDD ENN DROP3 IPCL IPADE SSMASFLSDE OCC.filter OCC.wrapper Fig. 5: Average classification times in seconds for Support Vector Data Description classifier before and after reduction by examined instance reduction methods over small datasets. Time equal to 0 stands for a situation in which the dataset after reduction was too small to train a classifier. 24 Bartosz Krawczyk et al. 17 18 19 20 21 0 50 116 190 264 338 412 486 560 634 708 782 856 ● ● ● ● ● ●● ●● ● ●● ●● ● ●●●● ● ●●●● ● Dataset Classification time [s.] ● ● ● ● ● NN.dd ENN DROP3 IPCL IPADE SSMASFLSDE OCC.filter 17 18 19 20 21 0 24 52 80 112 148 184 220 256 292 328 364 400 ●● ● ● ● ●● ● ●● ●● ● ●● ●● ● ● ● ●● ●● ● Dataset Classification time [s.] ● ● ● ● ● MST.dd ENN DROP3 IPCL IPADE SSMASFLSDE OCC.filter OCC.wrapper 17 18 19 20 21 0 18 40 62 84 108 134 160 186 212 238 264 290 ●● ● ● ● ●●● ●● ●●● ●● ●●● ● ● ●●● ●● Dataset Classification time [s.] ● ● ● ● ● SVDD ENN DROP3 IPCL IPADE SSMASFLSDE OCC.filter OCC.wrapper Fig. 6: Average classification times in seconds for (left) One-Class Nearest Neighbor, (center) Minimum Spanning Tree and (right) Support Vector Data Description classifiers before and after reduction by examined instance reduction methods over large-scale datasets. the best trade-off between reduction rates and classification performance for one-class support vector classifiers. 6 Conclusions and Future Works In this paper we have discussed the usability of instance reduction methods for one-class classification. We showed, that a carefully conducted InR can lead to a significant lowering of OCC complexity and often to improved classification performance. We have proposed two approaches to applying InR for OCC. Firstly, an universal framework was introduced that allowed to transform any existing InR method to one-class version. It used uniform generation of artificial objects combined with data cleaning procedure to remove overlap between classes. This way we obtained a binary dataset that can be supplied to any conventional InR algorithm. After reduction artificial outliers were discarded and one-class classifier was trained using a reduced set of target concept instances. We have identified potential shortcoming of methods relying on artificial data generation and proposed a second solution, native to OCC characteristics. It used SFLSDE, method based on differential evolution, to select training samples. We have augmented it with consistency measure in order to evaluate set of instances without a need for counterexamples. Filter and wrapper versions were proposed, varying in complexity and adaptability to selected classification model. Thorough experimental study backed-up by a statistical analysis proved the high usefulness of proposed solutions regardless of the base classifier used. We showed that consistency-based InR significantly outperforms methods that require artificial counterexamples. Obtained results encourage us to continue work on instance reduction for one-class classification. In future we plan to develop ensemble learning techniques based on diverse subsets of selected examples [24]. Instance Reduction for One-Class Classification 25 References 1. Aha, D.W., Kibler, D., Albert, M.K.: Instance-based learning algorithms. Machine Learning 6(1), 37–66 (1991) 2. Angiulli, F.: Prototype-based domain description for one-class classification. IEEE Trans. Pattern Anal. Mach. Intell. 34(6), 1131–1144 (2012) 3. Bicego, M., Figueiredo, M.A.T.: Soft clustering using weighted one-class support vector machines. Pattern Recognition 42(1), 27–32 (2009) 4. Bol´on-Canedo, V., S´anchez-Maro˜no, N., Alonso-Betanzos, A.: Feature Selection for High-Dimensional Data. Artificial Intelligence: Foundations, Theory, and Algorithms. Springer (2015) 5. Brest, J., Greiner, S., Boskovic, B., Mernik, M., Zumer, V.: Self-adapting control parameters in differential evolution: A comparative study on numerical benchmark problems. IEEE Transactions on Evolutionary Computation 10(6), 646–657 (2006). DOI 10.1109/TEVC.2006.872133 6. Cabral, G.G., de Oliveira, A.L.I.: A novel one-class classification method based on feature analysis and prototype reduction. In: Proceedings of the IEEE International Conference on Systems, Man and Cybernetics, Anchorage, Alaska, USA, October 9-12, 2011, pp. 983–988 (2011) 7. Cano, A., Ventura, S., Cios, K.J.: Multi-objective genetic programming for feature extraction and data visualization. Soft Comput. 21(8), 2069–2089 (2017) 8. Cano, J.R., Herrera, F., Lozano, M.: Using evolutionary algorithms as instance selection for data reduction in KDD: an experimental study. IEEE Transactions on Evolutionary Computation 7(6), 561–575 (2003) 9. Chen, Y., Garcia, E.K., Gupta, M.R., Rahimi, A., Cazzanti, L.: Similarity-based classification: Concepts and algorithms. Journal of Machine Learning Research 10, 747–776 (2009) 10. Cover, T.M., Hart, P.E.: Nearest neighbor pattern classification. IEEE Transactions on Information Theory 13(1), 21–27 (1967) 11. Cyganek, B.: One-class support vector ensembles for image segmentation and classification. Journal of Mathematical Imaging and Vision 42(2-3), 103–117 (2012) 12. Cyganek, B., Wiatr, K.: Image contents annotations with the ensemble of one-class support vector machines. In: NCTA 2011 - Proceedings of the International Conference on Neural Computation Theory and Applications [part of the International Joint Conference on Computational Intelligence IJCCI 2011], Paris, France, 24-26 October, 2011, pp. 277–282 (2011) 13. Czarnowski, I.: Prototype selection algorithms for distributed learning. Pattern Recognition 43(6), 2292–2300 (2010) 14. Czarnowski, I.: Cluster-based instance selection for machine classification. Knowl. Inf. Syst. 30(1), 113–133 (2012) 15. Das, S., Suganthan, P.: Differential evolution: A survey of the state-of-the-art. IEEE Transactions on Evolutionary Computation 15(1), 4–31 (2011) 16. Garc´ıa, S., Cano, J.R., Herrera, F.: A memetic algorithm for evolutionary prototype selection: A scaling up approach. Pattern Recognition 41(8), 2693–2709 (2008) 17. Garc´ıa, S., Derrac, J., Cano, J., Herrera, F.: Prototype selection for nearest neighbor classification: Taxonomy and empirical study. IEEE Transactions on Pattern Analysis and Machine Intelligence 34(3), 417–435 (2012) 18. Garc´ıa, S., Fern´andez, A., Luengo, J., Herrera, F.: Advanced nonparametric tests for multiple comparisons in the design of experiments in computational intelligence and data mining: Experimental analysis of power. Inf. Sci. 180(10), 2044–2064 (2010) 19. Garc´ıa, S., Herrera, F.: An extension on ”Statistical comparisons of classifiers over multiple data sets” for all pairwise comparisons. Journal of Machine Learning Research 9, 2677–2694 (2008) 20. Garc´ıa, S., Herrera, F.: Evolutionary under-sampling for classification with imbalanced data sets: Proposals and taxonomy. Evolutionary Computation 17(3), 275–306 (2009) 21. Garc´ıa, S., Luengo, J., Herrera, F.: Data Preprocessing in Data Mining. Springer Publishing Company, Incorporated (2014)