Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
ift
NIFTy
Commits
478a37dd
Commit
478a37dd
authored
Apr 24, 2018
by
Reimar H Leike
Browse files
summarized computations in krylov sampling
parent
adc1eca5
Changes
1
Hide whitespace changes
Inline
Side-by-side
nifty4/library/krylov_sampling.py
View file @
478a37dd
...
...
@@ -65,8 +65,7 @@ def generate_krylov_samples(D_inv, S, j=None, N_samps=1, N_iter=10,
break
x
+=
gamma
*
p
for
i
in
range
(
N_samps
):
y
[
i
]
-=
p
.
vdot
(
D_inv
(
y
[
i
]))
*
p
/
d
y
[
i
]
+=
randn
()
/
sqrt
(
d
)
*
p
y
[
i
]
+=
(
randn
()
*
sqrt
(
d
)
-
p
.
vdot
(
D_inv
(
y
[
i
])))
/
d
*
p
r_new
=
r
-
gamma
*
D_inv
(
p
)
beta
=
r_new
.
vdot
(
r_new
)
/
r
.
vdot
(
r
)
r
=
r_new
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment