Skip to content

Commit

Permalink
Upgrade fbcode/pytorch to Python Scientific Stack 2 (pytorch#1387)
Browse files Browse the repository at this point in the history
Summary: Pull Request resolved: pytorch#1387

Differential Revision: D64008689
  • Loading branch information
igorsugak authored and facebook-github-bot committed Oct 18, 2024
1 parent b1e2fc8 commit 4338362
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions captum/attr/_utils/visualization.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ def _cumulative_sum_threshold(
sorted_vals = np.sort(values.flatten())
cum_sums = np.cumsum(sorted_vals)
threshold_id = np.where(cum_sums >= cum_sums[-1] * 0.01 * percentile)[0][0]
# pyre-fixme[7]: Expected `float` but got `ndarray[typing.Any, dtype[typing.Any]]`.
return sorted_vals[threshold_id]


Expand Down

0 comments on commit 4338362

Please sign in to comment.