TensorPlay
API symbols_shape_funcs
Copy
View Markdown

tensorplay._shape_funcs.block_diag

tensorplay._shape_funcs.block_diag(*tensors)[source]

Builds a block diagonal matrix from the given blocks.

0-D blocks become 1x1 matrices and 1-D blocks become diagonal

On this page

Ask DeepWiki