ModErn Text Analysis
META Enumerates Textual Applications
Private Member Functions | Private Attributes | List of all members
meta::classify::loss::loss_function_factory Class Reference

Factory that is responsible for creating loss functions from strings. More...

#include <loss_function_factory.h>

Inheritance diagram for meta::classify::loss::loss_function_factory:
meta::util::factory< loss_function_factory, loss_function >

Private Member Functions

 loss_function_factory ()
 Constructs the loss_function_factory singleton.
 
template<class Loss >
void reg ()
 Registers a loss function. More...
 

Private Attributes

friend base_factory
 

Additional Inherited Members

- Public Types inherited from meta::util::factory< loss_function_factory, loss_function >
using base_factory = factory
 Convenience typedef for the derived classes.
 
using pointer = std::unique_ptr< loss_function >
 The return type for the create method.
 
using factory_method = std::function< pointer(Arguments...)>
 Convenience typedef for the factory methods used to create objects.
 
- Public Member Functions inherited from meta::util::factory< loss_function_factory, loss_function >
void add (const std::string &identifier, Function &&fn)
 Associates the given identifier with the given factory method. More...
 
pointer create (const std::string &identifier, Args &&...args)
 Creates a new object based on the factory method parameters. More...
 
- Static Public Member Functions inherited from meta::util::factory< loss_function_factory, loss_function >
static loss_function_factory & get ()
 Obtains the singleton. More...
 

Detailed Description

Factory that is responsible for creating loss functions from strings.

Clients should use the register_loss_function method instead of this class directly to add their own loss functions.

Member Function Documentation

template<class Loss >
void meta::classify::loss::loss_function_factory::reg ( )
private

Registers a loss function.

Used internally.


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