This is a pre-release version (2.0.0.dev0+git20260907.41eeb59).Go to latest (1.18.0)
{ } Raw JSON

bundles / scipy 2.0.0.dev0+git20260907.41eeb59 / scipy / _external / array_api_extra / _lib / _utils / _helpers / eager_shape

function

scipy._external.array_api_extra._lib._utils._helpers:eager_shape

source: build-install/usr/lib/python3.14/site-packages/scipy/_external/array_api_extra/_lib/_utils/_helpers.py:251

Signature

def eager_shape(x: Array, /, axis: int | None = None) → tuple[int, ...]

Summary

Return shape of an array. Raise if shape is not fully defined.

Parameters

x : Array

Input array.

axis : int, optional

If provided, only returns the tuple (shape[axis],).

Returns

: tuple[int, ...]

Shape of the array.

Aliases

  • scipy.differentiate.xpx._delegation.eager_shape