Number of elements in the array. Equal to ``np.prod(a.shape)``, i.e., the product of the array’s dimensions. See Also -------- numpy.ndarray.size
(self)
| 414 | |
| 415 | @property |
| 416 | def size(self) -> _IntOrUnknown: |
| 417 | """ |
| 418 | Number of elements in the array. |
| 419 | |
| 420 | Equal to ``np.prod(a.shape)``, i.e., the product of the array’s dimensions. |
| 421 | |
| 422 | See Also |
| 423 | -------- |
| 424 | numpy.ndarray.size |
| 425 | """ |
| 426 | return math.prod(self.shape) |
| 427 | |
| 428 | def __len__(self) -> _IntOrUnknown: |
| 429 | try: |