Who Is Your Right Mixup Partner in Positive and Unlabeled Learning

1 INTRODUCTION . Positive and Unlabeled ( PU ) learning refers to a specific binary classification problem , where only a small number of positive training instances are manually annotated but all other instances are unlabeled ( Liu et al. , 2002 ) . Such kind of datasets naturally arise in many significant real-world scenarios such as product recommendation ( Hsieh et al. , 2015 ) , deceptive reviews detection ( Ren et al. , 2014 ) , and medical diagnosis ( Yang et al. , 2012 ) . For specific example , many diseases , e.g. , Alzheimer ’ s disease , Amyotrophic Lateral Sclerosis , and Parkinson ’ s disease , are very infrequent and with long latency , hence only few diagnosed patients are known but a much larger population of undiagnosed individuals may be either diseased or healthy . Treating the diagnosed ones as positive instances and the undiagnosed ones as unlabeled instances results in such PU datasets of medical diagnosis . To meet those practical demands , PU learning has drawn increasing interest from the machine learning community ( Bekker & Davis , 2020 ) . Formally , let x ∈ Rd and y ∈ { 0 , 1 } be the feature representation and category label , respectively , where the positive instance is indicated by y = 1 and the negative one by y = 0 . In the context of PU learning , the training dataset is composed of the sets of positive instances P = { ( xi , yi = 1 ) } np i=1 and unlabeled instances U = { xi } np+nu i=np+1 , where U contains both positive and negative instances . The target is to learn a binary classifier based on such weak training dataset P ∪ U . During the past decades , many PU learning methods have been proposed , where , naturally , the essential idea is to estimate the negative instances from the set of unlabeled instances U . Generally , most of existing PU learning methods can be divided into two categories , termed as sample-selection methods and cost-sensitive methods . The sample-selection methods , as the name suggests , mainly select reliable negative instances from U using various heuristic strategies , e.g. , Naı̈ve Bayes ( Liu et al. , 2002 ) , kNN ( Zhang & Zuo , 2009 ) , k-means ( Chaudhari & Shevade , 2012 ) , and reinforcement learning ( Luo et al. , 2021 ) ; and then apply supervised methods over positive and those reliable negative instances . In contrast , the cost-sensitive methods treat all unlabeled instances as corrupted negative ones , and correct the estimation bias of the objective by employing well-designed misclas- sification risks such as unbiased risk estimator ( du Plessis et al. , 2014 ; 2015 ; Kiryo et al. , 2017 ) and maximum margin loss ( Shi et al. , 2018 ; Gong et al. , 2019b ; Zhang et al. , 2019 ; Gong et al. , 2019a ) . Orthogonal to the aforementioned techniques , we note that some PU learning methods such as ( Chen et al. , 2020a ; Wei et al. , 2020 ) have made preliminary attempts to integrate with the art of mixup , i.e. , an economic-yet-effective data augmentation method ( Zhang et al. , 2018 ) . Formally , mixup generates an augmented instance ( x̂ , ŷ ) with the convex combination of any pair of instances { ( xi , yi ) , ( xj , yj ) } drawn from the training dataset : x̂ = λxi + ( 1− λ ) xj , ŷ = λyi + ( 1− λ ) yj , λ ∼ Beta ( α , α ) , α ∈ ( 0 , ∞ ) . Previous studies have indicated that mixup is approximately equivalent to applying adversarial training ( Zhang et al. , 2021 ) , enabling to improve robustness with even scarce and noisy supervision ( Thulasidasan et al. , 2019 ; Carratino et al. , 2020 ; Zhang et al. , 2021 ) . Accordingly , it has been successfully used to solve various learning problems with weak supervision , e.g. , semi-supervised learning ( Berthelot et al. , 2019 ) , noisy label learning ( Li et al. , 2020 ) , and partial label learning ( Yan & Guo , 2020 ) . Our story and contribution . Inspired by the recent success of mixup in learning with weak supervision , our original goal is to thoroughly investigate the impact of mixup in PU learning . To this end , we begin with a naive disambiguation-free objective of PU learning , where all unlabeled instances are treated as pseudo-negative instances , denoted by Ũ = { ( xi , yi = 0 ) } np+nu i=np+1 , and the binary classifier is trained based on P ∪ Ũ . In preliminary experiments , we found an interesting phenomenon , where the number of training instances predicted as positive by the disambiguationfree classifier tends to be smaller than usual as illustrated in Fig.1 . This phenomenon implies that the disambiguation-free boundary tends to deviate from the fully supervised boundary towards the positive side , expressed by a toy example shown in Fig.2 ( a ) . We consider that the decision boundary deviation is mainly caused by the marginal pseudo-negative instances , which lie between the two boundaries . Such instances are more likely to be positive but actually annotated by negative . 1Specially , we apply the early learning regularization ( Liu et al. , 2020 ) into the objective to keep it stable . Motivated by this observation , we extend mixup to a specific heuristic version for PU learning , enabling to achieve data augmentation and supervision correction simultaneously . Its basic idea is to transform the marginal pseudo-negative instances into augmented instances which are partially positive and yet also lie between the two boundaries , so as to push the learned boundary towards the fully supervised one . This can be achieved by selecting the mixup partners for marginal pseudonegative instances from the positive instances that are around the learned boundary , as expressed in Fig.2 ( b ) . With this insight , we propose a novel PU method , namely Positive and unlabeled learning with Partially Positive Mixup ( P3Mix ) . Generally , P3Mix is easy-to-implement , where , specifically , we can define the marginal pseudo-negative instances using the predictive results and the positive instances around the boundary using the entropy values of predictive results . To evaluate the effectiveness of P3Mix , we conduct a number of experiments on benchmark datasets . Experimental results demonstrate that P3Mix can consistently outperform the state-of-the-art PU methods . 2 THE PROPOSED P3MIX METHOD In this section , we introduce the proposed P3Mix method for PU learning . We first revisit and clarify some important notations : the set of positive instances P = { ( xi , yi = 1 ) } np i=1 and the set of unlabeled instances U = { xi } np+nu i=np+1 . By treating all unlabeled instances as negative , we translate U into the set of pseudo-negative instances Ũ = { ( xi , yi = 0 ) } np+nu i=np+1 . Given batches Xp ⊂ P and Xu ⊂ Ũ , the disambiguation-free objective of PU learning can be formulated as follows : L ( Xp , Xu ; Θ ) = 1 |Xp| ∑ ( x , y ) ∈Xp ` ( f ( x ; Θ ) , y ) + β |Xu| ∑ ( x , y ) ∈Xu ` ( f ( x ; Θ ) , y ) , ( 1 ) where f ( · ; Θ ) is a trainable neural network , i.e. , the binary classifier , parameterized by Θ ; ` ( · , · ) is the loss function ; and β is the coefficient parameter . To achieve data augmentation and supervision correction simultaneously , P3Mix transforms Xp and Xu into the batches of augmented instances X̂p and X̂u using the proposed heuristic mixup technique . Accordingly , the objective of P3Mix is then expressed as follows : L ( X̂p , X̂u ; Θ ) = 1 |X̂p| ∑ ( x̂ , ŷ ) ∈X̂p ` ( f ( x̂ ; Θ ) , ŷ ) + β |X̂u| ∑ ( x̂ , ŷ ) ∈X̂u ` ( f ( x̂ ; Θ ) , ŷ ) , ( 2 ) X̂p , X̂u = HeuristicMixup ( Xp , Xu , α ) , ( 3 ) where α ∈ ( 0 , ∞ ) is a hyperparameter of mixup . Next , we describe the details of heuristic mixup . Algorithm 1 Training procedure of P3Mix , P3Mix-E and P3Mix-C Input : P ∪ U : training instances ; β : coefficient parameter ; γ : thresholding parameter ; k : size of the candidate mixup pool ; α : hyperparameter of mixup ; η : coefficient parameter of early-learning regularization . η = 0 for P3Mix and P3Mix-C Output : Θ : binary classifier parameters 1 : Initialize Θ , the mean-teacher parameters Θ̃ and the candidate mixup pool Xcnd randomly , translate U into Ũ ; 2 : for t = 1 , 2 , · · · , MaxEpoch do 3 : Shuffle P ∪ Ũ into I mini-batches and denote the i-th mini-batch by ( X ip , X iu ) ; 4 : for i = 1 , 2 , · · · , I do 5 : Estimate marginal pseudo-negative instances Xmpn using Eq . ( 6 ) ; 6 : Select the mixup partners for each instance within X ip ∪ X iu using Eq . ( 5 ) ; 7 : Set labels of { ( x , y = 0 ) | ( x , y = 0 ) ∈ X iu , f ( x ; Θ ) > γ } to 1 ; . Optional for P3Mix-C 8 : Construct X̂ ip ∪ X̂ iu by applying Eq . ( 4 ) to X ip ∪ X iu and their mixup partners ; 9 : Estimate { ỹj } |X̂ ip|+|X̂ i u| j=1 for instances in X̂ ip ∪ X̂ iu by f ( · ; Θ̃ ) ; . Optional for P3Mix-E 10 : Update Θ by ∇Θ ( L ( X̂ ip , X̂ iu ; Θ ) + ηRelr ( { ( x̂j , ỹj ) } |X̂ ip|+|X̂ i u| j=1 ; Θ ) ) with Adam ; 11 : end for 12 : Update Xcnd using Eq . ( 7 ) ; 13 : Update Θ̃ by Θ with the move-average ; . Optional for P3Mix-E 14 : end for 2.1 TRAINING WITH HEURISTIC MIXUP . Basically , for each instance ( xi , yi ) ∈ Xp ∪ Xu we select a mixup partner ( xj , yj ) to generate an augmented instance ( x̂i , ŷi ) using the modified mixup operator2 ( Berthelot et al. , 2019 ) : x̂i = λ ′xi + ( 1− λ′ ) xj , ŷi = λ′yi + ( 1− λ′ ) yj , λ′ = max ( λ , 1− λ ) , λ ∼ Beta ( α , α ) , α ∈ ( 0 , ∞ ) , ( 4 ) accordingly forming the augmented instance sets X̂p and X̂u . Our heuristic mixup refers to a guidance of mixup partner selection to refine the imprecise supervision within Xu . We take inspiration from the phenomenon , where the boundary learned by Eq . ( 1 ) tends to deviate from the fully supervised boundary towards the positive side as illustrated in Fig.2 ( a ) . The marginal pseudo-negative instances Xmpn ⊂ Xu lie between the two boundaries , and they are more likely to be positive but actually annotated by negative . To resolve this problem , for each of them we uniformly select a mixup partner from the candidate mixup pool Xcnd ⊂ P of positive instances that are around the current learned boundary , so as to generate an augmented instance which is partially positive and yet also lies between the two boundaries as expressed in Fig.2 ( b ) . Besides , for positive instances Xp and other pseudo-negative instances Xu \ Xmpn , we uniformly choose their mixup partners from Xp ∪ Xu The overall mixup partner selection is formulated as follows : ( xj , yj ) ∼ Uniform ( Xcnd ) if ( xi , yi ) ∈ Xmpn , Uniform ( Xp ∪ Xu ) if ( xi , yi ) ∈ Xp ∪ Xu \ Xmpn . ( 5 ) In what follows , we introduce how to estimate the marginal pseudo-negative instances Xmpn and construct the candidate mixup pool Xcnd . 2Because we compute individual loss terms for positive instances and pseudo-negative ones in Eq . ( 2 ) appropriately , we define λ′ = max ( λ , 1−λ ) to guarantee that the feature of each augmented instance x̂i is closer to xi than the mixup partner xj . Consequently , ( x̂i , ŷi ) is assigned into X̂p if ( xi , yi ) ∈ Xp , or X̂u otherwise . Marginal pseudo-negative instance estimation . Because the fully supervised boundary is exactly unknown , we have to estimate the set of marginal pseudo-negative instances Xmpn from Xu . In this work , we define them as the “ unreliable ” pseudo-negative instances measured by the predictive scores with thresholding parameter γ ∈ [ 0.5 , 1 ] : Xmpn = { ( x , y = 0 ) | ( x , y = 0 ) ∈ Xu , 1− γ ≤ f ( x ; Θ ) ≤ γ } , ( 6 ) where γ = 0.5 implies Xmpn = ∅ , and γ = 1 means Xmpn = Xu . Candidate mixup pool . We maintain a candidate mixup pool Xcnd containing the positive instances around the current learned boundary from P . To be specific , for each positive instance we compute its entropy value of the predictive score , and update the candidate mixup pool with the top-k positive instances as follows : Xcnd = { ( x , y = 1 ) | ( x , y = 1 ) ∈ P , H ( f ( x ; Θ ) ) ∈ Rank ( { H ( f ( xi ; Θ ) ) } np i=1 ) } , ( 7 ) where H ( · ) is the entropy , and Rank ( · ) outputs a set of positive instances with the top-k maximum entropy values . For efficiency , we update Xcnd in every epoch . The full training procedure is shown in Algorithm 1 .

Summary: This paper proposes a variant of the mixup technique for positive-unlabeled learning. Based on the observation that the learned PU boundary tends to deviate towards the positive side, the authors suggest selecting samples between the learned PU and supervised boundaries. The proposed P3MIX method and its variant improve the classification performance of PU learning.