Loading [MathJax]/jax/output/HTML-CSS/config.js
MSE-CNN Implementation 1
Code database with the implementation of MSE-CNN, from the paper 'DeepQTMT: A Deep Learning Approach for Fast QTMT-based CU Partition of Intra-mode VVC'
All Classes Namespaces Files Functions Variables Pages
Public Member Functions | Public Attributes | List of all members
msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios Class Reference
Inheritance diagram for msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios:

Public Member Functions

 __init__ (self, pm, use_mod_cross_entropy=True, beta=1, alpha=0.5)
 
 get_proportion_CUs (self, labels)
 This function returns the proportion of CU's for all the types of split mode.
 
 get_min_RDs (self, RDs)
 Obtain the lowest value that isnt zero from RDs tensor.
 
 remove_values_lower (self, tensor, max_val, subst_val)
 Remove values from tensor that are lower than a given value.
 
 remove_inf_values (self, tensor)
 Remove values from tensor that are inf and make them zeros.
 
 remove_zero (self, RDs)
 Substitutes the zeros values for big RD values.
 
 remove_values_above (self, RDs, max_val)
 Substitutes values above MAX_RD for the MAX_RD.
 
 forward (self, pred, labels, RD)
 This function implements the loss function.
 

Public Attributes

 beta
 
 alpha
 
 pm
 
 use_mod_cross_entropy
 
 MAX_RD
 
 MAX_LOSS
 
 last_loss
 
 last_pred
 
 last_RD
 

Constructor & Destructor Documentation

◆ __init__()

msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios.__init__ (   self,
  pm,
  use_mod_cross_entropy = True,
  beta = 1,
  alpha = 0.5 
)

Member Function Documentation

◆ forward()

msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios.forward (   self,
  pred,
  labels,
  RD 
)

This function implements the loss function.

Parameters
[in]predPredictions made by the model
[in]labelsGround-truth tensor
[in]RDRate distortion tensor
[out]lossVector of raw predictions that a classification model generates

◆ get_min_RDs()

msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios.get_min_RDs (   self,
  RDs 
)

Obtain the lowest value that isnt zero from RDs tensor.

Parameters
[in]RDsTensor with RDs
[out]min_RDLowest value of RDs that isnt zero

◆ get_proportion_CUs()

msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios.get_proportion_CUs (   self,
  labels 
)

This function returns the proportion of CU's for all the types of split mode.

Parameters
[in]labelsGround truth tensor
[out]p_mTensor with the proportions

◆ remove_inf_values()

msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios.remove_inf_values (   self,
  tensor 
)

Remove values from tensor that are inf and make them zeros.

Parameters
[in]tensorTensor with values
[out]tensorNew tensor

◆ remove_values_above()

msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios.remove_values_above (   self,
  RDs,
  max_val 
)

Substitutes values above MAX_RD for the MAX_RD.

Parameters
[in]RDsTensor with RDs
[in]max_valMax value to add
[out]clone_RDsTensor With Max values added

◆ remove_values_lower()

msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios.remove_values_lower (   self,
  tensor,
  max_val,
  subst_val 
)

Remove values from tensor that are lower than a given value.

Parameters
[in]tensorTensor with values
[in]max_valThreshold val
[in]subst_valMax value to replace the others
[out]tensorNew tensor

◆ remove_zero()

msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios.remove_zero (   self,
  RDs 
)

Substitutes the zeros values for big RD values.

Parameters
[in]RDsTensor with RDs
[out]RDsTensor With Max values added

Member Data Documentation

◆ alpha

msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios.alpha

◆ beta

msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios.beta

◆ last_loss

msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios.last_loss

◆ last_pred

msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios.last_pred

◆ last_RD

msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios.last_RD

◆ MAX_LOSS

msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios.MAX_LOSS

◆ MAX_RD

msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios.MAX_RD

◆ pm

msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios.pm

◆ use_mod_cross_entropy

msecnn_raulkviana.msecnn.LossFunctionMSE_Ratios.use_mod_cross_entropy

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