Skip to content

Commit 7baee63

Browse files
🤖 Format .jl files (#234)
Co-authored-by: tmigot <[email protected]>
1 parent d5e5753 commit 7baee63

File tree

2 files changed

+15
-10
lines changed

2 files changed

+15
-10
lines changed

src/trust-region/tron-trust-region.jl

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,8 @@ function aredpred!(
9595
slope::T;
9696
kwargs...,
9797
) where {T, V}
98-
ared, pred, tr.good_grad = aredpred_common(nlp, f, f_trial, Δm, x_trial, step, tr.gt, slope; kwargs...)
98+
ared, pred, tr.good_grad =
99+
aredpred_common(nlp, f, f_trial, Δm, x_trial, step, tr.gt, slope; kwargs...)
99100
γ = f_trial - f - slope
100101
tr.quad_min = γ <= 0 ? tr.increase_factor : max(tr.large_decrease_factor, -slope / γ / 2)
101102
return ared, pred
@@ -110,7 +111,7 @@ function aredpred!(
110111
x_trial::V,
111112
step::V,
112113
slope::T;
113-
kwargs...
114+
kwargs...,
114115
) where {T, V}
115116
Fx = similar(x_trial, nls.nls_meta.nequ)
116117
return aredpred!(tr, nls, Fx, f, f_trial, Δm, x_trial, step, slope; kwargs...)
@@ -126,9 +127,10 @@ function aredpred!(
126127
x_trial::V,
127128
step::V,
128129
slope::T;
129-
kwargs...
130+
kwargs...,
130131
) where {T, V}
131-
ared, pred, tr.good_grad = aredpred_common(nls, Fx, f, f_trial, Δm, x_trial, step, tr.gt, slope; kwargs...)
132+
ared, pred, tr.good_grad =
133+
aredpred_common(nls, Fx, f, f_trial, Δm, x_trial, step, tr.gt, slope; kwargs...)
132134
γ = f_trial - f - slope
133135
tr.quad_min = γ <= 0 ? tr.increase_factor : max(tr.large_decrease_factor, -slope / γ / 2)
134136
return ared, pred

src/trust-region/trust-region.jl

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -117,9 +117,10 @@ function aredpred!(
117117
x_trial::V,
118118
step::V,
119119
slope::T;
120-
kwargs...
120+
kwargs...,
121121
) where {T, V}
122-
ared, pred, tr.good_grad = aredpred_common(nlp, f, f_trial, Δm, x_trial, step, tr.gt, slope; kwargs...)
122+
ared, pred, tr.good_grad =
123+
aredpred_common(nlp, f, f_trial, Δm, x_trial, step, tr.gt, slope; kwargs...)
123124
return ared, pred
124125
end
125126

@@ -132,10 +133,11 @@ function aredpred!(
132133
x_trial::V,
133134
step::V,
134135
slope::T;
135-
kwargs...
136+
kwargs...,
136137
) where {T, V}
137138
Fx = similar(x_trial, nls.nls_meta.nequ)
138-
ared, pred, tr.good_grad = aredpred_common(nls, Fx, f, f_trial, Δm, x_trial, step, tr.gt, slope; kwargs...)
139+
ared, pred, tr.good_grad =
140+
aredpred_common(nls, Fx, f, f_trial, Δm, x_trial, step, tr.gt, slope; kwargs...)
139141
return ared, pred
140142
end
141143

@@ -149,9 +151,10 @@ function aredpred!(
149151
x_trial::V,
150152
step::V,
151153
slope::T;
152-
kwargs...
154+
kwargs...,
153155
) where {T, V}
154-
ared, pred, tr.good_grad = aredpred_common(nls, Fx, f, f_trial, Δm, x_trial, step, tr.gt, slope; kwargs...)
156+
ared, pred, tr.good_grad =
157+
aredpred_common(nls, Fx, f, f_trial, Δm, x_trial, step, tr.gt, slope; kwargs...)
155158
return ared, pred
156159
end
157160

0 commit comments

Comments
 (0)