Documentation ¶
Overview ¶
-*- mode: go; -*- * * Copyright (C) 2019-2020 Philipp Benner * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see <http://www.gnu.org/licenses/>.
-*- mode: go; -*- * * Copyright (C) 2019-2020 Philipp Benner * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see <http://www.gnu.org/licenses/>.
Index ¶
- func EvalStopping(xs, x1 DenseFloat64Vector, epsilon float64) (bool, float64, error)
- func Run(f interface{}, n int, x Vector, args ...interface{}) (Vector, int64, error)
- type ConstGradientDense
- type ConstGradientSparse
- type Epsilon
- type Gamma
- type GradientDense
- type GradientJit
- type GradientSparse
- type Hook
- type InSitu
- type JitUpdate
- type JitUpdateL1
- type JitUpdateType
- type L1Regularization
- type L2Regularization
- type MaxIterations
- type Objective1Dense
- type Objective1Sparse
- type Objective2Dense
- type Objective2Sparse
- type ProximalOperator
- type ProximalOperatorL1
- type ProximalOperatorL2
- type ProximalOperatorTi
- type ProximalOperatorType
- type Seed
- type TikhonovRegularization
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EvalStopping ¶
Types ¶
type ConstGradientDense ¶
type ConstGradientDense struct {
// contains filtered or unexported fields
}
--------------------------------------------------------------------------
type ConstGradientSparse ¶
type ConstGradientSparse struct {
// contains filtered or unexported fields
}
--------------------------------------------------------------------------
type GradientDense ¶
type GradientDense struct {
// contains filtered or unexported fields
}
--------------------------------------------------------------------------
type GradientJit ¶
type GradientJit struct { G SparseConstFloat64Vector W float64 }
func (GradientJit) Add ¶
func (obj GradientJit) Add(v DenseFloat64Vector)
func (*GradientJit) Set ¶
func (obj *GradientJit) Set(w float64, g SparseConstFloat64Vector)
func (GradientJit) Update ¶
func (obj GradientJit) Update(g2 GradientJit, v DenseFloat64Vector)
type GradientSparse ¶
type GradientSparse struct {
// contains filtered or unexported fields
}
--------------------------------------------------------------------------
type JitUpdate ¶
type JitUpdate struct {
Value JitUpdateType
}
type JitUpdateL1 ¶
type JitUpdateL1 struct {
Lambda float64
}
func (*JitUpdateL1) GetLambda ¶
func (obj *JitUpdateL1) GetLambda() float64
func (*JitUpdateL1) SetLambda ¶
func (obj *JitUpdateL1) SetLambda(lambda float64)
type JitUpdateType ¶
type L1Regularization ¶
type L1Regularization struct {
Value float64
}
type L2Regularization ¶
type L2Regularization struct {
Value float64
}
type MaxIterations ¶
type MaxIterations struct {
Value int
}
type Objective1Dense ¶
-------------------------------------------------------------------------- --------------------------------------------------------------------------
type Objective1Sparse ¶
type Objective1Sparse func(int, DenseFloat64Vector) (float64, float64, SparseConstFloat64Vector, error)
-------------------------------------------------------------------------- --------------------------------------------------------------------------
type Objective2Dense ¶
func WrapperDense ¶
func WrapperDense(f func(int, Vector, MagicScalar) error) Objective2Dense
type Objective2Sparse ¶
type ProximalOperator ¶
type ProximalOperator struct {
Value ProximalOperatorType
}
type ProximalOperatorL1 ¶
type ProximalOperatorL1 struct {
Lambda float64
}
func (*ProximalOperatorL1) Eval ¶
func (obj *ProximalOperatorL1) Eval(x DenseFloat64Vector, w DenseFloat64Vector)
func (*ProximalOperatorL1) GetLambda ¶
func (obj *ProximalOperatorL1) GetLambda() float64
func (*ProximalOperatorL1) SetLambda ¶
func (obj *ProximalOperatorL1) SetLambda(lambda float64)
type ProximalOperatorL2 ¶
type ProximalOperatorL2 struct {
Lambda float64
}
func (*ProximalOperatorL2) Eval ¶
func (obj *ProximalOperatorL2) Eval(x DenseFloat64Vector, w DenseFloat64Vector)
func (*ProximalOperatorL2) GetLambda ¶
func (obj *ProximalOperatorL2) GetLambda() float64
func (*ProximalOperatorL2) SetLambda ¶
func (obj *ProximalOperatorL2) SetLambda(lambda float64)
type ProximalOperatorTi ¶
type ProximalOperatorTi struct {
Lambda float64
}
func (*ProximalOperatorTi) Eval ¶
func (obj *ProximalOperatorTi) Eval(x DenseFloat64Vector, w DenseFloat64Vector)
func (*ProximalOperatorTi) GetLambda ¶
func (obj *ProximalOperatorTi) GetLambda() float64
func (*ProximalOperatorTi) SetLambda ¶
func (obj *ProximalOperatorTi) SetLambda(lambda float64)
type ProximalOperatorType ¶
type TikhonovRegularization ¶
type TikhonovRegularization struct {
Value float64
}