[XLA] Complex log1p(-1+0j) returns zero instead of -Inf on CPU and GPU
Maintainer antworten meist innerhalb von 2 Tagen
Bewertung
Dieses Issue wurde noch nicht bewertet.
Beschreibung
Issue type
Bug
Have you reproduced the bug with TensorFlow Nightly?
Yes
Source
binary
TensorFlow version
TensorFlow: 2.23.0-dev20261011
Custom code
Yes
OS platform and distribution
Ubuntu24.04
Mobile device
No response
Python version
3.11.15
Bazel version
No response
GCC/compiler version
No response
CUDA/cuDNN version
12.0.140
GPU model and memory
No response
Current behavior?
When compiling tf.math.log1p with XLA, the complex input -1+0j incorrectly produces 0+0j instead of a result with real part -Inf.
The issue reproduces on both CPU and GPU. Eager execution and non-XLA tf.function correctly preserve the logarithmic singularity.
Standalone code to reproduce the issue
import numpy as np
import tensorflow as tf
@tf.function(jit_compile=True)
def compiled(x):
return tf.math.log1p(x)
x = tf.constant([-1 + 0j], dtype=tf.complex64)
eager = tf.math.log1p(x).numpy()
xla = compiled(x).numpy()
print("eager:", eager)
print("XLA:", xla)
Relevant log output
eager: [-inf+nanj]
XLA: [0.+0.j]
- Vorherrschende Sprache
- C++
- Sterne
- 202k
- Forks
- 78k
- Ø Merge
- 2 T. 17 Std.
- Gemergte PRs (30 T.)
- 460
Entwicklungsumgebung
- Kein Dockerfile und keine Docker-Compose-Datei
- Keine Pull-Request-Vorlage
- Beitragsleitfaden lesen
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus tensorflow/tensorflow
-
tensorflowEvtl. vergeben @Venkat6871 hat das vor 1 Tag übernommen. Offencomp:runtime type:build/install
tensorflow/tensorflow#130510 · 1 zugewiesene Person ·
Maintainer antworten meist innerhalb von 2 Tagen
-
tf.image.image_gradients raises ValueError when tracing tf.function with unknown input rankEvtl. vergeben @Venkat6871 hat das vor 2 Tagen übernommen. Offen2.21.0 awaiting PR merge comp:ops type:bug
tensorflow/tensorflow#130492 · 1 zugewiesene Person ·
Maintainer antworten meist innerhalb von 2 Tagen
-
`tf.experimental.numpy.ravel` ignores `order` and `reshape` rejects NumPy's `shape` keywordEvtl. vergeben @Venkat6871 hat das vor 2 Tagen übernommen. Offen2.21.0 awaiting PR merge comp:apis comp:ops type:bug
tensorflow/tensorflow#130480 · 1 zugewiesene Person ·
Maintainer antworten meist innerhalb von 2 Tagen
-
`tf.experimental.numpy.pad` and `take_along_axis` require arguments that NumPy defaultsEvtl. vergeben @Venkat6871 hat das vor 2 Tagen übernommen. Offen2.21.0 awaiting PR merge comp:ops type:bug
tensorflow/tensorflow#130479 · 1 zugewiesene Person ·
Maintainer antworten meist innerhalb von 2 Tagen
-
`tf.experimental.numpy.roll` rejects a sequence of shifts and any non-int scalar shiftEvtl. vergeben @Venkat6871 hat das vor 2 Tagen übernommen. Offen2.21.0 awaiting PR merge comp:ops type:bug
tensorflow/tensorflow#130478 · 1 zugewiesene Person ·
Maintainer antworten meist innerhalb von 2 Tagen
Alle Issues in tensorflow/tensorflow
Ähnliche Issues
-
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 91/100
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 69/100
maplibre/maplibre-native#5072 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 79/100
tenstorrent/tt-umd#4017 ·
Maintainer antworten meist innerhalb von 3 Tagen
-
difficulty:easy func:gui prio:low type:bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
NatronGitHub/Natron#1538 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
hyprwm/hyprsunset#103 · 1 Kommentar ·