From d26ef2738dd4b567af4c0f999e5d63b6357d2f12 Mon Sep 17 00:00:00 2001 From: Alejandro Saucedo Date: Fri, 5 Mar 2021 08:35:21 +0000 Subject: [PATCH] Added the raedme exampel --- README.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 313fcc138..301572a09 100644 --- a/README.md +++ b/README.md @@ -78,8 +78,9 @@ void kompute(const std::string& shader) { mgr.sequence() ->record(params) ->record(algorithm) // Binds default push consts + ->eval() // Evaluates the two recorded operations ->record(algorithm, pushConstsB) // Overrides push consts - ->eval(); + ->eval(); // Evaluates only last recorded operation // 5. Sync results from the GPU asynchronously sq = mgr.sequence() @@ -164,8 +165,9 @@ def kompute(shader): (mgr.sequence() .record(kp.OpTensorSyncDevice(params)) .record(kp.OpAlgoDispatch(algo)) # Binds default push consts provided + .eval() # evaluates the two recorded ops .record(kp.OpAlgoDispatch(algo, push_consts_b)) # Overrides push consts - .eval()) + .eval()) # evaluates only the last recorded op # 5. Sync results from the GPU asynchronously sq = mgr.sequence()