Newer
Older
Cédric Traizet
committed
#ifndef AutoencoderModelFactory_h
#define AutoencoderModelFactory_h

Guillaume Pasero
committed
//#include <shark/Models/TiedAutoencoder.h>
//#include <shark/Models/Autoencoder.h>
Cédric Traizet
committed
#include "itkObjectFactoryBase.h"
Cédric Traizet
committed
#include "itkImageIOBase.h"
Cédric Traizet
committed
namespace otb
{
template <class TInputValue, class TTargetValue, class NeuronType>
Cédric Traizet
committed
class ITK_EXPORT AutoencoderModelFactoryBase : public itk::ObjectFactoryBase
Cédric Traizet
committed
{
public:
/** Standard class typedefs. */
Cédric Traizet
committed
typedef AutoencoderModelFactoryBase Self;
Cédric Traizet
committed
typedef itk::ObjectFactoryBase Superclass;
typedef itk::SmartPointer<Self> Pointer;
typedef itk::SmartPointer<const Self> ConstPointer;
/** Class methods used to interface with the registered factories. */
const char* GetITKSourceVersion(void) const ITK_OVERRIDE;
const char* GetDescription(void) const ITK_OVERRIDE;
/** Method for class instantiation. */
itkFactorylessNewMacro(Self);
/** Run-time type information (and related methods). */
Cédric Traizet
committed
itkTypeMacro(AutoencoderModelFactoryBase, itk::ObjectFactoryBase);
Cédric Traizet
committed
/** Register one factory of this type */
static void RegisterOneFactory(void)
{
Cédric Traizet
committed
Pointer AEFactory = AutoencoderModelFactoryBase::New();
Cédric Traizet
committed
itk::ObjectFactoryBase::RegisterFactory(AEFactory);
Cédric Traizet
committed
}
protected:
Cédric Traizet
committed
AutoencoderModelFactoryBase();
~AutoencoderModelFactoryBase() ITK_OVERRIDE;
Cédric Traizet
committed
private:
Cédric Traizet
committed
AutoencoderModelFactoryBase(const Self &); //purposely not implemented
Cédric Traizet
committed
void operator =(const Self&); //purposely not implemented
};
Cédric Traizet
committed
Cédric Traizet
committed
template <class TInputValue, class TTargetValue>
using AutoencoderModelFactory = AutoencoderModelFactoryBase<TInputValue, TTargetValue, shark::Autoencoder< shark::TanhNeuron, shark::LinearNeuron>> ;
Cédric Traizet
committed
template <class TInputValue, class TTargetValue>
using TiedAutoencoderModelFactory = AutoencoderModelFactoryBase<TInputValue, TTargetValue, shark::TiedAutoencoder< shark::TanhNeuron, shark::LinearNeuron>> ;
*/
Cédric Traizet
committed
Cédric Traizet
committed
} //namespace otb
Cédric Traizet
committed
Cédric Traizet
committed
#ifndef OTB_MANUAL_INSTANTIATION
#include "otbAutoencoderModelFactory.txx"
Cédric Traizet
committed
#endif