Skip to content

Commit 456cfba

Browse files
Merge pull request #2039 from mhavasi:patch-1
PiperOrigin-RevId: 431021958
2 parents c25295f + b48a1fd commit 456cfba

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

site/en/tutorials/interpretability/integrated_gradients.ipynb

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -904,8 +904,8 @@
904904
" gradient_batch = one_batch(baseline, image, alpha_batch, target_class_idx)\n",
905905
" gradient_batches.append(gradient_batch)\n",
906906
" \n",
907-
" # Stack path gradients together row-wise into single tensor.\n",
908-
" total_gradients = tf.stack(gradient_batch)\n",
907+
" # Concatenate path gradients together row-wise into single tensor.\n",
908+
" total_gradients = tf.concat(gradient_batches, axis=0)\n",
909909
"\n",
910910
" # Integral approximation through averaging gradients.\n",
911911
" avg_gradients = integral_approximation(gradients=total_gradients)\n",
@@ -1151,7 +1151,6 @@
11511151
"colab": {
11521152
"collapsed_sections": [],
11531153
"name": "integrated_gradients.ipynb",
1154-
"private_outputs": true,
11551154
"toc_visible": true
11561155
},
11571156
"kernelspec": {

0 commit comments

Comments
 (0)