Documentation ¶
Index ¶
- func LoadForCmd(cmd *cobra.Command, opts *Options)
- func New(opts ...ModelOption) (model.Model, error)
- func NewForOptions(opts Options) (model.Model, error)
- type ModelOption
- func ToLower() ModelOption
- func Verbose() ModelOption
- func WithBatchSize(v int) ModelOption
- func WithDimension(v int) ModelOption
- func WithInitLearningRate(v float64) ModelOption
- func WithIteration(v int) ModelOption
- func WithMaxDepth(v int) ModelOption
- func WithMinCount(v int) ModelOption
- func WithModel(typ ModelType) ModelOption
- func WithNegativeSampleSize(v int) ModelOption
- func WithOptimizer(typ OptimizerType) ModelOption
- func WithSubsampleThreshold(v float64) ModelOption
- func WithTheta(v float64) ModelOption
- func WithThreadSize(v int) ModelOption
- func WithWindow(v int) ModelOption
- type ModelType
- type OptimizerType
- type Options
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LoadForCmd ¶
Types ¶
type ModelOption ¶
type ModelOption func(*Options)
func ToLower ¶
func ToLower() ModelOption
func Verbose ¶
func Verbose() ModelOption
func WithDimension ¶
func WithDimension(v int) ModelOption
func WithInitLearningRate ¶
func WithInitLearningRate(v float64) ModelOption
func WithIteration ¶
func WithIteration(v int) ModelOption
func WithModel ¶
func WithModel(typ ModelType) ModelOption
func WithNegativeSampleSize ¶
func WithNegativeSampleSize(v int) ModelOption
func WithOptimizer ¶
func WithOptimizer(typ OptimizerType) ModelOption
func WithSubsampleThreshold ¶
func WithSubsampleThreshold(v float64) ModelOption
func WithTheta ¶
func WithTheta(v float64) ModelOption
func WithThreadSize ¶
func WithThreadSize(v int) ModelOption
func WithWindow ¶
func WithWindow(v int) ModelOption
type OptimizerType ¶
type OptimizerType string
const ( NegativeSampling OptimizerType = "ns" HierarchicalSoftmax OptimizerType = "hs" )
func (*OptimizerType) Set ¶
func (t *OptimizerType) Set(name string) error
func (*OptimizerType) String ¶
func (t *OptimizerType) String() string
func (*OptimizerType) Type ¶
func (t *OptimizerType) Type() string
Click to show internal directories.
Click to hide internal directories.