Skip to content

Commit 667ea6d

Browse files
author
Francisco Muñoz
committed
docs: add comments with the reason of the error
1 parent b0c5ef3 commit 667ea6d

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

ot/bregman/_convolutional.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -246,6 +246,8 @@ def _convolutional_barycenter2d_log(
246246
A = list_to_array(A)
247247

248248
nx = get_backend(A)
249+
# This error is raised because we are using mutable assignment in the line
250+
# `log_KU[k] = ...` which is not allowed in Jax and TF.
249251
if nx.__name__ in ("jax", "tf"):
250252
raise NotImplementedError(
251253
"Log-domain functions are not yet implemented"
@@ -483,6 +485,8 @@ def _convolutional_barycenter2d_debiased_log(
483485
A = list_to_array(A)
484486
n_hists, width, height = A.shape
485487
nx = get_backend(A)
488+
# This error is raised because we are using mutable assignment in the line
489+
# `log_KU[k] = ...` which is not allowed in Jax and TF.
486490
if nx.__name__ in ("jax", "tf"):
487491
raise NotImplementedError(
488492
"Log-domain functions are not yet implemented"

0 commit comments

Comments
 (0)