v4.3 update. (#2709)
* v4.3 update. * Update the cute_dsl_api changelog's doc link * Update version to 4.3.0 * Update the example link * Update doc to encourage user to install DSL from requirements.txt --------- Co-authored-by: Larry Wu <larwu@nvidia.com>
This commit is contained in:
@@ -169,7 +169,7 @@ def tensor_op_gemm_wrapper(
|
||||
acc_dtype: Type[cutlass.Numeric],
|
||||
atom_layout_mnk: cutlass.Constexpr[tuple[int, int, int]],
|
||||
):
|
||||
print(f"\n[DSL INFO] Input Parameters:")
|
||||
print("\n[DSL INFO] Input Parameters:")
|
||||
print(f"[DSL INFO] mnkl: {mnkl}")
|
||||
print(f"[DSL INFO] buffer_a: {buffer_a}")
|
||||
print(f"[DSL INFO] buffer_b: {buffer_b}")
|
||||
@@ -181,7 +181,7 @@ def tensor_op_gemm_wrapper(
|
||||
mB = buffer_b.to_tensor(cute.select(mnkl, mode=[3, 1, 2]))
|
||||
mC = buffer_c.to_tensor(cute.select(mnkl, mode=[3, 0, 1]))
|
||||
|
||||
print(f"\n[DSL INFO] Created Tensors:")
|
||||
print("\n[DSL INFO] Created Tensors:")
|
||||
print(f"[DSL INFO] mA = {mA}")
|
||||
print(f"[DSL INFO] mB = {mB}")
|
||||
print(f"[DSL INFO] mC = {mC}")
|
||||
@@ -192,7 +192,7 @@ def tensor_op_gemm_wrapper(
|
||||
acc_dtype,
|
||||
atom_layout_mnk,
|
||||
)
|
||||
print(f"\n[DSL INFO] Created TensorOpGemm instance")
|
||||
print("\n[DSL INFO] Created TensorOpGemm instance")
|
||||
print(f"[DSL INFO] Input dtype: {buffer_a.ptr.value_type}")
|
||||
print(f"[DSL INFO] Output dtype: {buffer_c.ptr.value_type}")
|
||||
print(f"[DSL INFO] Accumulation dtype: {acc_dtype}")
|
||||
@@ -200,11 +200,11 @@ def tensor_op_gemm_wrapper(
|
||||
|
||||
# No need to compile inside jit function
|
||||
tensor_op_gemm(mA, mB, mC)
|
||||
print(f"\n[DSL INFO] Executed TensorOpGemm")
|
||||
print("\n[DSL INFO] Executed TensorOpGemm")
|
||||
|
||||
|
||||
def run_tensor_op_gemm_wrapper(mnkl: Tuple[int, int, int, int]):
|
||||
print(f"\nRunning TensorOpGemm test with:")
|
||||
print("\nRunning TensorOpGemm test with:")
|
||||
print(f"Tensor dimensions: {mnkl}")
|
||||
|
||||
ab_dtype = cutlass.Float16
|
||||
@@ -220,7 +220,7 @@ def run_tensor_op_gemm_wrapper(mnkl: Tuple[int, int, int, int]):
|
||||
mnkl[3], mnkl[0], mnkl[1], dtype=torch_dtype(c_dtype), device="cuda"
|
||||
)
|
||||
|
||||
print(f"Input tensor shapes:")
|
||||
print("Input tensor shapes:")
|
||||
print(f"a: {a.shape}, dtype: {a.dtype}")
|
||||
print(f"b: {b.shape}, dtype: {b.dtype}")
|
||||
print(f"c: {c.shape}, dtype: {c.dtype}\n")
|
||||
@@ -251,7 +251,7 @@ def run_tensor_op_gemm_wrapper(mnkl: Tuple[int, int, int, int]):
|
||||
|
||||
ref = torch.einsum("lmk,lnk->lmn", a, b)
|
||||
torch.testing.assert_close(c, ref, atol=1e-05, rtol=1e-05)
|
||||
print(f"\n[DSL INFO] Results verified successfully!")
|
||||
print("\n[DSL INFO] Results verified successfully!")
|
||||
print(f"First few elements of result: \n{c[:3, :3, :3]}")
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user