Fix for the batch dim in the quantized matmul example. (#2073)

* Fix for the batch dim in the quantized matmul example.

* Enable more tests on cuda.

* Add a test for qmm with a batch.

* Fix the zeros-dim test on metal.
This commit is contained in:
Laurent Mazare
2024-04-15 20:00:28 +02:00
committed by GitHub
parent af955f260c
commit f135b7963d
3 changed files with 38 additions and 38 deletions

View File

@ -283,5 +283,5 @@ impl MetalDevice {
}
fn buf_size(size: NSUInteger) -> NSUInteger {
(size - 1).next_power_of_two() as NSUInteger
size.saturating_sub(1).next_power_of_two() as NSUInteger
}