TrivialEstimator<TTransformer> Classe

Definizione

L'implementazione semplice di IEstimator<TTransformer> che ha già il trasformatore e lo restituisce su ogni chiamata a Fit(IDataView).

Le implementazioni concrete devono comunque fornire il meccanismo di propagazione dello schema, poiché non esiste un modo semplice per dedurrlo dal trasformatore.

public abstract class TrivialEstimator<TTransformer> : Microsoft.ML.IEstimator<TTransformer> where TTransformer : class, ITransformer
type TrivialEstimator<'ransformer (requires 'ransformer : null and 'ransformer :> ITransformer)> = class
    interface IEstimator<'ransformer (requires 'ransformer : null and 'ransformer :> ITransformer)>
Public MustInherit Class TrivialEstimator(Of TTransformer)
Implements IEstimator(Of TTransformer)

Parametri di tipo

TTransformer
Ereditarietà
TrivialEstimator<TTransformer>
Derivato
Implementazioni

Metodi

Fit(IDataView)

L'implementazione semplice di IEstimator<TTransformer> che ha già il trasformatore e lo restituisce su ogni chiamata a Fit(IDataView).

Le implementazioni concrete devono comunque fornire il meccanismo di propagazione dello schema, poiché non esiste un modo semplice per dedurrlo dal trasformatore.

GetOutputSchema(SchemaShape)

L'implementazione semplice di IEstimator<TTransformer> che ha già il trasformatore e lo restituisce su ogni chiamata a Fit(IDataView).

Le implementazioni concrete devono comunque fornire il meccanismo di propagazione dello schema, poiché non esiste un modo semplice per dedurrlo dal trasformatore.

Metodi di estensione

AppendCacheCheckpoint<TTrans>(IEstimator<TTrans>, IHostEnvironment)

Aggiungere un "checkpoint di memorizzazione nella cache" alla catena di stima. Ciò garantisce che gli estimatori downstream vengano sottoposti a training sui dati memorizzati nella cache. È utile avere un checkpoint di memorizzazione nella cache prima dei training che accettano più passaggi di dati.

WithOnFitDelegate<TTransformer>(IEstimator<TTransformer>, Action<TTransformer>)

Dato un stimatore, restituire un oggetto wrapping che chiamerà un delegato una volta Fit(IDataView) chiamato. Spesso è importante che un stimatore restituisca informazioni su ciò che è stato adatto, che è il motivo per cui il Fit(IDataView) metodo restituisce un oggetto tipizzato in modo specifico, anziché solo un oggetto generale ITransformer. Tuttavia, allo stesso tempo, IEstimator<TTransformer> sono spesso formati in pipeline con molti oggetti, quindi potrebbe essere necessario creare una catena di stima tramite EstimatorChain<TLastTransformer> dove lo stimatore per cui si vuole ottenere il trasformatore è sepolto da qualche parte in questa catena. Per questo scenario, è possibile collegare questo metodo a un delegato che verrà chiamato una volta chiamato fit.

Si applica a