qazal
2649e87546
delete the fake buffer from const ( #8355 )
...
* delete the fake buffer from const
* fix test_sink_childless_const_alt
* it should be CONST(VIEW(DEVICE))
2024-12-21 04:20:28 +08:00
George Hotz
b7499764f5
horfix: have viz hide the stupid -1 BUFFERs
2024-12-20 10:47:44 -08:00
chenyu
cd79a904c5
add back explicit dict[DType, str] in ptx [pr] ( #8352 )
2024-12-20 13:19:48 -05:00
George Hotz
074315ec08
hotfix: simpler test_mnist_model
2024-12-20 10:18:17 -08:00
chenyu
20eebbc61a
minor PTX cleanups [pr] ( #8351 )
2024-12-20 12:52:53 -05:00
qazal
59f4b8da95
Tensor uop spec ( #8311 )
...
* Tensor uop spec
* minor
* feedback
* restrict ShapeTracker of VIEW(BUFFER) to contiguous
* in image base mutates, how do we rewrite the view?
* cast post realize
* now ucache errors
* how strict can this be?
* put constraints on EMPTY
* merge
* save lines
* import import
* overloaded assign target
* more strict
* fine don't overload it
* more
* actually, this is better
* and it even exists
* this way it works for BUFFER
* Revert "this way it works for BUFFER"
This reverts commit 71c15f6b14 .
* make it like linearize.py
* assign take 4
* minor
* all int, space and that's already base
* target
---------
Co-authored-by: George Hotz <72895+geohot@users.noreply.github.com >
2024-12-20 23:47:40 +08:00
qazal
5776ea9386
hotfix: account for all changes in process_replay early stopping [pr] ( #8348 )
2024-12-20 23:46:46 +08:00
chenyu
e63c7818dc
few type cleanups [pr] ( #8347 )
2024-12-20 01:56:01 -05:00
George Hotz
82833f1b3c
a little more typing [pr] ( #8346 )
...
* a little more typing [pr]
* few more
2024-12-19 22:09:52 -08:00
George Hotz
62e5d96446
more typing work [pr] ( #8345 )
2024-12-19 21:46:35 -08:00
George Hotz
9c77e9f9b7
replace Tuple with tuple [pr] ( #8344 )
...
* replace Tuple with tuple [pr]
* replace List with list [pr]
* replace Dict with dict [pr]
* replace Set with set [pr]
2024-12-19 21:27:56 -08:00
George Hotz
adcdc583a2
small cleanups [pr] ( #8343 )
...
* small cleanups [pr]
* GPU suppress
2024-12-19 21:20:46 -08:00
George Hotz
9f306e12ac
hotfix: test_net_speed can't backward before realize
2024-12-19 20:32:59 -08:00
George Hotz
aa9462c29b
fix (some) requires_grad [pr] ( #8342 )
2024-12-19 19:34:14 -08:00
Harald Schäfer
7059459648
Openpilot compile: fix for openpilot use ( #8338 )
...
* compile3 changes
* merge conflict
* merge conflict
* give dm npy for now
* Revert "give dm npy for now"
This reverts commit bfd980da7d2c2bab5b073127442c361922032ba1.
* updates
* Always float32 floats
* Update compile3.py
* Update compile3.py
---------
Co-authored-by: ZwX1616 <zwx1616@gmail.com >
2024-12-19 19:43:15 -05:00
chenyu
7153f7709f
update test_merge_view_recursion_err2 [pr] ( #8339 )
...
the view was not created through View.create, updated the test to show the expected behavior
2024-12-19 18:29:34 -05:00
chenyu
2bf47b75da
temp fix for symbolic shape view add [pr] ( #8337 )
...
something is still wrong with symbolic shape shrink, but it should not recurse forever
2024-12-19 16:10:42 -05:00
chenyu
791a80a1c7
add failed merge view example to test_simplify_valid_idx [pr] ( #8334 )
...
* add failed merge view example to test_simplify_valid_idx [pr]
* !=True is fine
2024-12-19 12:54:03 -05:00
qazal
8e266091fb
tensor const spec [pr] ( #8331 )
2024-12-19 22:41:30 +08:00
George Hotz
0ad264ed2d
new from uops [pr] ( #8330 )
...
* new from uops [pr]
* mem_estimate is it's own thing
2024-12-18 23:42:58 -08:00
George Hotz
2aa39d03cd
cleanups from Estimate [pr] ( #8329 )
2024-12-18 23:01:14 -08:00
George Hotz
3a9ca62b9e
get_single_element [pr] ( #8328 )
2024-12-18 22:23:45 -08:00
geohotstan
423d823c50
add GatherND and ScatterND to onnx ops ( #8241 )
...
* implemented
* this implementation is now correct
* this is fine I guess
* better variable names
* finally correct gathernd
* add a note
* eh just leave it at this for now
* teeny adjustment
2024-12-19 00:35:04 -05:00
chenyu
accc186c8b
remove a leading 1 check in _reshape_mask [pr] ( #8327 )
...
the only possible mask for it is either (0, 0) or (0, 1). so the logic is no-op
2024-12-18 19:30:10 -05:00
chenyu
8a8eaa1ed9
minor change to _reshape_mask [pr] ( #8324 )
...
formatting before logic change
2024-12-18 16:29:12 -05:00
George Hotz
6608ba316d
add size of the buffer to the ptr dtype ( #8322 )
2024-12-18 12:46:35 -08:00
George Hotz
52243b258c
move flops_mem to renderer [pr] ( #8320 )
2024-12-18 12:13:17 -08:00
chenyu
d2ee304337
minor cleanup to _reshape_mask [pr] ( #8321 )
...
removed usused mask check, and combined if blocks
2024-12-18 15:09:33 -05:00
chenyu
b4bb8de7f4
remove Sigmoid from function.py [pr] ( #8318 )
2024-12-18 13:23:38 -05:00
George Hotz
8f95b578f6
use Estimates class [pr] ( #8319 )
...
* use Estimates class [pr]
* frozen dataclass
2024-12-18 10:19:32 -08:00
chenyu
63f195729d
add gguf_load to doc [pr] ( #8314 )
...
Co-authored-by: George Hotz <72895+geohot@users.noreply.github.com >
2024-12-18 12:44:09 -05:00
George Hotz
bd9c015b09
tests from grad uop path [pr] ( #8313 )
2024-12-18 09:25:05 -08:00
George Hotz
6a1987f9f9
hotfix: detach is not a metaop
2024-12-18 09:23:42 -08:00
qazal
fddaeb6344
scheduler deduping spec and asserts [pr] ( #8307 )
...
Co-authored-by: George Hotz <72895+geohot@users.noreply.github.com >
2024-12-18 09:21:41 -08:00
leopf
c5ae66215a
[pr] move has_valid into pm_lowerer ( #8308 )
...
* [pr] move has_valid into pm_lowerer
* simpler
2024-12-18 09:05:18 -08:00
qazal
69eb55a529
bugfix: dtype mismatch in TestAssign.test_double_assign_alt [pr] ( #8310 )
2024-12-18 22:29:07 +08:00
George Hotz
32df46cd73
test const pattern [pr] ( #8304 )
...
* test const pattern [pr]
* add model to test_tiny
2024-12-17 23:34:17 -08:00
Jyotirmaya Mahanta
45f2fb82d5
add failing tests for merge views ( #8306 )
...
* add failing tests for merge views
* assert is not none
* make linter happy
2024-12-18 01:27:38 -05:00
George Hotz
801e199196
change buffer to not be pointer [pr] ( #8302 )
2024-12-17 16:47:51 -08:00
chenyu
4e2d98638d
redundant shape simplify in __unsafe_resize [pr] ( #8301 )
...
also done in View.create.
2024-12-17 19:00:45 -05:00
chenyu
a9f46ebf70
un1d -> unravel [pr] ( #8300 )
...
numpy/torch has a similar function called `unravel_index`
2024-12-17 18:08:37 -05:00
chenyu
66b92b6061
unused case where View adds invalid masked view [pr] ( #8299 )
...
code path does not hit this, and we might want to assert if it ever hits
2024-12-17 17:31:01 -05:00
chenyu
513d765c9e
remove duplicated canonicalize mask in __unsafe_resize [pr] ( #8296 )
...
also more comments and type annotation
2024-12-17 16:54:39 -05:00
qazal
673a76398a
fix viz with untracked graph_rewrite calls ( #8298 )
...
* fix viz with untracked graph_rewrite calls
* mark as green
2024-12-17 23:37:53 +02:00
qazal
5977a3d8a6
regression test viz failure when there's no tracked context ( #8297 )
...
* regression test viz failure when there's no tracked context
* test inner rewrite locations, keep notes
2024-12-17 23:23:27 +02:00
nimlgen
777d2aec05
metal profiler + cpu_profile ( #8291 )
...
* metal + cpu_profile
* gpt example
* linter + revert gpt2 for now
* a bit of readme
* linter
* unrelated
* tests
* linter
* b
2024-12-18 00:06:56 +03:00
geohotstan
32c995a5da
move to_python_const from onnx_ops to onnx ( #8158 )
...
* move to_python_const out
* move more over
* try deleting alternative gather implementation
* Revert "try deleting alternative gather implementation"
This reverts commit d46b30b717 .
* add types to onnx ops
* better debug msg
* improve some com.microsoft too
---------
Co-authored-by: chenyu <chenyu@fastmail.com >
2024-12-17 14:12:06 -05:00
George Hotz
21b085b8ed
add device UOp [pr] ( #8290 )
2024-12-17 09:11:51 -08:00
nimlgen
af87e4b53c
viz profiler ( #8287 )
...
* only hcq
* fix get_metadata
* linter
* oops
* tiny
* linter
* time
* print pm
* hmm
* nits
2024-12-17 20:00:53 +03:00
George Hotz
0794af97db
consts do not realize
2024-12-17 08:53:53 -08:00