DiSMEC++
dismec::prediction::AbandonmentAtK Class Reference

#include <metrics.h>

Inheritance diagram for dismec::prediction::AbandonmentAtK:
dismec::prediction::InstanceAveragedMetric dismec::prediction::MetricCollectionInterface

Public Member Functions

 AbandonmentAtK (long num_labels, long k)
 
void update (const pd_info_vec &prediction, const gt_info_vec &labels) override
 
std::unique_ptr< MetricCollectionInterfaceclone () const override
 
- Public Member Functions inherited from dismec::prediction::InstanceAveragedMetric
 InstanceAveragedMetric (long num_labels)
 
void reduce (const MetricCollectionInterface &other) override
 
double value () const
 
- Public Member Functions inherited from dismec::prediction::MetricCollectionInterface
 MetricCollectionInterface (long num_labels)
 
virtual ~MetricCollectionInterface ()=default
 
long num_labels () const
 Gets the number of labels. More...
 

Private Attributes

long m_K
 

Additional Inherited Members

- Public Types inherited from dismec::prediction::MetricCollectionInterface
using gt_info_vec = std::vector< sTrueLabelInfo >
 
using pd_info_vec = std::vector< sPredLabelInfo >
 
- Protected Member Functions inherited from dismec::prediction::InstanceAveragedMetric
void accumulate (double value)
 

Detailed Description

Definition at line 92 of file metrics.h.

Constructor & Destructor Documentation

◆ AbandonmentAtK()

AbandonmentAtK::AbandonmentAtK ( long  num_labels,
long  k 
)
explicit

Definition at line 147 of file metrics.cpp.

Member Function Documentation

◆ clone()

std::unique_ptr< MetricCollectionInterface > AbandonmentAtK::clone ( ) const
overridevirtual

◆ update()

void AbandonmentAtK::update ( const pd_info_vec prediction,
const gt_info_vec labels 
)
overridevirtual

Member Data Documentation

◆ m_K

long dismec::prediction::AbandonmentAtK::m_K
private

Definition at line 98 of file metrics.h.

Referenced by clone(), and update().


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