Commit Graph

10633 Commits

Author SHA1 Message Date
George Hotz
d39f21da8f scalar image is image [pr] (#7398)
* scalar image is image [pr]

* base property
2024-10-30 18:51:47 +08:00
George Hotz
76a41a1083 don't compare with pointer dtype (#7394)
* don't compare with pointer dtype

* more cleanup

* images are pointers

* handle IMAGE better

* cleaner test_image

* this work

* pr match

* cleanup
2024-10-30 17:48:27 +08:00
qazal
95390df02a save lines [pr] (#7373) 2024-10-30 17:34:00 +08:00
George Hotz
4e2895f8d2 safe changes from new dtype branch [pr] (#7397)
* safe changes from new dtype branch [pr]

* only image test on GPU
2024-10-30 17:18:48 +08:00
George Hotz
0ca241693b viz loads nothing by default [pr] (#7395) 2024-10-30 15:40:08 +08:00
qazal
5e2e5b2cdc finally big graph (#7293)
* real big graph

* extra lines
2024-10-30 13:58:09 +08:00
George Hotz
27995a2a04 vcount + cleanups (#7393)
* Revert "Revert "Restore vcount [pr] (#7390)" (#7392)"

This reverts commit 4ca53db604.

* ugh bugfix [pr]

* uops_to_dtypes function

* fixups

* varnames

* fix mypy

* just 4,8

* tests
2024-10-30 12:50:15 +08:00
George Hotz
32dd2dcba5 minor cleanups of cstyle [pr] (#7391)
* minor cleanups of cstyle [pr]

* work
2024-10-30 11:59:27 +08:00
George Hotz
4ca53db604 Revert "Restore vcount [pr] (#7390)" (#7392)
This reverts commit 1058f9c9ff.
2024-10-30 11:40:25 +08:00
George Hotz
1058f9c9ff Restore vcount [pr] (#7390)
* Revert "Revert "add vcount to PtrDtype (#7388)""

This reverts commit 399a5219dd.

* Revert "Revert "add tests to vcount stuff [pr] (#7389)""

This reverts commit cc8d6dbdf3.

* no ptr
2024-10-30 11:27:55 +08:00
George Hotz
399a5219dd Revert "add vcount to PtrDtype (#7388)"
This reverts commit b086584d64.
2024-10-30 10:56:52 +08:00
George Hotz
cc8d6dbdf3 Revert "add tests to vcount stuff [pr] (#7389)"
This reverts commit 1b7084899b.
2024-10-30 10:56:49 +08:00
George Hotz
1b7084899b add tests to vcount stuff [pr] (#7389) 2024-10-30 10:54:54 +08:00
George Hotz
b086584d64 add vcount to PtrDtype (#7388) 2024-10-30 10:43:54 +08:00
uuuvn
06a8700bfa Replace sqrtl (long double) with sqrt (double) for double (#7366) 2024-10-30 10:20:41 +08:00
gonutz
e7cbc6dc23 Fix ValueError in Yolo 8 example (#7387)
Calling

    python3 examples/yolov8.py ./test/models/efficientnet/Chicken.jpg

used to result in this error

    ValueError: Calling nonzero on 0d arrays is not allowed.

Using np.atleast_1d makes sure we avoid a zero-dimension array.

Co-authored-by: gonutz <gonutz@fake.mail>
2024-10-30 10:18:39 +08:00
chenyu
f389e1a8a0 test more special values for sin/cos/tan [pr] (#7386) 2024-10-29 21:13:37 -04:00
chenyu
33acbaeb24 reuse polyN in trig_poly float64 (#7385)
similar speed, less alu (151 v.s. 154 per sine) and simpler, the power of 2 thing should probably be done in polyN if needed
2024-10-29 20:45:56 -04:00
chenyu
6bf38c35e5 clean up transcendental frexp [pr] (#7384)
also added some unit tests for frexp
2024-10-29 18:51:37 -04:00
chenyu
99b82f5708 minor cleanup payne_hanek_reduction [pr] (#7383) 2024-10-29 17:59:18 -04:00
chenyu
f6abde95fa clean up Tensor._reduce (#7382)
use make_tuple and self.ndim
2024-10-29 17:23:57 -04:00
nimlgen
4ed2c40d48 qcom a bit cleaner (#7380) 2024-10-29 23:50:28 +03:00
chenyu
07ad6d20ed simpler commutative flipping condition (#7377)
`x.src[1].tuplize < x.src[0].tuplize` implies `x.src[0] is not x.src[1]`

also renamed cc -> op
2024-10-29 13:51:24 -04:00
chenyu
d3c192b056 Device method cleanup [pr] (#7375) 2024-10-29 12:49:47 -04:00
chenyu
f8a623b386 fix typing in Conv2d (#7374)
* fix typing in Conv2d

`self.padding: Union[int, List[int]]` was wrong

* fix that
2024-10-29 11:27:46 -04:00
qazal
7bd79f4922 pass viz render errors (#7369)
* pass viz render errors

* pcall
2024-10-29 22:48:27 +08:00
qazal
51c0c8d27e cachable small graph rewrite (#7371) 2024-10-29 22:28:13 +08:00
chenyu
9b81931a36 make_pair -> make_tuple [pr] (#7372)
it's used more often as generic tuple, also removed the default 2.
2024-10-29 10:27:39 -04:00
qazal
d803a9c7c8 global metadata try 2 (#7367) 2024-10-29 20:21:00 +08:00
George Hotz
2cfc7b6695 Index everywhere 2 (#7363)
* indexing everywhere [pr]

* fix tests
2024-10-29 19:29:40 +08:00
qazal
7149eabb34 assert set equality in TestTensorMetadata [pr] (#7364) 2024-10-29 19:29:29 +08:00
qazal
0ebdb136e8 revert metadata with graph_rewrite (#7353) (#7362)
This reverts commit 540e4179e7.
2024-10-29 19:16:31 +08:00
qazal
f2044cfb22 hotfix: if getenv("RUN_PROCESS_REPLAY") (#7361) 2024-10-29 18:51:29 +08:00
George Hotz
0af1212164 use assertEqual with new style uops [pr] (#7360) 2024-10-29 18:43:21 +08:00
George Hotz
0beb2d8f84 ptx indexing (#7359)
* ptx indexing

* shorter

* fix load/store
2024-10-29 18:29:44 +08:00
George Hotz
572499c71a add indexing to ops_python (#7358)
* add indexing to ops_python

* fix image
2024-10-29 18:11:03 +08:00
qazal
540e4179e7 global UOp to Metadata mapping + inverse DEBUG=2 metadata order [pr] (#7353)
* add ctx.buf_metadata [pr]

* revert metadata insertion order

* lint rename
2024-10-29 17:12:00 +08:00
George Hotz
2fdfcffe4c improve ci speed [pr] (#7357) 2024-10-29 17:00:35 +08:00
qazal
8fab7b21df everything is load (#7355)
* everything is load

* rename to ops
2024-10-29 16:47:33 +08:00
George Hotz
b647fa7514 rename MathTraits to maximum [pr] (#7356) 2024-10-29 16:43:04 +08:00
George Hotz
2bf55d8eda make ops more like tensor [pr] (#7352)
* make ops more like tensor [pr]

* tensor is simple math trait

* no shifts
2024-10-29 16:23:41 +08:00
George Hotz
3989bd2682 idiv + reciprocal [pr] (#7354)
* idiv + reciprocal

* remove upcast from div

* fix docs
2024-10-29 15:54:19 +08:00
Bhavya Gada
3419ae282d VIZ UI improvement: generic function for vscode opener (#7338)
* generic function for vscode opener

* eslint

* shorter

---------

Co-authored-by: qazal <qazal.software@gmail.com>
2024-10-29 15:02:04 +08:00
qazal
c03e1693fc shorter gate folding [pr] (#7350) 2024-10-29 14:49:32 +08:00
George Hotz
3e8225299c ext gate indexing (#7349)
* ext gate indexing

* copy paste better
2024-10-29 14:46:10 +08:00
Bhavya Gada
13ea4979d5 VIZ UI improvement: autoscroll kernel list when using arrow buttons (#7344) 2024-10-29 14:40:42 +08:00
George Hotz
d9d4dd6756 faster ci [pr] (#7348) 2024-10-29 14:01:44 +08:00
George Hotz
a5e0f59e41 move autogen to different CI runner [pr] (#7346)
* move autogen to different CI runner [pr]

* balance a bit

* readme back there

* compile enet in autogen
2024-10-29 13:35:22 +08:00
George Hotz
4cb236a495 index in cstyle (#7328)
* index only in cstyle

* fix prefix dtypes

* fix tests

* global indexing

* Revert "global indexing"

This reverts commit 4d507e8abb.

* fix image

* fix image

* ptx tests

* fix CUDA dtype rendering
2024-10-29 13:06:26 +08:00
George Hotz
f55c3dcff8 hotfix: bump ocelot 2024-10-29 12:46:24 +08:00