IR2Vec
Loading...
Searching...
No Matches
OpenKE.module.loss.SoftplusLoss.SoftplusLoss Class Reference
Inheritance diagram for OpenKE.module.loss.SoftplusLoss.SoftplusLoss:
Collaboration diagram for OpenKE.module.loss.SoftplusLoss.SoftplusLoss:

Public Member Functions

 __init__ (self, adv_temperature=None)
 
 get_weights (self, n_score)
 
 forward (self, p_score, n_score)
 
 predict (self, p_score, n_score)
 
- Public Member Functions inherited from OpenKE.module.loss.Loss.Loss
- Public Member Functions inherited from OpenKE.module.BaseModule.BaseModule
 load_checkpoint (self, path)
 
 save_checkpoint (self, path)
 
 load_parameters (self, path)
 
 save_parameters (self, path)
 
 get_parameters (self, mode="numpy", param_dict=None)
 
 set_parameters (self, parameters)
 

Public Attributes

 criterion = nn.Softplus()
 
 adv_temperature = nn.Parameter(torch.Tensor([adv_temperature]))
 
bool adv_flag = True
 
int adv_flag = -1)
 
- Public Attributes inherited from OpenKE.module.BaseModule.BaseModule
 zero_const = nn.Parameter(torch.Tensor([0]))
 
 pi_const = nn.Parameter(torch.Tensor([3.14159265358979323846]))
 

Constructor & Destructor Documentation

◆ __init__()

OpenKE.module.loss.SoftplusLoss.SoftplusLoss.__init__ ( self,
adv_temperature = None )

Reimplemented from OpenKE.module.loss.Loss.Loss.


The documentation for this class was generated from the following file: