The Modified BAPGs Method for Support Vector Machine Classifier with Truncated Loss

Abstract

In this paper, we modify the Bregman APGs (BAPGs) method proposed in (Wang, L, et al.) for solving the support vector machine problem with truncated loss (HTPSVM) given in (Zhu, W, et al.), we also add an adaptive parameter selection technique based on (Ren, K, et al.). In each iteration, we use the linear approximation method to get the explicit solution of the subproblem and set a function to apply the Bregman distance. Finally, numerical experiments are performed to verify the efficiency of BAPGs.

Share and Cite:

Ren, K. (2024) The Modified BAPGs Method for Support Vector Machine Classifier with Truncated Loss. Applied Mathematics, 15, 267-278. doi: 10.4236/am.2024.154015.

1. Introduction

SVM (Support Vector Machine) [1] is a supervised learning algorithm commonly used for classification tasks and has been successfully applied to many technological fields, such as text categorization [2] , financial forecast [3] , image classification [4] and so on. This paper focuses on a binary classification problem. Given training samples { ( x i , y i ) , i = 1 , , m } , where x i n , y i { 1,1 } , the objective of SVM is to identify an optimal separating hyperplane to separate data points into two classes. Scholars have proposed some classic SVM models based on convex loss functions, such as the hinge loss (also called L1 loss) in classic SVM [5] , the least square loss in LSSVM [6] and the huberized pinball loss in HPSVM [7] . However, in practice, the real dataset often contain noise. Since convex loss functions are generally unbounded, convex losses are highly sensitive to outliers and potentially influenced by outliers. Therefore, some nonconvex loss functions are proposed to improve robustness compared with the convex loss functions [8] . For example, [9] proposed the ramp loss based on hinge loss, the truncated pinball loss was proposed by [10] . Recently, a noise insensitive and robust support vector machine classifier with huberied truncated pinball loss (HTPSVM) was proposed in [11] , this loss is smooth and nonconvex loss function. The HTPSVM can be transformed into format of “Loss + Penalty”, in which the penalty is a hybrid of l 1 norm and l 2 norm penalty.

Here, the HTPSVM model and algorithm of literature [11] are briefly introduced. Consider a classification problem with training samples { x i , y i } i = 1 m d × { 1,1 } . The HTPSVM seeks to solve the following regularization problem:

min b , w d 1 m i = 1 m l h t p ( y i ( b + w T x i ) ) + λ w 1 + w 2 2 2 + b 2 2 , (1)

the huberied truncated pinball loss l h t p ( ) function is defines as

l h t p ( u ) = { 1 , u 2 5 4 5 u 5 4 u 2 , 2 5 < u 0 , 4 5 u , 0 < u 3 5 , 5 4 ( 1 u ) 2 , 3 5 < u 1 , 5 8 ( 1 u ) 2 , 1 u < 7 5 , 1 2 ( 6 5 u ) , 7 5 u < 8 5 , 1 2 ( 6 5 u ) 5 8 ( u 8 5 ) 2 , 8 5 u < 2 , 3 10 , u 2 , (2)

which is a nonconvex and smooth function. The HTPSVM combine the benefits of both l 1 and l 2 norm regularizers and and it has been demonstrated in [11] that it can reduce the effects of noise in the training sample. Therefore, we consider that studying the HTPSVM model is meaningful. The APG algorithm was used to solve the model in [11] . [12] applied the APGs method (first proposed in [13] ) to solve problem (1) and obtain better convergence behavior. However we find that the proximal operator for computing the l 1 norm causes the subproblem to be solved slowly in APG and APGs algorithms, we attempt to accelerate the solution process for this model. Recently, [14] propose the Bregman APGs (BAPGs) method, which avoids the restrictive global Lipschitz gradient continuity assumption. In this paper, we improve BAPGs algorithm to solve the problem (1) and replace the Lipschitz constant by an appropriate positive definite matrix and obtain better results after we perform numerical experiments on 10 datasets to test our method.

The rest of this paper is organized as follows. In the next section, we provide preliminary materials used in this work. In Section 3, we introduce the BAPGs algorithm proposed by [14] and present our algorithm based on the BAPGs method for solving the HTPSVM model (1). The convergence of our method is also discussed. Section 4 performs some experiments.

2. Preliminaries

In this paper, we let denote the set of real numbers. We work in the Euclidean space n , and the standard Euclidean inner product and the induced norm on n are denoted by , and . The domain of the function f : n ( , + ] is defined by dom f = { x n : f ( x ) < + } . We say that f is proper if dom f . A proper function f is said to be closed if it is lower semicontinuous at any x dom f , i.e. f ( x ) lim inf z x f ( z ) .

Definition 1. [ [15] , Definition 8.3] For a proper closed function f, the regular subdifferential of f : n { + } at x dom f is defined by

^ f ( x ) : = { x ^ n : lim inf z x , z x f ( z ) f ( x ) x ^ , z x z x 0 } . (3)

The (general) subdifferential of f at x dom f is defined

f ( x ) : = { x ^ : x k f x , x ^ k x ^ with x ^ k ^ f ( x k ) for each k } , (4)

where x k f x means both x k x and f ( x k ) f ( x ) . Note that if f is also convex, then the general subdifferential and regular subdifferential of f at x dom f reduce to the classical subdifferential [ [15] , Proposition 8.12], that is f ( x ) = { x ^ : f ( y ) f ( x ) + x ^ , y x for all y } . (5)

Definition 2. (Kernel Generating Distances and Bregman Distances [16] [17] [18] ) Let C be a nonempty, convex and open subset of n . Associated with C, a function ϕ : n ( , + ] is called a kernel generating distance if it satisfies the following:

1) ϕ is proper, lower semicontinuous and convex, with dom ϕ C ¯ and dom ϕ = C ;

2) ϕ is continuously differentiable on int dom ϕ C .

We denote the class of kernel generating distances by G ( C ) . Given ϕ G ( C ) , the Bregman distance D ϕ : dom ϕ × int dom ϕ ( 0 , + ] is defined by

D ϕ ( x , y ) : = ϕ ( x ) ϕ ( y ) ϕ ( y ) , x y .

For exmple, when ϕ ( x ) = x 2 , then D ϕ ( x , y ) = x y 2 . If ϕ ( x ) = x T A x , then D ϕ ( x , y ) = ( x y ) T A ( x y ) . In this article, the gradient Lipschitz continuity condition of the function f is no longer required, instead it is replaced by the L-smooth adaptive function of pair ( f , ϕ ) . The definition of L-smooth adaptable as follows.

Definition 3. A pair of functions ( f , ϕ ) , ϕ G ( C ) , f : n ( , + ] is a proper and lower semicontinuous function with dom ϕ dom f and f is continuously differentiable on C = int dom ϕ , is called L-smooth adaptable (L-smad) on C if there exists L > 0 such that L ϕ f and L ϕ + f are convex on C.

Lemma 1. (Full Extended Descent Lemma [19] ) A pair of functions ( f , ϕ ) is L-smad on C = int dom ϕ if and only if: | f ( x ) f ( y ) f ( y ) , x y | L D ϕ ( x , y ) , x , y int dom ϕ .

Definition 4. f : n { + } is called μ-relative weakly convex to ϕ on C if there exists μ > 0 such that f + μ ϕ is convex on C [14] .

3. The Modified BAPGs Method for HTPSVM

In this section, we first describe the BAPGs method proposed in [14] , then the modified BAPGs method with adaptive parameter is given for HTPSVM.

3.1. BAPGs Method

Consider the following optimization problem:

min x n F ( x ) : = f ( x ) + P 1 ( x ) P 2 ( x ) , (6)

where f is a μ-relative weakly convex continuously differentiable function, P1 is a proper, lower semicontinuous convex function and P2 is continuous and convex. Besides, F is level-bounded i.e., for every α , the set { x n | F ( x ) α } is bounded; F is bounded below i.e., inf x n F ( x ) > . The iterative scheme of BAPGs [14] for solving probelm (6) is shown in Algorithm 1, where D ϕ is a Bregman distance defined in Section 2.

We see that when D ϕ ( x , y ) = 1 2 x y 2 , BAPGs reduces to APGs in [13] . [14] proved the global convergence of the iterates generated by BAPGs to a limiting critical point under some assumptions.

3.2. Adaptive BAPGs Method for HTPSVM

By writing the nonconvex loss l h t p as the difference of three smooth convex functions, the problem (1) can be expressed as following from [12]

min b , w d F ( b , w ) = f 1 ( b , w ) f 2 ( b , w ) f 3 ( b , w ) + P 1 ( b , w ) , (8)

where P 1 ( b , w ) = λ w 1 + w 2 2 2 + b 2 2 , λ is the regularization parameter; for j = 1,2 , f j ( b , w ) = 1 m i = 1 m l j [ y i ( b + w T x i ) ] , and the smooth convex functions l j are defined as

l 1 ( u ) = { 4 5 u , if u < 3 5 , 5 4 ( 1 u ) 2 , if 3 5 u < 1 , 5 8 ( 1 u ) 2 , if 1 u < 7 5 , 1 2 ( 6 5 u ) , if u 7 5 , (9)

l 2 ( u ) = { u 1 5 , if u 2 5 , 5 4 u 2 , if 2 5 < u 0 , 0, if u 0, (10)

l 3 ( u ) = { 0, if u 8 5 , 5 8 ( u 8 5 ) 2 , if 8 5 u < 2 , 1 2 ( 9 5 u ) , if u 2. (11)

Then we can apply the BAPGs to solve problem (8) in the form of (6)

P 1 : f = f 1 f 3 (nonconvex), P 2 = f 2 (convex);

P 2 : f = f 1 f 2 (nonconvex), P 2 = f 3 (convex).

Next, We will briefly illistrate that the problem (8) can be solved by the BAPGs [14] .

Theorem 1. Let f as defined in P 1 and P 2 . Set ϕ ( x ) : = 1 2 x T Q x , where Q = 1 m i = 1 m 5 2 Q i , Q i = ( y i , y i x i T ) T ( y i , y i x i T ) . Then, the pair ( f , ϕ ) is L-smooth adaptable on n with L = 1 .

Proof. Firstly, for P 1 , since

l 1 3 ( u ) + 5 2 u = { 5 2 u 1 , u 3 5 , 5 u 5 2 , 3 5 < u 1 , 15 4 u 5 4 , 1 u < 7 5 , 5 2 u + 1 2 , 7 5 u < 8 5 , 5 4 u + 5 2 , 8 5 u < 2 , 5 2 u , u 2 , (12)

and

5 2 u l 1 3 ( u ) = { 5 2 u + 1 , u 3 5 , 5 2 , 3 5 < u 1 , 5 4 u + 5 4 , 1 < u 7 5 , 5 2 u 1 2 , 7 5 u < 8 5 , 15 4 u 5 2 , 8 5 u < 2 , 5 2 u , u 2 , (13)

are monotonically increasing, it is easy to verify that l 1 3 ( u ) + 5 4 u 2 and 5 4 u 2 l 1 3 ( u ) are convex. Then we can easily get the convexity of

f ( b , w ) + 1 2 x T Q x = 1 m i = 1 m l 1 3 [ y i ( b + w T x i ) ] + 1 2 m i = 1 m 5 2 ( b ; w ) T Q i ( b ; w ) = 1 m i = 1 m [ l 1 3 [ y i ( b + w T x i ) ] + 5 4 ( b ; w ) T Q i ( b ; w ) ] = 1 m i = 1 m [ l 1 3 [ y i ( b + w T x i ) ] + 5 4 [ y i ( b + w T x i ) ] 2 ] , (14)

and

1 2 x T Q x f ( b , w ) = 1 m i = 1 m [ 5 4 [ y i ( b + w T x i ) ] 2 l 1 3 [ y i ( b + w T x i ) ] ] , (15)

the proof is similar for P 2 . It is clear that ( f , ϕ ) is 1-smooth adaptable on n , this further implies that there exists 0 < μ 1 such that f + μ ϕ is convex.

We can see that the problem (8) satisfies the conditions required in [14] with ϕ ( x ) = 1 2 x T Q x for the pair ( f , ϕ ) , where Q defined as Theorem 1. Therefore the BAPGs method (Algorithm 1), here we let τ = 1 and replace (7) with the following steps, can be used for solving (8)

y k = θ k z k + ( 1 θ k ) x k , z k + 1 = arg min z n { f ( y k ) ξ k , z y k + P 1 ( z ) + θ k 2 [ ( z z k ) T Q ( z z k ) ] } , x k + 1 = θ k z k + 1 + ( 1 θ k ) x k . (16)

The selection of parameter { θ k } in [14] as: for fixed positive integer N, let θ 0 = 1 ,

θ k + 1 = θ k 4 + 4 θ k 2 θ k 2 2 , k = 1,2, , N

and θ k θ N for all k > N . It is to see that the value of the positive integer N is difficult to determine. Combining with the adaptive parameter selection criterion proposed in [12] : let θ 0 = 1 , θ k = θ k 1 4 + 4 θ k 1 2 θ k 1 2 2 for k 1 and compute

d k : = H k 1 H k ( x k x k 1 ) T ( x k x k 1 ) , (17)

when k 2 , where H k : = F ( x k ) + β k 2 ( x k x k 1 ) T Q ( x k x k 1 ) and β k = α k θ k 1 2 (the assumption of sequence { α k } given in [14, Assumption 2]). Let N be the first k satisfying d k d k + 1 . The BAPGs algorithm with adaptive parameter for problem (8) (HTPSVM) is shown in Algorithm 2.

4. Numerical Results

In this section, we aim to show the performance of Algorithm 2 for solving problem (1) by using MATLAB R2020b on a 64-bit PC with an Intel(R) Core(TM) i7-10870H CPU (2.20GHz) and 16GB of RAM.

First, consider the optimality condition (19) of Algorithm 2

0 f ( y k ) ξ k + P 1 ( z k + 1 ) + θ Q ( z k + 1 z k ) = f ( y k ) ξ k + λ z k + 1 1 + z k + 1 + θ Q ( z k + 1 z k ) .

Due to there is no explicit solution for this subproblem, we try to instead the l 1 norm by linear approximation, that is, z 1 x k 1 + v k T ( z x k ) , where v k x k 1 (here we take v k : = sign ( x k ) ), then we construct a new iteration step to replace the subproblem in Algorithm 2 as

z k + 1 = arg min z n { f ( y k ) ξ k , z y k + x k 1 + λ v k T ( z x k ) + 1 2 z T z + θ 2 [ ( z z k ) T Q ( z z k ) ] } , (20)

it is easy to calculate its solution:

0 = f ( y k ) ξ k + λ v k T + z k + 1 + θ Q ( z k + 1 z k ) ,

which means

( I + θ Q ) z k + 1 = θ Q z k f ( y k ) + ξ k λ v k .

Then the update (18) and (19) are replaced by

{ z k + 1 = ( I + θ k Q ) 1 ( θ k Q z k f ( y k ) + ξ k λ v k ) , z k + 1 = ( I + θ Q ) 1 ( θ Q z k f ( y k ) + ξ k λ v k ) , (21)

in experiments, where v k = sign ( x k ) and v k = sign ( x k ) . The experiments are conducted on several real world datasets. We select 10 datasets from UCI [20] , to compare the Algorithm 2 with APG (method in [11] ), APGs [12] and GIST [21] , where in GIST, we set F = f + P 1 with f = f 1 f 2 f 3 . The corresponding parameters of these methods are set the same as in [12] . For each dataset, The 21 initial points are used commonly for all methods: one zero vector, and 5 vectors selected independently from N (0, σ2I) for each σ { 1,2,4,8 } . All algorithms stop if ( b k + 1 ; w k + 1 ) ( b k ; w k ) max { 1, ( b k ; w k ) } < 10 6 or the number of iterations hits 3000. The average results are given in Table 1 and Table 2, including the number of iterations (iter), objective function value (fval) and CPU time in seconds (CPU) at termination with λ = 1 × 10 3 and 5 × 10 4 , where BAPGs- P 1 and APGs- P 1 represent using BAPGs (algorithm 2) and APGs [12] for P 1 respectively ( P 1 described in section 3.2).

Table 1. Comparison on 10 datasets with λ = 1 × 10 3 .

Table 2. Comparison on 10 datasets with λ = 5 × 10 4 .

From the above tables, we see that Algorithm 2 for P 2 always obtain the smaller function values and converge faster than others, this means that Algorithm 2 for solving HTPSVM model (1) performs well.

5. Conclusions and Suggestions

In this paper, based on the BAPGs method proposed by [14] , we construct the modified BAPGs with the adaptive parameter selection technique introduced in [12] for solving the HTPSVM model. The linear approximation method is used to improve the subproblem in algorithm and a function ϕ with a suitable matrix Q is set to obtain the L-smad property. Finally, numerical experiments show that our algorithm convergence faster.

Conflicts of Interest

The author declares no conflicts of interest regarding the publication of this paper.

References

[1] Vapnik, V. and Cortes, C. (1995) Support-Vector Networks. Machine Learning, 20, 273-297.
https://doi.org/10.1007/BF00994018
[2] Joachims, T. (1998) Text Categorization with Support Vector Machines: Learning with Many Relevant Features. 10th European Conference on Machine Learning, Chemnitz, 21-23 April 1998, 137-142.
https://doi.org/10.1007/BFb0026683
[3] Zhang, X., Li, A. and Pan, R. (2016) Stock Trend Prediction Based on a New Status Box Method and AdaBoost Probabilistic Support Vector Machine. Applied Soft Computing, 49, 385-398.
https://doi.org/10.1016/j.asoc.2016.08.026
[4] Chandra, M. and Bedi, S. (2021) Survey on SVM and Their Application in Image Classification. International Journal of Information Technology, 13, 1-11.
https://doi.org/10.1007/s41870-017-0080-1
[5] Rong-En, F., Kai-Wei, C., et al. (2008) LIBLINEAR: A Library for Large Linear Classification. The Journal of Machine Learning Research, 9, 1871-1874.
[6] Suykens, J. and Vandewalle, J. (1999) Least Squares Support Vector Machine Classifiers. Neural Processing Letters, 9, 293-300.
https://doi.org/10.1023/A:1018628609742
[7] Zhu, W., Song, Y. and Xiao, Y. (2021) Support Vector Machine Classifier with Huberized Pinball Loss. Engineering Applications of Artificial Intelligence, 91, Article 103635.
https://doi.org/10.1016/j.engappai.2020.103635
[8] Zhao, L., Mammadov, M., et al. (2010) From Convex to Nonconvex: A Loss Function Analysis for Binary Classification. 2010 IEEE International Conference on Data Mining Workshops, Sydney, 13 December 2010, 1281-1288.
https://doi.org/10.1109/ICDMW.2010.57
[9] Collobert, R., Sinz, F, et al. (2006) Large Scale Transductive SVMS. Journal of Machine Learning Research, 7, 1687-1712.
[10] Shen, X., Niu, L., Qi, Z. and Tian, Y. (2017) Support Vector Machine Classifier with Truncated Pinball Loss. Pattern Recognition, 68, 199-210.
[11] Zhu, W., Song, Y. and Xiao, Y. (2022) Robust Support Vector Machine Classifier with Truncated Loss Function by Gradient Algorithm. Computers & Industrial Engineering, 172, Article 108630.
[12] Ren, K., Liu, C. and Wang, L. (2024) The Modified Second APG Method for a Class of Nonconvex Nonsmooth Problems. (In Press)
[13] Lin, D. and Liu, C. (2019) The Modified Second APG Method for DC Optimization Problems. Optimization Letters, 13, 805-824.
https://doi.org/10.1007/s11590-018-1280-8
[14] Wang, L., Liu, C. and Ren, K. (2024) The Bregman Modified Second APG Method for DC Optimization Problems. (In Press)
[15] Rockafellar, R. and Wets, R. (2009) Variational Analysis. Springer Science & Business Media, Berlin.
[16] Bolte, J., Sabach, S., Teboulle, M., et al. (2017) First Order Methods beyond Convexity and Lipschitz Gradient Continuity with Applications to Quadratic Inverse Problems. SIAM Journal on Optimization, 28, 2131-2151.
https://doi.org/10.1137/17M1138558
[17] Lev, M.B. (1967) The Relaxation Method of Finding the Common Point of Convex Sets and Its Application to the Solution of Problems in Convex Programming. USSR Computational Mathematics and Mathematical Physics, 7, 200-217.
https://api.semanticscholar.org/corpusid:121309410
[18] Wu, Z., Li, C., et al. (2021) Inertial Proximal Gradient Methods with Bregman Regularization for a Class of Nonconvex Optimization Problems. Journal of Global Optimization, 79, 617-644.
https://doi.org/10.1007/s10898-020-00943-7
[19] Bauschke, H., Bolte, J. and Teboulle, M. (2017) A Descent Lemma beyond Lipschitz Gradient Continuity: First-Order Methods Revisited and Applications. Mathematics of Operations Research, 42, 330-348.
https://doi.org/10.1287/moor.2016.0817
[20] Asuncion, A. and Newman, D. (2007) UCI Machine Learning Repository.
http://archive.ics.uci.edu/ml
[21] Chen, X., Lu, Z., et al. (2016) Penalty Methods for a Class of Non-Lipschitz Optimization Problems. SIAM Journal on Optimization, 26, 1465-1492.
https://doi.org/10.1137/15M1028054

Copyright © 2024 by authors and Scientific Research Publishing Inc.

Creative Commons License

This work and the related PDF file are licensed under a Creative Commons Attribution 4.0 International License.