Skip to content

Commit c936387

Browse files
author
morelos
committed
Update base for Update on "[ET-VK][Ops] choose_qparams ops skeleton test framework"
Skeleton framework that is needed to build out the choose_qparams.tensor and choose_qparams_per_token_asymmetric.default operators based on cpu implementation Differential Revision: [D76436870](https://our.internmc.facebook.com/intern/diff/D76436870/) [ghstack-poisoned]
1 parent 34a6dce commit c936387

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

backends/vulkan/test/op_tests/utils/gen_benchmark_vk.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,8 @@ def generate_benchmark_fixture(self) -> str:
177177
178178
vkapi::ScalarType from_at_scalartype(c10::ScalarType at_scalartype) {{
179179
switch (at_scalartype) {{
180+
case c10::kDouble:
181+
return vkapi::kDouble;
180182
case c10::kFloat:
181183
return vkapi::kFloat;
182184
case c10::kHalf:
@@ -187,6 +189,8 @@ def generate_benchmark_fixture(self) -> str:
187189
return vkapi::kInt;
188190
case c10::kChar:
189191
return vkapi::kChar;
192+
case c10::kBool:
193+
return vkapi::kBool;
190194
default:
191195
VK_THROW("Unsupported at::ScalarType!");
192196
}}

backends/vulkan/test/op_tests/utils/gen_correctness_vk.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -119,15 +119,11 @@ def gen_parameterization(self) -> str:
119119
case c10::kInt:
120120
return vkapi::kInt;
121121
case c10::kLong:
122-
return vkapi::kLong;
123-
case c10::kShort:
124-
return vkapi::kShort;
122+
return vkapi::kInt;
125123
case c10::kChar:
126124
return vkapi::kChar;
127125
case c10::kBool:
128126
return vkapi::kBool;
129-
case c10::kByte:
130-
return vkapi::kByte;
131127
default:
132128
VK_THROW("Unsupported at::ScalarType!");
133129
}

0 commit comments

Comments
 (0)