superfloat 0.16.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.
@@ -0,0 +1,255 @@
1
+ Metadata-Version: 2.4
2
+ Name: superfloat
3
+ Version: 0.16.0
4
+ Summary: sf: the Python library for Superfloat numbers (sf4 to sf16 fixed point) on the Atreides chip: arrays, PyTorch integration and GPU-style kernels.
5
+ License: # Superfloat SDK License Agreement
6
+
7
+ Copyright (c) 2026 Superfloat Private Limited (superfloat.si) ("Licensor"). All rights reserved, except as granted below.
8
+
9
+ By installing, copying or using the Software, you agree to this Agreement. If you do not agree, do not use it. If you accept on behalf of an organization, you confirm you have the authority to bind it.
10
+
11
+ ## 1. Definitions
12
+
13
+ - **"Software"** means the sf Python package, its kernel language, PyTorch integration, lowering specification, golden vectors, documentation and any updates Licensor provides under this Agreement.
14
+ - **"Superfloat Hardware"** means Atreides processors and any other processors designed by or for Licensor and sold or authorized by Licensor.
15
+ - **"Authorized Target"** means (a) Superfloat Hardware, (b) Licensor's simulators, emulators and RTL models of Superfloat Hardware, and (c) the Software's host reference and mock devices, when used as allowed in Section 2.
16
+ - **"Application"** means your program that uses the Software and adds substantial functionality to it.
17
+ - **"Competing Hardware"** means any processor, accelerator, FPGA bitstream or circuit design that is not Superfloat Hardware.
18
+
19
+ ## 2. License grant
20
+
21
+ Subject to this Agreement, Licensor grants you a free, worldwide, non-exclusive, non-transferable, revocable license to:
22
+
23
+ 1. **Use** the Software to develop, test, debug and run Applications on Authorized Targets.
24
+ 2. **Develop on any computer.** Run the Software on any CPU or GPU to develop, test or evaluate work intended for Superfloat Hardware, and for research and evaluation of the SF number format. This includes running the host reference.
25
+ 3. **Modify** the Software for your own use under this Agreement.
26
+ 4. **Distribute Applications**, with the parts of the Software they need, if each recipient is bound by terms at least as protective as these, and you keep all notices.
27
+ 5. **Publish results.** Publish research and benchmark results obtained with the Software, if you state the Software version and method.
28
+
29
+ ## 3. Restrictions
30
+
31
+ You may not, and may not let others:
32
+
33
+ 1. **Use the Software in production on Competing Hardware,** or to build, program or tune a product for Competing Hardware. Section 2.2 is the only exception.
34
+ 2. **Port or translate.** Create a compiler back end, translation layer, emulator or compatibility layer that makes the Software, its kernels, its lowering specification or its output run on Competing Hardware.
35
+ 3. **Design from it.** Use the lowering specification, golden vectors or arithmetic definitions to design, verify or validate Competing Hardware.
36
+ 4. **Compete with it.** Distribute the Software on its own, or offer it or a modified version as a standalone SDK or hosted service.
37
+ 5. **Remove notices,** or use the Superfloat or Atreides names and marks, except to state accurately that an Application works with them.
38
+ 6. **Fork publicly** except as needed to contribute to the Software under Section 5.
39
+
40
+ Viewing the source code is permitted. It grants no rights beyond those in this Agreement.
41
+
42
+ ## 4. Patents and hardware rights
43
+
44
+ 1. **Reservation.** No rights are granted under any patent, or in any hardware design, RTL, netlist, layout or mask work. This includes the Superfloat hardware designs, which are not part of the Software. Publishing the Software is not a license to implement its arithmetic in hardware.
45
+ 2. **Limited patent permission.** To the extent a Licensor patent would otherwise be infringed by your use of the Software as Section 2 allows, Licensor will not assert it against that use.
46
+ 3. **Defensive termination.** If you bring a patent claim against Licensor or any user of the Software over the Software or Superfloat Hardware, your rights under this Agreement end on the date you file it.
47
+
48
+ ## 5. Contributions and feedback
49
+
50
+ If you submit code, documentation or feedback, you grant Licensor a perpetual, irrevocable, worldwide, royalty-free license, with the right to sublicense, to use it for any purpose, including under other license terms, and you confirm you have the right to grant this.
51
+
52
+ ## 6. Third-party software
53
+
54
+ Third-party components, including NumPy and PyTorch, are licensed by their own owners under their own terms.
55
+
56
+ ## 7. Term and termination
57
+
58
+ This Agreement lasts until terminated. It ends automatically if you breach it and do not cure the breach within 30 days of notice, or at once for a breach of Section 3. Licensor may also end it for all users of a version on 90 days' public notice. On termination, stop using and delete the Software. Applications lawfully distributed earlier may remain with their recipients. Sections 3, 4, 8, 9 and 10 survive.
59
+
60
+ ## 8. Disclaimer of warranty
61
+
62
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IT IS NOT DESIGNED FOR SAFETY-CRITICAL USE.
63
+
64
+ ## 9. Limitation of liability
65
+
66
+ TO THE EXTENT THE LAW ALLOWS, LICENSOR IS NOT LIABLE FOR INDIRECT, INCIDENTAL, SPECIAL, CONSEQUENTIAL OR PUNITIVE DAMAGES, OR LOST PROFITS OR DATA. LICENSOR'S TOTAL LIABILITY IS LIMITED TO USD 100.
67
+
68
+ ## 10. General
69
+
70
+ - **Export.** You must comply with applicable export control and sanctions laws.
71
+ - **Governing law.** The laws of India, with the courts of Kerala having exclusive jurisdiction.
72
+ - **Changes.** A new version of this Agreement applies to versions of the Software released with it.
73
+ - **Entire agreement.** This is the entire agreement about the Software. If a term is unenforceable, the rest stays in force. No waiver is effective unless written.
74
+ - **Other terms.** A separate signed agreement with Licensor takes priority over this one.
75
+
76
+ Project-URL: Homepage, https://superfloat.si
77
+ Project-URL: Documentation, https://docs.superfloat.si
78
+ Project-URL: Source, https://github.com/superfloat/superfloat.python
79
+ Requires-Python: >=3.10
80
+ Description-Content-Type: text/markdown
81
+ License-File: LICENSE
82
+ Requires-Dist: numpy>=1.24
83
+ Provides-Extra: torch
84
+ Requires-Dist: torch>=2.4; extra == "torch"
85
+ Provides-Extra: test
86
+ Requires-Dist: pytest>=8; extra == "test"
87
+ Requires-Dist: hypothesis>=6; extra == "test"
88
+ Requires-Dist: numpy>=1.24; extra == "test"
89
+ Requires-Dist: torch>=2.4; extra == "test"
90
+ Requires-Dist: scikit-learn>=1.3; extra == "test"
91
+ Provides-Extra: hf
92
+ Requires-Dist: transformers>=5.20; extra == "hf"
93
+ Requires-Dist: accelerate>=1.0; extra == "hf"
94
+ Provides-Extra: xdist
95
+ Requires-Dist: pytest-xdist>=3; extra == "xdist"
96
+ Dynamic: license-file
97
+
98
+ # sf: Superfloat in Python
99
+
100
+ `sf` is the Python library for the Superfloat number formats (sf4 to sf16)
101
+ used by the Atreides chip. You write normal Python, NumPy-style arrays,
102
+ PyTorch models or GPU kernels, and `sf` makes sure every number behaves
103
+ exactly as the chip would compute it, bit for bit, and tells you when
104
+ something overflowed, underflowed, divided by zero or went invalid.
105
+
106
+ ## What is Superfloat, in one paragraph
107
+
108
+ An sf16 value is a 16-bit signed fixed-point number strictly between -1 and 1.
109
+ There is no exponent, no NaN, no infinity. Adding or subtracting can push a
110
+ value past the edge: it then sticks at the largest value (saturates).
111
+ Multiplying two small values can land on 0 (underflows). Dividing `a / b`
112
+ only works when `|a| < |b|`. The chip does exactly this, and so does `sf`.
113
+
114
+ ## What you can do with it
115
+
116
+ **1. Scalars** (Stage 1.0)
117
+
118
+ ```python
119
+ import sf
120
+
121
+ a, b = sf.sf16(0.5), sf.sf16(0.25)
122
+ a + b # sf16(0.75)
123
+ a * b # sf16(0.125)
124
+ b / a # sf16(0.5)
125
+ a / b # SFOverflowError: 2.0 does not fit in sf16
126
+ a < 1 # True, comparisons are exact
127
+
128
+ with sf.errstate(over="ignore"): # or just let it saturate, like the chip
129
+ sf.sf16(0.75) + 0.5 # sf16(0.999969482421875)
130
+ ```
131
+
132
+ **2. Arrays, matmul, and the device** (Stage 1.1)
133
+
134
+ ```python
135
+ x = sf.array([0.10, -0.25, 0.50], dtype=sf.sf16) # lives on the host
136
+ h = sf.asarray(inputs, dtype=sf.sf16, device="atreides")
137
+ w = sf.asarray(weights, dtype=sf.sf16, device="atreides")
138
+ y = h @ w # runs on the device
139
+ y.status # what saturated, if anything
140
+ y.numpy() # back to floats
141
+ ```
142
+
143
+ Before anything is sent to the device, `sf` checks on the host whether the
144
+ answer is already known (a divide by zero, a result that must saturate, a
145
+ range that cannot saturate). Anything the host can decide never reaches the
146
+ chip. This is the rule the whole device path follows.
147
+
148
+ **3. PyTorch models** (Stage 2)
149
+
150
+ ```python
151
+ import sf.torch as sft
152
+
153
+ model = sft.convert(model, dtype=sf.sf16) # Linear, Conv2d and Hugging Face Conv1D now compute in sf16
154
+ fast = torch.compile(model, backend="superfloat") # sends the SF layers to the device
155
+ out = fast(x)
156
+ sft.last_status(model) # per-layer saturation report
157
+ ```
158
+
159
+ Weights and activations are scaled so the chip's -1..1 range is used well,
160
+ and by default the scale leaves enough headroom that nothing can saturate
161
+ inside a layer. Training still works (straight-through gradients).
162
+
163
+ **4. Your own GPU kernels** (Stage 3)
164
+
165
+ ```python
166
+ @sf.jit # Triton style
167
+ def axpy(a, x_ptr, y_ptr, out_ptr, n, BLOCK: sf.constexpr):
168
+ offs = sf.program_id(0) * BLOCK + sf.arange(0, BLOCK)
169
+ mask = offs < n
170
+ x = sf.load(x_ptr + offs, mask=mask)
171
+ y = sf.load(y_ptr + offs, mask=mask)
172
+ sf.store(out_ptr + offs, sf.fma(a, x, y), mask=mask)
173
+
174
+ dev = sf.device("atreides-sim")
175
+ x, y, out = dev.upload(xs), dev.upload(ys), dev.alloc(n)
176
+ r = axpy[(sf.cdiv(n, 256),)](sf.sf16(0.75), x, y, out, n, BLOCK=256)
177
+ r.status, r.cycles # exact events, simulated cycles
178
+ ```
179
+
180
+ There is also a CUDA-style `@sf.kernel` with `thread_idx`, shared memory and
181
+ barriers. Kernels run on a simulator today (`atreides-sim`) which has two
182
+ independent back ends, a Python interpreter and generated C, that must agree
183
+ bit for bit. `atreides-hw` is reserved for the real chip and waits for its
184
+ driver.
185
+
186
+ ## Install and run
187
+
188
+ ```
189
+ pip install superfloat # the library; in Python: import sf
190
+ pip install "superfloat[torch]" # with PyTorch, for sf.torch
191
+ ```
192
+
193
+ From a checkout, for development:
194
+
195
+ ```
196
+ pip install -e ".[test]" # library + test tools
197
+ pip install -e ".[torch]" # add PyTorch for sf.torch
198
+ pytest # the full per-commit suite (about 8 min)
199
+ pytest -m "not slow" # quick run while developing (about 40 s)
200
+ python examples/stage_3_tour.py # see the kernels in action
201
+ ```
202
+
203
+ Only NumPy is required. The C kernel back end needs a C compiler (`cc`).
204
+
205
+ ## Errors: what happens when a number does not fit
206
+
207
+ | Event | Meaning | Default |
208
+ |---|---|---|
209
+ | overflow | result saturated at the largest value | raise `SFOverflowError` |
210
+ | underflow | result became 0 | warn `SFUnderflowWarning` |
211
+ | divide | divided by zero | raise `SFZeroDivisionError` |
212
+ | invalid | no valid answer (sqrt of a negative) | raise `SFInvalidError` |
213
+
214
+ Change it per event with `sf.seterr(over="warn")` or inside a block with
215
+ `with sf.errstate(all="ignore"):`. The value you get back is always the
216
+ chip's value; the policy only decides whether Python also raises or warns.
217
+
218
+ ## How it is tested
219
+
220
+ Every result is compared as integer codes, never with float tolerances,
221
+ against an independent oracle written with exact fractions. 732 tests run
222
+ on every commit (Python 3.10, 3.12, 3.13) and the exhaustive sf16 sweep
223
+ runs nightly. The full matrix of what is checked, against what, at which
224
+ widths and on which target is in [docs/TESTING.md](https://github.com/superfloat/superfloat.python/blob/main/docs/TESTING.md).
225
+
226
+ ## What is done and what is not
227
+
228
+ Done: Stages 1.0, 1.1, 2 (2.0, 2.1, 2.2) and 3 (3.0 to 3.3) of the plan,
229
+ each reviewed independently with all findings fixed.
230
+
231
+ Not done:
232
+
233
+ * Running on the real chip. Everything above is proved on the host, a mock
234
+ and a simulator. The hardware gate needs the custom compiler, a driver to
235
+ attach, and answers to the open hardware questions (division and sqrt
236
+ fault values, accumulation order and width, `mat_fma` meaning, readable
237
+ flags). See `NOTES.md`.
238
+ * Stage 1.2 diagnostics (`sf.explain`) and Stage 2.3 PyTorch device tensors,
239
+ deferred on purpose.
240
+
241
+ ## Documentation
242
+
243
+ | File | What it holds |
244
+ |---|---|
245
+ | [docs/API.md](https://github.com/superfloat/superfloat.python/blob/main/docs/API.md) | Every function, decorator and object for Stages 1 to 3, with syntax and the Python semantics of SF values. The reference to use when writing tests against the simulator. |
246
+ | [docs/TESTING.md](https://github.com/superfloat/superfloat.python/blob/main/docs/TESTING.md) | The testing matrix, the test files, how to run each gate. |
247
+ | [docs/DETAILS.md](https://github.com/superfloat/superfloat.python/blob/main/docs/DETAILS.md) | Module map, exact semantics tables, every config option, design notes per stage. |
248
+ | [spec/](https://github.com/superfloat/superfloat.python/blob/main/spec/ops.py) | The lowering spec for the compiler: every IR op with operands, results, events, memory effects and legal rewrites, plus golden vectors. Generated pages under `website/compiler/`. Run `python tools/gen_spec.py` after editing `spec/ops.py`. |
249
+ | [NOTES.md](https://github.com/superfloat/superfloat.python/blob/main/NOTES.md) | Design decisions, open hardware questions, review history. |
250
+ | `examples/` | A runnable tour per stage. |
251
+ | `website/` | The developer docs site at [docs.superfloat.si](https://docs.superfloat.si) (Mintlify, hand-written). |
252
+
253
+ ## License
254
+
255
+ sf is free to use for developing and running software on Atreides hardware, under the [Superfloat SDK License Agreement](https://github.com/superfloat/superfloat.python/blob/main/LICENSE). Copyright (c) 2026 Superfloat Private Limited ([superfloat.si](https://superfloat.si)).
@@ -0,0 +1,46 @@
1
+ sf/__init__.py,sha256=G2gB6q-STY7SpHuwRt7QZ6VCqD3bmkRRQv0um5cYIoE,3683
2
+ sf/_accumulate.py,sha256=HA9X8Oh6T45nYtID5m4u5uLF4q3be-ycehJri_RdGLc,3554
3
+ sf/_array.py,sha256=1iiHy_tumu2pWX451dvk2QLv7Gw7S3PwX3MU-21Mtvw,35553
4
+ sf/_cache.py,sha256=O-Q4ans2FrW9if0omhmJIeVEh1_Jy-hp-xJYAcpOmHE,2751
5
+ sf/_config.py,sha256=OmDIUEodeonF2pCDNkOqLsOagwGX7Bsl_f12DcHGVVo,5389
6
+ sf/_device.py,sha256=AzVukYl1jxE9N-7MgPiY_VWZq1CtHZ5Y08Weev7MgvQ,9540
7
+ sf/_errors.py,sha256=mSkcsA1t520sHvmn22HOlKD6inCxW82R8Z58kethU14,3208
8
+ sf/_errstate.py,sha256=SM8JOx52tAk5vgh3c8oV3qZqyHrh6R6p9YgS0U8AHGM,5973
9
+ sf/_fastmx.py,sha256=0E2_KIq8roCd0TFvKcxOE0hwXj_tzHGkkV75tRNcnqc,8024
10
+ sf/_format.py,sha256=eTi4LPf-rplst7l5SvpKRjV5PMHBhsdu1g_tH1JPiXc,4120
11
+ sf/_functions.py,sha256=S2_HLnx__7H4uLaXBnW3PeTYvJHEmADz3lpc9caSnJY,14238
12
+ sf/_heuristic.py,sha256=ppnH2mla1ihOYBQ-PlPu8stqbYWE_Utzi3ePYrxoDpk,8006
13
+ sf/_intops.py,sha256=H2x0QvfR1JsLO1nJ5J059SxceB3ghE7DpuG9V3-hWEk,23119
14
+ sf/_linalg.py,sha256=eyMfkAAmDIScdDtRNJ6wPG1yYOPvOOwoH8y41AB1ueg,16785
15
+ sf/_preflight.py,sha256=_8wE_yTKR7DY46qPU1gd6uPt5mEP1c4hGhz_K28qWg0,10160
16
+ sf/_reference.py,sha256=Nw_VeDScDEA3N3mxw_uueoO2AK0uuBQgujkOKs9TX2Q,6631
17
+ sf/_scalar.py,sha256=lFYvS4QsWr3j7ZytS73xbXhFfsvaHM5t-T9n2KgzQJU,16076
18
+ sf/_status.py,sha256=ORGPjRMm9uhhC4_yJTNbv4Q1nAfRUmAPi3zAzGpTnbU,2692
19
+ sf/_vectorized.py,sha256=csBerMSwnIpPbvwTRvlkGUt0PKB285uSS9Pt9GeFQVs,5767
20
+ sf/kernels/__init__.py,sha256=lQ1HyxzznUbP3jkXOfzCcHCU0FP-_uxU8zfq0CPK2XU,593
21
+ sf/kernels/_cgen.py,sha256=peEPvW-Ss0OJsV1p_VOLX1PJgUmz125bLJRoygGHzvU,22612
22
+ sf/kernels/_interp.py,sha256=mWBvU2Lzeg83yY8FgXoVA5viJ32XCeFwQxnJfccx_Gk,12579
23
+ sf/kernels/_ir.py,sha256=Zl7r_1wm7u5xdiDmHOJjM8kh7nsEBcaZE1DDwvfPcdE,7330
24
+ sf/kernels/_lang.py,sha256=qvoKfvmjH4Dcdi0n3su3LNBzjvqW-AhXDglhsOJ2sDs,13937
25
+ sf/kernels/_runtime.py,sha256=owB2pu58EeHXa2QsgyCyTcjZiAZha__jZ5xry1VyKnM,23339
26
+ sf/kernels/_sym.py,sha256=u5yhpc9T2V2fvAIY8HlqVXJJNc883-oGQVqCB1pg6ps,16680
27
+ sf/kernels/sf16_builtins.h,sha256=eDFP6WdeTWIg_VGwhmSs4ZXwW9d7Msp8Orum4eaTlnM,5733
28
+ sf/torch/__init__.py,sha256=Mj59G57AJu7KXhzsUkQ0hrgIWZOkZPGgXvLbV7QL3Rw,5839
29
+ sf/torch/_attention.py,sha256=F6Ij-DTWh6_XvJ82SWOxv5wFGI86b0MTsSWJvZ9lHI0,11130
30
+ sf/torch/_autocast.py,sha256=6ItPlmx_GsdXa7WqN4vp9I5kXyEiLskO6l39kTS4LRY,4961
31
+ sf/torch/_backend.py,sha256=AolsjJM9gov-NfGWhYGgR0Fad6CCXUHtmbJpFDRTXqg,6889
32
+ sf/torch/_configs.py,sha256=9sgBQbDZSL8mxxX5MWHW-zf38MXPscr5mKhIGP9RjR4,7800
33
+ sf/torch/_core.py,sha256=QV-2MTPoiv-h5yYE9QMcBM4RkVczklt-Q9WFSNH2E2c,37231
34
+ sf/torch/_intops.py,sha256=7qDdXYwrTLbVsDM6E-WK-tZjMpTQXVYSPnjZFJl35qg,2584
35
+ sf/torch/_modules.py,sha256=GeV74jwG2foG7XzuV4r8i71bWizz1yJ5MXbzhsjJIGs,26053
36
+ sf/torch/_mxfp4.py,sha256=RygPSKesJzmuPN86ImxY4kvhE0dEuPW5s9x-Rgr7j8U,8633
37
+ sf/torch/_ops.py,sha256=QAODf1IXW8wFstpCtf9n7diIu9b1UmCw5gcDAtN_Cdg,17376
38
+ sf/torch/_scopes.py,sha256=XAcQpDJ99IpSqXaPIjFJo0yPZiQe275dl5aOKXf3t8Q,18602
39
+ sf/torch/_status.py,sha256=Vp-74c4eP2cpEK7BfPAYkCB4GsxPRSdefcyXS73FtPs,5957
40
+ sf/torch/_widths.py,sha256=DCcOeplS1daZs0Y3-1fjvVdzrd04anjd432vExsx7U8,15421
41
+ sf/torch/data/cost_table_v0.json,sha256=2Nqo5ALklHrxWWVygqlMj_aKxuDLHlRRmQrdNpfNGQ8,43037
42
+ superfloat-0.16.0.dist-info/licenses/LICENSE,sha256=PQYU_RNjA_HeHtWXA6EzP0AGqtfQV51OAWSXNz1HqJI,5667
43
+ superfloat-0.16.0.dist-info/METADATA,sha256=3ST9ADsToli-XYUrE3vdYAxXAHUktlZpPXoYSikxVow,14659
44
+ superfloat-0.16.0.dist-info/WHEEL,sha256=mOdXR9C3wMVov7cSY8PY-XCzo3SmmWCHvGQr5csJoao,91
45
+ superfloat-0.16.0.dist-info/top_level.txt,sha256=oU2b2msmcEmVnuSGukku4hZdlPlbxggXw2m80NpoKsw,3
46
+ superfloat-0.16.0.dist-info/RECORD,,
@@ -0,0 +1,5 @@
1
+ Wheel-Version: 1.0
2
+ Generator: setuptools (84.2.1)
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
5
+
@@ -0,0 +1,70 @@
1
+ # Superfloat SDK License Agreement
2
+
3
+ Copyright (c) 2026 Superfloat Private Limited (superfloat.si) ("Licensor"). All rights reserved, except as granted below.
4
+
5
+ By installing, copying or using the Software, you agree to this Agreement. If you do not agree, do not use it. If you accept on behalf of an organization, you confirm you have the authority to bind it.
6
+
7
+ ## 1. Definitions
8
+
9
+ - **"Software"** means the sf Python package, its kernel language, PyTorch integration, lowering specification, golden vectors, documentation and any updates Licensor provides under this Agreement.
10
+ - **"Superfloat Hardware"** means Atreides processors and any other processors designed by or for Licensor and sold or authorized by Licensor.
11
+ - **"Authorized Target"** means (a) Superfloat Hardware, (b) Licensor's simulators, emulators and RTL models of Superfloat Hardware, and (c) the Software's host reference and mock devices, when used as allowed in Section 2.
12
+ - **"Application"** means your program that uses the Software and adds substantial functionality to it.
13
+ - **"Competing Hardware"** means any processor, accelerator, FPGA bitstream or circuit design that is not Superfloat Hardware.
14
+
15
+ ## 2. License grant
16
+
17
+ Subject to this Agreement, Licensor grants you a free, worldwide, non-exclusive, non-transferable, revocable license to:
18
+
19
+ 1. **Use** the Software to develop, test, debug and run Applications on Authorized Targets.
20
+ 2. **Develop on any computer.** Run the Software on any CPU or GPU to develop, test or evaluate work intended for Superfloat Hardware, and for research and evaluation of the SF number format. This includes running the host reference.
21
+ 3. **Modify** the Software for your own use under this Agreement.
22
+ 4. **Distribute Applications**, with the parts of the Software they need, if each recipient is bound by terms at least as protective as these, and you keep all notices.
23
+ 5. **Publish results.** Publish research and benchmark results obtained with the Software, if you state the Software version and method.
24
+
25
+ ## 3. Restrictions
26
+
27
+ You may not, and may not let others:
28
+
29
+ 1. **Use the Software in production on Competing Hardware,** or to build, program or tune a product for Competing Hardware. Section 2.2 is the only exception.
30
+ 2. **Port or translate.** Create a compiler back end, translation layer, emulator or compatibility layer that makes the Software, its kernels, its lowering specification or its output run on Competing Hardware.
31
+ 3. **Design from it.** Use the lowering specification, golden vectors or arithmetic definitions to design, verify or validate Competing Hardware.
32
+ 4. **Compete with it.** Distribute the Software on its own, or offer it or a modified version as a standalone SDK or hosted service.
33
+ 5. **Remove notices,** or use the Superfloat or Atreides names and marks, except to state accurately that an Application works with them.
34
+ 6. **Fork publicly** except as needed to contribute to the Software under Section 5.
35
+
36
+ Viewing the source code is permitted. It grants no rights beyond those in this Agreement.
37
+
38
+ ## 4. Patents and hardware rights
39
+
40
+ 1. **Reservation.** No rights are granted under any patent, or in any hardware design, RTL, netlist, layout or mask work. This includes the Superfloat hardware designs, which are not part of the Software. Publishing the Software is not a license to implement its arithmetic in hardware.
41
+ 2. **Limited patent permission.** To the extent a Licensor patent would otherwise be infringed by your use of the Software as Section 2 allows, Licensor will not assert it against that use.
42
+ 3. **Defensive termination.** If you bring a patent claim against Licensor or any user of the Software over the Software or Superfloat Hardware, your rights under this Agreement end on the date you file it.
43
+
44
+ ## 5. Contributions and feedback
45
+
46
+ If you submit code, documentation or feedback, you grant Licensor a perpetual, irrevocable, worldwide, royalty-free license, with the right to sublicense, to use it for any purpose, including under other license terms, and you confirm you have the right to grant this.
47
+
48
+ ## 6. Third-party software
49
+
50
+ Third-party components, including NumPy and PyTorch, are licensed by their own owners under their own terms.
51
+
52
+ ## 7. Term and termination
53
+
54
+ This Agreement lasts until terminated. It ends automatically if you breach it and do not cure the breach within 30 days of notice, or at once for a breach of Section 3. Licensor may also end it for all users of a version on 90 days' public notice. On termination, stop using and delete the Software. Applications lawfully distributed earlier may remain with their recipients. Sections 3, 4, 8, 9 and 10 survive.
55
+
56
+ ## 8. Disclaimer of warranty
57
+
58
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IT IS NOT DESIGNED FOR SAFETY-CRITICAL USE.
59
+
60
+ ## 9. Limitation of liability
61
+
62
+ TO THE EXTENT THE LAW ALLOWS, LICENSOR IS NOT LIABLE FOR INDIRECT, INCIDENTAL, SPECIAL, CONSEQUENTIAL OR PUNITIVE DAMAGES, OR LOST PROFITS OR DATA. LICENSOR'S TOTAL LIABILITY IS LIMITED TO USD 100.
63
+
64
+ ## 10. General
65
+
66
+ - **Export.** You must comply with applicable export control and sanctions laws.
67
+ - **Governing law.** The laws of India, with the courts of Kerala having exclusive jurisdiction.
68
+ - **Changes.** A new version of this Agreement applies to versions of the Software released with it.
69
+ - **Entire agreement.** This is the entire agreement about the Software. If a term is unenforceable, the rest stays in force. No waiver is effective unless written.
70
+ - **Other terms.** A separate signed agreement with Licensor takes priority over this one.
@@ -0,0 +1 @@
1
+ sf