George Hotz
01f39b19dc
move to shapetracker.py
2023-03-11 07:50:07 -08:00
George Hotz
f3ac52aee8
Mypyc ( #680 )
...
* building shapetracker
* default ENABLE_METHOD_CACHE
* symbolic compiles
* improve types
* tensor compiles
* oops, that's a bug
* best of both worlds
* find legit typing bugs
* pad2d can take list or tuple
* sub 200ms when compiled
2023-03-11 07:33:30 -08:00
George Hotz
d7cb8e3e56
multithreaded fake_torch_load_zipped
2023-03-10 19:16:27 -08:00
George Hotz
b1206bcb18
third try at torch loading ( #677 )
...
* third try at torch loading
* numpy fixed
* fix enet compile
* load_single_weight supports empty weights
* oops, CPU wasn't the default
* so many bugs
2023-03-10 19:11:29 -08:00
George Hotz
4780f9a6df
llama runs (slowly) in master
2023-03-10 17:36:51 -08:00
George Hotz
1826ff6b89
dtypes nice and clean ( #673 )
...
* add dtype class
* dtypes
* buffers are lazy
* dtype is tracked by lazybuffer and GenericShape
* fix types in llvm
* llvm store
* dtype tests
* fix tests maybe
* fix flop counter
* fix CI
* CI fix and check format
* fix dtype and dtype check
* fix custom test
* fix test graph
2023-03-10 16:56:07 -08:00
George Hotz
d26345595d
more llama stuff
2023-03-10 10:48:10 -08:00
George Hotz
1a039306d2
good changes from llama branch ( #671 )
...
* good changes from llama
* transpose behavior changed
2023-03-09 20:51:22 -08:00
George Hotz
d8dda2af3a
openpilot fixups
2023-03-06 14:14:44 -08:00
George Hotz
a77d792aff
Codegen gpu cleanups ( #640 )
...
* cleanups
* fixups
* handle pre upcasted global buffers
* early is just required
* delete junk from hand coded opt
* implicit upcast_in_mid_reduce
* speedup
* fix exec w validhacks
* reorder opt
* only need to check the output for that
* return total runtime from kernels if debugging
2023-03-04 15:31:51 -08:00
Patrick Geneva
117111825c
Fix windows file permission error ( #634 )
2023-03-04 09:23:55 -08:00
George Hotz
528cb3b3b9
fix ast test
2023-03-04 07:49:25 -08:00
George Hotz
893f136fe0
lines from helpers
2023-03-03 23:07:46 -08:00
George Hotz
c53efb3635
optimize for CL ( #633 )
...
* required opt
* simplify
* works
* shift_to_last
* required is fine
* print shape in colored
* better shape
* args was wrong
* debugs
* fix empty shape
* colored shape printer
2023-03-03 22:00:09 -08:00
Diogo
52204a7b88
adding comparison operators ( #616 )
...
* Less, LessOrEqual, Greater, GreaterOrEqual, Equal
* lint fix
* using built in functions
* overriding __eq__ breaks things
* backwards pass for less - foward only tests
* one other spot
* removing backwards for comparison ops to match pytorch
* raise runtime error
* more tests for comparison ops
* fixed the lineup
* added number upcast tests
2023-03-02 08:10:44 -08:00
George Hotz
d062cc82b8
put restrict back
2023-03-01 21:34:45 -08:00
George Hotz
bfcec234a2
Refactor ASTs ( #622 )
...
* ugh worst branch name
* compiler refactor continues
* scc -> cloc
* buf -> _buf
* finish _buf, and program -> runtime
* gpu is still working, clang isn't
* clang in new style
* ops_metal
* something broke it
* improve metal
* clean up tons of cl crap
* hack fix sync
* cleaner gpu
* gpu metal clang
* cleanups
* minor refactor
* GPUCodegen
* fix up LLVM
* blind CUDA refactor
* codegen / runtime
* keep ops naming
* linter passes
* woah, llvm was allocing 4x what it needed to
* bugfixes
* fix openpilot compiler
* fix compile_efficientnet
* method cache should fix tests
* deal with duped functions
2023-03-01 18:57:29 -08:00
George Hotz
7e6edfbc64
unbreak onnx conv padding
2023-02-28 13:55:03 -08:00
George Hotz
7d556ca7e0
avg/max pool work in N-D
2023-02-28 13:38:27 -08:00
George Hotz
d584bae5c0
fine, openpilot can have 197 kernels
2023-02-27 11:48:36 -08:00
George Hotz
7b999add1d
all onnx model tests pass
2023-02-27 11:22:45 -08:00
George Hotz
652d48ccec
onnx : openpilot expand issue was fixed yesterday. remove hack
2023-02-27 11:04:42 -08:00
George Hotz
9d6b63f043
add ConstantOfShape
2023-02-27 10:57:50 -08:00
George Hotz
082134952b
CastLike works with one type hack
2023-02-27 10:51:26 -08:00
Jacky Lee
1ffe8d68d5
Add more onnx ops ( #615 )
...
* Add Celu
* Add thresholded relu
* Add softsign
2023-02-27 10:43:41 -08:00
George Hotz
643e8b0388
fix tests, test bn evaluate too
2023-02-27 10:39:47 -08:00
Diogo
07e643431c
added onnx group norm ( #614 )
2023-02-27 08:11:01 -08:00
Diogo
e68fa18c9b
layer norm support in onnx ( #607 )
...
* layer norm support
* switched to 1e-05
2023-02-26 22:04:02 -08:00
George Hotz
3a2a500e90
prevent race condition, external yolo test for now
2023-02-26 17:08:24 -08:00
Sohaib
71ae6e5605
fix: avgpool without counting padding ( #605 )
2023-02-26 07:13:00 -08:00
George Hotz
a8de233e12
only div, no reciprocal ( #601 )
...
* only div, no reciprocal
* remove reciprocal
* fix pad shuffling
2023-02-25 09:35:03 -08:00
Sohaib
d581a99d90
onnx: lrn ( #602 )
...
Co-authored-by: Sohaib Errabii <errabii.sohaib@gmail.com >
2023-02-25 09:24:53 -08:00
voidz
94bec40110
moved extras/jit.py -> tinygrad/jit.py ( #599 )
...
* moved extras/jit.py to tinygrad/jit.py
* fixed indent
* removed tinygrad.helpers.DEBUG from jit.py
2023-02-25 08:32:33 -08:00
George Hotz
2c5e13a513
Reluless ( #600 )
...
* replace relu for maximum
* fix for other backend
* clean up RELU and GT0
* tests for maximum
* had to clean that up
* why reverse a maximum?
2023-02-25 01:21:16 -08:00
George Hotz
176ad29974
retain support for old onnx
2023-02-24 22:29:54 -08:00
George Hotz
da5643d024
rest of tests shouid be made to pass
2023-02-24 12:52:23 -08:00
George Hotz
85452fbaf3
onnx 58/109/208
2023-02-24 12:19:05 -08:00
George Hotz
e8a153e4e9
onnx : add a whole bunch of ops
2023-02-24 12:00:03 -08:00
George Hotz
f2486a7248
more onnx ops
2023-02-24 10:55:58 -08:00
George Hotz
4d0a3dd653
openpilot expand is bugged
2023-02-24 10:25:59 -08:00
George Hotz
2e56a4793e
rename log_softmax, support dim, fix onnx Softmax
2023-02-24 10:11:24 -08:00
George Hotz
5cdfeffe2c
fix shape test
2023-02-24 09:36:32 -08:00
George Hotz
3becefa218
fix onnx tests
2023-02-24 09:27:18 -08:00
George Hotz
e263c0c628
onnx : another model test is passing
2023-02-24 09:22:58 -08:00
George Hotz
d3feea302d
much cleaner way to write onnx ops
2023-02-24 08:46:28 -08:00
George Hotz
f6d946853c
more bugfixes
2023-02-24 00:21:29 -08:00
George Hotz
b1b2d8f440
onnx : some op tests working
2023-02-23 23:58:13 -08:00
George Hotz
b287b1d529
fix yolov8 to get to ConvTranspose
2023-02-23 22:46:48 -08:00
George Hotz
2d59b25ead
onnx backend test : enable only the model tests
2023-02-23 22:36:26 -08:00
George Hotz
d8b6f241f1
external_test_onnx_backend
2023-02-23 21:55:07 -08:00