pyrefly-numpy-stubs 1.4.0.dev2__py3-none-any.whl → 1.4.0.dev3__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
numpy-stubs/__init__.pyi CHANGED
@@ -377,7 +377,6 @@ from numpy.matrixlib import (
377
377
  )
378
378
  from shape_extensions import (
379
379
  broadcast as _broadcast_shape,
380
- Elements,
381
380
  Flag,
382
381
  Index,
383
382
  index_shape,
@@ -496,7 +495,7 @@ class ndarray[Shape: _Shape = _Shape, DType = Any]:
496
495
  @real.setter
497
496
  def real(self, value: Any) -> None: ...
498
497
  def __len__[N: IntVar, Rest: _Shape = []](
499
- self: ndarray[[N, *Elements[Rest]]],
498
+ self: ndarray[[N, *Rest]],
500
499
  ) -> Int[N]: ...
501
500
  @overload
502
501
  def __getitem__[
@@ -527,8 +526,8 @@ class ndarray[Shape: _Shape = _Shape, DType = Any]:
527
526
  def __setitem__(self, key: _ArrayIndex, value: ArrayLike, /) -> None: ...
528
527
  @overload
529
528
  def __iter__[N: IntVar, M: IntVar, Rest: _Shape = []](
530
- self: ndarray[[N, M, *Elements[Rest]], DType], /
531
- ) -> Iterator[ndarray[[M, *Elements[Rest]], DType]]: ...
529
+ self: ndarray[[N, M, *Rest], DType], /
530
+ ) -> Iterator[ndarray[[M, *Rest], DType]]: ...
532
531
  # Iteration over one-dimensional arrays yields NumPy scalars.
533
532
  @overload
534
533
  def __iter__[N: IntVar](self: ndarray[[N], DType], /) -> Iterator[Any]: ...
@@ -542,48 +541,48 @@ class ndarray[Shape: _Shape = _Shape, DType = Any]:
542
541
  ) -> ndarray[[P, N], DType]: ...
543
542
  # Unpacking preserves gradual array shapes instead of using the scalar default.
544
543
  def __add__[OtherShape: _Shape = []](
545
- self, other: ndarray[[*Elements[OtherShape]]] | int | float
544
+ self, other: ndarray[[*OtherShape]] | int | float
546
545
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), DType]: ...
547
546
  def __radd__[OtherShape: _Shape = []](
548
- self, other: ndarray[[*Elements[OtherShape]]] | int | float
547
+ self, other: ndarray[[*OtherShape]] | int | float
549
548
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), DType]: ...
550
549
  def __sub__[OtherShape: _Shape = []](
551
- self, other: ndarray[[*Elements[OtherShape]]] | int | float
550
+ self, other: ndarray[[*OtherShape]] | int | float
552
551
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), DType]: ...
553
552
  def __rsub__[OtherShape: _Shape = []](
554
- self, other: ndarray[[*Elements[OtherShape]]] | int | float
553
+ self, other: ndarray[[*OtherShape]] | int | float
555
554
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), DType]: ...
556
555
  def __truediv__[OtherShape: _Shape = []](
557
- self, other: ndarray[[*Elements[OtherShape]]] | int | float
556
+ self, other: ndarray[[*OtherShape]] | int | float
558
557
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), DType]: ...
559
558
  def __rtruediv__[OtherShape: _Shape = []](
560
- self, other: ndarray[[*Elements[OtherShape]]] | int | float
559
+ self, other: ndarray[[*OtherShape]] | int | float
561
560
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), DType]: ...
562
561
  def __mul__[OtherShape: _Shape = []](
563
- self, other: ndarray[[*Elements[OtherShape]]] | int | float
562
+ self, other: ndarray[[*OtherShape]] | int | float
564
563
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), DType]: ...
565
564
  def __rmul__[OtherShape: _Shape = []](
566
- self, other: ndarray[[*Elements[OtherShape]]] | int | float
565
+ self, other: ndarray[[*OtherShape]] | int | float
567
566
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), DType]: ...
568
567
  def __floordiv__[OtherShape: _Shape = []](
569
- self, other: ndarray[[*Elements[OtherShape]]] | int | float
568
+ self, other: ndarray[[*OtherShape]] | int | float
570
569
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), DType]: ...
571
570
  def __rfloordiv__[OtherShape: _Shape = []](
572
- self, other: ndarray[[*Elements[OtherShape]]] | int | float
571
+ self, other: ndarray[[*OtherShape]] | int | float
573
572
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), DType]: ...
574
573
  def __mod__[OtherShape: _Shape = []](
575
- self, other: ndarray[[*Elements[OtherShape]]] | int | float
574
+ self, other: ndarray[[*OtherShape]] | int | float
576
575
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), DType]: ...
577
576
  def __rmod__[OtherShape: _Shape = []](
578
- self, other: ndarray[[*Elements[OtherShape]]] | int | float
577
+ self, other: ndarray[[*OtherShape]] | int | float
579
578
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), DType]: ...
580
579
  def __neg__(self) -> ndarray[Shape, DType]: ...
581
580
  def __pos__(self) -> ndarray[Shape, DType]: ...
582
581
  def __pow__[OtherShape: _Shape = []](
583
- self, other: ndarray[[*Elements[OtherShape]]] | int | float
582
+ self, other: ndarray[[*OtherShape]] | int | float
584
583
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), DType]: ...
585
584
  def __rpow__[OtherShape: _Shape = []](
586
- self, other: ndarray[[*Elements[OtherShape]]] | int | float
585
+ self, other: ndarray[[*OtherShape]] | int | float
587
586
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), DType]: ...
588
587
  # Scalar results also satisfy Python's truth-valued comparison protocols.
589
588
  @overload
@@ -591,13 +590,7 @@ class ndarray[Shape: _Shape = _Shape, DType = Any]:
591
590
  @overload
592
591
  def __lt__[OtherShape: _Shape = []](
593
592
  self,
594
- other: ndarray[[*Elements[OtherShape]]]
595
- | int
596
- | float
597
- | complex
598
- | str
599
- | bytes
600
- | generic,
593
+ other: ndarray[[*OtherShape]] | int | float | complex | str | bytes | generic,
601
594
  /,
602
595
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), _dtype[bool_]]: ...
603
596
  @overload
@@ -607,13 +600,7 @@ class ndarray[Shape: _Shape = _Shape, DType = Any]:
607
600
  @overload
608
601
  def __le__[OtherShape: _Shape = []](
609
602
  self,
610
- other: ndarray[[*Elements[OtherShape]]]
611
- | int
612
- | float
613
- | complex
614
- | str
615
- | bytes
616
- | generic,
603
+ other: ndarray[[*OtherShape]] | int | float | complex | str | bytes | generic,
617
604
  /,
618
605
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), _dtype[bool_]]: ...
619
606
  @overload
@@ -623,13 +610,7 @@ class ndarray[Shape: _Shape = _Shape, DType = Any]:
623
610
  @overload
624
611
  def __gt__[OtherShape: _Shape = []](
625
612
  self,
626
- other: ndarray[[*Elements[OtherShape]]]
627
- | int
628
- | float
629
- | complex
630
- | str
631
- | bytes
632
- | generic,
613
+ other: ndarray[[*OtherShape]] | int | float | complex | str | bytes | generic,
633
614
  /,
634
615
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), _dtype[bool_]]: ...
635
616
  @overload
@@ -639,13 +620,7 @@ class ndarray[Shape: _Shape = _Shape, DType = Any]:
639
620
  @overload
640
621
  def __ge__[OtherShape: _Shape = []](
641
622
  self,
642
- other: ndarray[[*Elements[OtherShape]]]
643
- | int
644
- | float
645
- | complex
646
- | str
647
- | bytes
648
- | generic,
623
+ other: ndarray[[*OtherShape]] | int | float | complex | str | bytes | generic,
649
624
  /,
650
625
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), _dtype[bool_]]: ...
651
626
  @overload
@@ -655,13 +630,7 @@ class ndarray[Shape: _Shape = _Shape, DType = Any]:
655
630
  @overload
656
631
  def __eq__[OtherShape: _Shape = []](
657
632
  self,
658
- other: ndarray[[*Elements[OtherShape]]]
659
- | int
660
- | float
661
- | complex
662
- | str
663
- | bytes
664
- | generic,
633
+ other: ndarray[[*OtherShape]] | int | float | complex | str | bytes | generic,
665
634
  /,
666
635
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), _dtype[bool_]]: ...
667
636
  @overload
@@ -671,35 +640,29 @@ class ndarray[Shape: _Shape = _Shape, DType = Any]:
671
640
  @overload
672
641
  def __ne__[OtherShape: _Shape = []](
673
642
  self,
674
- other: ndarray[[*Elements[OtherShape]]]
675
- | int
676
- | float
677
- | complex
678
- | str
679
- | bytes
680
- | generic,
643
+ other: ndarray[[*OtherShape]] | int | float | complex | str | bytes | generic,
681
644
  /,
682
645
  ) -> ndarray[_broadcast_shape(Shape, OtherShape), _dtype[bool_]]: ...
683
646
  @overload
684
647
  def __ne__(self, other: ArrayLike, /) -> ndarray[IntTuple, _dtype[bool_]]: ...
685
648
  def __invert__(self) -> ndarray[Shape, DType]: ...
686
649
  def __and__[OtherShape: _Shape = []](
687
- self, other: ndarray[[*Elements[OtherShape]]] | _IndexScalar, /
650
+ self, other: ndarray[[*OtherShape]] | _IndexScalar, /
688
651
  ) -> ndarray[_broadcast_shape(Shape, OtherShape)]: ...
689
652
  def __or__[OtherShape: _Shape = []](
690
- self, other: ndarray[[*Elements[OtherShape]]] | _IndexScalar, /
653
+ self, other: ndarray[[*OtherShape]] | _IndexScalar, /
691
654
  ) -> ndarray[_broadcast_shape(Shape, OtherShape)]: ...
692
655
  def __xor__[OtherShape: _Shape = []](
693
- self, other: ndarray[[*Elements[OtherShape]]] | _IndexScalar, /
656
+ self, other: ndarray[[*OtherShape]] | _IndexScalar, /
694
657
  ) -> ndarray[_broadcast_shape(Shape, OtherShape)]: ...
695
658
  def __rand__[OtherShape: _Shape = []](
696
- self, other: ndarray[[*Elements[OtherShape]]] | _IndexScalar, /
659
+ self, other: ndarray[[*OtherShape]] | _IndexScalar, /
697
660
  ) -> ndarray[_broadcast_shape(Shape, OtherShape)]: ...
698
661
  def __ror__[OtherShape: _Shape = []](
699
- self, other: ndarray[[*Elements[OtherShape]]] | _IndexScalar, /
662
+ self, other: ndarray[[*OtherShape]] | _IndexScalar, /
700
663
  ) -> ndarray[_broadcast_shape(Shape, OtherShape)]: ...
701
664
  def __rxor__[OtherShape: _Shape = []](
702
- self, other: ndarray[[*Elements[OtherShape]]] | _IndexScalar, /
665
+ self, other: ndarray[[*OtherShape]] | _IndexScalar, /
703
666
  ) -> ndarray[_broadcast_shape(Shape, OtherShape)]: ...
704
667
  def __matmul__[OtherShape: _Shape](
705
668
  self, other: ndarray[OtherShape]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: pyrefly-numpy-stubs
3
- Version: 1.4.0.dev2
3
+ Version: 1.4.0.dev3
4
4
  Summary: NumPy type stubs with array-shape tracking, maintained by Pyrefly
5
5
  Project-URL: homepage, https://pyrefly.org
6
6
  Project-URL: documentation, https://pyrefly.org/en/docs/
@@ -33,7 +33,7 @@ Classifier: Programming Language :: Python
33
33
  Classifier: Programming Language :: Python :: 3
34
34
  Classifier: Typing :: Stubs Only
35
35
  Requires-Python: >=3.12
36
- Requires-Dist: pyrefly-shape-extensions==1.4.0.dev2
36
+ Requires-Dist: pyrefly-shape-extensions==1.4.0.dev3
37
37
  Description-Content-Type: text/markdown
38
38
 
39
39
  # pyrefly-numpy-stubs
@@ -1,9 +1,9 @@
1
- numpy-stubs/__init__.pyi,sha256=hQWmGEAgvHTVwqs_-YIoSFyB6wGhvHWUoJWe07YE-tA,48601
1
+ numpy-stubs/__init__.pyi,sha256=oqLstLya9CVOV64Xbrxnk4NFKGF_PAtKcnmrBfUIiVY,48009
2
2
  numpy-stubs/_shapes.pyi,sha256=kvbytJygme4DluXr_v2iO_kAnWrZaRTUCb0MNgi-6Oo,4802
3
3
  numpy-stubs/py.typed,sha256=la67KBlbjXN-_-DfGNcdOcjYumVpKG_Tkw-8n5dnGB4,8
4
4
  numpy-stubs/linalg/__init__.pyi,sha256=HqAg4mSr0csSnsIRougqxHP7dzUww7wa6USyN51PPAQ,2734
5
5
  numpy-stubs/random/__init__.pyi,sha256=rZT47dwZw1ev6xXQsngIZQL8SnkI2vEUBbK2p-vSi7w,2404
6
- pyrefly_numpy_stubs-1.4.0.dev2.dist-info/METADATA,sha256=12Q53aX_k9HEN2PsBsHq1tXxHSTuzQtbF_p908sVC9U,2662
7
- pyrefly_numpy_stubs-1.4.0.dev2.dist-info/WHEEL,sha256=W3fkpkm7-wf9vBI5Z-7s0eWkeM-spu78I8Neb98DeEg,87
8
- pyrefly_numpy_stubs-1.4.0.dev2.dist-info/licenses/LICENSE,sha256=2m03A-0Ry-Qr0hLHJZV8mNojy_8ZmMBfpLPZdtGljpM,1088
9
- pyrefly_numpy_stubs-1.4.0.dev2.dist-info/RECORD,,
6
+ pyrefly_numpy_stubs-1.4.0.dev3.dist-info/METADATA,sha256=aIsXl5CWsurKc73ZyNHSbwzebFWd5R2tzl9-VuZvNnE,2662
7
+ pyrefly_numpy_stubs-1.4.0.dev3.dist-info/WHEEL,sha256=W3fkpkm7-wf9vBI5Z-7s0eWkeM-spu78I8Neb98DeEg,87
8
+ pyrefly_numpy_stubs-1.4.0.dev3.dist-info/licenses/LICENSE,sha256=2m03A-0Ry-Qr0hLHJZV8mNojy_8ZmMBfpLPZdtGljpM,1088
9
+ pyrefly_numpy_stubs-1.4.0.dev3.dist-info/RECORD,,