numpy-ts 0.6.0 → 0.8.0

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.
package/README.md CHANGED
@@ -3,7 +3,7 @@
3
3
  ![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)
4
4
  [![npm version](https://img.shields.io/npm/v/numpy-ts)](https://www.npmjs.com/package/numpy-ts)
5
5
  ![bundle size](https://img.shields.io/bundlephobia/minzip/numpy-ts)
6
- ![numpy api coverage](https://img.shields.io/badge/numpy_api_coverage-58%20%25-yellow)
6
+ ![numpy api coverage](https://img.shields.io/badge/numpy_api_coverage-71%20%25-yellow)
7
7
 
8
8
  ```
9
9
  ███╗ ██╗██╗ ██╗███╗ ███╗██████╗ ██╗ ██╗ ████████╗███████╗
@@ -18,16 +18,14 @@ Complete NumPy implementation for TypeScript and JavaScript
18
18
 
19
19
  **⚠️ Under active development** — API may change before v1.0
20
20
 
21
- A faithful NumPy 2.0+ implementation for TypeScript/JavaScript, validated against Python NumPy. **192 of 333 NumPy functions (57.7% complete)** covering array creation, manipulation, linear algebra, reductions, and more.
22
-
23
21
  ```bash
24
22
  npm install numpy-ts
25
23
  ```
26
24
 
27
25
  ## Why numpy-ts?
28
26
 
29
- - **📊 Extensive API** — 120+ NumPy functions with 1365+ tests validated against Python NumPy
30
- - **✅ NumPy-validated** — 1365+ test cases cross-validated against Python NumPy
27
+ - **📊 Extensive API** — **238 of 333 NumPy functions (71.5% coverage)**
28
+ - **✅ NumPy-validated** — 2000+ test cases cross-validated against Python NumPy
31
29
  - **🔒 Type-safe** — Full TypeScript support with shape and dtype inference
32
30
  - **🌐 Universal** — Works in Node.js and browsers with .npy/.npz file support
33
31
  - **🎯 Zero dependencies** — Pure TypeScript, no heavy external libraries
@@ -67,29 +65,29 @@ Progress toward complete NumPy API compatibility:
67
65
  | **Arithmetic** | 19/19 | 100% | ✅ |
68
66
  | **Array Creation** | 32/32 | 100% | ✅ |
69
67
  | **Array Manipulation** | 35/35 | 100% | ✅ |
68
+ | **Bit Operations** | 9/9 | 100% | ✅ |
70
69
  | **Broadcasting** | 3/3 | 100% | ✅ |
71
70
  | **Comparison** | 10/10 | 100% | ✅ |
72
71
  | **Hyperbolic** | 6/6 | 100% | ✅ |
72
+ | **I/O** | 8/8 | 100% | ✅ |
73
+ | **Indexing** | 20/20 | 100% | ✅ |
73
74
  | **Linear Algebra** | 9/9 | 100% | ✅ |
74
75
  | **Reductions** | 30/30 | 100% | ✅ |
76
+ | **Searching** | 6/6 | 100% | ✅ |
77
+ | **Sorting** | 6/6 | 100% | ✅ |
75
78
  | **Trigonometric** | 12/12 | 100% | ✅ |
76
- | **Indexing** | 3/20 | 15% | 🔴 |
77
- | **Bit Operations** | 0/9 | 0% | 🔴 |
78
79
  | **Exponential** | 0/9 | 0% | 🔴 |
79
80
  | **FFT** | 0/18 | 0% | 🔴 |
80
81
  | **Gradient** | 0/4 | 0% | 🔴 |
81
- | **I/O** | 0/8 | 0% | 🔴 |
82
82
  | **Linear Algebra (linalg)** | 0/19 | 0% | 🔴 |
83
83
  | **Logic** | 0/12 | 0% | 🔴 |
84
84
  | **Other Math** | 0/11 | 0% | 🔴 |
85
85
  | **Random** | 0/17 | 0% | 🔴 |
86
86
  | **Rounding** | 0/7 | 0% | 🔴 |
87
- | **Searching** | 0/6 | 0% | 🔴 |
88
87
  | **Set Operations** | 0/7 | 0% | 🔴 |
89
- | **Sorting** | 0/6 | 0% | 🔴 |
90
88
  | **Statistics** | 0/9 | 0% | 🔴 |
91
89
 
92
- **Overall: 192/333 functions (57.7% complete)**
90
+ **Overall: 238/333 functions (71.5% complete)**
93
91
 
94
92
  See the complete [API Reference](docs/API-REFERENCE.md) for detailed function list.
95
93
 
@@ -239,7 +237,7 @@ arr.sum(); // Type: number
239
237
 
240
238
  | Feature | numpy-ts | numjs | ndarray | TensorFlow.js |
241
239
  |---------|----------|-------|---------|---------------|
242
- | NumPy API Coverage | 192/333 (58%) | ~20% | Different | ML-focused |
240
+ | NumPy API Coverage | 238/333 (71%) | ~20% | Different | ML-focused |
243
241
  | TypeScript Native | ✅ Full | Partial | ❌ No | ✅ Yes |
244
242
  | NumPy Validated | ✅ 1365+ tests | Mostly | ❌ No | ❌ No |
245
243
  | .npy/.npz Files | ✅ v1/v2/v3 | ❌ No | ❌ No | ❌ No |