This is an automated email from the ASF dual-hosted git repository.

tqchen pushed a commit to branch 
tvm-ffi-fix-sphinx-autosummary-warnings-for-tensor-methods-in-docs-reference-python-index-rst
in repository https://gitbox.apache.org/repos/asf/tvm-ffi.git

commit d62818cc2038ee8b912933279d388d62bdc0b74d
Author: tqchen <[email protected]>
AuthorDate: Fri Jun 5 17:19:09 2026 +0000

    [DOC] Move tensor methods (ndim, numel, size, is_contiguous) under Tensor 
autosummary
    
    PR #604 added ndim, numel, size, is_contiguous as methods/properties on
    tvm_ffi.Tensor, but listed them as bare names in the top-level autosummary
    block, causing sphinx to look for tvm_ffi.ndim etc. (which don't exist):
    
        docs/reference/python/index.rst:41: WARNING: autosummary: failed to 
import ndim.
        ... (same for numel, size, is_contiguous)
    
    Fix: qualify the four entries as Tensor.ndim, Tensor.numel, Tensor.size,
    Tensor.is_contiguous so that sphinx resolves them as tvm_ffi.Tensor.* under
    the existing .. currentmodule:: tvm_ffi directive. No other changes.
---
 docs/reference/python/index.rst | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/docs/reference/python/index.rst b/docs/reference/python/index.rst
index 33881c0..ac499b4 100644
--- a/docs/reference/python/index.rst
+++ b/docs/reference/python/index.rst
@@ -48,10 +48,10 @@ Tensor
   Device
   DLDeviceType
   device
-  ndim
-  numel
-  size
-  is_contiguous
+  Tensor.ndim
+  Tensor.numel
+  Tensor.size
+  Tensor.is_contiguous
 
 Function
 ~~~~~~~~

Reply via email to