Skip to content

Commit

Permalink
error fix
Browse files Browse the repository at this point in the history
  • Loading branch information
smribet committed Sep 26, 2024
1 parent 6d2efd3 commit d6a6f54
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions py4DSTEM/tomography/tomography.py
Original file line number Diff line number Diff line change
Expand Up @@ -1323,7 +1323,6 @@ def _calculate_update(
if dp_patterns.shape[0] == 0:
update = xp.zeros(object_sliced.shape)

## TODO check this
error = xp.mean(object_sliced.ravel() ** 2)

error = copy_to_device(error, "cpu")
Expand Down Expand Up @@ -1380,9 +1379,7 @@ def _calculate_update(

update = dp_patterns_counted - object_sliced

error = xp.mean(update.ravel() ** 2) / xp.mean(
dp_patterns_counted.ravel() ** 2
)
error = xp.mean(update.ravel() ** 2)

error = copy_to_device(error, "cpu")

Expand Down

0 comments on commit d6a6f54

Please sign in to comment.