Skip to content

Commit a071216

Browse files
set 5 as default value in opnorm_maxiter
1 parent 4566840 commit a071216

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/R2N.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ For advanced usage, first define a solver "R2NSolver" to preallocate the memory
139139
- `η2::T = T(0.9)`: very successful iteration threshold;
140140
- `γ::T = T(3)`: regularization parameter multiplier, σ := σ/γ when the iteration is very successful and σ := σγ when the iteration is unsuccessful;
141141
- `θ::T = 1/(1 + eps(T)^(1 / 5))`: is the model decrease fraction with respect to the decrease of the Cauchy model;
142-
- `opnorm_maxiter::Int = 1`: how many iterations of the power method to use to compute the operator norm of Bₖ. If a negative number is provided, then Arpack is used instead;
142+
- `opnorm_maxiter::Int = 5`: how many iterations of the power method to use to compute the operator norm of Bₖ. If a negative number is provided, then Arpack is used instead;
143143
- `m_monotone::Int = 1`: monotonicity parameter. By default, R2N is monotone but the non-monotone variant will be used if `m_monotone > 1`;
144144
- `sub_kwargs::NamedTuple = NamedTuple()`: a named tuple containing the keyword arguments to be sent to the subsolver. The solver will fail if invalid keyword arguments are provided to the subsolver. For example, if the subsolver is `R2Solver`, you can pass `sub_kwargs = (max_iter = 100, σmin = 1e-6,)`.
145145
@@ -231,7 +231,7 @@ function SolverCore.solve!(
231231
γ::T = T(3),
232232
β::T = 1 / eps(T),
233233
θ::T = 1/(1 + eps(T)^(1 / 5)),
234-
opnorm_maxiter::Int = 1,
234+
opnorm_maxiter::Int = 5,
235235
sub_kwargs::NamedTuple = NamedTuple(),
236236
) where {T, V, G}
237237
reset!(stats)

src/TR_alg.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ For advanced usage, first define a solver "TRSolver" to preallocate the memory u
134134
- `η1::T = √√eps(T)`: successful iteration threshold;
135135
- `η2::T = T(0.9)`: very successful iteration threshold;
136136
- `γ::T = T(3)`: trust-region radius parameter multiplier. Must satisfy `γ > 1`. The trust-region radius is updated as Δ := Δ*γ when the iteration is very successful and Δ := Δ/γ when the iteration is unsuccessful;
137-
- `opnorm_maxiter::Int = 1`: how many iterations of the power method to use to compute the operator norm of Bₖ. If a negative number is provided, then Arpack is used instead;
137+
- `opnorm_maxiter::Int = 5`: how many iterations of the power method to use to compute the operator norm of Bₖ. If a negative number is provided, then Arpack is used instead;
138138
- `χ::F = NormLinf(1)`: norm used to define the trust-region;`
139139
- `subsolver::S = R2Solver`: subsolver used to solve the subproblem that appears at each iteration.
140140
- `sub_kwargs::NamedTuple = NamedTuple()`: a named tuple containing the keyword arguments to be sent to the subsolver. The solver will fail if invalid keyword arguments are provided to the subsolver. For example, if the subsolver is `R2Solver`, you can pass `sub_kwargs = (max_iter = 100, σmin = 1e-6,)`.
@@ -207,7 +207,7 @@ function SolverCore.solve!(
207207
η2::T = T(0.9),
208208
γ::T = T(3),
209209
sub_kwargs::NamedTuple = NamedTuple(),
210-
opnorm_maxiter::Int = 1,
210+
opnorm_maxiter::Int = 5,
211211
) where {T, G, V}
212212
reset!(stats)
213213

0 commit comments

Comments
 (0)