Skip to content

Commit bc1d91a

Browse files
committed
Merge pull request #8 from nico/master
Fix ROF code.
2 parents 7635885 + 88e8112 commit bc1d91a

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

PCV/tools/rof.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ def denoise(im,U_init,tolerance=0.1,tau=0.125,tv_weight=100):
1515

1616
# initialize
1717
U = U_init
18-
Px = im #x-component to the dual field
19-
Py = im #y-component of the dual field
18+
Px = zeros((m, n)) #x-component to the dual field
19+
Py = zeros((m, n)) #y-component of the dual field
2020
error = 1
2121

2222
while (error > tolerance):

pcv_book/rof.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ def denoise(im,U_init,tolerance=0.1,tau=0.125,tv_weight=100):
1515

1616
# initialize
1717
U = U_init
18-
Px = im #x-component to the dual field
19-
Py = im #y-component of the dual field
18+
Px = zeros((m, n)) #x-component to the dual field
19+
Py = zeros((m, n)) #y-component of the dual field
2020
error = 1
2121

2222
while (error > tolerance):

0 commit comments

Comments
 (0)