You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If I try to follow the logic of the lines 155-157, it seems natural to me that line 157 should be:
-np.expand_dims(dx[-1, ], axis=0)),
As if continuing what was taking place in line 156 and then subtracting the final row of the array from zero. But, this reasoning does not quite hold, because in this case dx[-1, ] - dx[-2, ] is not computed anywhere and it does not seem to make sense to skip that. Based on that, I wonder if line 157 should instead be:
np.expand_dims(dx[-1, ] - dx[-2, ], axis=0)),
It is quite possible I am just completely mistaken, but if there is something wrong here, the following should be checked as well:
For sure, I understand the confusion... However I believe the code is correct. In this toolbox, divergence is defined as the - grad transposed. I just added this test:
I am going through the code in this package in detail as part of working on #13. Looking at the
operators.div
operator, I notice this:pyunlocbox/pyunlocbox/operators.py
Lines 155 to 158 in ee37c50
If I try to follow the logic of the lines 155-157, it seems natural to me that line 157 should be:
As if continuing what was taking place in line 156 and then subtracting the final row of the array from zero. But, this reasoning does not quite hold, because in this case
dx[-1, ] - dx[-2, ]
is not computed anywhere and it does not seem to make sense to skip that. Based on that, I wonder if line 157 should instead be:It is quite possible I am just completely mistaken, but if there is something wrong here, the following should be checked as well:
pyunlocbox/pyunlocbox/operators.py
Lines 167 to 170 in ee37c50
pyunlocbox/pyunlocbox/operators.py
Lines 179 to 182 in ee37c50
pyunlocbox/pyunlocbox/operators.py
Lines 191 to 194 in ee37c50
The text was updated successfully, but these errors were encountered: