{ } Raw JSON

bundles / numpy 2.4.4 / numpy / _core / einsumfunc / _compute_size_by_dict

function

numpy._core.einsumfunc:_compute_size_by_dict

source: /numpy/_core/einsumfunc.py :61

Signature

def   _compute_size_by_dict ( indices idx_dict )

Summary

Computes the product of the elements in indices based on the dictionary idx_dict.

Parameters

indices : iterable

Indices to base the product on.

idx_dict : dictionary

Dictionary of index sizes

Returns

ret : int

The resulting product.

Examples

_compute_size_by_dict('abbc', {'a': 2, 'b':3, 'c':5})

Aliases

  • numpy._core.einsumfunc._compute_size_by_dict