PyPyNum 1.9.2__py3-none-any.whl → 1.10.0__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.
- {PyPyNum-1.9.2.dist-info → PyPyNum-1.10.0.dist-info}/METADATA +251 -130
- {PyPyNum-1.9.2.dist-info → PyPyNum-1.10.0.dist-info}/RECORD +19 -18
- pypynum/Array.py +16 -0
- pypynum/Group.py +3 -16
- pypynum/Matrix.py +74 -61
- pypynum/README.md +250 -129
- pypynum/Vector.py +0 -14
- pypynum/__init__.py +22 -3
- pypynum/equations.py +2 -2
- pypynum/file.py +5 -1
- pypynum/image.py +260 -0
- pypynum/maths.py +130 -111
- pypynum/numbers.py +14 -6
- pypynum/polynomial.py +7 -2
- pypynum/regression.py +4 -4
- pypynum/test.py +10 -10
- pypynum/tools.py +28 -28
- {PyPyNum-1.9.2.dist-info → PyPyNum-1.10.0.dist-info}/WHEEL +0 -0
- {PyPyNum-1.9.2.dist-info → PyPyNum-1.10.0.dist-info}/top_level.txt +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: PyPyNum
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.10.0
|
|
4
4
|
Summary: A multifunctional mathematical calculation package written in pure Python programming language [Python>=3.4]
|
|
5
5
|
Home-page: https://github.com/PythonSJL/PyPyNum
|
|
6
6
|
Author: Shen Jiayi
|
|
@@ -692,7 +692,7 @@ Description-Content-Type: text/markdown
|
|
|
692
692
|
[](https://pepy.tech/project/pypynum)
|
|
693
693
|
[](https://pepy.tech/project/pypynum)
|
|
694
694
|
|
|
695
|
-
## Version -> 1.
|
|
695
|
+
## Version -> 1.10.0 | PyPI -> https://pypi.org/project/PyPyNum/ | Gitee -> https://www.gitee.com/PythonSJL/PyPyNum | GitHub -> https://github.com/PythonSJL/PyPyNum
|
|
696
696
|
|
|
697
697
|

|
|
698
698
|
|
|
@@ -716,41 +716,42 @@ The logo cannot be displayed on PyPI, it can be viewed in Gitee or GitHub.
|
|
|
716
716
|
|
|
717
717
|
#### Name and Function Introduction of Submodules
|
|
718
718
|
|
|
719
|
-
| 子模块名称 Submodule Name |
|
|
720
|
-
|
|
721
|
-
|
|
|
722
|
-
|
|
|
723
|
-
|
|
|
724
|
-
|
|
|
725
|
-
|
|
|
726
|
-
|
|
|
727
|
-
|
|
|
728
|
-
|
|
|
729
|
-
|
|
|
730
|
-
|
|
|
731
|
-
|
|
|
732
|
-
|
|
|
733
|
-
|
|
|
734
|
-
|
|
|
735
|
-
|
|
|
736
|
-
|
|
|
737
|
-
|
|
|
738
|
-
|
|
|
739
|
-
| `pypynum.
|
|
740
|
-
| `pypynum.
|
|
741
|
-
| `pypynum.
|
|
742
|
-
|
|
|
743
|
-
| `pypynum.
|
|
744
|
-
|
|
|
745
|
-
|
|
|
746
|
-
|
|
|
747
|
-
|
|
|
748
|
-
|
|
|
749
|
-
|
|
|
750
|
-
|
|
|
751
|
-
|
|
|
752
|
-
|
|
|
753
|
-
|
|
|
719
|
+
| 子模块名称 Submodule Name | 功能简介 Function Introduction |
|
|
720
|
+
|:---------------------:|:------------------------------------------:|
|
|
721
|
+
| `pypynum.Array` | 多维数组 Multidimensional array |
|
|
722
|
+
| `pypynum.chars` | 特殊数学符号 Special mathematical symbols |
|
|
723
|
+
| `pypynum.cipher` | 加密解密算法 Encryption and decryption algorithm |
|
|
724
|
+
| `pypynum.constants` | 数学常数集合 Set of mathematical constants |
|
|
725
|
+
| `pypynum.equations` | 方程求解 Solving equations |
|
|
726
|
+
| `pypynum.errors` | 异常对象 Exception object |
|
|
727
|
+
| `pypynum.file` | 文件读写 File read and write |
|
|
728
|
+
| `pypynum.FourierT` | 傅里叶变换 Fourier transform |
|
|
729
|
+
| `pypynum.Geometry` | 几何形状 Geometric shape |
|
|
730
|
+
| `pypynum.Graph` | 图论算法 Graph Theory Algorithm |
|
|
731
|
+
| `pypynum.Group` | 群论算法 Group Theory Algorithm |
|
|
732
|
+
| `pypynum.image` | 图像处理 Image processing |
|
|
733
|
+
| `pypynum.Logic` | 逻辑电路设计 Logic circuit design |
|
|
734
|
+
| `pypynum.maths` | 通用数学函数 General mathematical functions |
|
|
735
|
+
| `pypynum.Matrix` | 矩阵运算 Matrix operation |
|
|
736
|
+
| `pypynum.NeuralN` | 神经网络训练 Neural network training |
|
|
737
|
+
| `pypynum.numbers` | 数字处理 Number processing |
|
|
738
|
+
| `pypynum.plotting` | 数据可视化 Data visualization |
|
|
739
|
+
| `pypynum.polynomial` | 多项式运算 Polynomial operation |
|
|
740
|
+
| `pypynum.probability` | 概率统计 Probability statistics |
|
|
741
|
+
| `pypynum.Quaternion` | 四元数运算 Quaternion operation |
|
|
742
|
+
| `pypynum.random` | 随机数生成 Random number generation |
|
|
743
|
+
| `pypynum.regression` | 回归分析 Regression analysis |
|
|
744
|
+
| `pypynum.sequence` | 数列计算 Sequence calculation |
|
|
745
|
+
| `pypynum.Symbolics` | 符号计算 Symbol calculation |
|
|
746
|
+
| `pypynum.Tensor` | 张量运算 Tensor operation |
|
|
747
|
+
| `pypynum.test` | 简易测试 Easy test |
|
|
748
|
+
| `pypynum.this` | 项目之禅 Zen of Projects |
|
|
749
|
+
| `pypynum.tools` | 辅助函数 Auxiliary functions |
|
|
750
|
+
| `pypynum.Tree` | 树形数据结构 Tree data structure |
|
|
751
|
+
| `pypynum.types` | 特殊类型 Special types |
|
|
752
|
+
| `pypynum.ufuncs` | 通用函数 Universal functions |
|
|
753
|
+
| `pypynum.utils` | 实用工具 Utility |
|
|
754
|
+
| `pypynum.Vector` | 向量运算 Vector operation |
|
|
754
755
|
|
|
755
756
|
### PyPyNum的Zen(预览)
|
|
756
757
|
|
|
@@ -790,80 +791,201 @@ Python interpreter and run it!
|
|
|
790
791
|
```
|
|
791
792
|
!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=
|
|
792
793
|
|
|
793
|
-
|
|
794
|
+
名称缩写的函数
|
|
794
795
|
|
|
795
|
-
|
|
796
|
-
|
|
796
|
+
Functions with abbreviated names
|
|
797
|
+
|
|
798
|
+
linear_regression -> lin_reg
|
|
799
|
+
parabolic_regression -> par_reg
|
|
800
|
+
polynomial_regression -> poly_reg
|
|
801
|
+
linear_equation -> lin_eq
|
|
802
|
+
polynomial_equation -> poly_eq
|
|
803
|
+
derivative -> deriv
|
|
804
|
+
definite_integral -> integ
|
|
797
805
|
|
|
798
806
|
!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=
|
|
799
807
|
|
|
800
|
-
|
|
808
|
+
★ Matrix.inv(self):
|
|
809
|
+
★ 速度提高约55000%
|
|
810
|
+
★ Speed increased by about 55000%
|
|
801
811
|
|
|
802
|
-
|
|
812
|
+
Matrix.outer(self, other):
|
|
813
|
+
速度提高约900%
|
|
814
|
+
Speed increased by about 900%
|
|
803
815
|
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
816
|
+
identity(n: int) -> Matrix:
|
|
817
|
+
速度提高约630%
|
|
818
|
+
Speed increased by about 630%
|
|
819
|
+
|
|
820
|
+
tril_indices(n: int,
|
|
821
|
+
k: int = 0,
|
|
822
|
+
m: int | None = None) -> tuple:
|
|
823
|
+
速度提高约140%
|
|
824
|
+
Speed increased by about 140%
|
|
825
|
+
|
|
826
|
+
Matrix.kron(self, other):
|
|
827
|
+
速度提高约130%
|
|
828
|
+
Speed increased by about 130%
|
|
829
|
+
|
|
830
|
+
Matrix.t(self):
|
|
831
|
+
速度提高约70%
|
|
832
|
+
Speed increased by about 70%
|
|
833
|
+
|
|
834
|
+
lu(matrix: Matrix) -> tuple:
|
|
835
|
+
速度提高约9%
|
|
836
|
+
Speed increased by about 9%
|
|
837
|
+
|
|
838
|
+
Matrix.inner(self, other):
|
|
839
|
+
速度提高约5%
|
|
840
|
+
Speed increased by about 5%
|
|
808
841
|
|
|
809
842
|
!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=
|
|
810
843
|
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
Newly added functions
|
|
814
|
-
|
|
815
|
-
class Polynomial(builtins.object)
|
|
816
|
-
<以下为新增加的方法>
|
|
817
|
-
<The following are the newly added methods>
|
|
818
|
-
__divmod__ = __truediv__(self, other)
|
|
819
|
-
__float__(self)
|
|
820
|
-
__int__(self)
|
|
821
|
-
__round__(self, n=None)
|
|
822
|
-
coeffs(self, reverse=False)
|
|
823
|
-
degs(self, reverse=False)
|
|
824
|
-
deriv(self)
|
|
825
|
-
evaluate(self, x)
|
|
826
|
-
gcd(self, other)
|
|
827
|
-
integ(self, constant=0)
|
|
828
|
-
is_zero(self)
|
|
829
|
-
latex(self)
|
|
830
|
-
lcm(self, other)
|
|
831
|
-
roots(self)
|
|
832
|
-
sqrt(self)
|
|
844
|
+
矩阵支持更好的修改元素方式
|
|
833
845
|
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
846
|
+
Matrix supports better ways
|
|
847
|
+
to modify elements
|
|
848
|
+
|
|
849
|
+
示例 Example
|
|
850
|
+
|
|
851
|
+
A = [[0, 1, 2, 3],
|
|
852
|
+
[4, 5, 6, 7],
|
|
853
|
+
[8, 9, 10, 11],
|
|
854
|
+
[12, 13, 14, 15]]
|
|
855
|
+
matrix = mat(A)
|
|
856
|
+
matrix[0:2, 0:2] = [[16, 77],
|
|
857
|
+
[72, 16]]
|
|
858
|
+
|
|
859
|
+
!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=
|
|
860
|
+
|
|
861
|
+
这个方法添加了是否返回所有主元
|
|
862
|
+
|
|
863
|
+
This method adds whether to return all main elements
|
|
864
|
+
|
|
865
|
+
Matrix.rref(self, pivots=True)
|
|
866
|
+
|
|
867
|
+
!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=
|
|
868
|
+
|
|
869
|
+
新增的函数
|
|
870
|
+
|
|
871
|
+
New functions added
|
|
872
|
+
|
|
873
|
+
aslist(data)
|
|
874
|
+
asarray(data)
|
|
875
|
+
roll(seq, shift)
|
|
876
|
+
|
|
877
|
+
请注意,“roll”函数目前是一个初步实现,将来将被设计为数组绑定方法。
|
|
878
|
+
Please note that the "roll" function is currently a preliminary implementation
|
|
879
|
+
and will be designed as an array binding method in the future.
|
|
880
|
+
|
|
881
|
+
!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=
|
|
882
|
+
|
|
883
|
+
<<<添加了image模块>>>
|
|
884
|
+
|
|
885
|
+
<<<Added image module>>>
|
|
886
|
+
|
|
887
|
+
<<<添加了PNG类>>>
|
|
888
|
+
|
|
889
|
+
<<<Added PNG class>>>
|
|
890
|
+
|
|
891
|
+
class PNG(builtins.object)
|
|
892
|
+
|
|
893
|
+
Introduction
|
|
894
|
+
==========
|
|
895
|
+
This is a PNG class written in pure Python,
|
|
896
|
+
supporting the creation, reading, modification, and saving of PNG images.
|
|
897
|
+
|
|
898
|
+
Roadmap
|
|
899
|
+
==========
|
|
900
|
+
This class is currently in development.
|
|
901
|
+
Future updates will expand its functionality to enhance the capabilities of working with PNG images.
|
|
902
|
+
|
|
903
|
+
Usage
|
|
904
|
+
==========
|
|
905
|
+
|
|
906
|
+
Creating a new PNG image:
|
|
907
|
+
----------
|
|
908
|
+
To create a new PNG image, instantiate the PNG class and use the `new` method
|
|
909
|
+
to define the image dimensions, bit depth, and color mode.
|
|
910
|
+
|
|
911
|
+
- from png import PNG
|
|
912
|
+
|
|
913
|
+
# Create a new image with a width of 200 pixels, a height of 100 pixels,
|
|
914
|
+
an 8-bit depth, and the default RGB color mode.
|
|
915
|
+
|
|
916
|
+
- image = PNG()
|
|
917
|
+
- image.new(200, 100, 8)
|
|
918
|
+
|
|
919
|
+
# Optionally, you can specify a background color. For example, to create a new image with a blue background:
|
|
920
|
+
|
|
921
|
+
- image.new(200, 100, 8, color=(0, 0, 255))
|
|
922
|
+
|
|
923
|
+
Reading an existing PNG image:
|
|
924
|
+
----------
|
|
925
|
+
To read an existing PNG image from a file, use the `read` method.
|
|
926
|
+
|
|
927
|
+
- image = PNG()
|
|
928
|
+
- image.read("example.png")
|
|
929
|
+
|
|
930
|
+
Modifying a pixel:
|
|
931
|
+
----------
|
|
932
|
+
To modify the color of a pixel at a specific coordinate, use the `setp` method.
|
|
933
|
+
|
|
934
|
+
# Set the pixel at (10, 10) to red (255, 0, 0).
|
|
935
|
+
|
|
936
|
+
- image.setp(10, 10, (255, 0, 0))
|
|
937
|
+
|
|
938
|
+
Getting a pixel's color:
|
|
939
|
+
----------
|
|
940
|
+
To retrieve the color of a pixel at a specific coordinate, use the `getp` method.
|
|
941
|
+
|
|
942
|
+
- color = image.getp(10, 10)
|
|
943
|
+
- print(color) # Output: (255, 0, 0) for the example above
|
|
944
|
+
|
|
945
|
+
Saving the image:
|
|
946
|
+
----------
|
|
947
|
+
To save the image to a file, use the `write` method.
|
|
948
|
+
|
|
949
|
+
- image.write("output.png")
|
|
950
|
+
|
|
951
|
+
Getting image information:
|
|
952
|
+
----------
|
|
953
|
+
To obtain information about the image, such as its dimensions and color mode, use the `info` method.
|
|
954
|
+
|
|
955
|
+
- info = image.info()
|
|
956
|
+
- print(info) # Output: {'width': 200, 'height': 100, 'bit_depth': 8, 'color_mode': 'RGB'}
|
|
957
|
+
|
|
958
|
+
__init__(self) -> None
|
|
959
|
+
|
|
960
|
+
__repr__(self) -> str
|
|
961
|
+
|
|
962
|
+
getp(self, x: int, y: int) -> tuple
|
|
963
|
+
|
|
964
|
+
info(self) -> dict
|
|
965
|
+
|
|
966
|
+
new(self, width: int, height: int, bit_depth: int, color: tuple = (), color_mode: str = 'RGB') -> None
|
|
967
|
+
|
|
968
|
+
read(self, filename: str) -> None
|
|
969
|
+
|
|
970
|
+
setp(self, x: int, y: int, color: tuple) -> None
|
|
971
|
+
|
|
972
|
+
write(self, filename: str = None) -> bytes
|
|
973
|
+
|
|
974
|
+
!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=
|
|
861
975
|
```
|
|
862
976
|
|
|
863
977
|
### 运行用时测试
|
|
864
978
|
|
|
865
979
|
#### Run Time Test
|
|
866
980
|
|
|
981
|
+
Python解释器版本
|
|
982
|
+
|
|
983
|
+
Python interpreter version
|
|
984
|
+
|
|
985
|
+
+ CPython 3.8.10
|
|
986
|
+
|
|
987
|
+
+ PyPy 3.10.12
|
|
988
|
+
|
|
867
989
|
| 矩阵用时测试<br>Matrix Time Test | NumPy+CPython(seconds) | 排名<br>Ranking | PyPyNum+PyPy(seconds) | 排名<br>Ranking | Mpmath_+_PyPy_(_seconds_) | 排名<br>Ranking | SymPy_+_PyPy_(_seconds_) | 排名<br>Ranking |
|
|
868
990
|
|:------------------------------------------------------------------:|:----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------:|:-------------:|:----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------:|:-------------:|:---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------:|:-------------:|:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------:|:-------------:|
|
|
869
991
|
| 创建一百阶随机数矩阵<br>Create a hundred order random number matrix | 0.000083 | 1 | 0.005374 | 2 | 0.075253 | 3 | 0.230530 | 4 |
|
|
@@ -871,9 +993,9 @@ PyPyNum
|
|
|
871
993
|
| 一百阶矩阵相加<br>Addition of matrices of order one hundred | 0.000029 | 1 | 0.002163 | 2 | 0.045641 | 4 | 0.035700 | 3 |
|
|
872
994
|
| 一千阶矩阵相加<br>Adding matrices of order one thousand | 0.002647 | 1 | 0.019111 | 2 | 1.746957 | 4 | 0.771542 | 3 |
|
|
873
995
|
| 一百阶矩阵行列式<br>Determinant of a hundred order matrix | 0.087209 | 2 | 0.016331 | 1 | 4.354507 | 3 | 5.157206 | 4 |
|
|
874
|
-
| 一千阶矩阵行列式<br>Determinant of a thousand order matrix | 0.616113 | 1 | 3.509747 | 2 |
|
|
875
|
-
| 一百阶矩阵求逆<br>Finding the inverse of a hundred order matrix | 0.162770 |
|
|
876
|
-
| 一千阶矩阵求逆<br>Finding the inverse of a thousand order matrix | 0.598905 | 1 |
|
|
996
|
+
| 一千阶矩阵行列式<br>Determinant of a thousand order matrix | 0.616113 | 1 | 3.509747 | 2 | It takes a long time | 3 | It takes a long time | 4 |
|
|
997
|
+
| 一百阶矩阵求逆<br>Finding the inverse of a hundred order matrix | 0.162770 | 2 | 0.015768 | 1 | 8.162948 | 3 | 21.437424 | 4 |
|
|
998
|
+
| 一千阶矩阵求逆<br>Finding the inverse of a thousand order matrix | 0.598905 | 1 | 17.072552 | 2 | It takes a long time | 3 | It takes a long time | 4 |
|
|
877
999
|
| 数组输出效果<br>Array output effect | ```[[[[ -7 -67]```<br>```[-78 29]]```<br><br>```[[-86 -97]```<br>```[ 68 -3]]]```<br><br><br>```[[[ 11 42]```<br>```[ 24 -65]]```<br><br>```[[-60 72]```<br>```[ 73 2]]]]``` | / | ```[[[[ 37 83]```<br>```[ 40 2]]```<br><br>```[[ -5 -34]```<br>```[ -7 72]]]```<br><br><br>```[[[ 13 -64]```<br>```[ 6 90]]```<br><br>```[[ 68 57]```<br>```[ 78 11]]]]``` | / | ```[-80.0 -8.0 80.0 -88.0]```<br>```[-99.0 -43.0 87.0 81.0]```<br>```[ 20.0 -55.0 98.0 8.0]```<br>```[ 8.0 44.0 64.0 -35.0]```<br>(只支持矩阵)<br>(Only supports matrices) | / | ```⎡⎡16 -56⎤ ⎡ 8 -28⎤⎤```<br>```⎢⎢ ⎥ ⎢ ⎥⎥```<br>```⎢⎣-56 56 ⎦ ⎣-28 28 ⎦⎥```<br>```⎢ ⎥```<br>```⎢ ⎡-2 7 ⎤ ⎡-18 63 ⎤⎥```<br>```⎢ ⎢ ⎥ ⎢ ⎥⎥```<br>```⎣ ⎣7 -7⎦ ⎣63 -63⎦⎦``` | / |
|
|
878
1000
|
|
|
879
1001
|
### 基本结构
|
|
@@ -887,6 +1009,8 @@ PyPyNum
|
|
|
887
1009
|
│ │ └── Array(object)/__init__(self: Any, data: Any, check: Any) -> Any
|
|
888
1010
|
│ └── FUNCTION
|
|
889
1011
|
│ ├── array(data: Any) -> Any
|
|
1012
|
+
│ ├── asarray(data: Any) -> Any
|
|
1013
|
+
│ ├── aslist(data: Any) -> Any
|
|
890
1014
|
│ ├── fill(shape: Any, sequence: Any, repeat: Any, pad: Any, rtype: Any) -> Any
|
|
891
1015
|
│ ├── full(shape: Any, fill_value: Any, rtype: Any) -> Any
|
|
892
1016
|
│ ├── full_like(a: Any, fill_value: Any, rtype: Any) -> Any
|
|
@@ -923,11 +1047,7 @@ PyPyNum
|
|
|
923
1047
|
│ ├── CLASS
|
|
924
1048
|
│ │ └── Group(object)/__init__(self: Any, data: Any) -> Any
|
|
925
1049
|
│ └── FUNCTION
|
|
926
|
-
│
|
|
927
|
-
│ ├── divide(x: Any, y: Any) -> Any
|
|
928
|
-
│ ├── group(data: Any) -> Any
|
|
929
|
-
│ ├── multiply(x: Any, y: Any) -> Any
|
|
930
|
-
│ └── subtract(x: Any, y: Any) -> Any
|
|
1050
|
+
│ └── group(data: Any) -> Any
|
|
931
1051
|
├── Logic
|
|
932
1052
|
│ ├── CLASS
|
|
933
1053
|
│ │ ├── AND(pypynum.Logic.Binary)/__init__(self: Any, label: Any, pin0: Any, pin1: Any) -> Any
|
|
@@ -965,11 +1085,8 @@ PyPyNum
|
|
|
965
1085
|
│ ├── mat(data: Any) -> Any
|
|
966
1086
|
│ ├── qr(matrix: pypynum.Matrix.Matrix) -> tuple
|
|
967
1087
|
│ ├── rotate90(matrix: pypynum.Matrix.Matrix, times: int) -> pypynum.Matrix.Matrix
|
|
968
|
-
│ ├── same(rows: Any, cols: Any, value: Any) -> Any
|
|
969
1088
|
│ ├── svd(matrix: pypynum.Matrix.Matrix) -> tuple
|
|
970
|
-
│
|
|
971
|
-
│ ├── zeros(_dimensions: Any) -> Any
|
|
972
|
-
│ └── zeros_like(_nested_list: Any) -> Any
|
|
1089
|
+
│ └── tril_indices(n: int, k: int, m: int) -> tuple
|
|
973
1090
|
├── NeuralN
|
|
974
1091
|
│ ├── CLASS
|
|
975
1092
|
│ │ └── NeuralNetwork(object)/__init__(self: Any, _input: Any, _hidden: Any, _output: Any) -> Any
|
|
@@ -1005,10 +1122,7 @@ PyPyNum
|
|
|
1005
1122
|
│ ├── CLASS
|
|
1006
1123
|
│ │ └── Vector(pypynum.Array.Array)/__init__(self: Any, data: Any, check: Any) -> Any
|
|
1007
1124
|
│ └── FUNCTION
|
|
1008
|
-
│
|
|
1009
|
-
│ ├── vec(data: Any) -> Any
|
|
1010
|
-
│ ├── zeros(_dimensions: Any) -> Any
|
|
1011
|
-
│ └── zeros_like(_nested_list: Any) -> Any
|
|
1125
|
+
│ └── vec(data: Any) -> Any
|
|
1012
1126
|
├── chars
|
|
1013
1127
|
│ ├── CLASS
|
|
1014
1128
|
│ └── FUNCTION
|
|
@@ -1033,8 +1147,8 @@ PyPyNum
|
|
|
1033
1147
|
├── equations
|
|
1034
1148
|
│ ├── CLASS
|
|
1035
1149
|
│ └── FUNCTION
|
|
1036
|
-
│ ├──
|
|
1037
|
-
│ └──
|
|
1150
|
+
│ ├── lin_eq(left: list, right: list) -> list
|
|
1151
|
+
│ └── poly_eq(coefficients: list) -> list
|
|
1038
1152
|
├── errors
|
|
1039
1153
|
│ ├── CLASS
|
|
1040
1154
|
│ └── FUNCTION
|
|
@@ -1043,6 +1157,11 @@ PyPyNum
|
|
|
1043
1157
|
│ └── FUNCTION
|
|
1044
1158
|
│ ├── read(file: str) -> list
|
|
1045
1159
|
│ └── write(file: str, cls: object) -> Any
|
|
1160
|
+
├── image
|
|
1161
|
+
│ ├── CLASS
|
|
1162
|
+
│ │ └── PNG(object)/__init__(self: Any) -> None
|
|
1163
|
+
│ └── FUNCTION
|
|
1164
|
+
│ └── crc(data: Any, length: Any, init: Any, xor: Any) -> Any
|
|
1046
1165
|
├── maths
|
|
1047
1166
|
│ ├── CLASS
|
|
1048
1167
|
│ └── FUNCTION
|
|
@@ -1077,8 +1196,7 @@ PyPyNum
|
|
|
1077
1196
|
│ ├── csch(x: typing.Union[int, float]) -> typing.Union[int, float]
|
|
1078
1197
|
│ ├── cumprod(lst: typing.Union[list, tuple]) -> list
|
|
1079
1198
|
│ ├── cumsum(lst: typing.Union[list, tuple]) -> list
|
|
1080
|
-
│ ├──
|
|
1081
|
-
│ ├── derivative(f: Any, x: typing.Union[int, float], h: typing.Union[int, float], args: Any, kwargs: Any) -> float
|
|
1199
|
+
│ ├── deriv(f: Any, x: typing.Union[int, float], h: typing.Union[int, float], args: Any, kwargs: Any) -> float
|
|
1082
1200
|
│ ├── erf(x: typing.Union[int, float]) -> float
|
|
1083
1201
|
│ ├── exgcd(a: int, b: int) -> tuple
|
|
1084
1202
|
│ ├── exp(x: typing.Union[int, float]) -> typing.Union[int, float]
|
|
@@ -1089,6 +1207,7 @@ PyPyNum
|
|
|
1089
1207
|
│ ├── gcd(args: int) -> int
|
|
1090
1208
|
│ ├── geom_mean(numbers: typing.Union[list, tuple]) -> typing.Union[int, float, complex]
|
|
1091
1209
|
│ ├── harm_mean(numbers: typing.Union[list, tuple]) -> typing.Union[int, float, complex]
|
|
1210
|
+
│ ├── integ(f: Any, x_start: typing.Union[int, float], x_end: typing.Union[int, float], n: int, args: Any, kwargs: Any) -> float
|
|
1092
1211
|
│ ├── iroot(y: int, n: int) -> int
|
|
1093
1212
|
│ ├── is_possibly_square(n: int) -> bool
|
|
1094
1213
|
│ ├── is_square(n: int) -> bool
|
|
@@ -1108,6 +1227,7 @@ PyPyNum
|
|
|
1108
1227
|
│ ├── product(numbers: typing.Union[list, tuple]) -> typing.Union[int, float, complex]
|
|
1109
1228
|
│ ├── ptp(numbers: typing.Union[list, tuple]) -> typing.Union[int, float, complex]
|
|
1110
1229
|
│ ├── raw_moment(data: typing.Union[list, tuple], order: int) -> float
|
|
1230
|
+
│ ├── roll(seq: typing.Union[list, tuple, str], shift: int) -> typing.Union[list, tuple, str]
|
|
1111
1231
|
│ ├── root(x: typing.Union[int, float, complex], y: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
|
|
1112
1232
|
│ ├── sec(x: typing.Union[int, float]) -> typing.Union[int, float]
|
|
1113
1233
|
│ ├── sech(x: typing.Union[int, float]) -> typing.Union[int, float]
|
|
@@ -1147,6 +1267,7 @@ PyPyNum
|
|
|
1147
1267
|
│ │ └── Polynomial(object)/__init__(self: Any, terms: Any) -> Any
|
|
1148
1268
|
│ └── FUNCTION
|
|
1149
1269
|
│ ├── from_coeffs(coeffs: Any) -> Any
|
|
1270
|
+
│ ├── from_coords(coords: Any) -> Any
|
|
1150
1271
|
│ ├── leggauss(polynomial: Any) -> Any
|
|
1151
1272
|
│ ├── legpoly(n: Any) -> Any
|
|
1152
1273
|
│ └── poly(terms: Any) -> Any
|
|
@@ -1169,9 +1290,9 @@ PyPyNum
|
|
|
1169
1290
|
├── regression
|
|
1170
1291
|
│ ├── CLASS
|
|
1171
1292
|
│ └── FUNCTION
|
|
1172
|
-
│ ├──
|
|
1173
|
-
│ ├──
|
|
1174
|
-
│ └──
|
|
1293
|
+
│ ├── lin_reg(x: typing.Union[list, tuple], y: typing.Union[list, tuple]) -> list
|
|
1294
|
+
│ ├── par_reg(x: typing.Union[list, tuple], y: typing.Union[list, tuple]) -> list
|
|
1295
|
+
│ └── poly_reg(x: typing.Union[list, tuple], y: typing.Union[list, tuple], n: int) -> list
|
|
1175
1296
|
├── sequence
|
|
1176
1297
|
│ ├── CLASS
|
|
1177
1298
|
│ └── FUNCTION
|
|
@@ -1300,8 +1421,8 @@ print(m1.rank())
|
|
|
1300
1421
|
[10 12]]
|
|
1301
1422
|
[[19 22]
|
|
1302
1423
|
[43 50]]
|
|
1303
|
-
[[-
|
|
1304
|
-
[
|
|
1424
|
+
[[ -1.9999999999999996 0.9999999999999998]
|
|
1425
|
+
[ 1.4999999999999998 -0.49999999999999994]]
|
|
1305
1426
|
2
|
|
1306
1427
|
"""
|
|
1307
1428
|
|
|
@@ -1434,8 +1555,8 @@ m = [
|
|
|
1434
1555
|
],
|
|
1435
1556
|
[-1, -2, -3]
|
|
1436
1557
|
]
|
|
1437
|
-
print(equations.
|
|
1438
|
-
print(equations.
|
|
1558
|
+
print(equations.poly_eq(p))
|
|
1559
|
+
print(equations.lin_eq(*m))
|
|
1439
1560
|
|
|
1440
1561
|
"""
|
|
1441
1562
|
[(-1.5615528128088307-6.5209667308287455e-24j) (1.0000000000000007+3.241554513744382e-25j) (2.5615528128088294+4.456233626665941e-24j)]
|
|
@@ -1539,20 +1660,20 @@ print(random.randint(0, 9, [2, 3, 4]))
|
|
|
1539
1660
|
print(random.uniform(0, 9, [2, 3, 4]))
|
|
1540
1661
|
|
|
1541
1662
|
"""
|
|
1542
|
-
[[[
|
|
1543
|
-
[[[0.
|
|
1544
|
-
[[[
|
|
1545
|
-
[[[
|
|
1663
|
+
[[[1.0022026821190488, -0.38242004448759154, -0.23648445523561967, 0.43813038741951754], [-0.3778652198785619, -0.03865603124657112, -1.5186239424691736, -0.7368762975012327], [-0.7580654190380791, -1.3672869759158346, 0.582588816791107, 1.0281649895276377]], [[0.5270622699930536, 0.6132250709048543, 0.9764619731696673, -0.13740454362420268], [-2.0801461607759886, -0.1935521020633617, 0.44420106801354153, 1.4830089202063659], [-0.8790685594194517, 0.45517163054358967, -1.1448643981658326, 0.986414969442009]]]
|
|
1664
|
+
[[[0.13698864758140294, 0.634190467772759, 0.25683276170297875, 0.9026812741081188], [0.26303437123782614, 0.02477620234532174, 0.9947822450199725, 0.5916822332583692], [0.7523977891797228, 0.6198410071512576, 0.05799276940261333, 0.4181042411131305]], [[0.21564211884049145, 0.30667940527138227, 0.03010277335333611, 0.904264028183912], [0.33977550248572597, 0.042594462434406455, 0.6371061749651907, 0.8639246364627866], [0.009159271907318911, 0.054475512265855563, 0.7109847662274855, 0.9695933487818381]]]
|
|
1665
|
+
[[[1, 6, 0, 1], [0, 4, 8, 3], [2, 4, 2, 8]], [[9, 7, 0, 6], [6, 2, 4, 6], [2, 2, 0, 1]]]
|
|
1666
|
+
[[[4.281963231653285, 7.6564706580977155, 2.7831005401808904, 4.69275453971821], [7.731377457312142, 7.026081604862776, 3.1623746844355916, 4.097454457127405], [1.0053860355938644, 8.396390096875859, 5.860124932392565, 0.7556741321519111]], [[3.0505373562186717, 5.846422325897977, 5.79128924014881, 5.322513543793011], [7.97334322055796, 0.4266873959996582, 6.217219949795519, 2.819046997201407], [7.195256735457888, 3.205909055908082, 2.9903485221015123, 6.695032815286013]]]
|
|
1546
1667
|
"""
|
|
1547
1668
|
|
|
1548
|
-
print(regression.
|
|
1549
|
-
print(regression.
|
|
1550
|
-
print(regression.
|
|
1669
|
+
print(regression.lin_reg(list(range(5)), [2, 4, 6, 7, 8]))
|
|
1670
|
+
print(regression.par_reg(list(range(5)), [2, 4, 6, 7, 8]))
|
|
1671
|
+
print(regression.poly_reg(list(range(5)), [2, 4, 6, 7, 8], 4))
|
|
1551
1672
|
|
|
1552
1673
|
"""
|
|
1553
1674
|
[1.5, 2.4000000000000004]
|
|
1554
1675
|
[-0.21428571428571563, 2.3571428571428625, 1.971428571428569]
|
|
1555
|
-
[0.
|
|
1676
|
+
[0.08333333333320592, -0.666666666666571, 1.4166666666628345, 1.1666666666688208, 1.9999999999999258]
|
|
1556
1677
|
"""
|
|
1557
1678
|
|
|
1558
1679
|
print(tools.classify([1, 2.3, 4 + 5j, "string", list, True, 3.14, False, tuple, tools]))
|
|
@@ -1,40 +1,41 @@
|
|
|
1
|
-
pypynum/Array.py,sha256=
|
|
1
|
+
pypynum/Array.py,sha256=qABWeR4bSRf6t-h9v-KTDUQb8jJIpa2mQsPRLv31F_U,8978
|
|
2
2
|
pypynum/FourierT.py,sha256=AtG0tESykzEs4gDsXhcizW7qhQnmw0gjcWcXefBqzhs,1401
|
|
3
3
|
pypynum/Geometry.py,sha256=bJCuif-wHO-t7oHFEE7ntzIdQwzUEbT3mcKgmBV6Wps,13982
|
|
4
4
|
pypynum/Graph.py,sha256=m9iTCNYRCZmAexDzwJ8Y6J7v1aweT-6TZkqh4fOtZDE,10131
|
|
5
|
-
pypynum/Group.py,sha256=
|
|
5
|
+
pypynum/Group.py,sha256=QZdUUxa8zD9jxn69cJsbQlWZNvnSlw-31LZsmzXUxU0,2810
|
|
6
6
|
pypynum/Logic.py,sha256=IJAv59ECHU0HmG9lYCAQ_puqeL6Zor3-IDIVH48KBWE,11000
|
|
7
|
-
pypynum/Matrix.py,sha256=
|
|
7
|
+
pypynum/Matrix.py,sha256=HccbMMLgrcLNvg7moOrfAMDctiLAWTa4b3V4UYwsakM,18682
|
|
8
8
|
pypynum/NeuralN.py,sha256=iSOvC9JW1h4AFGokGGOTkKie5hAYN_YT9H4f3apI9b8,3275
|
|
9
9
|
pypynum/PyPyNum.png,sha256=t96tJPWfHxT8kcXm_qZI2z5W36TgOqjCU9qdgbmlFws,11623
|
|
10
10
|
pypynum/Quaternion.py,sha256=-BW_crP_i-veHN0_pD3Z1dipFNUX198oZDrUYTsoZw0,8017
|
|
11
|
-
pypynum/README.md,sha256=
|
|
11
|
+
pypynum/README.md,sha256=EM9yjBPsBor8oGJCbRYXqqUzMVsk9gI-DRQKnaF7XTY,58918
|
|
12
12
|
pypynum/Symbolics.py,sha256=u-Dig3OLs6qoLzxMpTAYJGq5uSWDMvgU13TAHKLyjMY,2768
|
|
13
13
|
pypynum/Tensor.py,sha256=gi7OjrGgP5BSJS9Oma1B2EdX9qSpMNIP2BnKLojdT78,3930
|
|
14
14
|
pypynum/Tree.py,sha256=BYnlb2kKNJ8kkuq8BAHIcLvPZw5KHxbvM7YuVGhQVMk,4330
|
|
15
|
-
pypynum/Vector.py,sha256=
|
|
16
|
-
pypynum/__init__.py,sha256=
|
|
15
|
+
pypynum/Vector.py,sha256=ee-gkBtyG0l5dLFwAKRTTlnDG05pWpM19RGN7VoPvqE,3212
|
|
16
|
+
pypynum/__init__.py,sha256=v698plpqMZaMvqCevw1WWC4rJBjs_WbEnRnNlo_K2iY,2452
|
|
17
17
|
pypynum/chars.py,sha256=VcK9w0i73FMCzc-9aIibjdHqyMsofJXdoBq0d8L7Vr0,1001
|
|
18
18
|
pypynum/cipher.py,sha256=DaitY3DCoTuzyrXtD8Ap3IYDLhlMc7-o4AJfLlicvB4,10011
|
|
19
19
|
pypynum/constants.py,sha256=xELv4DIKEqBdwF9tUqCmTQVbgVrlrj385ht5eawvshU,1406
|
|
20
|
-
pypynum/equations.py,sha256=
|
|
20
|
+
pypynum/equations.py,sha256=pwbSLpmFl9eChyxkTeRrs3KC3gy19kpAcpxNvWAKQVA,749
|
|
21
21
|
pypynum/errors.py,sha256=I3nh5YD5F_sBoa7hjPJi81goRflbVAZcjtmW7O2BhJk,220
|
|
22
|
-
pypynum/file.py,sha256
|
|
23
|
-
pypynum/
|
|
24
|
-
pypynum/
|
|
22
|
+
pypynum/file.py,sha256=-sg3pndZdiyM8cS6KeIhCvB6NfAovHnLOhEf0XkjidE,3411
|
|
23
|
+
pypynum/image.py,sha256=nhTZmaBVIKhuar-CcwZWb-hRYmkj4b_g7vIlYvEJEEE,12155
|
|
24
|
+
pypynum/maths.py,sha256=3jJtTy7IlyIFd5q2xc7ovlySmf3b04IUf2Q1C8JvxMI,27975
|
|
25
|
+
pypynum/numbers.py,sha256=PqQ07TWfcNlfjCjUg1UJda-BI1uOffmQVK1qIGbll_s,8619
|
|
25
26
|
pypynum/plotting.py,sha256=mbIYK5TpY1qvuMJrqz4d8bxJEiZww3AI684vSKV-DgU,7781
|
|
26
|
-
pypynum/polynomial.py,sha256=
|
|
27
|
+
pypynum/polynomial.py,sha256=qRNITUY5Tcx43bccs2kx_dmvL_heLM0v-IcR-FyQBl8,9465
|
|
27
28
|
pypynum/probability.py,sha256=aUHaS7NMIJJWI8vZktgvn1zQKLtjdBiY5d-qwbJ6fGM,3778
|
|
28
29
|
pypynum/random.py,sha256=vfTtyH5yOSKJoSI_-NT_Tg8wC-ZXT0wt34f87oaSpJY,4610
|
|
29
|
-
pypynum/regression.py,sha256=
|
|
30
|
+
pypynum/regression.py,sha256=PfTM8glJSi3Jgvc_C_3hQBeVjkbrzSuDqRbEf3s403w,2040
|
|
30
31
|
pypynum/sequence.py,sha256=7NSZm_p_B00KFj5XZrtSm2FXhsowxs0qg_Q_P4pAA8o,7194
|
|
31
|
-
pypynum/test.py,sha256=
|
|
32
|
+
pypynum/test.py,sha256=hkLxhtBl9XVjaqcbzDPEuYB92vDXfM9f7AS3tF5FSEE,9005
|
|
32
33
|
pypynum/this.py,sha256=oRX1OpMa4NJmQSdEjJxfszEo5FRYlxRiF8OTDRIcdMA,2154
|
|
33
|
-
pypynum/tools.py,sha256=
|
|
34
|
+
pypynum/tools.py,sha256=xN2hYpEnPGmn1CsdQ60OUv5HIwJRbQAWTI8NclwwHno,12609
|
|
34
35
|
pypynum/types.py,sha256=CVWPZo_ACr_QGH5gAOhoG3jK35peiqipu3PH8ScEYHE,181
|
|
35
36
|
pypynum/ufuncs.py,sha256=g2tewdsGa4VrIq2khR-0SWJoXBitVRN87DulOnTxxDA,2572
|
|
36
37
|
pypynum/utils.py,sha256=oeHpAMFItWXfKjb0UQITPwMVKZBd3H5JT3R-jBgn2_w,14466
|
|
37
|
-
PyPyNum-1.
|
|
38
|
-
PyPyNum-1.
|
|
39
|
-
PyPyNum-1.
|
|
40
|
-
PyPyNum-1.
|
|
38
|
+
PyPyNum-1.10.0.dist-info/METADATA,sha256=lpsZLPsOBvxZ5poG-NZjTkAJpcuTNJ0EVMUOBsVx3zQ,100363
|
|
39
|
+
PyPyNum-1.10.0.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
|
|
40
|
+
PyPyNum-1.10.0.dist-info/top_level.txt,sha256=4wW_Xb4bRglmiMsdPAe9f75MkXhNpuN88H17g_Cr5u8,8
|
|
41
|
+
PyPyNum-1.10.0.dist-info/RECORD,,
|