From f3589b6793afad0769350f6b78548d591dd11cdd Mon Sep 17 00:00:00 2001 From: Brendt Wohlberg Date: Tue, 24 Oct 2023 09:21:09 -0600 Subject: [PATCH] Simplify conditional --- scico/numpy/util.py | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/scico/numpy/util.py b/scico/numpy/util.py index c91ce998b..90620dc92 100644 --- a/scico/numpy/util.py +++ b/scico/numpy/util.py @@ -334,8 +334,4 @@ def is_scalar_equiv(s: Any) -> bool: ``True`` if the object is a scalar or a singleton array, otherwise ``False``. """ - return ( - snp.isscalar(s) - or isinstance(s, jax.core.Tracer) - or (isinstance(s, jax.Array) and s.ndim == 0) - ) + return snp.isscalar(s) or (isinstance(s, jax.Array) and s.ndim == 0)