mirror of https://github.com/commaai/tinygrad.git
add timing to fuzz_linearizer (#7056)
and applied smaller FUZZ_MAX_SIZE. this is getting quite slow in CI
This commit is contained in:
parent
0d2462cbdf
commit
fbaab30fe3
|
@ -345,7 +345,7 @@ jobs:
|
||||||
- name: Test Beam Search
|
- name: Test Beam Search
|
||||||
run: PYTHONPATH="." METAL=1 IGNORE_BEAM_CACHE=1 python3 -m pytest extra/optimization/test_beam_search.py
|
run: PYTHONPATH="." METAL=1 IGNORE_BEAM_CACHE=1 python3 -m pytest extra/optimization/test_beam_search.py
|
||||||
- name: Fuzz Test linearizer
|
- name: Fuzz Test linearizer
|
||||||
run: PYTHONPATH="." METAL=1 FUZZ_ALL_ACTIONS=1 DEPTH=2 FUZZ_N=24 FUZZ_MAX_SIZE=10000000 python test/external/fuzz_linearizer.py
|
run: PYTHONPATH="." METAL=1 FUZZ_ALL_ACTIONS=1 DEPTH=2 FUZZ_N=24 FUZZ_MAX_SIZE=1000000 python test/external/fuzz_linearizer.py
|
||||||
- name: Fuzz Test models schedule
|
- name: Fuzz Test models schedule
|
||||||
run: FUZZ_SCHEDULE=1 FUZZ_SCHEDULE_MAX_PATHS=5 python -m pytest test/models/test_train.py test/models/test_end2end.py
|
run: FUZZ_SCHEDULE=1 FUZZ_SCHEDULE_MAX_PATHS=5 python -m pytest test/models/test_train.py test/models/test_end2end.py
|
||||||
- name: Run TRANSCENDENTAL math
|
- name: Run TRANSCENDENTAL math
|
||||||
|
|
|
@ -10,7 +10,7 @@ from tinygrad.codegen.kernel import Kernel
|
||||||
from tinygrad.codegen.kernel import Opt, OptOps
|
from tinygrad.codegen.kernel import Opt, OptOps
|
||||||
from tinygrad.engine.search import get_kernel_actions, bufs_from_lin
|
from tinygrad.engine.search import get_kernel_actions, bufs_from_lin
|
||||||
from tinygrad.engine.realize import CompiledRunner
|
from tinygrad.engine.realize import CompiledRunner
|
||||||
from tinygrad.helpers import getenv, from_mv, prod, colored, Context, DEBUG
|
from tinygrad.helpers import getenv, from_mv, prod, colored, Context, DEBUG, Timing
|
||||||
from tinygrad.ops import UnaryOps, UOp, UOps
|
from tinygrad.ops import UnaryOps, UOp, UOps
|
||||||
from test.helpers import is_dtype_supported
|
from test.helpers import is_dtype_supported
|
||||||
|
|
||||||
|
@ -231,9 +231,8 @@ if __name__ == "__main__":
|
||||||
print("skipping kernel due to not supported dtype")
|
print("skipping kernel due to not supported dtype")
|
||||||
continue
|
continue
|
||||||
|
|
||||||
print(f"testing ast {i}")
|
with Timing(f"tested ast {i}: "):
|
||||||
tested += 1
|
tested += 1
|
||||||
|
|
||||||
fuzz_failures = fuzz_linearizer(lin, rtol=args.rtol, atol=args.atol)
|
fuzz_failures = fuzz_linearizer(lin, rtol=args.rtol, atol=args.atol)
|
||||||
if fuzz_failures: failed_ids.append(i)
|
if fuzz_failures: failed_ids.append(i)
|
||||||
for k, v in fuzz_failures.items():
|
for k, v in fuzz_failures.items():
|
||||||
|
|
Loading…
Reference in New Issue