TensorPlay

Latest development documentation · Updated 2026-09-08. A documentation snapshot for package 1.0.0.dev20260909 is not available.

On this page

tensorplay.is_tensor

tensorplay.is_tensor(obj: Any, /) TypeIs[TensorBase][source]

Returns True if obj is a TensorPlay tensor.

Note that this function is simply doing isinstance(obj, Tensor). Using that isinstance check is better for type checking with mypy, and more explicit - so it’s recommended to use that instead of is_tensor.

Parameters:

obj (object) – Object to test

Example:

>>> x = tensorplay.tensor([1, 2, 3])
>>> tensorplay.is_tensor(x)
True

Search documentation

Search all 1,743 documentation pages.

Keyboard shortcuts

Global

  • /Focus search
  • ?This dialog
  • ,Open settings
  • jAI assistant

Search

  • Navigate results
  • Open result
  • escClose

Package

  • mMain information
  • dDocs
  • .Code
  • -Changelog
  • tTimeline
  • sStats
  • vVersions